@zeniai/web-cockpit-ui 1.14.95-prod → 1.14.96-dev

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 (275) hide show
  1. package/dist/assets/{ACHDetailsPage-OhfwzmDP-CUPlHlS1.js → ACHDetailsPage-BRWOdhMx-lCkplz0-.js} +1 -1
  2. package/dist/assets/{AIPerformancePage-9OxanlvK-Bk_qTUs7.js → AIPerformancePage-4v4Fkm9f-BqYLGo1s.js} +1 -1
  3. package/dist/assets/AccountInfoPage-Ca_vKG58-pmVk2hiY.js +18 -0
  4. package/dist/assets/{AccountInfoPageContent-Bu-ZFVKf-BazFs_cA.js → AccountInfoPageContent-Dv1IPcdF-ChZIyLOA.js} +1 -1
  5. package/dist/assets/{AccountLockedInfoModal-BqLkGmTA-Bi36nE_K.js → AccountLockedInfoModal-CEk5d9hq-BU7zCzNG.js} +1 -1
  6. package/dist/assets/{AccountReconDetailsDrawerPage-CyQ13mJl-CAv47_Mb.js → AccountReconDetailsDrawerPage-DYKjrPwN-BReGAKzb.js} +4 -4
  7. package/dist/assets/{AccountRow-pJ59k4-J-BFmtHL3N.js → AccountRow-BM3xLbeh-DwBWMEiu.js} +1 -1
  8. package/dist/assets/{AccountsPromoCardStack-Ukdm1VDj-Dh0SxjJq.js → AccountsPromoCardStack-CTkwARBJ-Dqd8qLkS.js} +1 -1
  9. package/dist/assets/{AddAddressForCardDrawer-CZ9kZK-_-7zBs11LO.js → AddAddressForCardDrawer-DfOyebHX-BnGN6mbi.js} +1 -1
  10. package/dist/assets/{AddToWalletPage-Bc0GY8mw-CwBrjgnk.js → AddToWalletPage-OJBvAKUj-CKSRCSe6.js} +1 -1
  11. package/dist/assets/{AgingReportsPage-Cam_Ox67-DaZT71t6.js → AgingReportsPage-n-UKn3Ei-CfeYGvlE.js} +1 -1
  12. package/dist/assets/{AllUserItems-CEBWfFac-DPOuER5U.js → AllUserItems-BsvKEVcx-Ckn7N6Nq.js} +1 -1
  13. package/dist/assets/{ApAgingDetailPage-uy2AK45a-JhYM22T9.js → ApAgingDetailPage-Duu2uAEr-CuSndO2U.js} +2 -2
  14. package/dist/assets/{AppBasePage-BBolfeYB-CAoueBdK.js → AppBasePage-DoCF494Z-BPFvSn_P.js} +1 -1
  15. package/dist/assets/{AppDrawerContent-Df0b3OK2-CKxXRIrV.js → AppDrawerContent-DM1t0oLS-DX8gDdRy.js} +1 -1
  16. package/dist/assets/{ApprovalRulesSettingsPage-ChI1Wnf--DELVy5mB.js → ApprovalRulesSettingsPage-GZCo6_i2-ClrA48La.js} +1 -1
  17. package/dist/assets/{ArAgingChart-PIQ_BFy4-YcKcd549.js → ArAgingChart-CsFDVdeO-C-RKv3GM.js} +1 -1
  18. package/dist/assets/{ArAgingDetailPage-DpdUPb6--BJoxfTPP.js → ArAgingDetailPage-CaOr6vAU-Dju9MqE9.js} +1 -1
  19. package/dist/assets/{AttachmentView-mC246Bpw-CT1OWA3c.js → AttachmentView-B0d42oAf-CFenLcCO.js} +1 -1
  20. package/dist/assets/{BankAccountSection-DehqZ04x-BJbbHUH9.js → BankAccountSection-Bgdk93V0-DEu58Lvd.js} +1 -1
  21. package/dist/assets/{BankAccountWarningSection-WkczfI75-p--soGkR.js → BankAccountWarningSection-DMRmF2yM-Bdqe05tT.js} +1 -1
  22. package/dist/assets/{BankConnectionsSettingsPage-CCEKqkfW-CxNmb7UL.js → BankConnectionsSettingsPage-BpwKq93l-yFMdYswL.js} +1 -1
  23. package/dist/assets/{BillDetailPage-DA1djKtd-CT6NN5ei.js → BillDetailPage-BG7FhHEq-CI73yv-V.js} +1 -1
  24. package/dist/assets/{BillPayApprovalRuleDetailPage-CLkMLaIk-DBi0iP3G.js → BillPayApprovalRuleDetailPage-BAK1Gfko-DXu3RSd8.js} +1 -1
  25. package/dist/assets/{BillPayApprovalRulesPage-CZnYZ8cn-D3dv90TB.js → BillPayApprovalRulesPage-DiCNUU-G-CN0GV9DL.js} +1 -1
  26. package/dist/assets/{BillPayPromoPage-M3bRYehy-Bpwpx-W-.js → BillPayPromoPage-aGKOv8Ur-59DxEGOU.js} +1 -1
  27. package/dist/assets/{BillPaySetUpPage-CJyPhrld-BW-k6Cq5.js → BillPaySetUpPage-DRCjyEfB-CkG4ce3e.js} +1 -1
  28. package/dist/assets/{BillingSettingsPage-CQngU3lq-DrWAQyUl.js → BillingSettingsPage-CdYb74V7-D26O7kQD.js} +1 -1
  29. package/dist/assets/{BillsBulkReviewDrawerPage-DlAOz-SY-hKyZsi63.js → BillsBulkReviewDrawerPage-D8EGfY5P-BpW4NDmq.js} +1 -1
  30. package/dist/assets/{BoxItem-Cb4_ZBkK-xDHkx3mk.js → BoxItem-WOrvBzns-DD4R649W.js} +1 -1
  31. package/dist/assets/{BusinessVerificationPage-D7btikKT-BPUDQBNI.js → BusinessVerificationPage-CbqJIVpz-BiQu25FO.js} +1 -1
  32. package/dist/assets/{CardNumberSubText-DQ6T2OKm-CtS54mYI.js → CardNumberSubText-DBOH0_yP-Be1TwMNo.js} +1 -1
  33. package/dist/assets/{CashbackDetailPage-ToN5ueBt-BpzeYowT.js → CashbackDetailPage-D-kXy6LW-DDN4yxLo.js} +1 -1
  34. package/dist/assets/{ChargeCardDetailPage-BYNjlLQX-smovJQ3p.js → ChargeCardDetailPage-BQnJsfn5-D6Qm3_DY.js} +21 -21
  35. package/dist/assets/{ChargeCardListPage-CTG6bNbA-DN4yg5h2.js → ChargeCardListPage-130ILwkr-xWvWRUI-.js} +1 -1
  36. package/dist/assets/{ChargeCardListTable-BRAAvmWW-BCMrKmLw.js → ChargeCardListTable-EGkwcy7i-Gk77wXoS.js} +1 -1
  37. package/dist/assets/{ChargeCardPromoPage-xhEvT_sU-D7VUd9Kw.js → ChargeCardPromoPage-BwqrXrY--B5or9kQv.js} +1 -1
  38. package/dist/assets/{ChargeCardSetupPage-Be89R3A7-BvY-IfNf.js → ChargeCardSetupPage-DRzB7Rt4-SAR76aeK.js} +1 -1
  39. package/dist/assets/{ChargeCardStatementsPage-CFNCOiLr-DDhNhCxi.js → ChargeCardStatementsPage-C3NxKjmB-Bqdh-I41.js} +1 -1
  40. package/dist/assets/{CheckDepositDrawerPage-Cy0NVgKc-D8fpunhe.js → CheckDepositDrawerPage-ClxKj2js-BOLtAKO1.js} +1 -1
  41. package/dist/assets/{CollapsableReportTable-CrR91Kpi-DnJZSUDi.js → CollapsableReportTable-xkNXkjfh-CuBOzrbM.js} +1 -1
  42. package/dist/assets/{CompanyOfficerDetailsSection-4FjXy6T9-CStOu48U.js → CompanyOfficerDetailsSection-BtUBatbQ-CS2katNY.js} +1 -1
  43. package/dist/assets/{CompanyPassportCard-Bv6Aws7i-dO40WjmK.js → CompanyPassportCard-BOxM716U-DxvRrHgL.js} +2 -2
  44. package/dist/assets/{CompanyPassportPage-DRhnOgdd-BOnCftvv.js → CompanyPassportPage-DzE7sm8S-ZZY5euQN.js} +13 -13
  45. package/dist/assets/{CompleteProfile-CdVQdaB0-CLoHBDqw.js → CompleteProfile-BjGSPASa-Bfp0I59Q.js} +1 -1
  46. package/dist/assets/{ConfettiBurst-Cygb8bhF-CpMHcY5K.js → ConfettiBurst-1rYKpbAj-DHWZb_DF.js} +1 -1
  47. package/dist/assets/{CreateOrEditVendorPage-_jZBL7C2-BT5eOx4Y.js → CreateOrEditVendorPage-WQeDCj-E-ZLNX3FBX.js} +1 -1
  48. package/dist/assets/{CreditCardPaymentDrawerPage-CWF47Q9G-lJ5s9KFG.js → CreditCardPaymentDrawerPage-Q12y6HMX-CRUPlZFr.js} +101 -101
  49. package/dist/assets/{CurrencySelectField-ppkSKTpN-BC31P_0q.js → CurrencySelectField-AjAWhg6e-h8iODRHM.js} +1 -1
  50. package/dist/assets/{CustomerOnboardingActivationPage-DbaC9Uy1-BzvBGrNi.js → CustomerOnboardingActivationPage-BJhw-PvI-DfxjHeaa.js} +1 -1
  51. package/dist/assets/CustomerOnboardingContainerPage-C9radmIS-D7esgWyy.js +1 -0
  52. package/dist/assets/{CustomerOnboardingDetailPageSkeleton-5PeyznvM-B8Mhh2k2.js → CustomerOnboardingDetailPageSkeleton-B0WzN1Sx-A_sh3_b9.js} +1 -1
  53. package/dist/assets/{CustomerOnboardingNoStepsPage-CWvaI2vY-BkjuYe-o.js → CustomerOnboardingNoStepsPage-CNni6chX-DEHNST6I.js} +1 -1
  54. package/dist/assets/{CustomerOnboardingPage-DWmMR5Ke-C-0daaby.js → CustomerOnboardingPage-CvN9Jrdy-BbxW7een.js} +4 -4
  55. package/dist/assets/CustomerOnboardingProductSuitePage-CZkX9ur7-CVf3ueoc.js +202 -0
  56. package/dist/assets/{Dashboard-CJSMYKO7-S41CzF6L.js → Dashboard-_o0Ftdv8-B4FMEqu7.js} +1 -1
  57. package/dist/assets/{DashboardReportPage-CcY-7-W_-DdmW4wbH.js → DashboardReportPage-Cu5wqWkj-BjOABFkU.js} +1 -1
  58. package/dist/assets/{DashboardSidebarBackgroundAnimation-D3qI_q0a-iCovmnlW.js → DashboardSidebarBackgroundAnimation-Bl8Ss6Gf-1uwRQXQg.js} +1 -1
  59. package/dist/assets/{DepositAccTransactionItem-BpbS0SRE-NmcXTIJb.js → DepositAccTransactionItem-BOPK7-7P-CmYSzV4w.js} +1 -1
  60. package/dist/assets/{DepositAccTransactionListPage-C1EuUbFg-CI8oEH7-.js → DepositAccTransactionListPage-oj9tntbI-CMORNmGB.js} +1 -1
  61. package/dist/assets/{DomesticWireDetailsPage-DTrY_uHQ-CknHfbIJ.js → DomesticWireDetailsPage-FGdEilUB-BIDfGIPL.js} +1 -1
  62. package/dist/assets/{DownloadOverlay-gRH0FIa6-e2777Hoq.js → DownloadOverlay-c57lEf_V-BH-A5hnp.js} +1 -1
  63. package/dist/assets/{DrawerPage-gsfboWa--D8_bnW1E.js → DrawerPage-inbhWwND-BaLC0Hdr.js} +1 -1
  64. package/dist/assets/{EditPeoplePage-D3GenIke-s4IX6oMr.js → EditPeoplePage-DJthuIP4-Ccr8TbIs.js} +1 -1
  65. package/dist/assets/{EditReimbursementDetailPage-CC4JbXua-Dip_aVtM.js → EditReimbursementDetailPage-Bt7XKq5h-BcSPiJVn.js} +1 -1
  66. package/dist/assets/{EntityDetailPage-dZ-H_-kO-B3yxSec8.js → EntityDetailPage-DbTiF9Hs-DOWN_WQU.js} +1 -1
  67. package/dist/assets/{EntitySummarySection-BaSzuw3T-DJX_ZTYK.js → EntitySummarySection-CHgrPo86-C_DZGpt7.js} +1 -1
  68. package/dist/assets/{ExpenseAutomationOverviewPage-CtBVIXza-8HVAkTgZ.js → ExpenseAutomationOverviewPage-QZT_UFXf-Q6Yezq8W.js} +1 -1
  69. package/dist/assets/{ExpenseAutomationPage-BByZfMUo-Bp9htN-p.js → ExpenseAutomationPage-Y7V_Z8rd-Nz-tHH0P.js} +36 -36
  70. package/dist/assets/{ExpressPayPage-Dx4Cc9w2-5nFukiXm.js → ExpressPayPage-CIp_R6ZQ-SvQXytoV.js} +1 -1
  71. package/dist/assets/{FeaturePreviewPage-Us5W5Wo9-CTfS268U.js → FeaturePreviewPage-qsUO3mUu-CQPzEAZz.js} +1 -1
  72. package/dist/assets/{FollowStepsSection-DDXRZdXi-BkUwTVWQ.js → FollowStepsSection-ebmR-eLP-CCCIBkct.js} +1 -1
  73. package/dist/assets/{GlobalReviewListPage-Ou4B6O28-Cj-vrRvJ.js → GlobalReviewListPage-9V-xoqvs-O56nx8QU.js} +1 -1
  74. package/dist/assets/{InformationCardStack-DEj81xCg-BlO4gF2p.js → InformationCardStack-DnB7TmOk-BJQfDBIj.js} +1 -1
  75. package/dist/assets/{InsightsCardStack-BSigEuRs-DrhT2GS8.js → InsightsCardStack-BBczCYEz-CM9k6Dqk.js} +5 -5
  76. package/dist/assets/{InsightsSection-BrjpMz4X-DExiKNju.js → InsightsSection-BTXj5WUe-BehAISJe.js} +5 -5
  77. package/dist/assets/{IntegrationsSettingsPage-BEBtsJ8z-BJ7jcJB8.js → IntegrationsSettingsPage-CByj2tO4-zF-3f5Vb.js} +2 -2
  78. package/dist/assets/{InternationalWireSwiftDetailsPage-DqTA5UPe-CmHr1otA.js → InternationalWireSwiftDetailsPage-4-pl1ozv-BL59ObmT.js} +4 -4
  79. package/dist/assets/{InternationalWireVerificationPage-CGLyTJOX-CNAH8NOm.js → InternationalWireVerificationPage-kIajgPZt-Cim3HMUE.js} +1 -1
  80. package/dist/assets/{InviteFormPage-CHZVhrof-Ctwgv0tR.js → InviteFormPage-XsnZcAvb-F0roB33R.js} +1 -1
  81. package/dist/assets/{InvitePageListView-B0aN2fz0-C_ebzQNV.js → InvitePageListView-HfsehyxK-ADhebkRn.js} +1 -1
  82. package/dist/assets/{InvitePeoplePage-DLPupvdi-DD0j_YWt.js → InvitePeoplePage-DrBtwpMH-D70ug1bL.js} +1 -1
  83. package/dist/assets/{InvoiceUploadSection-COIpUGEB-wLZvdMHG.js → InvoiceUploadSection-DPd4VmqZ-BLpPijn4.js} +1 -1
  84. package/dist/assets/{IssueChargeCardPage-6LWMwuaq-BfBIAKq3.js → IssueChargeCardPage-xbfFhV0O-D87TKikm.js} +1 -1
  85. package/dist/assets/{LabeledAddressValue-BOPQCQtK-glMgUt5i.js → LabeledAddressValue-CB_KH7v5-DhXcxbM6.js} +1 -1
  86. package/dist/assets/{LabeledAddressValueField-DxybAWPO-DIu3ggxx.js → LabeledAddressValueField-Bt41wdNQ-CdN5suyF.js} +1 -1
  87. package/dist/assets/{LabeledControlledCheckBoxField-BSciMX7_-DpOi6Pih.js → LabeledControlledCheckBoxField-Btw_zwzy-I7spg7Dx.js} +1 -1
  88. package/dist/assets/{LabeledCreatableSingleSelectField-q23ARfG8-CRQFWLML.js → LabeledCreatableSingleSelectField-fycRE7PX-BLM_4t-_.js} +1 -1
  89. package/dist/assets/{LabeledDocumentField-Icg5_obX-DhGSKEqK.js → LabeledDocumentField-C73vQNgq-xVgwP02Y.js} +1 -1
  90. package/dist/assets/{LabeledDropDownFormattedTextField-BiJOzT5B-urCKQV5c.js → LabeledDropDownFormattedTextField-DGb_bDyp-DbOxXrX_.js} +1 -1
  91. package/dist/assets/{LabeledText-Tn7u-Ek3-DOKeDUtN.js → LabeledText-yhm8qxrA-B5O06POj.js} +1 -1
  92. package/dist/assets/{LabeledUserSingleSelectWithSubtitlesField-B_MWazM_-Deht3VPb.js → LabeledUserSingleSelectWithSubtitlesField-CgA4UPJh-BYzGVtZI.js} +1 -1
  93. package/dist/assets/{LabeledZeniRolesDropDownField-DyCxNVQD-CDJPm5Uy.js → LabeledZeniRolesDropDownField-DGkU72cd-iMLOxXqS.js} +1 -1
  94. package/dist/assets/{LinkJETransactionPage-NXVaaeQn-Dc1IDF_5.js → LinkJETransactionPage-C0onrP5t-DohOtG77.js} +1 -1
  95. package/dist/assets/{LockCardPage-DFFQF_XE-ZW7dAknw.js → LockCardPage-DaVzuRMw-C59qINIA.js} +1 -1
  96. package/dist/assets/{LowBalancePopup-T5Ms2v-E-DO0_djob.js → LowBalancePopup-Dd9HLWlh-qIEjt8fN.js} +1 -1
  97. package/dist/assets/MagicLinkACHDetailsPage-Cpde2XoD-JoGWlKNi.js +1 -0
  98. package/dist/assets/MagicLinkDomesticWireDetailsPage-DQYH52_8-Clx_7zaI.js +1 -0
  99. package/dist/assets/MagicLinkInternationalWireDetailsPage-DwBUSxwe-x_28I9nn.js +1 -0
  100. package/dist/assets/{MagicLinkSuccessPage-BU8oXuny-C8cR1VFE.js → MagicLinkSuccessPage-DbhdGmhh-DNYzgAJU.js} +1 -1
  101. package/dist/assets/{MagicLinkTitleSection-kbY8yTTa-9EHeM1LM.js → MagicLinkTitleSection-Bx92291D-D9nsnbMt.js} +1 -1
  102. package/dist/assets/MailingDetailsSection-D-tnK244-BXHufBP2.js +21 -0
  103. package/dist/assets/{Menu-DTdVYIrC-BIdLGG6J.js → Menu-0YHUdU0n-12P5RljB.js} +1 -1
  104. package/dist/assets/{MyBankConnectionsSettingsPage-B67G0-7Z-n6eVqpf_.js → MyBankConnectionsSettingsPage-Dn9AT8p1-BbviCBBU.js} +1 -1
  105. package/dist/assets/{MyPendingActivationChargeCardListPage-Cbap6Vpr-CSFLEHXK.js → MyPendingActivationChargeCardListPage-DrQu6s7j-DI8j4Roq.js} +1 -1
  106. package/dist/assets/{MyProfileSettingsPage-TqtGXk0G-LTkAmfNQ.js → MyProfileSettingsPage-CBvjEd7r-B3f0C00b.js} +1 -1
  107. package/dist/assets/{NavBarWithPicker-C4_SW0nA-DEnXFLuU.js → NavBarWithPicker-aXn2QYh1-CB_AN-HG.js} +1 -1
  108. package/dist/assets/{NavigationArrow-6jp6I9fp-c3H2_Bem.js → NavigationArrow-JLUXaIrz-BZffLUxV.js} +1 -1
  109. package/dist/assets/{NavigationDots-BSjG6OlY-Buo2a5d0.js → NavigationDots-B0_dDbgu-D1euhRa0.js} +1 -1
  110. package/dist/assets/{NewGlobalMerchantPage-BXM36kwh-Cd4H2AF3.js → NewGlobalMerchantPage-B_019EtP-Cnin4QvT.js} +1 -1
  111. package/dist/assets/{NoDataChart-CRhOisS1-BTCCqtJ6.js → NoDataChart-DLKHNXD4-CdqcDLeH.js} +1 -1
  112. package/dist/assets/{NoDataTable-bIZY56VS-ccYortqh.js → NoDataTable-BMD2qygC-4Ck98ufk.js} +1 -1
  113. package/dist/assets/{NotFoundPage-Y4UqiUrL-Dl07MVyQ.js → NotFoundPage-BEya4LS2-BrCuBa4j.js} +3 -3
  114. package/dist/assets/{NotificationSettingsPage-Ct1wYM98-cHt-xjmV.js → NotificationSettingsPage-C9SjRKCu-Du1Cf4y_.js} +1 -1
  115. package/dist/assets/{NotificationsListConfig-tD8IFVDs-CZIDK_9u.js → NotificationsListConfig-OCeJNw1G-DxjI9EUe.js} +1 -1
  116. package/dist/assets/{NotificationsPage-C8PlG40Q-CVuSfSFc.js → NotificationsPage-FJHx_WBG-TAfeF35H.js} +1 -1
  117. package/dist/assets/{OpExByVendorPage-B5dz3g_I-CwduKJys.js → OpExByVendorPage-Dxk68R6U-TSpF0BZT.js} +1 -1
  118. package/dist/assets/{OverlayContainerPage-Daz3A7cI-DCcii6jR.js → OverlayContainerPage-Daz3A7cI-BG61qzjJ.js} +1 -1
  119. package/dist/assets/{PandLWithForecastPage-BzeV5E9J-BCbR55BC.js → PandLWithForecastPage-Bu49FbWD-DV8somvz.js} +4 -4
  120. package/dist/assets/{PaymentAccountSetupBillingAddressSection-C7ucXP-C-vD6tp49H.js → PaymentAccountSetupBillingAddressSection-s9EEHxoG-Ccng4Jbq.js} +1 -1
  121. package/dist/assets/{PeoplePage-Di9LbUPG-Da8rtaKy.js → PeoplePage-DN5VtG7Q-CKG_6p7l.js} +1 -1
  122. package/dist/assets/{Preview-tV-yCjmx.js → Preview-8iqIdVv4.js} +1 -1
  123. package/dist/assets/{ProductsCarousel-IX34mwaP-9RoB5Xfe.js → ProductsCarousel-6gthLCkf-RpcyX94H.js} +1 -1
  124. package/dist/assets/{PromoBaseCards-DKl5hmY7-DihqgpsA.js → PromoBaseCards-CzPzj69A-DGTVwpLe.js} +1 -1
  125. package/dist/assets/{QBOConnectionDialog-CFgV4ltt-DFaL9t9h.js → QBOConnectionDialog-BFy0lMZd-D5AhMSo8.js} +1 -1
  126. package/dist/assets/{QBOSetupSection-3Igwysxj-wURB4Ues.js → QBOSetupSection-DcLYyQ5m-DYCAROkc.js} +7 -7
  127. package/dist/assets/ReimbursementApprovalRuleDetailPage-0o5lDuM2-Cr0TZK-s.js +26 -0
  128. package/dist/assets/{ReimbursementApprovalRulesPage-CUQt2z6s-CacQtgTe.js → ReimbursementApprovalRulesPage-D5ZMrrmO-CIYzhtUg.js} +1 -1
  129. package/dist/assets/{ReimbursementDetailPage-CgwRpLnh-BB4SRwDm.js → ReimbursementDetailPage-DatcF8rt-B5PSoIBr.js} +1 -1
  130. package/dist/assets/{ReimbursementPromoPage-BxBAhFM1-BF6hJaxb.js → ReimbursementPromoPage-MweW-4DO-BO5Os0EF.js} +4 -4
  131. package/dist/assets/{ReimbursementSetUpPage-CP8WtKvQ-CigASL8Y.js → ReimbursementSetUpPage-BD2LWlbW-YI084Mlh.js} +1 -1
  132. package/dist/assets/{ReimbursementsBulkReviewDrawerPage-Ir7LV3Qg-Dnq7FHvk.js → ReimbursementsBulkReviewDrawerPage-DV_PLm_g-CdjeW3Za.js} +1 -1
  133. package/dist/assets/{ReloadCard-DLKVg3Sx-raifO-B_.js → ReloadCard-9KpQCrce-Y78Zw9cJ.js} +1 -1
  134. package/dist/assets/{ReportTableViewSelector-BlpUjTMl-C-RA5eDL.js → ReportTableViewSelector-BPliEsuo-CZegsDsW.js} +1 -1
  135. package/dist/assets/{ReportsPage-D-4SKTVF-DBO0HPPe.js → ReportsPage-h2DAaQfK-Dj7aDDw4.js} +5 -5
  136. package/dist/assets/{RevenueChart-C3cckydL-DuMhXuaA.js → RevenueChart-DY2s_upY-DFXm-6Am.js} +1 -1
  137. package/dist/assets/{ReviewDetailsPage-Df882foz-DSNm6Tvp.js → ReviewDetailsPage-BiYxRnvA-cVXSS1nN.js} +1 -1
  138. package/dist/assets/{ReviewOverlay-n3lZIztC-Jt6HA3yk.js → ReviewOverlay-BvPN7IKD-BVyGsnOK.js} +1 -1
  139. package/dist/assets/{RoleWithToolTip-jGxjGCFo-Cfrtl2v2.js → RoleWithToolTip-aW95rpRe-D_rCTb4X.js} +1 -1
  140. package/dist/assets/{ScheduleDetailsFixedAssetsPage-cVGyXDC1-BNedCqMx.js → ScheduleDetailsFixedAssetsPage-DlXqz1QQ-CI8b87nD.js} +1 -1
  141. package/dist/assets/{ScheduleDetailsPage-Dcl5GREY-Ct_YcYBo.js → ScheduleDetailsPage-DebosLND-CytjKLyD.js} +3 -3
  142. package/dist/assets/{ScheduleSequenceTable-CkqvmnzR-ChIiKEV4.js → ScheduleSequenceTable-Dd4Ep_c0-CndtHY8m.js} +1 -1
  143. package/dist/assets/{ScreenRoutes-B-IHS-7V.js → ScreenRoutes-CrZHoFIY.js} +1 -1
  144. package/dist/assets/{SetUpAccountSection-bKk_0Pau-Bgf6Zs6Q.js → SetUpAccountSection-Dhb8A0Oe-CHZzV0W4.js} +1 -1
  145. package/dist/assets/{SignIn-BZXzRb1K-B_z9rDGz.js → SignIn-DQBJB5ad-yHNBe1dm.js} +1 -1
  146. package/dist/assets/{SignInScreen-aZSIS5dr.js → SignInScreen-B08t21nJ.js} +1 -1
  147. package/dist/assets/{SpendManagementListViewPage-jdvSYQ4J-C-TI7b_0.js → SpendManagementListViewPage-Ac-9u-X2-ConJ7IhF.js} +3 -3
  148. package/dist/assets/{SpendManagementPerTabPage-BlyFIn6o-CDHF62oQ.js → SpendManagementPerTabPage-DgrMAQ8l-CwC7irjo.js} +1 -1
  149. package/dist/assets/{SpendManagementSection-Dzlokoym-DFpoafz0.js → SpendManagementSection-Ci2yOCJ9-DUAKhgdu.js} +1 -1
  150. package/dist/assets/StatementItem-hcBoe79o-BTjI_1ZK.js +31 -0
  151. package/dist/assets/{StatementsPage-Cw6GRd81-ChCacJhz.js → StatementsPage-DVR5LhTi-ldyTOd7O.js} +1 -1
  152. package/dist/assets/{StatusSwitcher-CcLiXtx4-f9qUB_aI.js → StatusSwitcher-Cy5ITFgi-DNMieZwF.js} +1 -1
  153. package/dist/assets/{SubTabSwitcher-zpnLoSBy-DHPyjZjM.js → SubTabSwitcher-DhsES2OW-DrYqVYfO.js} +1 -1
  154. package/dist/assets/{SummaryCard-C2KHXXwg-D6dUyKsz.js → SummaryCard-Byv4Hw8Q-CEnhPnYc.js} +1 -1
  155. package/dist/assets/{TaskManagementPage-C3M_HCXR-DTuYPwo5.js → TaskManagementPage-CVXMOPf2-q63kh_yR.js} +1 -1
  156. package/dist/assets/{TimeRangeSwitcher-COHAPH9b-d1DuuIDi.js → TimeRangeSwitcher-jct2_5PE-DPu4jgs4.js} +11 -11
  157. package/dist/assets/{TimeframeSwitcher-5ql0bSzz-Bs-WyJqF.js → TimeframeSwitcher-BK-qliOX-BjbSBToW.js} +1 -1
  158. package/dist/assets/{TimeframeSwitcherWithToggle-BXSkHN5Y-DtM__aUW.js → TimeframeSwitcherWithToggle-Cl6ISBIz-3_smJQH4.js} +2 -2
  159. package/dist/assets/{TopExCard-BrodwfJq-BuNuom9E.js → TopExCard-o4Q3ze1b-CQFtRtLu.js} +1 -1
  160. package/dist/assets/{TopExDetailPage-B8-Zzr1B-CRfyljYM.js → TopExDetailPage-BsCwwwDi-CdmjqJ_1.js} +5 -5
  161. package/dist/assets/{TransactionDetailPage-D8v3KPrb-BrPGsz8W.js → TransactionDetailPage-rpCG65yC-CLh205i5.js} +1 -1
  162. package/dist/assets/{TransactionList-DMb2xYOV-CraifWnm.js → TransactionList-YI4oZaim-xbjxS_zo.js} +1 -1
  163. package/dist/assets/{TransactionListBig-dUBjAacV-DC5_6EqD.js → TransactionListBig-D_Jw9Ip2-Bz8jw08Q.js} +5 -5
  164. package/dist/assets/{TransactionListPage-x0r04hx4-ByjUdu-s.js → TransactionListPage-B2yWm7eA-DCySOEer.js} +2 -2
  165. package/dist/assets/{TransactionVendorDetailPage-BqjeDf6Q-Dzq8RIOd.js → TransactionVendorDetailPage-Dr5C4-7q-BPGPWJM6.js} +1 -1
  166. package/dist/assets/{TransferDrawerPage-LppLtT6A-9tQ3RVxi.js → TransferDrawerPage-BnEVH7Mc-C6QWMjAo.js} +1 -1
  167. package/dist/assets/{TreasuryOverviewPage-DNoQLXPn-DtJgqzkX.js → TreasuryOverviewPage-C927Rdkg-PWkTzy8N.js} +1 -1
  168. package/dist/assets/{TreasuryPromoPage--MgysW-J-BnZiQCLe.js → TreasuryPromoPage-C6D3bF2f-xmypxDfH.js} +1 -1
  169. package/dist/assets/{TreasuryStatementsPage-DRPB8HzF-D1pupcJw.js → TreasuryStatementsPage-BE54gWl6-BusQnftI.js} +1 -1
  170. package/dist/assets/{TreasuryTaxLetterPage-BeeNFRtm-BSH1fBvD.js → TreasuryTaxLetterPage-BaHut8Wc-DaO1lvfz.js} +2 -2
  171. package/dist/assets/{TrendChart-C7DgNHh6-CJUZv0E3.js → TrendChart-BI4Tz813-BMzjSOb0.js} +1 -1
  172. package/dist/assets/{TrendWithTransactions-CpQPkCN4-C20sTqz7.js → TrendWithTransactions-BicIDSlC-GPxD5Pyy.js} +1 -1
  173. package/dist/assets/{UncategorizedAccountsMappingPage-f9xrtur3-C6VmI6RW.js → UncategorizedAccountsMappingPage-sbn4Sdr2-CCtQxv0E.js} +5 -5
  174. package/dist/assets/{UnitIntegrationPage-SiS8CA0g-CWR3OzFU.js → UnitIntegrationPage-CZUyjeh5-DYAwrSQY.js} +1 -1
  175. package/dist/assets/{UploadAdditionalDocumentOverlay-Djnl6dYH-B9X_EH8P.js → UploadAdditionalDocumentOverlay-4AWDV_HK-CxD_HluI.js} +1 -1
  176. package/dist/assets/{Vendor2FAPopup-CYwD3yQ8-C90N1LpP.js → Vendor2FAPopup-C_PmEAQ7-BaU4ZlJ1.js} +1 -1
  177. package/dist/assets/{VendorACHDetailsPage-ChZp1Db0-Cse3K9q8.js → VendorACHDetailsPage-DMMoCytX-D-f3jOPl.js} +1 -1
  178. package/dist/assets/{VendorDetailPage-CG0SxxIa-DRDl0JtE.js → VendorDetailPage-CLFKkF8I-DlccPRJ1.js} +1 -1
  179. package/dist/assets/VendorDomesticWireDetailsPage-WxmpwlTS-CXFWxa5o.js +1 -0
  180. package/dist/assets/{VendorFiling1099EditablePage-DQs8RP_2-BUbnv_T9.js → VendorFiling1099EditablePage-CrWrhHZl-MLHVoFXe.js} +1 -1
  181. package/dist/assets/{VendorFirstReviewPage-XaE6ddOQ-rVweCi-_.js → VendorFirstReviewPage-C6MnbIan-CvuNZRdM.js} +1 -1
  182. package/dist/assets/{VendorInternationalWireDetailsPage-CT75sZ0O-CdoJJkNf.js → VendorInternationalWireDetailsPage-CzPRK4E2-DP27a23P.js} +1 -1
  183. package/dist/assets/VendorInternationalWireSwiftDetailsPage-BBYmlLxN-CGwvkONg.js +1 -0
  184. package/dist/assets/{VendorsAccountsSection-C9NkRN0p-B0pCAjM_.js → VendorsAccountsSection-CVh1n81R-CZE2h2vy.js} +1 -1
  185. package/dist/assets/{VerifyDevice-c6uTgDIl-CbEOfzzD.js → VerifyDevice-BHocExfO-CXvB8GAp.js} +1 -1
  186. package/dist/assets/{VideoPlayer-BgTXP1p7-Cluk8mf7.js → VideoPlayer-9rYRtSLf-C_MG4aUQ.js} +2 -2
  187. package/dist/assets/VideoPopup-D1o92dj6-Dti5suvC.js +31 -0
  188. package/dist/assets/{WarningsDrawerPage-BS-TFvBs-DNJve9qV.js → WarningsDrawerPage-CzufXgaN-BVjYF7DU.js} +1 -1
  189. package/dist/assets/{ZeniAccountDetailPage-CSVQF6vO-BffDIt1S.js → ZeniAccountDetailPage-ZZ3Ra-Jf-_49Q_UUx.js} +1 -1
  190. package/dist/assets/{ZeniAccountListViewPage-BVGsjSB2-BZPNsiNG.js → ZeniAccountListViewPage-Cxid0mfh-Bo45T4Gx.js} +1 -1
  191. package/dist/assets/{ZeniAccountNavBarPieces-B1l8Hjdg-CBpgN60Q.js → ZeniAccountNavBarPieces-DDc-xph4-CzcxivOl.js} +1 -1
  192. package/dist/assets/{ZeniAccountPromoPage-s-QGT-pZ-4BJMfYD4.js → ZeniAccountPromoPage-YIYFkPIB-YhnencbA.js} +1 -1
  193. package/dist/assets/{ZeniAccountSetupPage-CqXokSq4-D67zlWge.js → ZeniAccountSetupPage-BJ9UJ0dP-yNigxq0M.js} +1 -1
  194. package/dist/assets/{ZeniCopyright-_f5jw1U0-Cm_sE86z.js → ZeniCopyright-CztmWsFm-x7y7hEtI.js} +1 -1
  195. package/dist/assets/{ZeniTransferAmountSlider-yvd98l69-CXQir1uN.js → ZeniTransferAmountSlider-g9qU5Lsq-BdpWeRuR.js} +1 -1
  196. package/dist/assets/{add-to-wallet-DgdBD8_G-DcIDYSUN.js → add-to-wallet-DgdBD8_G-CnbN5S25.js} +1 -1
  197. package/dist/assets/{analytics-A_-qSDYO.js → analytics-C6bOaJY9.js} +1 -1
  198. package/dist/assets/{analyticsHelper-BvohFLdK-Dzhl4b0m.js → analyticsHelper-D4lKCWjQ-7uZfvraO.js} +1 -1
  199. package/dist/assets/{analyticsHelper-z7zDW-m3.js → analyticsHelper-Dyr99-JR.js} +1 -1
  200. package/dist/assets/{arrow-south-east-round-PEovUgvH-Bjs-Qn41.js → arrow-south-east-round-PEovUgvH-D0tcq0ac.js} +1 -1
  201. package/dist/assets/{auto-transfer-rule-mbafm5D3-DwSG-0Tc.js → auto-transfer-rule-mbafm5D3-C5MrpFJF.js} +1 -1
  202. package/dist/assets/{chartTypes-h1GkAvwh-FT7wGKaw.js → chartTypes-BPPSjkhb-H7A_cnp3.js} +1 -1
  203. package/dist/assets/{commonDimensions-7B20r1RL-_hVmC3-Q.js → commonDimensions-Ds75pRzR-DJ4H9OI5.js} +1 -1
  204. package/dist/assets/{constants-BJHEKrOg.js → constants-DNQWEIo3.js} +1 -1
  205. package/dist/assets/{core-CIAE9Iou.js → core-BiYEzgTE.js} +1 -1
  206. package/dist/assets/{dash.all.min-OQiut6fg.js → dash.all.min-CNiNGlQC.js} +1 -1
  207. package/dist/assets/{detailCommon-C28aeDGm-BwKr3Jwq.js → detailCommon-DdZdfmYT-DWQ_1h8d.js} +5 -5
  208. package/dist/assets/{downloadPdf-D1MhyCE3-BRAULud8.js → downloadPdf-B8UMaJCC-BA2fFFfC.js} +1 -1
  209. package/dist/assets/{empty-qC9xuHfK.js → empty-B0QxjPHg.js} +1 -1
  210. package/dist/assets/{empty-Cz51lwOs.js → empty-D0VQVmJ6.js} +1 -1
  211. package/dist/assets/{epic-DhKV_nq7.js → epic-BPfIZ-JM.js} +1 -1
  212. package/dist/assets/{gift-box-Cmt9OgIZ-C3WoTp93.js → gift-box-Cmt9OgIZ-DZtTQChg.js} +1 -1
  213. package/dist/assets/{graphic-no-data-l-DU4J8fDt-BJxMLkUg.js → graphic-no-data-l-DU4J8fDt-D9COe3MR.js} +1 -1
  214. package/dist/assets/{graphic-no-data-net-burn-l-CzmycA0m-D-qWdRKa.js → graphic-no-data-net-burn-l-CzmycA0m-CnFblD9c.js} +1 -1
  215. package/dist/assets/{handshake-BPg58FML-WPUTSbks.js → handshake-BPg58FML-Dk4MbD0e.js} +1 -1
  216. package/dist/assets/{index-4PNYlcwA.js → index-BBJ8MbHB.js} +9 -9
  217. package/dist/assets/{index-DhrgV_ix.js → index-BLOT0kav.js} +1 -1
  218. package/dist/assets/{index-DRnHG-3E.js → index-BWdq4kfG.js} +1 -1
  219. package/dist/assets/{index-CGQmgJEE.js → index-Bl0eTNht.js} +1 -1
  220. package/dist/assets/{index-MXpgXI6y.js → index-CmMi38cf.js} +1 -1
  221. package/dist/assets/{index-Bu7tM8jp.js → index-D66eZF3S.js} +1 -1
  222. package/dist/assets/{index-Dvl7ZPqE.js → index-QkeEXb1H.js} +1 -1
  223. package/dist/assets/{lexical-D0mgjaqy.js → lexical-Cbl76XZt.js} +1 -1
  224. package/dist/assets/{liveblocks-B2g7ROdB.js → liveblocks-BstIT-4Z.js} +1 -1
  225. package/dist/assets/{lottie-DvUF1pax.js → lottie-Dcr3TlBE.js} +1 -1
  226. package/dist/assets/mapLoadingInProgressToTreeNode-DGRrn6kh-B7ARKarP.js +1 -0
  227. package/dist/assets/{mapSectionWithAcOnlyToTreeNode-DtwKYRnC-Caj3kiPo.js → mapSectionWithAcOnlyToTreeNode-rrJBbsC8-DldkvgD3.js} +1 -1
  228. package/dist/assets/mapSpacerToTreeNode-CWvamMX2-8qhsm047.js +1 -0
  229. package/dist/assets/mapTimeframeBalancesToTreeNode-DfQk4Tsr-CLPrV0Gx.js +1 -0
  230. package/dist/assets/mapTimeframeBalancesToTreeNode-_jEVk1uh-Dt-fMHUy.js +1 -0
  231. package/dist/assets/{mapTimeframeHeaderLoadingInProgressToTreeNode-Dscp66eK-lBQd2IWW.js → mapTimeframeHeaderLoadingInProgressToTreeNode-DCb9paz3-BVNM6n_o.js} +1 -1
  232. package/dist/assets/{mui-o4KTDVYm.js → mui-CqcpY1UR.js} +1 -1
  233. package/dist/assets/{page-detail-CWX5S47F-CPwel8vo.js → page-detail-CWX5S47F-KNgKNFoz.js} +1 -1
  234. package/dist/assets/{radio-default-CiSgisfh-CywL4kIK.js → radio-default-CiSgisfh-yEV1b0CM.js} +1 -1
  235. package/dist/assets/{react-BCcPfS1c.js → react-4Ya91sN5.js} +1 -1
  236. package/dist/assets/{react-Z5v0eeyD.js → react-B4eK6Gcb.js} +1 -1
  237. package/dist/assets/{react-NUTeTPEN.js → react-BPBfJ6wZ.js} +1 -1
  238. package/dist/assets/{react-CXz3KePA.js → react-BR4cTFeR.js} +1 -1
  239. package/dist/assets/{react-BYU6BCD1.js → react-CAF4_aM2.js} +1 -1
  240. package/dist/assets/{react-CCHDJHXq.js → react-CG2AEOc2.js} +1 -1
  241. package/dist/assets/{react-BSMWc32-.js → react-CHCFBd-l.js} +2 -2
  242. package/dist/assets/{react-lMeFMTFb.js → react-COBWBcIx.js} +1 -1
  243. package/dist/assets/{recharts-BJmPBfq4.js → recharts-bDaLwU4I.js} +1 -1
  244. package/dist/assets/{sentry-CjZuZb_k.js → sentry-CTfRDee5.js} +1 -1
  245. package/dist/assets/{shield-DOlUxcFf-DKVN6gSI.js → shield-DOlUxcFf-CaZu4NEg.js} +1 -1
  246. package/dist/assets/toCOABalancesWithID-CkjRB0sJ-DDXgenlP.js +1 -0
  247. package/dist/assets/{toChartData-BYQCR1Q4-DFPuCktO.js → toChartData-CMi2WgAy-Bk_h1ue0.js} +1 -1
  248. package/dist/assets/{transaction-placeholder-CpOwZAMG-BQ2O_9lU.js → transaction-placeholder-CpOwZAMG-DpKoIbbu.js} +1 -1
  249. package/dist/assets/{uploadAttachment-Cs2BAs2F-D_wyMmah.js → uploadAttachment-B4ddYCCL-B4kq7cBL.js} +1 -1
  250. package/dist/assets/{uploadReceipts-CPw64UYa-CVPftMJd.js → uploadReceipts-CPw64UYa-DdOlSolA.js} +1 -1
  251. package/dist/assets/{url-caPnqlhh.js → url-BPLyW2rO.js} +1 -1
  252. package/dist/assets/{url-BjWWFI3O.js → url-DI6ZTkbp.js} +1 -1
  253. package/dist/assets/{useLongPress-GCK2COYQ-D6HBn4oj.js → useLongPress-GCK2COYQ-DwbMzQIX.js} +1 -1
  254. package/dist/assets/{usp-line-BBd1wKwW-C1bodntP.js → usp-line-BBd1wKwW-CG6D_gsM.js} +1 -1
  255. package/dist/assets/{utils-BdW9S11I.js → utils-BI6ira9J.js} +1 -1
  256. package/dist/assets/{zeni-epic-state-DJnPqdxc.js → zeni-epic-state-n7oqKrUc.js} +3 -3
  257. package/dist/index.html +1 -1
  258. package/package.json +2 -2
  259. package/dist/assets/AccountInfoPage-CDn5K_o2-641sWKgU.js +0 -18
  260. package/dist/assets/CustomerOnboardingContainerPage-qmrLtjkH-BEltfCv2.js +0 -1
  261. package/dist/assets/CustomerOnboardingProductSuitePage-CEOJEMdY-ntP-LOfn.js +0 -202
  262. package/dist/assets/MagicLinkACHDetailsPage-DtxKOlmX-C3DvZH5g.js +0 -1
  263. package/dist/assets/MagicLinkDomesticWireDetailsPage-C7DsI3GD-DonhhvUC.js +0 -1
  264. package/dist/assets/MagicLinkInternationalWireDetailsPage-BQtq93Cv-Cdv7ebZp.js +0 -1
  265. package/dist/assets/MailingDetailsSection-CMekdUCQ-xJE41G8i.js +0 -21
  266. package/dist/assets/ReimbursementApprovalRuleDetailPage-gUzCi41q-KVZqQggT.js +0 -24
  267. package/dist/assets/StatementItem-BMV39A0D-BrJFdPY2.js +0 -31
  268. package/dist/assets/VendorDomesticWireDetailsPage-Dfawpwuo-BLDa-BWv.js +0 -1
  269. package/dist/assets/VendorInternationalWireSwiftDetailsPage-CBKqnkvK-Bir8wvug.js +0 -1
  270. package/dist/assets/VideoPopup-BD0vmbkL-D5UO4z6F.js +0 -31
  271. package/dist/assets/mapLoadingInProgressToTreeNode-B5fs_QGb-BbA7RFsu.js +0 -1
  272. package/dist/assets/mapSpacerToTreeNode-BufNagSk-TTaGXpmE.js +0 -1
  273. package/dist/assets/mapTimeframeBalancesToTreeNode-BHbBvkxK-C7-N1YyL.js +0 -1
  274. package/dist/assets/mapTimeframeBalancesToTreeNode-BOahnk__-RnE09Z0i.js +0 -1
  275. package/dist/assets/toCOABalancesWithID-DScSc4rG-Bzsy78A1.js +0 -1
@@ -1,5 +1,5 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/empty-qC9xuHfK.js","assets/sentry-CjZuZb_k.js","assets/empty-Cz51lwOs.js","assets/index-Dvl7ZPqE.js","assets/index-MXpgXI6y.js","assets/zeni-epic-state-DJnPqdxc.js","assets/core-CIAE9Iou.js","assets/utils-BdW9S11I.js","assets/recharts-BJmPBfq4.js","assets/url-caPnqlhh.js","assets/index-CGQmgJEE.js","assets/index-Bu7tM8jp.js","assets/url-BjWWFI3O.js","assets/index-DRnHG-3E.js","assets/constants-BJHEKrOg.js","assets/OverlayContainerPage-Daz3A7cI-DCcii6jR.js","assets/mui-o4KTDVYm.js","assets/liveblocks-B2g7ROdB.js","assets/lottie-DvUF1pax.js","assets/analytics-A_-qSDYO.js","assets/lexical-D0mgjaqy.js","assets/ConfettiBurst-Cygb8bhF-CpMHcY5K.js","assets/SignIn-BZXzRb1K-B_z9rDGz.js","assets/ZeniCopyright-_f5jw1U0-Cm_sE86z.js","assets/ProductsCarousel-IX34mwaP-9RoB5Xfe.js","assets/handshake-BPg58FML-WPUTSbks.js","assets/Dashboard-CJSMYKO7-S41CzF6L.js","assets/DashboardSidebarBackgroundAnimation-D3qI_q0a-iCovmnlW.js","assets/ArAgingChart-PIQ_BFy4-YcKcd549.js","assets/chartTypes-h1GkAvwh-FT7wGKaw.js","assets/ReloadCard-DLKVg3Sx-raifO-B_.js","assets/TopExCard-BrodwfJq-BuNuom9E.js","assets/graphic-no-data-l-DU4J8fDt-BJxMLkUg.js","assets/RevenueChart-C3cckydL-DuMhXuaA.js","assets/toCOABalancesWithID-DScSc4rG-Bzsy78A1.js","assets/toChartData-BYQCR1Q4-DFPuCktO.js","assets/InsightsCardStack-BSigEuRs-DrhT2GS8.js","assets/SummaryCard-C2KHXXwg-D6dUyKsz.js","assets/NavigationArrow-6jp6I9fp-c3H2_Bem.js","assets/NavigationDots-BSjG6OlY-Buo2a5d0.js","assets/arrow-south-east-round-PEovUgvH-Bjs-Qn41.js","assets/AccountsPromoCardStack-Ukdm1VDj-Dh0SxjJq.js","assets/CompanyPassportCard-Bv6Aws7i-dO40WjmK.js","assets/gift-box-Cmt9OgIZ-C3WoTp93.js","assets/InformationCardStack-DEj81xCg-BlO4gF2p.js","assets/graphic-no-data-net-burn-l-CzmycA0m-D-qWdRKa.js","assets/PromoBaseCards-DKl5hmY7-DihqgpsA.js","assets/VideoPlayer-BgTXP1p7-Cluk8mf7.js","assets/AppDrawerContent-Df0b3OK2-CKxXRIrV.js","assets/TransactionListBig-dUBjAacV-DC5_6EqD.js","assets/TransactionListPage-x0r04hx4-ByjUdu-s.js","assets/TransactionList-DMb2xYOV-CraifWnm.js","assets/BoxItem-Cb4_ZBkK-xDHkx3mk.js","assets/commonDimensions-7B20r1RL-_hVmC3-Q.js","assets/page-detail-CWX5S47F-CPwel8vo.js","assets/DashboardReportPage-CcY-7-W_-DdmW4wbH.js","assets/analyticsHelper-BvohFLdK-Dzhl4b0m.js","assets/ReportTableViewSelector-BlpUjTMl-C-RA5eDL.js","assets/CollapsableReportTable-CrR91Kpi-DnJZSUDi.js","assets/AccountRow-pJ59k4-J-BFmtHL3N.js","assets/InsightsSection-BrjpMz4X-DExiKNju.js","assets/detailCommon-C28aeDGm-BwKr3Jwq.js","assets/NoDataChart-CRhOisS1-BTCCqtJ6.js","assets/getReferrerType-DjPOy76W-DRP5VHem.js","assets/TimeRangeSwitcher-COHAPH9b-d1DuuIDi.js","assets/TimeframeSwitcher-5ql0bSzz-Bs-WyJqF.js","assets/mapSectionWithAcOnlyToTreeNode-DtwKYRnC-Caj3kiPo.js","assets/NoDataTable-bIZY56VS-ccYortqh.js","assets/mapTimeframeHeaderLoadingInProgressToTreeNode-Dscp66eK-lBQd2IWW.js","assets/mapLoadingInProgressToTreeNode-B5fs_QGb-BbA7RFsu.js","assets/ReportsPage-D-4SKTVF-DBO0HPPe.js","assets/TimeframeSwitcherWithToggle-BXSkHN5Y-DtM__aUW.js","assets/DownloadOverlay-gRH0FIa6-e2777Hoq.js","assets/mapTimeframeBalancesToTreeNode-BHbBvkxK-C7-N1YyL.js","assets/TopExDetailPage-B8-Zzr1B-CRfyljYM.js","assets/TransactionDetailPage-D8v3KPrb-BrPGsz8W.js","assets/LabeledControlledCheckBoxField-BSciMX7_-DpOi6Pih.js","assets/TrendWithTransactions-CpQPkCN4-C20sTqz7.js","assets/TrendChart-C7DgNHh6-CJUZv0E3.js","assets/uploadAttachment-Cs2BAs2F-D_wyMmah.js","assets/radio-default-CiSgisfh-CywL4kIK.js","assets/QBOConnectionDialog-CFgV4ltt-DFaL9t9h.js","assets/VerifyDevice-c6uTgDIl-CbEOfzzD.js","assets/AccountLockedInfoModal-BqLkGmTA-Bi36nE_K.js","assets/PeoplePage-Di9LbUPG-Da8rtaKy.js","assets/Menu-DTdVYIrC-BIdLGG6J.js","assets/RoleWithToolTip-jGxjGCFo-Cfrtl2v2.js","assets/PandLWithForecastPage-BzeV5E9J-BCbR55BC.js","assets/NavBarWithPicker-C4_SW0nA-DEnXFLuU.js","assets/usp-line-BBd1wKwW-C1bodntP.js","assets/EntityDetailPage-dZ-H_-kO-B3yxSec8.js","assets/NotFoundPage-Y4UqiUrL-Dl07MVyQ.js","assets/CompanyPassportPage-DRhnOgdd-BOnCftvv.js","assets/LabeledCreatableSingleSelectField-q23ARfG8-CRQFWLML.js","assets/LabeledDocumentField-Icg5_obX-DhGSKEqK.js","assets/LabeledAddressValue-BOPQCQtK-glMgUt5i.js","assets/CreateOrEditVendorPage-_jZBL7C2-BT5eOx4Y.js","assets/VendorACHDetailsPage-ChZp1Db0-Cse3K9q8.js","assets/ACHDetailsPage-OhfwzmDP-CUPlHlS1.js","assets/BankAccountWarningSection-WkczfI75-p--soGkR.js","assets/MagicLinkTitleSection-kbY8yTTa-9EHeM1LM.js","assets/BankAccountSection-DehqZ04x-BJbbHUH9.js","assets/VendorDomesticWireDetailsPage-Dfawpwuo-BLDa-BWv.js","assets/DomesticWireDetailsPage-DTrY_uHQ-CknHfbIJ.js","assets/MailingDetailsSection-CMekdUCQ-xJE41G8i.js","assets/LabeledAddressValueField-DxybAWPO-DIu3ggxx.js","assets/VendorInternationalWireDetailsPage-CT75sZ0O-CdoJJkNf.js","assets/CurrencySelectField-ppkSKTpN-BC31P_0q.js","assets/ReviewDetailsPage-Df882foz-DSNm6Tvp.js","assets/LowBalancePopup-T5Ms2v-E-DO0_djob.js","assets/LabeledText-Tn7u-Ek3-DOKeDUtN.js","assets/BillPayPromoPage-M3bRYehy-Bpwpx-W-.js","assets/VideoPopup-BD0vmbkL-D5UO4z6F.js","assets/BillPaySetUpPage-CJyPhrld-BW-k6Cq5.js","assets/UploadAdditionalDocumentOverlay-Djnl6dYH-B9X_EH8P.js","assets/ApprovalRulesSettingsPage-ChI1Wnf--DELVy5mB.js","assets/BankConnectionsSettingsPage-CCEKqkfW-CxNmb7UL.js","assets/SetUpAccountSection-bKk_0Pau-Bgf6Zs6Q.js","assets/MyBankConnectionsSettingsPage-B67G0-7Z-n6eVqpf_.js","assets/MyProfileSettingsPage-TqtGXk0G-LTkAmfNQ.js","assets/LabeledUserSingleSelectWithSubtitlesField-B_MWazM_-Deht3VPb.js","assets/LabeledZeniRolesDropDownField-DyCxNVQD-CDJPm5Uy.js","assets/NotificationSettingsPage-Ct1wYM98-cHt-xjmV.js","assets/BusinessVerificationPage-D7btikKT-BPUDQBNI.js","assets/CompanyOfficerDetailsSection-4FjXy6T9-CStOu48U.js","assets/ReimbursementPromoPage-BxBAhFM1-BF6hJaxb.js","assets/ReimbursementSetUpPage-CP8WtKvQ-CigASL8Y.js","assets/BillDetailPage-DA1djKtd-CT6NN5ei.js","assets/InvoiceUploadSection-COIpUGEB-wLZvdMHG.js","assets/AttachmentView-mC246Bpw-CT1OWA3c.js","assets/uploadReceipts-CPw64UYa-CVPftMJd.js","assets/BillPayApprovalRulesPage-CZnYZ8cn-D3dv90TB.js","assets/BillPayApprovalRuleDetailPage-CLkMLaIk-DBi0iP3G.js","assets/FollowStepsSection-DDXRZdXi-BkUwTVWQ.js","assets/ReimbursementApprovalRulesPage-CUQt2z6s-CacQtgTe.js","assets/ReimbursementApprovalRuleDetailPage-gUzCi41q-KVZqQggT.js","assets/EditReimbursementDetailPage-CC4JbXua-Dip_aVtM.js","assets/types-DyvtCprH-NFPm5TaG.js","assets/ReimbursementDetailPage-CgwRpLnh-BB4SRwDm.js","assets/InvitePeoplePage-DLPupvdi-DD0j_YWt.js","assets/AllUserItems-CEBWfFac-DPOuER5U.js","assets/CompleteProfile-CdVQdaB0-CLoHBDqw.js","assets/EditPeoplePage-D3GenIke-s4IX6oMr.js","assets/AppBasePage-BBolfeYB-CAoueBdK.js","assets/SpendManagementListViewPage-jdvSYQ4J-C-TI7b_0.js","assets/SpendManagementSection-Dzlokoym-DFpoafz0.js","assets/StatusSwitcher-CcLiXtx4-f9qUB_aI.js","assets/VendorDetailPage-CG0SxxIa-DRDl0JtE.js","assets/SubTabSwitcher-zpnLoSBy-DHPyjZjM.js","assets/LabeledDropDownFormattedTextField-BiJOzT5B-urCKQV5c.js","assets/VendorFiling1099EditablePage-DQs8RP_2-BUbnv_T9.js","assets/ZeniAccountListViewPage-BVGsjSB2-BZPNsiNG.js","assets/auto-transfer-rule-mbafm5D3-DwSG-0Tc.js","assets/shield-DOlUxcFf-DKVN6gSI.js","assets/ZeniAccountNavBarPieces-B1l8Hjdg-CBpgN60Q.js","assets/ZeniTransferAmountSlider-yvd98l69-CXQir1uN.js","assets/ZeniAccountDetailPage-CSVQF6vO-BffDIt1S.js","assets/downloadPdf-D1MhyCE3-BRAULud8.js","assets/DepositAccTransactionItem-BpbS0SRE-NmcXTIJb.js","assets/AccountInfoPage-CDn5K_o2-641sWKgU.js","assets/AccountInfoPageContent-Bu-ZFVKf-BazFs_cA.js","assets/TransferDrawerPage-LppLtT6A-9tQ3RVxi.js","assets/CreditCardPaymentDrawerPage-CWF47Q9G-lJ5s9KFG.js","assets/CheckDepositDrawerPage-Cy0NVgKc-D8fpunhe.js","assets/ZeniAccountPromoPage-s-QGT-pZ-4BJMfYD4.js","assets/ZeniAccountSetupPage-CqXokSq4-D67zlWge.js","assets/DepositAccTransactionListPage-C1EuUbFg-CI8oEH7-.js","assets/StatementsPage-Cw6GRd81-ChCacJhz.js","assets/StatementItem-BMV39A0D-BrJFdPY2.js","assets/TransactionVendorDetailPage-BqjeDf6Q-Dzq8RIOd.js","assets/CustomerOnboardingPage-DWmMR5Ke-C-0daaby.js","assets/PaymentAccountSetupBillingAddressSection-C7ucXP-C-vD6tp49H.js","assets/CustomerOnboardingDetailPageSkeleton-5PeyznvM-B8Mhh2k2.js","assets/QBOSetupSection-3Igwysxj-wURB4Ues.js","assets/CustomerOnboardingContainerPage-qmrLtjkH-BEltfCv2.js","assets/CustomerOnboardingNoStepsPage-CWvaI2vY-BkjuYe-o.js","assets/CustomerOnboardingProductSuitePage-CEOJEMdY-ntP-LOfn.js","assets/CustomerOnboardingActivationPage-DbaC9Uy1-BzvBGrNi.js","assets/BillingSettingsPage-CQngU3lq-DrWAQyUl.js","assets/UncategorizedAccountsMappingPage-f9xrtur3-C6VmI6RW.js","assets/VendorsAccountsSection-C9NkRN0p-B0pCAjM_.js","assets/IntegrationsSettingsPage-BEBtsJ8z-BJ7jcJB8.js","assets/UnitIntegrationPage-SiS8CA0g-CWR3OzFU.js","assets/MagicLinkACHDetailsPage-DtxKOlmX-C3DvZH5g.js","assets/MagicLinkDomesticWireDetailsPage-C7DsI3GD-DonhhvUC.js","assets/MagicLinkInternationalWireDetailsPage-BQtq93Cv-Cdv7ebZp.js","assets/InternationalWireSwiftDetailsPage-DqTA5UPe-CmHr1otA.js","assets/MagicLinkSuccessPage-BU8oXuny-C8cR1VFE.js","assets/Vendor2FAPopup-CYwD3yQ8-C90N1LpP.js","assets/AgingReportsPage-Cam_Ox67-DaZT71t6.js","assets/mapSpacerToTreeNode-BufNagSk-TTaGXpmE.js","assets/agingReportHelper-ovKP-qSS-Cx4Hdid-.js","assets/ApAgingDetailPage-uy2AK45a-JhYM22T9.js","assets/EntitySummarySection-BaSzuw3T-DJX_ZTYK.js","assets/ArAgingDetailPage-DpdUPb6--BJoxfTPP.js","assets/OpExByVendorPage-B5dz3g_I-CwduKJys.js","assets/mapTimeframeBalancesToTreeNode-BOahnk__-RnE09Z0i.js","assets/VendorInternationalWireSwiftDetailsPage-CBKqnkvK-Bir8wvug.js","assets/VendorFirstReviewPage-XaE6ddOQ-rVweCi-_.js","assets/NewGlobalMerchantPage-BXM36kwh-Cd4H2AF3.js","assets/GlobalReviewListPage-Ou4B6O28-Cj-vrRvJ.js","assets/ScheduleDetailsPage-Dcl5GREY-Ct_YcYBo.js","assets/ScheduleSequenceTable-CkqvmnzR-ChIiKEV4.js","assets/ScheduleDetailsFixedAssetsPage-cVGyXDC1-BNedCqMx.js","assets/LinkJETransactionPage-NXVaaeQn-Dc1IDF_5.js","assets/ChargeCardPromoPage-xhEvT_sU-D7VUd9Kw.js","assets/ChargeCardSetupPage-Be89R3A7-BvY-IfNf.js","assets/ChargeCardListPage-CTG6bNbA-DN4yg5h2.js","assets/ChargeCardListTable-BRAAvmWW-BCMrKmLw.js","assets/CardNumberSubText-DQ6T2OKm-CtS54mYI.js","assets/LockCardPage-DFFQF_XE-ZW7dAknw.js","assets/MyPendingActivationChargeCardListPage-Cbap6Vpr-CSFLEHXK.js","assets/ChargeCardDetailPage-BYNjlLQX-smovJQ3p.js","assets/add-to-wallet-DgdBD8_G-DcIDYSUN.js","assets/CashbackDetailPage-ToN5ueBt-BpzeYowT.js","assets/ChargeCardStatementsPage-CFNCOiLr-DDhNhCxi.js","assets/IssueChargeCardPage-6LWMwuaq-BfBIAKq3.js","assets/AddToWalletPage-Bc0GY8mw-CwBrjgnk.js","assets/AddAddressForCardDrawer-CZ9kZK-_-7zBs11LO.js","assets/TaskManagementPage-C3M_HCXR-DTuYPwo5.js","assets/NotificationsListConfig-tD8IFVDs-CZIDK_9u.js","assets/InvitePageListView-B0aN2fz0-C_ebzQNV.js","assets/InviteFormPage-CHZVhrof-Ctwgv0tR.js","assets/DrawerPage-gsfboWa--D8_bnW1E.js","assets/NotificationsPage-C8PlG40Q-CVuSfSFc.js","assets/useLongPress-GCK2COYQ-D6HBn4oj.js","assets/FeaturePreviewPage-Us5W5Wo9-CTfS268U.js","assets/BillsBulkReviewDrawerPage-DlAOz-SY-hKyZsi63.js","assets/ReviewOverlay-n3lZIztC-Jt6HA3yk.js","assets/ReimbursementsBulkReviewDrawerPage-Ir7LV3Qg-Dnq7FHvk.js","assets/ExpenseAutomationOverviewPage-CtBVIXza-8HVAkTgZ.js","assets/transaction-placeholder-CpOwZAMG-BQ2O_9lU.js","assets/AIPerformancePage-9OxanlvK-Bk_qTUs7.js","assets/ExpenseAutomationPage-BByZfMUo-Bp9htN-p.js","assets/AccountReconDetailsDrawerPage-CyQ13mJl-CAv47_Mb.js","assets/InternationalWireVerificationPage-CGLyTJOX-CNAH8NOm.js","assets/ExpressPayPage-Dx4Cc9w2-5nFukiXm.js","assets/TreasuryPromoPage--MgysW-J-BnZiQCLe.js","assets/TreasuryOverviewPage-DNoQLXPn-DtJgqzkX.js","assets/TreasuryStatementsPage-DRPB8HzF-D1pupcJw.js","assets/TreasuryTaxLetterPage-BeeNFRtm-BSH1fBvD.js","assets/WarningsDrawerPage-BS-TFvBs-DNJve9qV.js","assets/ScreenRoutes-B-IHS-7V.js","assets/analyticsHelper-z7zDW-m3.js","assets/SignInScreen-aZSIS5dr.js"])))=>i.map(i=>d[i]);
2
- import{a as b,w as C,R as Aye,b as Lc,p as i1,g as aw,e as Lye,s as Lz,d as Dz,r as Es,f as Dye,i as Mye,S as Pye,j as Iye,k as jye,l as Rye,m as Fye}from"./sentry-CjZuZb_k.js";import{j as Wt,_ as kR,a as Js,u as pce,T as Oye,C as Nye,b as zye,c as W7,d as Y7,e as Bye,f as hce,g as Hye,h as Vye,L as Uye,i as Mz,k as Wye,l as Yye,P as Gye,m as qye,n as Zye,o as mce,p as Kye,q as Xye,I as Pz,r as Qye,s as Jye,t as eve,v as tve,w as rve,x as nve,y as fce,z as ove,A as ive,B as ave}from"./liveblocks-B2g7ROdB.js";import{f as gce,Y as Ih,r as el,b as sve,u as sw,g as b1,h as lve,i as ER,j as cve,R as dve,k as Y$,N as uve,l as pve,m as hve,B as mve}from"./core-CIAE9Iou.js";import{B as ev,ba as bt,bb as fve,bc as Iz,bd as B0,be as gve,bf as _R,bg as ug,bh as Ft,bi as yce,bj as vce,bk as TR,bl as co,bm as jz,bn as a1,bo as yve,bp as d7,bq as vve,br as bve,bs as wve,bt as Rz,bu as xve,bv as Cve,bw as $ve,bx as Sve,by as kve,bz as Eve,bA as _ve,bB as Tve,bC as AR,bD as Ave,bE as bP,bF as Lve,bG as bce,bH as f0,bI as Il,bJ as wce,bK as tv,bL as hr,bM as Dve,bN as jh,bO as wP,bP as Ol,bQ as Mve,bR as Pve,bS as Ive,bT as jve,bU as Rve,bV as Fve,bW as Ove,bX as Nve,bY as zve,bZ as xce,b_ as lw,b$ as Bve,c0 as Hve,c1 as Cce,c2 as Vve,c3 as Uve,c4 as $ce,c5 as Wve,c6 as Fz,c7 as Yve,c8 as Gve,c9 as Sce,ca as kce,cb as qve,cc as Ece,cd as pg,ce as cw,cf as _ce,cg as xP,ch as Zve,ci as Kve,cj as Xve,ck as rv,cl as Qve,cm as Tce,cn as Ace,co as Lce,cp as Dce,cq as Mce,cr as Jve,cs as ebe,ct as tbe,cu as Pce,cv as CP,cw as rbe,cx as Ice,cy as nbe,cz as obe,cA as ibe,cB as abe,cC as sbe,cD as lbe,cE as cbe,cF as dbe,cG as ube,cH as pbe,v as hbe,cI as dw,cJ as jce,cK as Rce,cL as mbe,cM as fbe,cN as gbe,cO as ybe,cP as vbe,cQ as bbe,cR as wbe,cS as xbe,cT as Cbe,cU as Oz,cV as $be,cW as Sbe,cX as kbe,cY as Ebe}from"./zeni-epic-state-DJnPqdxc.js";import{T as Fce,j as gr,n as m,c as at,k as rn,C as Oce,G as LR,u as _be}from"./mui-o4KTDVYm.js";import{L as Nz}from"./lottie-DvUF1pax.js";import{r as Tbe,m as yh}from"./analytics-A_-qSDYO.js";import{E as yn,c as hg,P as Abe}from"./recharts-BJmPBfq4.js";import{r as vi}from"./lexical-D0mgjaqy.js";import{r as Lbe}from"./utils-BdW9S11I.js";(function(){try{var e=typeof window<"u"?window:typeof Lc<"u"?Lc:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="4b8e66f7-ed9b-43e3-a6fa-88a7ae937f5d",e._sentryDebugIdIdentifier="sentry-dbid-4b8e66f7-ed9b-43e3-a6fa-88a7ae937f5d")}catch{}})();(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))n(o);new MutationObserver(o=>{for(const i of o)if(i.type==="childList")for(const a of i.addedNodes)a.tagName==="LINK"&&a.rel==="modulepreload"&&n(a)}).observe(document,{childList:!0,subtree:!0});function r(o){const i={};return o.integrity&&(i.integrity=o.integrity),o.referrerPolicy&&(i.referrerPolicy=o.referrerPolicy),o.crossOrigin==="use-credentials"?i.credentials="include":o.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function n(o){if(o.ep)return;o.ep=!0;const i=r(o);fetch(o.href,i)}})();var G6={},zz;function Dbe(){if(zz)return G6;zz=1;var e=gce();return G6.createRoot=e.createRoot,G6.hydrateRoot=e.hydrateRoot,G6}var Mbe=Dbe();function E0(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function or(){return or=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},or.apply(null,arguments)}function ys(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function nv(e,t){return nv=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,n){return r.__proto__=n,r},nv(e,t)}function mg(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,nv(e,t)}var vs=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof Lc<"u"?Lc:typeof self<"u"?self:{};function $r(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Bz={exports:{}},Bn={};/** @license React v16.13.1
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/empty-B0QxjPHg.js","assets/sentry-CTfRDee5.js","assets/empty-D0VQVmJ6.js","assets/index-QkeEXb1H.js","assets/index-CmMi38cf.js","assets/zeni-epic-state-n7oqKrUc.js","assets/core-BiYEzgTE.js","assets/utils-BI6ira9J.js","assets/recharts-bDaLwU4I.js","assets/url-BPLyW2rO.js","assets/index-Bl0eTNht.js","assets/index-D66eZF3S.js","assets/url-DI6ZTkbp.js","assets/index-BWdq4kfG.js","assets/constants-DNQWEIo3.js","assets/OverlayContainerPage-Daz3A7cI-BG61qzjJ.js","assets/mui-CqcpY1UR.js","assets/liveblocks-BstIT-4Z.js","assets/lottie-Dcr3TlBE.js","assets/analytics-C6bOaJY9.js","assets/lexical-Cbl76XZt.js","assets/ConfettiBurst-1rYKpbAj-DHWZb_DF.js","assets/SignIn-DQBJB5ad-yHNBe1dm.js","assets/ZeniCopyright-CztmWsFm-x7y7hEtI.js","assets/ProductsCarousel-6gthLCkf-RpcyX94H.js","assets/handshake-BPg58FML-Dk4MbD0e.js","assets/Dashboard-_o0Ftdv8-B4FMEqu7.js","assets/DashboardSidebarBackgroundAnimation-Bl8Ss6Gf-1uwRQXQg.js","assets/ArAgingChart-CsFDVdeO-C-RKv3GM.js","assets/chartTypes-BPPSjkhb-H7A_cnp3.js","assets/ReloadCard-9KpQCrce-Y78Zw9cJ.js","assets/TopExCard-o4Q3ze1b-CQFtRtLu.js","assets/graphic-no-data-l-DU4J8fDt-D9COe3MR.js","assets/RevenueChart-DY2s_upY-DFXm-6Am.js","assets/toCOABalancesWithID-CkjRB0sJ-DDXgenlP.js","assets/toChartData-CMi2WgAy-Bk_h1ue0.js","assets/InsightsCardStack-BBczCYEz-CM9k6Dqk.js","assets/SummaryCard-Byv4Hw8Q-CEnhPnYc.js","assets/NavigationArrow-JLUXaIrz-BZffLUxV.js","assets/NavigationDots-B0_dDbgu-D1euhRa0.js","assets/arrow-south-east-round-PEovUgvH-D0tcq0ac.js","assets/AccountsPromoCardStack-CTkwARBJ-Dqd8qLkS.js","assets/CompanyPassportCard-BOxM716U-DxvRrHgL.js","assets/gift-box-Cmt9OgIZ-DZtTQChg.js","assets/InformationCardStack-DnB7TmOk-BJQfDBIj.js","assets/graphic-no-data-net-burn-l-CzmycA0m-CnFblD9c.js","assets/PromoBaseCards-CzPzj69A-DGTVwpLe.js","assets/VideoPlayer-9rYRtSLf-C_MG4aUQ.js","assets/AppDrawerContent-DM1t0oLS-DX8gDdRy.js","assets/TransactionListBig-D_Jw9Ip2-Bz8jw08Q.js","assets/TransactionListPage-B2yWm7eA-DCySOEer.js","assets/TransactionList-YI4oZaim-xbjxS_zo.js","assets/BoxItem-WOrvBzns-DD4R649W.js","assets/commonDimensions-Ds75pRzR-DJ4H9OI5.js","assets/page-detail-CWX5S47F-KNgKNFoz.js","assets/DashboardReportPage-Cu5wqWkj-BjOABFkU.js","assets/analyticsHelper-D4lKCWjQ-7uZfvraO.js","assets/ReportTableViewSelector-BPliEsuo-CZegsDsW.js","assets/CollapsableReportTable-xkNXkjfh-CuBOzrbM.js","assets/AccountRow-BM3xLbeh-DwBWMEiu.js","assets/InsightsSection-BTXj5WUe-BehAISJe.js","assets/detailCommon-DdZdfmYT-DWQ_1h8d.js","assets/NoDataChart-DLKHNXD4-CdqcDLeH.js","assets/getReferrerType-DjPOy76W-DRP5VHem.js","assets/TimeRangeSwitcher-jct2_5PE-DPu4jgs4.js","assets/TimeframeSwitcher-BK-qliOX-BjbSBToW.js","assets/mapSectionWithAcOnlyToTreeNode-rrJBbsC8-DldkvgD3.js","assets/NoDataTable-BMD2qygC-4Ck98ufk.js","assets/mapTimeframeHeaderLoadingInProgressToTreeNode-DCb9paz3-BVNM6n_o.js","assets/mapLoadingInProgressToTreeNode-DGRrn6kh-B7ARKarP.js","assets/ReportsPage-h2DAaQfK-Dj7aDDw4.js","assets/TimeframeSwitcherWithToggle-Cl6ISBIz-3_smJQH4.js","assets/DownloadOverlay-c57lEf_V-BH-A5hnp.js","assets/mapTimeframeBalancesToTreeNode-DfQk4Tsr-CLPrV0Gx.js","assets/TopExDetailPage-BsCwwwDi-CdmjqJ_1.js","assets/TransactionDetailPage-rpCG65yC-CLh205i5.js","assets/LabeledControlledCheckBoxField-Btw_zwzy-I7spg7Dx.js","assets/TrendWithTransactions-BicIDSlC-GPxD5Pyy.js","assets/TrendChart-BI4Tz813-BMzjSOb0.js","assets/uploadAttachment-B4ddYCCL-B4kq7cBL.js","assets/radio-default-CiSgisfh-yEV1b0CM.js","assets/QBOConnectionDialog-BFy0lMZd-D5AhMSo8.js","assets/VerifyDevice-BHocExfO-CXvB8GAp.js","assets/AccountLockedInfoModal-CEk5d9hq-BU7zCzNG.js","assets/PeoplePage-DN5VtG7Q-CKG_6p7l.js","assets/Menu-0YHUdU0n-12P5RljB.js","assets/RoleWithToolTip-aW95rpRe-D_rCTb4X.js","assets/PandLWithForecastPage-Bu49FbWD-DV8somvz.js","assets/NavBarWithPicker-aXn2QYh1-CB_AN-HG.js","assets/usp-line-BBd1wKwW-CG6D_gsM.js","assets/EntityDetailPage-DbTiF9Hs-DOWN_WQU.js","assets/NotFoundPage-BEya4LS2-BrCuBa4j.js","assets/CompanyPassportPage-DzE7sm8S-ZZY5euQN.js","assets/LabeledCreatableSingleSelectField-fycRE7PX-BLM_4t-_.js","assets/LabeledDocumentField-C73vQNgq-xVgwP02Y.js","assets/LabeledAddressValue-CB_KH7v5-DhXcxbM6.js","assets/CreateOrEditVendorPage-WQeDCj-E-ZLNX3FBX.js","assets/VendorACHDetailsPage-DMMoCytX-D-f3jOPl.js","assets/ACHDetailsPage-BRWOdhMx-lCkplz0-.js","assets/BankAccountWarningSection-DMRmF2yM-Bdqe05tT.js","assets/MagicLinkTitleSection-Bx92291D-D9nsnbMt.js","assets/BankAccountSection-Bgdk93V0-DEu58Lvd.js","assets/VendorDomesticWireDetailsPage-WxmpwlTS-CXFWxa5o.js","assets/DomesticWireDetailsPage-FGdEilUB-BIDfGIPL.js","assets/MailingDetailsSection-D-tnK244-BXHufBP2.js","assets/LabeledAddressValueField-Bt41wdNQ-CdN5suyF.js","assets/VendorInternationalWireDetailsPage-CzPRK4E2-DP27a23P.js","assets/CurrencySelectField-AjAWhg6e-h8iODRHM.js","assets/ReviewDetailsPage-BiYxRnvA-cVXSS1nN.js","assets/LowBalancePopup-Dd9HLWlh-qIEjt8fN.js","assets/LabeledText-yhm8qxrA-B5O06POj.js","assets/BillPayPromoPage-aGKOv8Ur-59DxEGOU.js","assets/VideoPopup-D1o92dj6-Dti5suvC.js","assets/BillPaySetUpPage-DRCjyEfB-CkG4ce3e.js","assets/UploadAdditionalDocumentOverlay-4AWDV_HK-CxD_HluI.js","assets/ApprovalRulesSettingsPage-GZCo6_i2-ClrA48La.js","assets/BankConnectionsSettingsPage-BpwKq93l-yFMdYswL.js","assets/SetUpAccountSection-Dhb8A0Oe-CHZzV0W4.js","assets/MyBankConnectionsSettingsPage-Dn9AT8p1-BbviCBBU.js","assets/MyProfileSettingsPage-CBvjEd7r-B3f0C00b.js","assets/LabeledUserSingleSelectWithSubtitlesField-CgA4UPJh-BYzGVtZI.js","assets/LabeledZeniRolesDropDownField-DGkU72cd-iMLOxXqS.js","assets/NotificationSettingsPage-C9SjRKCu-Du1Cf4y_.js","assets/BusinessVerificationPage-CbqJIVpz-BiQu25FO.js","assets/CompanyOfficerDetailsSection-BtUBatbQ-CS2katNY.js","assets/ReimbursementPromoPage-MweW-4DO-BO5Os0EF.js","assets/ReimbursementSetUpPage-BD2LWlbW-YI084Mlh.js","assets/BillDetailPage-BG7FhHEq-CI73yv-V.js","assets/InvoiceUploadSection-DPd4VmqZ-BLpPijn4.js","assets/AttachmentView-B0d42oAf-CFenLcCO.js","assets/uploadReceipts-CPw64UYa-DdOlSolA.js","assets/BillPayApprovalRulesPage-DiCNUU-G-CN0GV9DL.js","assets/BillPayApprovalRuleDetailPage-BAK1Gfko-DXu3RSd8.js","assets/FollowStepsSection-ebmR-eLP-CCCIBkct.js","assets/ReimbursementApprovalRulesPage-D5ZMrrmO-CIYzhtUg.js","assets/ReimbursementApprovalRuleDetailPage-0o5lDuM2-Cr0TZK-s.js","assets/EditReimbursementDetailPage-Bt7XKq5h-BcSPiJVn.js","assets/types-DyvtCprH-NFPm5TaG.js","assets/ReimbursementDetailPage-DatcF8rt-B5PSoIBr.js","assets/InvitePeoplePage-DrBtwpMH-D70ug1bL.js","assets/AllUserItems-BsvKEVcx-Ckn7N6Nq.js","assets/CompleteProfile-BjGSPASa-Bfp0I59Q.js","assets/EditPeoplePage-DJthuIP4-Ccr8TbIs.js","assets/AppBasePage-DoCF494Z-BPFvSn_P.js","assets/SpendManagementListViewPage-Ac-9u-X2-ConJ7IhF.js","assets/SpendManagementSection-Ci2yOCJ9-DUAKhgdu.js","assets/StatusSwitcher-Cy5ITFgi-DNMieZwF.js","assets/VendorDetailPage-CLFKkF8I-DlccPRJ1.js","assets/SubTabSwitcher-DhsES2OW-DrYqVYfO.js","assets/LabeledDropDownFormattedTextField-DGb_bDyp-DbOxXrX_.js","assets/VendorFiling1099EditablePage-CrWrhHZl-MLHVoFXe.js","assets/ZeniAccountListViewPage-Cxid0mfh-Bo45T4Gx.js","assets/auto-transfer-rule-mbafm5D3-C5MrpFJF.js","assets/shield-DOlUxcFf-CaZu4NEg.js","assets/ZeniAccountNavBarPieces-DDc-xph4-CzcxivOl.js","assets/ZeniTransferAmountSlider-g9qU5Lsq-BdpWeRuR.js","assets/ZeniAccountDetailPage-ZZ3Ra-Jf-_49Q_UUx.js","assets/downloadPdf-B8UMaJCC-BA2fFFfC.js","assets/DepositAccTransactionItem-BOPK7-7P-CmYSzV4w.js","assets/AccountInfoPage-Ca_vKG58-pmVk2hiY.js","assets/AccountInfoPageContent-Dv1IPcdF-ChZIyLOA.js","assets/TransferDrawerPage-BnEVH7Mc-C6QWMjAo.js","assets/CreditCardPaymentDrawerPage-Q12y6HMX-CRUPlZFr.js","assets/CheckDepositDrawerPage-ClxKj2js-BOLtAKO1.js","assets/ZeniAccountPromoPage-YIYFkPIB-YhnencbA.js","assets/ZeniAccountSetupPage-BJ9UJ0dP-yNigxq0M.js","assets/DepositAccTransactionListPage-oj9tntbI-CMORNmGB.js","assets/StatementsPage-DVR5LhTi-ldyTOd7O.js","assets/StatementItem-hcBoe79o-BTjI_1ZK.js","assets/TransactionVendorDetailPage-Dr5C4-7q-BPGPWJM6.js","assets/CustomerOnboardingPage-CvN9Jrdy-BbxW7een.js","assets/PaymentAccountSetupBillingAddressSection-s9EEHxoG-Ccng4Jbq.js","assets/CustomerOnboardingDetailPageSkeleton-B0WzN1Sx-A_sh3_b9.js","assets/QBOSetupSection-DcLYyQ5m-DYCAROkc.js","assets/CustomerOnboardingContainerPage-C9radmIS-D7esgWyy.js","assets/CustomerOnboardingNoStepsPage-CNni6chX-DEHNST6I.js","assets/CustomerOnboardingProductSuitePage-CZkX9ur7-CVf3ueoc.js","assets/CustomerOnboardingActivationPage-BJhw-PvI-DfxjHeaa.js","assets/BillingSettingsPage-CdYb74V7-D26O7kQD.js","assets/UncategorizedAccountsMappingPage-sbn4Sdr2-CCtQxv0E.js","assets/VendorsAccountsSection-CVh1n81R-CZE2h2vy.js","assets/IntegrationsSettingsPage-CByj2tO4-zF-3f5Vb.js","assets/UnitIntegrationPage-CZUyjeh5-DYAwrSQY.js","assets/MagicLinkACHDetailsPage-Cpde2XoD-JoGWlKNi.js","assets/MagicLinkDomesticWireDetailsPage-DQYH52_8-Clx_7zaI.js","assets/MagicLinkInternationalWireDetailsPage-DwBUSxwe-x_28I9nn.js","assets/InternationalWireSwiftDetailsPage-4-pl1ozv-BL59ObmT.js","assets/MagicLinkSuccessPage-DbhdGmhh-DNYzgAJU.js","assets/Vendor2FAPopup-C_PmEAQ7-BaU4ZlJ1.js","assets/AgingReportsPage-n-UKn3Ei-CfeYGvlE.js","assets/mapSpacerToTreeNode-CWvamMX2-8qhsm047.js","assets/agingReportHelper-ovKP-qSS-Cx4Hdid-.js","assets/ApAgingDetailPage-Duu2uAEr-CuSndO2U.js","assets/EntitySummarySection-CHgrPo86-C_DZGpt7.js","assets/ArAgingDetailPage-CaOr6vAU-Dju9MqE9.js","assets/OpExByVendorPage-Dxk68R6U-TSpF0BZT.js","assets/mapTimeframeBalancesToTreeNode-_jEVk1uh-Dt-fMHUy.js","assets/VendorInternationalWireSwiftDetailsPage-BBYmlLxN-CGwvkONg.js","assets/VendorFirstReviewPage-C6MnbIan-CvuNZRdM.js","assets/NewGlobalMerchantPage-B_019EtP-Cnin4QvT.js","assets/GlobalReviewListPage-9V-xoqvs-O56nx8QU.js","assets/ScheduleDetailsPage-DebosLND-CytjKLyD.js","assets/ScheduleSequenceTable-Dd4Ep_c0-CndtHY8m.js","assets/ScheduleDetailsFixedAssetsPage-DlXqz1QQ-CI8b87nD.js","assets/LinkJETransactionPage-C0onrP5t-DohOtG77.js","assets/ChargeCardPromoPage-BwqrXrY--B5or9kQv.js","assets/ChargeCardSetupPage-DRzB7Rt4-SAR76aeK.js","assets/ChargeCardListPage-130ILwkr-xWvWRUI-.js","assets/ChargeCardListTable-EGkwcy7i-Gk77wXoS.js","assets/CardNumberSubText-DBOH0_yP-Be1TwMNo.js","assets/LockCardPage-DaVzuRMw-C59qINIA.js","assets/MyPendingActivationChargeCardListPage-DrQu6s7j-DI8j4Roq.js","assets/ChargeCardDetailPage-BQnJsfn5-D6Qm3_DY.js","assets/add-to-wallet-DgdBD8_G-CnbN5S25.js","assets/CashbackDetailPage-D-kXy6LW-DDN4yxLo.js","assets/ChargeCardStatementsPage-C3NxKjmB-Bqdh-I41.js","assets/IssueChargeCardPage-xbfFhV0O-D87TKikm.js","assets/AddToWalletPage-OJBvAKUj-CKSRCSe6.js","assets/AddAddressForCardDrawer-DfOyebHX-BnGN6mbi.js","assets/TaskManagementPage-CVXMOPf2-q63kh_yR.js","assets/NotificationsListConfig-OCeJNw1G-DxjI9EUe.js","assets/InvitePageListView-HfsehyxK-ADhebkRn.js","assets/InviteFormPage-XsnZcAvb-F0roB33R.js","assets/DrawerPage-inbhWwND-BaLC0Hdr.js","assets/NotificationsPage-FJHx_WBG-TAfeF35H.js","assets/useLongPress-GCK2COYQ-DwbMzQIX.js","assets/FeaturePreviewPage-qsUO3mUu-CQPzEAZz.js","assets/BillsBulkReviewDrawerPage-D8EGfY5P-BpW4NDmq.js","assets/ReviewOverlay-BvPN7IKD-BVyGsnOK.js","assets/ReimbursementsBulkReviewDrawerPage-DV_PLm_g-CdjeW3Za.js","assets/ExpenseAutomationOverviewPage-QZT_UFXf-Q6Yezq8W.js","assets/transaction-placeholder-CpOwZAMG-DpKoIbbu.js","assets/AIPerformancePage-4v4Fkm9f-BqYLGo1s.js","assets/ExpenseAutomationPage-Y7V_Z8rd-Nz-tHH0P.js","assets/AccountReconDetailsDrawerPage-DYKjrPwN-BReGAKzb.js","assets/InternationalWireVerificationPage-kIajgPZt-Cim3HMUE.js","assets/ExpressPayPage-CIp_R6ZQ-SvQXytoV.js","assets/TreasuryPromoPage-C6D3bF2f-xmypxDfH.js","assets/TreasuryOverviewPage-C927Rdkg-PWkTzy8N.js","assets/TreasuryStatementsPage-BE54gWl6-BusQnftI.js","assets/TreasuryTaxLetterPage-BaHut8Wc-DaO1lvfz.js","assets/WarningsDrawerPage-CzufXgaN-BVjYF7DU.js","assets/ScreenRoutes-CrZHoFIY.js","assets/analyticsHelper-Dyr99-JR.js","assets/SignInScreen-B08t21nJ.js"])))=>i.map(i=>d[i]);
2
+ import{a as b,w as C,R as Aye,b as Lc,p as i1,g as aw,e as Lye,s as Lz,d as Dz,r as Es,f as Dye,i as Mye,S as Pye,j as Iye,k as jye,l as Rye,m as Fye}from"./sentry-CTfRDee5.js";import{j as Wt,_ as kR,a as Js,u as pce,T as Oye,C as Nye,b as zye,c as W7,d as Y7,e as Bye,f as hce,g as Hye,h as Vye,L as Uye,i as Mz,k as Wye,l as Yye,P as Gye,m as qye,n as Zye,o as mce,p as Kye,q as Xye,I as Pz,r as Qye,s as Jye,t as eve,v as tve,w as rve,x as nve,y as fce,z as ove,A as ive,B as ave}from"./liveblocks-BstIT-4Z.js";import{f as gce,Y as Ih,r as el,b as sve,u as sw,g as b1,h as lve,i as ER,j as cve,R as dve,k as Y$,N as uve,l as pve,m as hve,B as mve}from"./core-BiYEzgTE.js";import{B as ev,ba as bt,bb as fve,bc as Iz,bd as B0,be as gve,bf as _R,bg as ug,bh as Ft,bi as yce,bj as vce,bk as TR,bl as co,bm as jz,bn as a1,bo as yve,bp as d7,bq as vve,br as bve,bs as wve,bt as Rz,bu as xve,bv as Cve,bw as $ve,bx as Sve,by as kve,bz as Eve,bA as _ve,bB as Tve,bC as AR,bD as Ave,bE as bP,bF as Lve,bG as bce,bH as f0,bI as Il,bJ as wce,bK as tv,bL as hr,bM as Dve,bN as jh,bO as wP,bP as Ol,bQ as Mve,bR as Pve,bS as Ive,bT as jve,bU as Rve,bV as Fve,bW as Ove,bX as Nve,bY as zve,bZ as xce,b_ as lw,b$ as Bve,c0 as Hve,c1 as Cce,c2 as Vve,c3 as Uve,c4 as $ce,c5 as Wve,c6 as Fz,c7 as Yve,c8 as Gve,c9 as Sce,ca as kce,cb as qve,cc as Ece,cd as pg,ce as cw,cf as _ce,cg as xP,ch as Zve,ci as Kve,cj as Xve,ck as rv,cl as Qve,cm as Tce,cn as Ace,co as Lce,cp as Dce,cq as Mce,cr as Jve,cs as ebe,ct as tbe,cu as Pce,cv as CP,cw as rbe,cx as Ice,cy as nbe,cz as obe,cA as ibe,cB as abe,cC as sbe,cD as lbe,cE as cbe,cF as dbe,cG as ube,cH as pbe,v as hbe,cI as dw,cJ as jce,cK as Rce,cL as mbe,cM as fbe,cN as gbe,cO as ybe,cP as vbe,cQ as bbe,cR as wbe,cS as xbe,cT as Cbe,cU as Oz,cV as $be,cW as Sbe,cX as kbe,cY as Ebe}from"./zeni-epic-state-n7oqKrUc.js";import{T as Fce,j as gr,n as m,c as at,k as rn,C as Oce,G as LR,u as _be}from"./mui-CqcpY1UR.js";import{L as Nz}from"./lottie-Dcr3TlBE.js";import{r as Tbe,m as yh}from"./analytics-C6bOaJY9.js";import{E as yn,c as hg,P as Abe}from"./recharts-bDaLwU4I.js";import{r as vi}from"./lexical-Cbl76XZt.js";import{r as Lbe}from"./utils-BI6ira9J.js";(function(){try{var e=typeof window<"u"?window:typeof Lc<"u"?Lc:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="38c7c166-f0e6-41a0-9513-8dd5c7acd88a",e._sentryDebugIdIdentifier="sentry-dbid-38c7c166-f0e6-41a0-9513-8dd5c7acd88a")}catch{}})();(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))n(o);new MutationObserver(o=>{for(const i of o)if(i.type==="childList")for(const a of i.addedNodes)a.tagName==="LINK"&&a.rel==="modulepreload"&&n(a)}).observe(document,{childList:!0,subtree:!0});function r(o){const i={};return o.integrity&&(i.integrity=o.integrity),o.referrerPolicy&&(i.referrerPolicy=o.referrerPolicy),o.crossOrigin==="use-credentials"?i.credentials="include":o.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function n(o){if(o.ep)return;o.ep=!0;const i=r(o);fetch(o.href,i)}})();var G6={},zz;function Dbe(){if(zz)return G6;zz=1;var e=gce();return G6.createRoot=e.createRoot,G6.hydrateRoot=e.hydrateRoot,G6}var Mbe=Dbe();function E0(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function or(){return or=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},or.apply(null,arguments)}function ys(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function nv(e,t){return nv=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,n){return r.__proto__=n,r},nv(e,t)}function mg(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,nv(e,t)}var vs=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof Lc<"u"?Lc:typeof self<"u"?self:{};function $r(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Bz={exports:{}},Bn={};/** @license React v16.13.1
3
3
  * react-is.production.min.js
4
4
  *
5
5
  * Copyright (c) Facebook, Inc. and its affiliates.
@@ -286,7 +286,7 @@ and limitations under the License.
286
286
  see this guide: https://github.com/louisbrunner/dnd-multi-backend/tree/master/packages/react-dnd-multi-backend#migrating-from-5xx`);if(_r(this,Os)[l])throw new Error(`You must specify a unique 'id' property in your Backend entry:
287
287
  ${JSON.stringify(i)} (conflicts with: ${JSON.stringify(_r(this,Os)[l])})`);return{id:l,instance:a,preview:i.preview??!1,transition:i.transition,skipDispatchOnTransition:i.skipDispatchOnTransition??!1}}),this.setup=()=>{if(!(typeof window>"u")){if(My.isSetUp)throw new Error("Cannot have two MultiBackends at the same time.");My.isSetUp=!0,_r(this,XI).call(this,window),_r(this,Os)[_r(this,Fs)].instance.setup()}},this.teardown=()=>{typeof window>"u"||(My.isSetUp=!1,_r(this,QI).call(this,window),_r(this,Os)[_r(this,Fs)].instance.teardown())},this.connectDragSource=(n,o,i)=>_r(this,M5).call(this,"connectDragSource",n,o,i),this.connectDragPreview=(n,o,i)=>_r(this,M5).call(this,"connectDragPreview",n,o,i),this.connectDropTarget=(n,o,i)=>_r(this,M5).call(this,"connectDropTarget",n,o,i),this.profile=()=>_r(this,Os)[_r(this,Fs)].instance.profile(),this.previewEnabled=()=>_r(this,Os)[_r(this,Fs)].preview,this.previewsList=()=>_r(this,D5),this.backendsList=()=>_r(this,ku),xl(this,XI,n=>{_r(this,ku).forEach(o=>{o.transition&&n.addEventListener(o.transition.event,_r(this,Ly))})}),xl(this,QI,n=>{_r(this,ku).forEach(o=>{o.transition&&n.removeEventListener(o.transition.event,_r(this,Ly))})}),xl(this,Ly,n=>{let o=_r(this,Fs);if(_r(this,ku).some(i=>i.id!==_r(this,Fs)&&i.transition&&i.transition.check(n)?(xh(this,Fs,i.id),!0):!1),_r(this,Fs)!==o){_r(this,Os)[o].instance.teardown(),Object.keys(_r(this,V2)).forEach(d=>{let u=_r(this,V2)[d];u.unsubscribe(),u.unsubscribe=_r(this,Dy).call(this,u.func,...u.args)}),_r(this,D5).backendChanged(this);let i=_r(this,Os)[_r(this,Fs)];if(i.instance.setup(),i.skipDispatchOnTransition)return;let a=n.constructor,l=new a(n.type,n);n.target?.dispatchEvent(l)}}),xl(this,Dy,(n,o,i,a)=>_r(this,Os)[_r(this,Fs)].instance[n](o,i,a)),xl(this,M5,(n,o,i,a)=>{let l=`${n}_${o}`,d=_r(this,Dy).call(this,n,o,i,a);return _r(this,V2)[l]={func:n,args:[o,i,a],unsubscribe:d},()=>{_r(this,V2)[l].unsubscribe(),delete _r(this,V2)[l]}}),!r||!r.backends||r.backends.length<1)throw new Error(`You must specify at least one Backend, if you are coming from 2.x.x (or don't understand this error)
288
288
  see this guide: https://github.com/louisbrunner/dnd-multi-backend/tree/master/packages/react-dnd-multi-backend#migrating-from-2xx`);xh(this,D5,new i1t),xh(this,Os,{}),xh(this,ku,[]),r.backends.forEach(n=>{let o=_r(this,KI).call(this,e,t,n);_r(this,Os)[o.id]=o,_r(this,ku).push(o)}),xh(this,Fs,_r(this,ku)[0].id),xh(this,V2,{})}},Lge=My;Fs=new WeakMap,D5=new WeakMap,Os=new WeakMap,ku=new WeakMap,V2=new WeakMap,KI=new WeakMap,XI=new WeakMap,QI=new WeakMap,Ly=new WeakMap,Dy=new WeakMap,M5=new WeakMap,Lge.isSetUp=!1;var a1t=(e,t,r)=>new Lge(e,t,r),Dge=(e,t)=>({event:e,check:t}),s1t=Dge("touchstart",e=>{let t=e;return t.touches!==null&&t.touches!==void 0}),l1t=Dge("mousedown",e=>e.type.indexOf("touch")===-1&&e.type.indexOf("mouse")!==-1);const FO=b.createContext({dragDropManager:void 0});function Nr(e,t,...r){if(c1t()&&t===void 0)throw new Error("invariant requires an error message argument");if(!e){let n;if(t===void 0)n=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{let o=0;n=new Error(t.replace(/%s/g,function(){return r[o++]})),n.name="Invariant Violation"}throw n.framesToPop=1,n}}function c1t(){return typeof i1<"u"&&!0}function d1t(e,t,r){return t.split(".").reduce((n,o)=>n&&n[o]?n[o]:r||null,e)}function u1t(e,t){return e.filter(r=>r!==t)}function Mge(e){return typeof e=="object"}function p1t(e,t){const r=new Map,n=i=>{r.set(i,r.has(i)?r.get(i)+1:1)};e.forEach(n),t.forEach(n);const o=[];return r.forEach((i,a)=>{i===1&&o.push(a)}),o}function h1t(e,t){return e.filter(r=>t.indexOf(r)>-1)}const OO="dnd-core/INIT_COORDS",fx="dnd-core/BEGIN_DRAG",NO="dnd-core/PUBLISH_DRAG_SOURCE",gx="dnd-core/HOVER",yx="dnd-core/DROP",vx="dnd-core/END_DRAG";function jQ(e,t){return{type:OO,payload:{sourceClientOffset:t||null,clientOffset:e||null}}}const m1t={type:OO,payload:{clientOffset:null,sourceClientOffset:null}};function f1t(e){return function(r=[],n={publishSource:!0}){const{publishSource:o=!0,clientOffset:i,getSourceClientOffset:a}=n,l=e.getMonitor(),d=e.getRegistry();e.dispatch(jQ(i)),g1t(r,l,d);const u=b1t(r,l);if(u==null){e.dispatch(m1t);return}let p=null;if(i){if(!a)throw new Error("getSourceClientOffset must be defined");y1t(a),p=a(u)}e.dispatch(jQ(i,p));const f=d.getSource(u).beginDrag(l,u);if(f==null)return;v1t(f),d.pinSource(u);const g=d.getSourceType(u);return{type:fx,payload:{itemType:g,item:f,sourceId:u,clientOffset:i||null,sourceClientOffset:p||null,isSourcePublic:!!o}}}}function g1t(e,t,r){Nr(!t.isDragging(),"Cannot call beginDrag while dragging."),e.forEach(function(n){Nr(r.getSource(n),"Expected sourceIds to be registered.")})}function y1t(e){Nr(typeof e=="function","When clientOffset is provided, getSourceClientOffset must be a function.")}function v1t(e){Nr(Mge(e),"Item must be an object.")}function b1t(e,t){let r=null;for(let n=e.length-1;n>=0;n--)if(t.canDragSource(e[n])){r=e[n];break}return r}function w1t(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function x1t(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{},n=Object.keys(r);typeof Object.getOwnPropertySymbols=="function"&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(o){return Object.getOwnPropertyDescriptor(r,o).enumerable}))),n.forEach(function(o){w1t(e,o,r[o])})}return e}function C1t(e){return function(r={}){const n=e.getMonitor(),o=e.getRegistry();$1t(n),E1t(n).forEach((a,l)=>{const d=S1t(a,l,o,n),u={type:yx,payload:{dropResult:x1t({},r,d)}};e.dispatch(u)})}}function $1t(e){Nr(e.isDragging(),"Cannot call drop while not dragging."),Nr(!e.didDrop(),"Cannot call drop twice during one drag operation.")}function S1t(e,t,r,n){const o=r.getTarget(e);let i=o?o.drop(n,e):void 0;return k1t(i),typeof i>"u"&&(i=t===0?{}:n.getDropResult()),i}function k1t(e){Nr(typeof e>"u"||Mge(e),"Drop result must either be an object or undefined.")}function E1t(e){const t=e.getTargetIds().filter(e.canDropOnTarget,e);return t.reverse(),t}function _1t(e){return function(){const r=e.getMonitor(),n=e.getRegistry();T1t(r);const o=r.getSourceId();return o!=null&&(n.getSource(o,!0).endDrag(r,o),n.unpinSource()),{type:vx}}}function T1t(e){Nr(e.isDragging(),"Cannot call endDrag while not dragging.")}function JI(e,t){return t===null?e===null:Array.isArray(e)?e.some(r=>r===t):e===t}function A1t(e){return function(r,{clientOffset:n}={}){L1t(r);const o=r.slice(0),i=e.getMonitor(),a=e.getRegistry(),l=i.getItemType();return M1t(o,a,l),D1t(o,i,a),P1t(o,i,a),{type:gx,payload:{targetIds:o,clientOffset:n||null}}}}function L1t(e){Nr(Array.isArray(e),"Expected targetIds to be an array.")}function D1t(e,t,r){Nr(t.isDragging(),"Cannot call hover while not dragging."),Nr(!t.didDrop(),"Cannot call hover after drop.");for(let n=0;n<e.length;n++){const o=e[n];Nr(e.lastIndexOf(o)===n,"Expected targetIds to be unique in the passed array.");const i=r.getTarget(o);Nr(i,"Expected targetIds to be registered.")}}function M1t(e,t,r){for(let n=e.length-1;n>=0;n--){const o=e[n],i=t.getTargetType(o);JI(i,r)||e.splice(n,1)}}function P1t(e,t,r){e.forEach(function(n){r.getTarget(n).hover(t,n)})}function I1t(e){return function(){if(e.getMonitor().isDragging())return{type:NO}}}function j1t(e){return{beginDrag:f1t(e),publishDragSource:I1t(e),hover:A1t(e),drop:C1t(e),endDrag:_1t(e)}}class R1t{receiveBackend(t){this.backend=t}getMonitor(){return this.monitor}getBackend(){return this.backend}getRegistry(){return this.monitor.registry}getActions(){const t=this,{dispatch:r}=this.store;function n(i){return(...a)=>{const l=i.apply(t,a);typeof l<"u"&&r(l)}}const o=j1t(this);return Object.keys(o).reduce((i,a)=>{const l=o[a];return i[a]=n(l),i},{})}dispatch(t){this.store.dispatch(t)}constructor(t,r){this.isSetUp=!1,this.handleRefCountChange=()=>{const n=this.store.getState().refCount>0;this.backend&&(n&&!this.isSetUp?(this.backend.setup(),this.isSetUp=!0):!n&&this.isSetUp&&(this.backend.teardown(),this.isSetUp=!1))},this.store=t,this.monitor=r,t.subscribe(this.handleRefCountChange)}}function F1t(e,t){return{x:e.x+t.x,y:e.y+t.y}}function Pge(e,t){return{x:e.x-t.x,y:e.y-t.y}}function O1t(e){const{clientOffset:t,initialClientOffset:r,initialSourceClientOffset:n}=e;return!t||!r||!n?null:Pge(F1t(t,n),r)}function N1t(e){const{clientOffset:t,initialClientOffset:r}=e;return!t||!r?null:Pge(t,r)}const X5=[],zO=[];X5.__IS_NONE__=!0;zO.__IS_ALL__=!0;function z1t(e,t){return e===X5?!1:e===zO||typeof t>"u"?!0:h1t(t,e).length>0}class B1t{subscribeToStateChange(t,r={}){const{handlerIds:n}=r;Nr(typeof t=="function","listener must be a function."),Nr(typeof n>"u"||Array.isArray(n),"handlerIds, when specified, must be an array of strings.");let o=this.store.getState().stateId;const i=()=>{const a=this.store.getState(),l=a.stateId;try{l===o||l===o+1&&!z1t(a.dirtyHandlerIds,n)||t()}finally{o=l}};return this.store.subscribe(i)}subscribeToOffsetChange(t){Nr(typeof t=="function","listener must be a function.");let r=this.store.getState().dragOffset;const n=()=>{const o=this.store.getState().dragOffset;o!==r&&(r=o,t())};return this.store.subscribe(n)}canDragSource(t){if(!t)return!1;const r=this.registry.getSource(t);return Nr(r,`Expected to find a valid source. sourceId=${t}`),this.isDragging()?!1:r.canDrag(this,t)}canDropOnTarget(t){if(!t)return!1;const r=this.registry.getTarget(t);if(Nr(r,`Expected to find a valid target. targetId=${t}`),!this.isDragging()||this.didDrop())return!1;const n=this.registry.getTargetType(t),o=this.getItemType();return JI(n,o)&&r.canDrop(this,t)}isDragging(){return!!this.getItemType()}isDraggingSource(t){if(!t)return!1;const r=this.registry.getSource(t,!0);if(Nr(r,`Expected to find a valid source. sourceId=${t}`),!this.isDragging()||!this.isSourcePublic())return!1;const n=this.registry.getSourceType(t),o=this.getItemType();return n!==o?!1:r.isDragging(this,t)}isOverTarget(t,r={shallow:!1}){if(!t)return!1;const{shallow:n}=r;if(!this.isDragging())return!1;const o=this.registry.getTargetType(t),i=this.getItemType();if(i&&!JI(o,i))return!1;const a=this.getTargetIds();if(!a.length)return!1;const l=a.indexOf(t);return n?l===a.length-1:l>-1}getItemType(){return this.store.getState().dragOperation.itemType}getItem(){return this.store.getState().dragOperation.item}getSourceId(){return this.store.getState().dragOperation.sourceId}getTargetIds(){return this.store.getState().dragOperation.targetIds}getDropResult(){return this.store.getState().dragOperation.dropResult}didDrop(){return this.store.getState().dragOperation.didDrop}isSourcePublic(){return!!this.store.getState().dragOperation.isSourcePublic}getInitialClientOffset(){return this.store.getState().dragOffset.initialClientOffset}getInitialSourceClientOffset(){return this.store.getState().dragOffset.initialSourceClientOffset}getClientOffset(){return this.store.getState().dragOffset.clientOffset}getSourceClientOffset(){return O1t(this.store.getState().dragOffset)}getDifferenceFromInitialOffset(){return N1t(this.store.getState().dragOffset)}constructor(t,r){this.store=t,this.registry=r}}const RQ=typeof Lc<"u"?Lc:self,Ige=RQ.MutationObserver||RQ.WebKitMutationObserver;function jge(e){return function(){const r=setTimeout(o,0),n=setInterval(o,50);function o(){clearTimeout(r),clearInterval(n),e()}}}function H1t(e){let t=1;const r=new Ige(e),n=document.createTextNode("");return r.observe(n,{characterData:!0}),function(){t=-t,n.data=t}}const V1t=typeof Ige=="function"?H1t:jge;class U1t{enqueueTask(t){const{queue:r,requestFlush:n}=this;r.length||(n(),this.flushing=!0),r[r.length]=t}constructor(){this.queue=[],this.pendingErrors=[],this.flushing=!1,this.index=0,this.capacity=1024,this.flush=()=>{const{queue:t}=this;for(;this.index<t.length;){const r=this.index;if(this.index++,t[r].call(),this.index>this.capacity){for(let n=0,o=t.length-this.index;n<o;n++)t[n]=t[n+this.index];t.length-=this.index,this.index=0}}t.length=0,this.index=0,this.flushing=!1},this.registerPendingError=t=>{this.pendingErrors.push(t),this.requestErrorThrow()},this.requestFlush=V1t(this.flush),this.requestErrorThrow=jge(()=>{if(this.pendingErrors.length)throw this.pendingErrors.shift()})}}class W1t{call(){try{this.task&&this.task()}catch(t){this.onError(t)}finally{this.task=null,this.release(this)}}constructor(t,r){this.onError=t,this.release=r,this.task=null}}class Y1t{create(t){const r=this.freeTasks,n=r.length?r.pop():new W1t(this.onError,o=>r[r.length]=o);return n.task=t,n}constructor(t){this.onError=t,this.freeTasks=[]}}const Rge=new U1t,G1t=new Y1t(Rge.registerPendingError);function q1t(e){Rge.enqueueTask(G1t.create(e))}const BO="dnd-core/ADD_SOURCE",HO="dnd-core/ADD_TARGET",VO="dnd-core/REMOVE_SOURCE",bx="dnd-core/REMOVE_TARGET";function Z1t(e){return{type:BO,payload:{sourceId:e}}}function K1t(e){return{type:HO,payload:{targetId:e}}}function X1t(e){return{type:VO,payload:{sourceId:e}}}function Q1t(e){return{type:bx,payload:{targetId:e}}}function J1t(e){Nr(typeof e.canDrag=="function","Expected canDrag to be a function."),Nr(typeof e.beginDrag=="function","Expected beginDrag to be a function."),Nr(typeof e.endDrag=="function","Expected endDrag to be a function.")}function eut(e){Nr(typeof e.canDrop=="function","Expected canDrop to be a function."),Nr(typeof e.hover=="function","Expected hover to be a function."),Nr(typeof e.drop=="function","Expected beginDrag to be a function.")}function ej(e,t){if(t&&Array.isArray(e)){e.forEach(r=>ej(r,!1));return}Nr(typeof e=="string"||typeof e=="symbol",t?"Type can only be a string, a symbol, or an array of either.":"Type can only be a string or a symbol.")}var Al;(function(e){e.SOURCE="SOURCE",e.TARGET="TARGET"})(Al||(Al={}));let tut=0;function rut(){return tut++}function nut(e){const t=rut().toString();switch(e){case Al.SOURCE:return`S${t}`;case Al.TARGET:return`T${t}`;default:throw new Error(`Unknown Handler Role: ${e}`)}}function FQ(e){switch(e[0]){case"S":return Al.SOURCE;case"T":return Al.TARGET;default:throw new Error(`Cannot parse handler ID: ${e}`)}}function OQ(e,t){const r=e.entries();let n=!1;do{const{done:o,value:[,i]}=r.next();if(i===t)return!0;n=!!o}while(!n);return!1}class out{addSource(t,r){ej(t),J1t(r);const n=this.addHandler(Al.SOURCE,t,r);return this.store.dispatch(Z1t(n)),n}addTarget(t,r){ej(t,!0),eut(r);const n=this.addHandler(Al.TARGET,t,r);return this.store.dispatch(K1t(n)),n}containsHandler(t){return OQ(this.dragSources,t)||OQ(this.dropTargets,t)}getSource(t,r=!1){return Nr(this.isSourceId(t),"Expected a valid source ID."),r&&t===this.pinnedSourceId?this.pinnedSource:this.dragSources.get(t)}getTarget(t){return Nr(this.isTargetId(t),"Expected a valid target ID."),this.dropTargets.get(t)}getSourceType(t){return Nr(this.isSourceId(t),"Expected a valid source ID."),this.types.get(t)}getTargetType(t){return Nr(this.isTargetId(t),"Expected a valid target ID."),this.types.get(t)}isSourceId(t){return FQ(t)===Al.SOURCE}isTargetId(t){return FQ(t)===Al.TARGET}removeSource(t){Nr(this.getSource(t),"Expected an existing source."),this.store.dispatch(X1t(t)),q1t(()=>{this.dragSources.delete(t),this.types.delete(t)})}removeTarget(t){Nr(this.getTarget(t),"Expected an existing target."),this.store.dispatch(Q1t(t)),this.dropTargets.delete(t),this.types.delete(t)}pinSource(t){const r=this.getSource(t);Nr(r,"Expected an existing source."),this.pinnedSourceId=t,this.pinnedSource=r}unpinSource(){Nr(this.pinnedSource,"No source is pinned at the time."),this.pinnedSourceId=null,this.pinnedSource=null}addHandler(t,r,n){const o=nut(t);return this.types.set(o,r),t===Al.SOURCE?this.dragSources.set(o,n):t===Al.TARGET&&this.dropTargets.set(o,n),o}constructor(t){this.types=new Map,this.dragSources=new Map,this.dropTargets=new Map,this.pinnedSourceId=null,this.pinnedSource=null,this.store=t}}const iut=(e,t)=>e===t;function aut(e,t){return!e&&!t?!0:!e||!t?!1:e.x===t.x&&e.y===t.y}function sut(e,t,r=iut){if(e.length!==t.length)return!1;for(let n=0;n<e.length;++n)if(!r(e[n],t[n]))return!1;return!0}function lut(e=X5,t){switch(t.type){case gx:break;case BO:case HO:case bx:case VO:return X5;case fx:case NO:case vx:case yx:default:return zO}const{targetIds:r=[],prevTargetIds:n=[]}=t.payload,o=p1t(r,n);if(!(o.length>0||!sut(r,n)))return X5;const a=n[n.length-1],l=r[r.length-1];return a!==l&&(a&&o.push(a),l&&o.push(l)),o}function cut(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function dut(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{},n=Object.keys(r);typeof Object.getOwnPropertySymbols=="function"&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(o){return Object.getOwnPropertyDescriptor(r,o).enumerable}))),n.forEach(function(o){cut(e,o,r[o])})}return e}const NQ={initialSourceClientOffset:null,initialClientOffset:null,clientOffset:null};function uut(e=NQ,t){const{payload:r}=t;switch(t.type){case OO:case fx:return{initialSourceClientOffset:r.sourceClientOffset,initialClientOffset:r.clientOffset,clientOffset:r.clientOffset};case gx:return aut(e.clientOffset,r.clientOffset)?e:dut({},e,{clientOffset:r.clientOffset});case vx:case yx:return NQ;default:return e}}function put(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function L3(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{},n=Object.keys(r);typeof Object.getOwnPropertySymbols=="function"&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(o){return Object.getOwnPropertyDescriptor(r,o).enumerable}))),n.forEach(function(o){put(e,o,r[o])})}return e}const hut={itemType:null,item:null,sourceId:null,targetIds:[],dropResult:null,didDrop:!1,isSourcePublic:null};function mut(e=hut,t){const{payload:r}=t;switch(t.type){case fx:return L3({},e,{itemType:r.itemType,item:r.item,sourceId:r.sourceId,isSourcePublic:r.isSourcePublic,dropResult:null,didDrop:!1});case NO:return L3({},e,{isSourcePublic:!0});case gx:return L3({},e,{targetIds:r.targetIds});case bx:return e.targetIds.indexOf(r.targetId)===-1?e:L3({},e,{targetIds:u1t(e.targetIds,r.targetId)});case yx:return L3({},e,{dropResult:r.dropResult,didDrop:!0,targetIds:[]});case vx:return L3({},e,{itemType:null,item:null,sourceId:null,dropResult:null,didDrop:!1,isSourcePublic:null,targetIds:[]});default:return e}}function fut(e=0,t){switch(t.type){case BO:case HO:return e+1;case VO:case bx:return e-1;default:return e}}function gut(e=0){return e+1}function yut(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function vut(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{},n=Object.keys(r);typeof Object.getOwnPropertySymbols=="function"&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(o){return Object.getOwnPropertyDescriptor(r,o).enumerable}))),n.forEach(function(o){yut(e,o,r[o])})}return e}function but(e={},t){return{dirtyHandlerIds:lut(e.dirtyHandlerIds,{type:t.type,payload:vut({},t.payload,{prevTargetIds:d1t(e,"dragOperation.targetIds",[])})}),dragOffset:uut(e.dragOffset,t),refCount:fut(e.refCount,t),dragOperation:mut(e.dragOperation,t),stateId:gut(e.stateId)}}function wut(e,t=void 0,r={},n=!1){const o=xut(n),i=new B1t(o,new out(o)),a=new R1t(o,i),l=e(a,t,r);return a.receiveBackend(l),a}function xut(e){const t=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION__;return sve(but,e&&t&&t({name:"dnd-core",instanceId:"dnd-core"}))}function Cut(e,t){if(e==null)return{};var r=$ut(e,t),n,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)n=i[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function $ut(e,t){if(e==null)return{};var r={},n=Object.keys(e),o,i;for(i=0;i<n.length;i++)o=n[i],!(t.indexOf(o)>=0)&&(r[o]=e[o]);return r}let zQ=0;const Py=Symbol.for("__REACT_DND_CONTEXT_INSTANCE__");var Sut=b.memo(function(t){var{children:r}=t,n=Cut(t,["children"]);const[o,i]=kut(n);return b.useEffect(()=>{if(i){const a=Fge();return++zQ,()=>{--zQ===0&&(a[Py]=null)}}},[]),Wt.jsx(FO.Provider,{value:o,children:r})});function kut(e){if("manager"in e)return[{dragDropManager:e.manager},!1];const t=Eut(e.backend,e.context,e.options,e.debugMode),r=!e.context;return[t,r]}function Eut(e,t=Fge(),r,n){const o=t;return o[Py]||(o[Py]={dragDropManager:wut(e,t,r,n)}),o[Py]}function Fge(){return typeof Lc<"u"?Lc:window}var eL,BQ;function _ut(){return BQ||(BQ=1,eL=function e(t,r){if(t===r)return!0;if(t&&r&&typeof t=="object"&&typeof r=="object"){if(t.constructor!==r.constructor)return!1;var n,o,i;if(Array.isArray(t)){if(n=t.length,n!=r.length)return!1;for(o=n;o--!==0;)if(!e(t[o],r[o]))return!1;return!0}if(t.constructor===RegExp)return t.source===r.source&&t.flags===r.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===r.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===r.toString();if(i=Object.keys(t),n=i.length,n!==Object.keys(r).length)return!1;for(o=n;o--!==0;)if(!Object.prototype.hasOwnProperty.call(r,i[o]))return!1;for(o=n;o--!==0;){var a=i[o];if(!e(t[a],r[a]))return!1}return!0}return t!==t&&r!==r}),eL}var Tut=_ut();const Aut=aw(Tut),lm=typeof window<"u"?b.useLayoutEffect:b.useEffect;function Oge(e,t,r){const[n,o]=b.useState(()=>t(e)),i=b.useCallback(()=>{const a=t(e);Aut(n,a)||(o(a),r&&r())},[n,e,r]);return lm(i),[n,i]}function Lut(e,t,r){const[n,o]=Oge(e,t,r);return lm(function(){const a=e.getHandlerId();if(a!=null)return e.subscribeToStateChange(o,{handlerIds:[a]})},[e,o]),n}function Nge(e,t,r){return Lut(t,e||(()=>({})),()=>r.reconnect())}function zge(e,t){const r=[];return typeof e!="function"&&r.push(e),b.useMemo(()=>typeof e=="function"?e():e,r)}function Dut(e){return b.useMemo(()=>e.hooks.dragSource(),[e])}function Mut(e){return b.useMemo(()=>e.hooks.dragPreview(),[e])}let tL=!1,rL=!1;class Put{receiveHandlerId(t){this.sourceId=t}getHandlerId(){return this.sourceId}canDrag(){Nr(!tL,"You may not call monitor.canDrag() inside your canDrag() implementation. Read more: http://react-dnd.github.io/react-dnd/docs/api/drag-source-monitor");try{return tL=!0,this.internalMonitor.canDragSource(this.sourceId)}finally{tL=!1}}isDragging(){if(!this.sourceId)return!1;Nr(!rL,"You may not call monitor.isDragging() inside your isDragging() implementation. Read more: http://react-dnd.github.io/react-dnd/docs/api/drag-source-monitor");try{return rL=!0,this.internalMonitor.isDraggingSource(this.sourceId)}finally{rL=!1}}subscribeToStateChange(t,r){return this.internalMonitor.subscribeToStateChange(t,r)}isDraggingSource(t){return this.internalMonitor.isDraggingSource(t)}isOverTarget(t,r){return this.internalMonitor.isOverTarget(t,r)}getTargetIds(){return this.internalMonitor.getTargetIds()}isSourcePublic(){return this.internalMonitor.isSourcePublic()}getSourceId(){return this.internalMonitor.getSourceId()}subscribeToOffsetChange(t){return this.internalMonitor.subscribeToOffsetChange(t)}canDragSource(t){return this.internalMonitor.canDragSource(t)}canDropOnTarget(t){return this.internalMonitor.canDropOnTarget(t)}getItemType(){return this.internalMonitor.getItemType()}getItem(){return this.internalMonitor.getItem()}getDropResult(){return this.internalMonitor.getDropResult()}didDrop(){return this.internalMonitor.didDrop()}getInitialClientOffset(){return this.internalMonitor.getInitialClientOffset()}getInitialSourceClientOffset(){return this.internalMonitor.getInitialSourceClientOffset()}getSourceClientOffset(){return this.internalMonitor.getSourceClientOffset()}getClientOffset(){return this.internalMonitor.getClientOffset()}getDifferenceFromInitialOffset(){return this.internalMonitor.getDifferenceFromInitialOffset()}constructor(t){this.sourceId=null,this.internalMonitor=t.getMonitor()}}let nL=!1;class Iut{receiveHandlerId(t){this.targetId=t}getHandlerId(){return this.targetId}subscribeToStateChange(t,r){return this.internalMonitor.subscribeToStateChange(t,r)}canDrop(){if(!this.targetId)return!1;Nr(!nL,"You may not call monitor.canDrop() inside your canDrop() implementation. Read more: http://react-dnd.github.io/react-dnd/docs/api/drop-target-monitor");try{return nL=!0,this.internalMonitor.canDropOnTarget(this.targetId)}finally{nL=!1}}isOver(t){return this.targetId?this.internalMonitor.isOverTarget(this.targetId,t):!1}getItemType(){return this.internalMonitor.getItemType()}getItem(){return this.internalMonitor.getItem()}getDropResult(){return this.internalMonitor.getDropResult()}didDrop(){return this.internalMonitor.didDrop()}getInitialClientOffset(){return this.internalMonitor.getInitialClientOffset()}getInitialSourceClientOffset(){return this.internalMonitor.getInitialSourceClientOffset()}getSourceClientOffset(){return this.internalMonitor.getSourceClientOffset()}getClientOffset(){return this.internalMonitor.getClientOffset()}getDifferenceFromInitialOffset(){return this.internalMonitor.getDifferenceFromInitialOffset()}constructor(t){this.targetId=null,this.internalMonitor=t.getMonitor()}}function jut(e,t,r){const n=r.getRegistry(),o=n.addTarget(e,t);return[o,()=>n.removeTarget(o)]}function Rut(e,t,r){const n=r.getRegistry(),o=n.addSource(e,t);return[o,()=>n.removeSource(o)]}function tj(e,t,r,n){let o;if(o!==void 0)return!!o;if(e===t)return!0;if(typeof e!="object"||!e||typeof t!="object"||!t)return!1;const i=Object.keys(e),a=Object.keys(t);if(i.length!==a.length)return!1;const l=Object.prototype.hasOwnProperty.bind(t);for(let d=0;d<i.length;d++){const u=i[d];if(!l(u))return!1;const p=e[u],h=t[u];if(o=void 0,o===!1||o===void 0&&p!==h)return!1}return!0}function rj(e){return e!==null&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function Fut(e){if(typeof e.type=="string")return;const t=e.type.displayName||e.type.name||"the component";throw new Error(`Only native element nodes can now be passed to React DnD connectors.You can either wrap ${t} into a <div>, or turn it into a drag source or a drop target itself.`)}function Out(e){return(t=null,r=null)=>{if(!b.isValidElement(t)){const i=t;return e(i,r),i}const n=t;return Fut(n),Nut(n,r?i=>e(i,r):e)}}function Bge(e){const t={};return Object.keys(e).forEach(r=>{const n=e[r];if(r.endsWith("Ref"))t[r]=e[r];else{const o=Out(n);t[r]=()=>o}}),t}function HQ(e,t){typeof e=="function"?e(t):e.current=t}function Nut(e,t){const r=e.ref;return Nr(typeof r!="string","Cannot connect React DnD to an element with an existing string ref. Please convert it to use a callback ref instead, or wrap it into a <span> or <div>. Read more: https://reactjs.org/docs/refs-and-the-dom.html#callback-refs"),r?b.cloneElement(e,{ref:n=>{HQ(r,n),HQ(t,n)}}):b.cloneElement(e,{ref:t})}class zut{receiveHandlerId(t){this.handlerId!==t&&(this.handlerId=t,this.reconnect())}get connectTarget(){return this.dragSource}get dragSourceOptions(){return this.dragSourceOptionsInternal}set dragSourceOptions(t){this.dragSourceOptionsInternal=t}get dragPreviewOptions(){return this.dragPreviewOptionsInternal}set dragPreviewOptions(t){this.dragPreviewOptionsInternal=t}reconnect(){const t=this.reconnectDragSource();this.reconnectDragPreview(t)}reconnectDragSource(){const t=this.dragSource,r=this.didHandlerIdChange()||this.didConnectedDragSourceChange()||this.didDragSourceOptionsChange();return r&&this.disconnectDragSource(),this.handlerId?t?(r&&(this.lastConnectedHandlerId=this.handlerId,this.lastConnectedDragSource=t,this.lastConnectedDragSourceOptions=this.dragSourceOptions,this.dragSourceUnsubscribe=this.backend.connectDragSource(this.handlerId,t,this.dragSourceOptions)),r):(this.lastConnectedDragSource=t,r):r}reconnectDragPreview(t=!1){const r=this.dragPreview,n=t||this.didHandlerIdChange()||this.didConnectedDragPreviewChange()||this.didDragPreviewOptionsChange();if(n&&this.disconnectDragPreview(),!!this.handlerId){if(!r){this.lastConnectedDragPreview=r;return}n&&(this.lastConnectedHandlerId=this.handlerId,this.lastConnectedDragPreview=r,this.lastConnectedDragPreviewOptions=this.dragPreviewOptions,this.dragPreviewUnsubscribe=this.backend.connectDragPreview(this.handlerId,r,this.dragPreviewOptions))}}didHandlerIdChange(){return this.lastConnectedHandlerId!==this.handlerId}didConnectedDragSourceChange(){return this.lastConnectedDragSource!==this.dragSource}didConnectedDragPreviewChange(){return this.lastConnectedDragPreview!==this.dragPreview}didDragSourceOptionsChange(){return!tj(this.lastConnectedDragSourceOptions,this.dragSourceOptions)}didDragPreviewOptionsChange(){return!tj(this.lastConnectedDragPreviewOptions,this.dragPreviewOptions)}disconnectDragSource(){this.dragSourceUnsubscribe&&(this.dragSourceUnsubscribe(),this.dragSourceUnsubscribe=void 0)}disconnectDragPreview(){this.dragPreviewUnsubscribe&&(this.dragPreviewUnsubscribe(),this.dragPreviewUnsubscribe=void 0,this.dragPreviewNode=null,this.dragPreviewRef=null)}get dragSource(){return this.dragSourceNode||this.dragSourceRef&&this.dragSourceRef.current}get dragPreview(){return this.dragPreviewNode||this.dragPreviewRef&&this.dragPreviewRef.current}clearDragSource(){this.dragSourceNode=null,this.dragSourceRef=null}clearDragPreview(){this.dragPreviewNode=null,this.dragPreviewRef=null}constructor(t){this.hooks=Bge({dragSource:(r,n)=>{this.clearDragSource(),this.dragSourceOptions=n||null,rj(r)?this.dragSourceRef=r:this.dragSourceNode=r,this.reconnectDragSource()},dragPreview:(r,n)=>{this.clearDragPreview(),this.dragPreviewOptions=n||null,rj(r)?this.dragPreviewRef=r:this.dragPreviewNode=r,this.reconnectDragPreview()}}),this.handlerId=null,this.dragSourceRef=null,this.dragSourceOptionsInternal=null,this.dragPreviewRef=null,this.dragPreviewOptionsInternal=null,this.lastConnectedHandlerId=null,this.lastConnectedDragSource=null,this.lastConnectedDragSourceOptions=null,this.lastConnectedDragPreview=null,this.lastConnectedDragPreviewOptions=null,this.backend=t}}class But{get connectTarget(){return this.dropTarget}reconnect(){const t=this.didHandlerIdChange()||this.didDropTargetChange()||this.didOptionsChange();t&&this.disconnectDropTarget();const r=this.dropTarget;if(this.handlerId){if(!r){this.lastConnectedDropTarget=r;return}t&&(this.lastConnectedHandlerId=this.handlerId,this.lastConnectedDropTarget=r,this.lastConnectedDropTargetOptions=this.dropTargetOptions,this.unsubscribeDropTarget=this.backend.connectDropTarget(this.handlerId,r,this.dropTargetOptions))}}receiveHandlerId(t){t!==this.handlerId&&(this.handlerId=t,this.reconnect())}get dropTargetOptions(){return this.dropTargetOptionsInternal}set dropTargetOptions(t){this.dropTargetOptionsInternal=t}didHandlerIdChange(){return this.lastConnectedHandlerId!==this.handlerId}didDropTargetChange(){return this.lastConnectedDropTarget!==this.dropTarget}didOptionsChange(){return!tj(this.lastConnectedDropTargetOptions,this.dropTargetOptions)}disconnectDropTarget(){this.unsubscribeDropTarget&&(this.unsubscribeDropTarget(),this.unsubscribeDropTarget=void 0)}get dropTarget(){return this.dropTargetNode||this.dropTargetRef&&this.dropTargetRef.current}clearDropTarget(){this.dropTargetRef=null,this.dropTargetNode=null}constructor(t){this.hooks=Bge({dropTarget:(r,n)=>{this.clearDropTarget(),this.dropTargetOptions=n,rj(r)?this.dropTargetRef=r:this.dropTargetNode=r,this.reconnect()}}),this.handlerId=null,this.dropTargetRef=null,this.dropTargetOptionsInternal=null,this.lastConnectedHandlerId=null,this.lastConnectedDropTarget=null,this.lastConnectedDropTargetOptions=null,this.backend=t}}function Tm(){const{dragDropManager:e}=b.useContext(FO);return Nr(e!=null,"Expected drag drop context"),e}function Hut(e,t){const r=Tm(),n=b.useMemo(()=>new zut(r.getBackend()),[r]);return lm(()=>(n.dragSourceOptions=e||null,n.reconnect(),()=>n.disconnectDragSource()),[n,e]),lm(()=>(n.dragPreviewOptions=t||null,n.reconnect(),()=>n.disconnectDragPreview()),[n,t]),n}function Vut(){const e=Tm();return b.useMemo(()=>new Put(e),[e])}class Uut{beginDrag(){const t=this.spec,r=this.monitor;let n=null;return typeof t.item=="object"?n=t.item:typeof t.item=="function"?n=t.item(r):n={},n??null}canDrag(){const t=this.spec,r=this.monitor;return typeof t.canDrag=="boolean"?t.canDrag:typeof t.canDrag=="function"?t.canDrag(r):!0}isDragging(t,r){const n=this.spec,o=this.monitor,{isDragging:i}=n;return i?i(o):r===t.getSourceId()}endDrag(){const t=this.spec,r=this.monitor,n=this.connector,{end:o}=t;o&&o(r.getItem(),r),n.reconnect()}constructor(t,r,n){this.spec=t,this.monitor=r,this.connector=n}}function Wut(e,t,r){const n=b.useMemo(()=>new Uut(e,t,r),[t,r]);return b.useEffect(()=>{n.spec=e},[e]),n}function Yut(e){return b.useMemo(()=>{const t=e.type;return Nr(t!=null,"spec.type must be defined"),t},[e])}function Gut(e,t,r){const n=Tm(),o=Wut(e,t,r),i=Yut(e);lm(function(){if(i!=null){const[l,d]=Rut(i,o,n);return t.receiveHandlerId(l),r.receiveHandlerId(l),d}},[n,t,r,o,i])}function qut(e,t){const r=zge(e);Nr(!r.begin,"useDrag::spec.begin was deprecated in v14. Replace spec.begin() with spec.item(). (see more here - https://react-dnd.github.io/react-dnd/docs/api/use-drag)");const n=Vut(),o=Hut(r.options,r.previewOptions);return Gut(r,n,o),[Nge(r.collect,n,o),Dut(o),Mut(o)]}function Zut(e){const r=Tm().getMonitor(),[n,o]=Oge(r,e);return b.useEffect(()=>r.subscribeToOffsetChange(o)),b.useEffect(()=>r.subscribeToStateChange(o)),n}function Kut(e){return b.useMemo(()=>e.hooks.dropTarget(),[e])}function Xut(e){const t=Tm(),r=b.useMemo(()=>new But(t.getBackend()),[t]);return lm(()=>(r.dropTargetOptions=e||null,r.reconnect(),()=>r.disconnectDropTarget()),[e]),r}function Qut(){const e=Tm();return b.useMemo(()=>new Iut(e),[e])}function Jut(e){const{accept:t}=e;return b.useMemo(()=>(Nr(e.accept!=null,"accept must be defined"),Array.isArray(t)?t:[t]),[t])}class e2t{canDrop(){const t=this.spec,r=this.monitor;return t.canDrop?t.canDrop(r.getItem(),r):!0}hover(){const t=this.spec,r=this.monitor;t.hover&&t.hover(r.getItem(),r)}drop(){const t=this.spec,r=this.monitor;if(t.drop)return t.drop(r.getItem(),r)}constructor(t,r){this.spec=t,this.monitor=r}}function t2t(e,t){const r=b.useMemo(()=>new e2t(e,t),[t]);return b.useEffect(()=>{r.spec=e},[e]),r}function r2t(e,t,r){const n=Tm(),o=t2t(e,t),i=Jut(e);lm(function(){const[l,d]=jut(i,o,n);return t.receiveHandlerId(l),r.receiveHandlerId(l),d},[n,t,o,r,i.map(a=>a.toString()).join("|")])}function n2t(e,t){const r=zge(e),n=Qut(),o=Xut(r.options);return r2t(r,n,o),[Nge(r.collect,n,o),Kut(o)]}var nj=(e,t)=>({x:e.x-t.x,y:e.y-t.y}),o2t=e=>{let t=e.getInitialClientOffset(),r=e.getInitialSourceClientOffset();return t===null||r===null?{x:0,y:0}:nj(t,r)},i2t=(e,t)=>{let r=e.getClientOffset();if(r===null)return null;if(!t.current||!t.current.getBoundingClientRect)return nj(r,o2t(e));let n=t.current.getBoundingClientRect(),o={x:n.width/2,y:n.height/2};return nj(r,o)},a2t=e=>{let t=`translate(${e.x.toFixed(1)}px, ${e.y.toFixed(1)}px)`;return{pointerEvents:"none",position:"fixed",top:0,left:0,transform:t,WebkitTransform:t}},s2t=()=>{let e=b.useRef(null),t=Zut(r=>({currentOffset:i2t(r,e),isDragging:r.isDragging(),itemType:r.getItemType(),item:r.getItem(),monitor:r}));return!t.isDragging||t.currentOffset===null?{display:!1}:{display:!0,itemType:t.itemType,item:t.item,style:a2t(t.currentOffset),monitor:t.monitor,ref:e}};b.createContext(void 0);var l2t=b.createContext(null),c2t=({portal:e,...t})=>{let[r,n]=b.useState(null);return C.createElement(l2t.Provider,{value:e??r},C.createElement(Sut,{backend:a1t,...t}),e?null:C.createElement("div",{ref:n}))},d2t=()=>{let[e,t]=b.useState(!1),r=b.useContext(FO);return b.useEffect(()=>{let n=r?.dragDropManager?.getBackend(),o={backendChanged:i=>{t(i.previewEnabled())}};return t(n.previewEnabled()),n.previewsList().register(o),()=>{n.previewsList().unregister(o)}},[r,r.dragDropManager]),e},u2t=()=>{let e=d2t(),t=s2t();return e?t:{display:!1}},w0;(function(e){e.mouse="mouse",e.touch="touch",e.keyboard="keyboard"})(w0||(w0={}));class p2t{get delay(){var t;return(t=this.args.delay)!==null&&t!==void 0?t:0}get scrollAngleRanges(){return this.args.scrollAngleRanges}get getDropTargetElementsAtPoint(){return this.args.getDropTargetElementsAtPoint}get ignoreContextMenu(){var t;return(t=this.args.ignoreContextMenu)!==null&&t!==void 0?t:!1}get enableHoverOutsideTarget(){var t;return(t=this.args.enableHoverOutsideTarget)!==null&&t!==void 0?t:!1}get enableKeyboardEvents(){var t;return(t=this.args.enableKeyboardEvents)!==null&&t!==void 0?t:!1}get enableMouseEvents(){var t;return(t=this.args.enableMouseEvents)!==null&&t!==void 0?t:!1}get enableTouchEvents(){var t;return(t=this.args.enableTouchEvents)!==null&&t!==void 0?t:!0}get touchSlop(){return this.args.touchSlop||0}get delayTouchStart(){var t,r,n,o;return(o=(n=(t=this.args)===null||t===void 0?void 0:t.delayTouchStart)!==null&&n!==void 0?n:(r=this.args)===null||r===void 0?void 0:r.delay)!==null&&o!==void 0?o:0}get delayMouseStart(){var t,r,n,o;return(o=(n=(t=this.args)===null||t===void 0?void 0:t.delayMouseStart)!==null&&n!==void 0?n:(r=this.args)===null||r===void 0?void 0:r.delay)!==null&&o!==void 0?o:0}get window(){if(this.context&&this.context.window)return this.context.window;if(typeof window<"u")return window}get document(){var t;if(!((t=this.context)===null||t===void 0)&&t.document)return this.context.document;if(this.window)return this.window.document}get rootElement(){var t;return((t=this.args)===null||t===void 0?void 0:t.rootElement)||this.document}constructor(t,r){this.args=t,this.context=r}}function h2t(e,t,r,n){return Math.sqrt(Math.pow(Math.abs(r-e),2)+Math.pow(Math.abs(n-t),2))}function m2t(e,t,r,n,o){if(!o)return!1;const i=Math.atan2(n-t,r-e)*180/Math.PI+180;for(let a=0;a<o.length;++a){const l=o[a];if(l&&(l.start==null||i>=l.start)&&(l.end==null||i<=l.end))return!0}return!1}const f2t={Left:1},g2t={Left:0};function oL(e){return e.button===void 0||e.button===g2t.Left}function y2t(e){return e.buttons===void 0||(e.buttons&f2t.Left)===0}function Hge(e){return!!e.targetTouches}const v2t=1;function b2t(e){const t=e.nodeType===v2t?e:e.parentElement;if(!t)return;const{top:r,left:n}=t.getBoundingClientRect();return{x:n,y:r}}function w2t(e,t){if(e.targetTouches.length===1)return nb(e.targetTouches[0]);if(t&&e.touches.length===1&&e.touches[0].target===t.target)return nb(e.touches[0])}function nb(e,t){return Hge(e)?w2t(e,t):{x:e.clientX,y:e.clientY}}const VQ=(()=>{let e=!1;try{addEventListener("test",()=>{},Object.defineProperty({},"passive",{get(){return e=!0,!0}}))}catch{}return e})(),z4={[w0.mouse]:{start:"mousedown",move:"mousemove",end:"mouseup",contextmenu:"contextmenu"},[w0.touch]:{start:"touchstart",move:"touchmove",end:"touchend"},[w0.keyboard]:{keydown:"keydown"}};class Q5{profile(){var t;return{sourceNodes:this.sourceNodes.size,sourcePreviewNodes:this.sourcePreviewNodes.size,sourcePreviewNodeOptions:this.sourcePreviewNodeOptions.size,targetNodes:this.targetNodes.size,dragOverTargetIds:((t=this.dragOverTargetIds)===null||t===void 0?void 0:t.length)||0}}get document(){return this.options.document}setup(){const t=this.options.rootElement;t&&(Nr(!Q5.isSetUp,"Cannot have two Touch backends at the same time."),Q5.isSetUp=!0,this.addEventListener(t,"start",this.getTopMoveStartHandler()),this.addEventListener(t,"start",this.handleTopMoveStartCapture,!0),this.addEventListener(t,"move",this.handleTopMove),this.addEventListener(t,"move",this.handleTopMoveCapture,!0),this.addEventListener(t,"end",this.handleTopMoveEndCapture,!0),this.options.enableMouseEvents&&!this.options.ignoreContextMenu&&this.addEventListener(t,"contextmenu",this.handleTopMoveEndCapture),this.options.enableKeyboardEvents&&this.addEventListener(t,"keydown",this.handleCancelOnEscape,!0))}teardown(){const t=this.options.rootElement;t&&(Q5.isSetUp=!1,this._mouseClientOffset={},this.removeEventListener(t,"start",this.handleTopMoveStartCapture,!0),this.removeEventListener(t,"start",this.handleTopMoveStart),this.removeEventListener(t,"move",this.handleTopMoveCapture,!0),this.removeEventListener(t,"move",this.handleTopMove),this.removeEventListener(t,"end",this.handleTopMoveEndCapture,!0),this.options.enableMouseEvents&&!this.options.ignoreContextMenu&&this.removeEventListener(t,"contextmenu",this.handleTopMoveEndCapture),this.options.enableKeyboardEvents&&this.removeEventListener(t,"keydown",this.handleCancelOnEscape,!0),this.uninstallSourceNodeRemovalObserver())}addEventListener(t,r,n,o=!1){const i=VQ?{capture:o,passive:!1}:o;this.listenerTypes.forEach(function(a){const l=z4[a][r];l&&t.addEventListener(l,n,i)})}removeEventListener(t,r,n,o=!1){const i=VQ?{capture:o,passive:!1}:o;this.listenerTypes.forEach(function(a){const l=z4[a][r];l&&t.removeEventListener(l,n,i)})}connectDragSource(t,r){const n=this.handleMoveStart.bind(this,t);return this.sourceNodes.set(t,r),this.addEventListener(r,"start",n),()=>{this.sourceNodes.delete(t),this.removeEventListener(r,"start",n)}}connectDragPreview(t,r,n){return this.sourcePreviewNodeOptions.set(t,n),this.sourcePreviewNodes.set(t,r),()=>{this.sourcePreviewNodes.delete(t),this.sourcePreviewNodeOptions.delete(t)}}connectDropTarget(t,r){const n=this.options.rootElement;if(!this.document||!n)return()=>{};const o=i=>{if(!this.document||!n||!this.monitor.isDragging())return;let a;switch(i.type){case z4.mouse.move:a={x:i.clientX,y:i.clientY};break;case z4.touch.move:var l,d;a={x:((l=i.touches[0])===null||l===void 0?void 0:l.clientX)||0,y:((d=i.touches[0])===null||d===void 0?void 0:d.clientY)||0};break}const u=a!=null?this.document.elementFromPoint(a.x,a.y):void 0,p=u&&r.contains(u);if(u===r||p)return this.handleMove(i,t)};return this.addEventListener(this.document.body,"move",o),this.targetNodes.set(t,r),()=>{this.document&&(this.targetNodes.delete(t),this.removeEventListener(this.document.body,"move",o))}}getTopMoveStartHandler(){return!this.options.delayTouchStart&&!this.options.delayMouseStart?this.handleTopMoveStart:this.handleTopMoveStartDelay}installSourceNodeRemovalObserver(t){this.uninstallSourceNodeRemovalObserver(),this.draggedSourceNode=t,this.draggedSourceNodeRemovalObserver=new MutationObserver(()=>{t&&!t.parentElement&&(this.resurrectSourceNode(),this.uninstallSourceNodeRemovalObserver())}),!(!t||!t.parentElement)&&this.draggedSourceNodeRemovalObserver.observe(t.parentElement,{childList:!0})}resurrectSourceNode(){this.document&&this.draggedSourceNode&&(this.draggedSourceNode.style.display="none",this.draggedSourceNode.removeAttribute("data-reactid"),this.document.body.appendChild(this.draggedSourceNode))}uninstallSourceNodeRemovalObserver(){this.draggedSourceNodeRemovalObserver&&this.draggedSourceNodeRemovalObserver.disconnect(),this.draggedSourceNodeRemovalObserver=void 0,this.draggedSourceNode=void 0}constructor(t,r,n){this.getSourceClientOffset=o=>{const i=this.sourceNodes.get(o);return i&&b2t(i)},this.handleTopMoveStartCapture=o=>{oL(o)&&(this.moveStartSourceIds=[])},this.handleMoveStart=o=>{Array.isArray(this.moveStartSourceIds)&&this.moveStartSourceIds.unshift(o)},this.handleTopMoveStart=o=>{if(!oL(o))return;const i=nb(o);i&&(Hge(o)&&(this.lastTargetTouchFallback=o.targetTouches[0]),this._mouseClientOffset=i),this.waitingForDelay=!1},this.handleTopMoveStartDelay=o=>{if(!oL(o))return;const i=o.type===z4.touch.start?this.options.delayTouchStart:this.options.delayMouseStart;this.timeout=setTimeout(this.handleTopMoveStart.bind(this,o),i),this.waitingForDelay=!0},this.handleTopMoveCapture=()=>{this.dragOverTargetIds=[]},this.handleMove=(o,i)=>{this.dragOverTargetIds&&this.dragOverTargetIds.unshift(i)},this.handleTopMove=o=>{if(this.timeout&&clearTimeout(this.timeout),!this.document||this.waitingForDelay)return;const{moveStartSourceIds:i,dragOverTargetIds:a}=this,l=this.options.enableHoverOutsideTarget,d=nb(o,this.lastTargetTouchFallback);if(!d)return;if(this._isScrolling||!this.monitor.isDragging()&&m2t(this._mouseClientOffset.x||0,this._mouseClientOffset.y||0,d.x,d.y,this.options.scrollAngleRanges)){this._isScrolling=!0;return}if(!this.monitor.isDragging()&&this._mouseClientOffset.hasOwnProperty("x")&&i&&h2t(this._mouseClientOffset.x||0,this._mouseClientOffset.y||0,d.x,d.y)>(this.options.touchSlop?this.options.touchSlop:0)&&(this.moveStartSourceIds=void 0,this.actions.beginDrag(i,{clientOffset:this._mouseClientOffset,getSourceClientOffset:this.getSourceClientOffset,publishSource:!1})),!this.monitor.isDragging())return;const u=this.sourceNodes.get(this.monitor.getSourceId());this.installSourceNodeRemovalObserver(u),this.actions.publishDragSource(),o.cancelable&&o.preventDefault();const p=(a||[]).map(y=>this.targetNodes.get(y)).filter(y=>!!y),h=this.options.getDropTargetElementsAtPoint?this.options.getDropTargetElementsAtPoint(d.x,d.y,p):this.document.elementsFromPoint(d.x,d.y),f=[];for(const y in h){if(!h.hasOwnProperty(y))continue;let v=h[y];for(v!=null&&f.push(v);v;)v=v.parentElement,v&&f.indexOf(v)===-1&&f.push(v)}const g=f.filter(y=>p.indexOf(y)>-1).map(y=>this._getDropTargetId(y)).filter(y=>!!y).filter((y,v,w)=>w.indexOf(y)===v);if(l)for(const y in this.targetNodes){const v=this.targetNodes.get(y);if(u&&v&&v.contains(u)&&g.indexOf(y)===-1){g.unshift(y);break}}g.reverse(),this.actions.hover(g,{clientOffset:d})},this._getDropTargetId=o=>{const i=this.targetNodes.keys();let a=i.next();for(;a.done===!1;){const l=a.value;if(o===this.targetNodes.get(l))return l;a=i.next()}},this.handleTopMoveEndCapture=o=>{if(this._isScrolling=!1,this.lastTargetTouchFallback=void 0,!!y2t(o)){if(!this.monitor.isDragging()||this.monitor.didDrop()){this.moveStartSourceIds=void 0;return}o.cancelable&&o.preventDefault(),this._mouseClientOffset={},this.uninstallSourceNodeRemovalObserver(),this.actions.drop(),this.actions.endDrag()}},this.handleCancelOnEscape=o=>{o.key==="Escape"&&this.monitor.isDragging()&&(this._mouseClientOffset={},this.uninstallSourceNodeRemovalObserver(),this.actions.endDrag())},this.options=new p2t(n,r),this.actions=t.getActions(),this.monitor=t.getMonitor(),this.sourceNodes=new Map,this.sourcePreviewNodes=new Map,this.sourcePreviewNodeOptions=new Map,this.targetNodes=new Map,this.listenerTypes=[],this._mouseClientOffset={},this._isScrolling=!1,this.options.enableMouseEvents&&this.listenerTypes.push(w0.mouse),this.options.enableTouchEvents&&this.listenerTypes.push(w0.touch),this.options.enableKeyboardEvents&&this.listenerTypes.push(w0.keyboard)}}const x2t=function(t,r={},n={}){return new Q5(t,r,n)};var $n=Tbe(),J5={};J5.d=(e,t)=>{for(var r in t)J5.o(t,r)&&!J5.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})};J5.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var kr=globalThis.pdfjsLib={};J5.d(kr,{AbortException:()=>Lm,AnnotationEditorLayer:()=>Au,AnnotationEditorParamsType:()=>Lr,AnnotationEditorType:()=>hn,AnnotationEditorUIManager:()=>I0,AnnotationLayer:()=>bpt,AnnotationMode:()=>X2,CMapCompressionType:()=>ij,ColorPicker:()=>n1,DOMSVGFactory:()=>YO,DrawLayer:()=>ba,FeatureTest:()=>bs,GlobalWorkerOptions:()=>E7,ImageKind:()=>Iy,InvalidPDFException:()=>Uge,MissingPDFException:()=>Am,OPS:()=>$c,Outliner:()=>hj,PDFDataRangeTransport:()=>s4e,PDFDateString:()=>Kge,PDFWorker:()=>kl,PasswordResponses:()=>k2t,PermissionFlag:()=>S2t,PixelsPerInch:()=>Qf,RenderingCancelledException:()=>GO,TextLayer:()=>ab,UnexpectedResponseException:()=>$x,Util:()=>lr,VerbosityLevel:()=>wx,XfaLayer:()=>c4e,build:()=>J0t,createValidAbsoluteUrl:()=>A2t,fetchData:()=>Ax,getDocument:()=>U0t,getFilenameFromUrl:()=>N2t,getPdfFilenameFromUrl:()=>z2t,getXfaPageViewport:()=>B2t,isDataScheme:()=>qO,isPdfFile:()=>ZO,noContextMenu:()=>$s,normalizeUnicode:()=>j2t,renderTextLayer:()=>j0t,setLayerDimensions:()=>cm,shadow:()=>vn,updateTextLayer:()=>R0t,version:()=>Q0t});const ka=typeof i1=="object"&&i1+""=="[object process]"&&!i1.versions.nw&&!(i1.versions.electron&&i1.type&&i1.type!=="browser"),Vge=[1,0,0,1,0,0],oj=[.001,0,0,.001,0,0],C2t=1e7,iL=1.35,$l={ANY:1,DISPLAY:2,PRINT:4,ANNOTATIONS_FORMS:16,ANNOTATIONS_STORAGE:32,ANNOTATIONS_DISABLE:64,OPLIST:256},X2={DISABLE:0,ENABLE:1,ENABLE_FORMS:2,ENABLE_STORAGE:3},$2t="pdfjs_internal_editor_",hn={DISABLE:-1,NONE:0,FREETEXT:3,HIGHLIGHT:9,STAMP:13,INK:15},Lr={RESIZE:1,CREATE:2,FREETEXT_SIZE:11,FREETEXT_COLOR:12,FREETEXT_OPACITY:13,INK_COLOR:21,INK_THICKNESS:22,INK_OPACITY:23,HIGHLIGHT_COLOR:31,HIGHLIGHT_DEFAULT_COLOR:32,HIGHLIGHT_THICKNESS:33,HIGHLIGHT_FREE:34,HIGHLIGHT_SHOW_ALL:35},S2t={PRINT:4,MODIFY_CONTENTS:8,COPY:16,MODIFY_ANNOTATIONS:32,FILL_INTERACTIVE_FORMS:256,COPY_FOR_ACCESSIBILITY:512,ASSEMBLE:1024,PRINT_HIGH_QUALITY:2048},va={FILL:0,STROKE:1,FILL_STROKE:2,INVISIBLE:3,FILL_STROKE_MASK:3,ADD_TO_PATH_FLAG:4},Iy={GRAYSCALE_1BPP:1,RGB_24BPP:2,RGBA_32BPP:3},Si={TEXT:1,LINK:2,FREETEXT:3,LINE:4,SQUARE:5,CIRCLE:6,POLYGON:7,POLYLINE:8,HIGHLIGHT:9,UNDERLINE:10,SQUIGGLY:11,STRIKEOUT:12,STAMP:13,CARET:14,INK:15,POPUP:16,FILEATTACHMENT:17,WIDGET:20},B4={SOLID:1,DASHED:2,BEVELED:3,INSET:4,UNDERLINE:5},wx={ERRORS:0,WARNINGS:1,INFOS:5},ij={NONE:0,BINARY:1},$c={dependency:1,setLineWidth:2,setLineCap:3,setLineJoin:4,setMiterLimit:5,setDash:6,setRenderingIntent:7,setFlatness:8,setGState:9,save:10,restore:11,transform:12,moveTo:13,lineTo:14,curveTo:15,curveTo2:16,curveTo3:17,closePath:18,rectangle:19,stroke:20,closeStroke:21,fill:22,eoFill:23,fillStroke:24,eoFillStroke:25,closeFillStroke:26,closeEOFillStroke:27,endPath:28,clip:29,eoClip:30,beginText:31,endText:32,setCharSpacing:33,setWordSpacing:34,setHScale:35,setLeading:36,setFont:37,setTextRenderingMode:38,setTextRise:39,moveText:40,setLeadingMoveText:41,setTextMatrix:42,nextLine:43,showText:44,showSpacedText:45,nextLineShowText:46,nextLineSetSpacingShowText:47,setCharWidth:48,setCharWidthAndBounds:49,setStrokeColorSpace:50,setFillColorSpace:51,setStrokeColor:52,setStrokeColorN:53,setFillColor:54,setFillColorN:55,setStrokeGray:56,setFillGray:57,setStrokeRGBColor:58,setFillRGBColor:59,setStrokeCMYKColor:60,setFillCMYKColor:61,shadingFill:62,beginInlineImage:63,beginImageData:64,endInlineImage:65,paintXObject:66,markPoint:67,markPointProps:68,beginMarkedContent:69,beginMarkedContentProps:70,endMarkedContent:71,beginCompat:72,endCompat:73,paintFormXObjectBegin:74,paintFormXObjectEnd:75,beginGroup:76,endGroup:77,beginAnnotation:80,endAnnotation:81,paintImageMaskXObject:83,paintImageMaskXObjectGroup:84,paintImageXObject:85,paintInlineImageXObject:86,paintInlineImageXObjectGroup:87,paintImageXObjectRepeat:88,paintImageMaskXObjectRepeat:89,paintSolidColorImageMask:90,constructPath:91},k2t={NEED_PASSWORD:1,INCORRECT_PASSWORD:2};let xx=wx.WARNINGS;function E2t(e){Number.isInteger(e)&&(xx=e)}function _2t(){return xx}function Cx(e){xx>=wx.INFOS&&console.log(`Info: ${e}`)}function Jr(e){xx>=wx.WARNINGS&&console.log(`Warning: ${e}`)}function Xn(e){throw new Error(e)}function Ai(e,t){e||Xn(t)}function T2t(e){switch(e?.protocol){case"http:":case"https:":case"ftp:":case"mailto:":case"tel:":return!0;default:return!1}}function A2t(e,t=null,r=null){if(!e)return null;try{if(r&&typeof e=="string"&&(r.addDefaultProtocol&&e.startsWith("www.")&&e.match(/\./g)?.length>=2&&(e=`http://${e}`),r.tryConvertEncoding))try{e=I2t(e)}catch{}const n=t?new URL(e,t):new URL(e);if(T2t(n))return n}catch{}return null}function vn(e,t,r,n=!1){return Object.defineProperty(e,t,{value:r,enumerable:!n,configurable:!0,writable:!1}),r}const q0=function(){function t(r,n){this.constructor===t&&Xn("Cannot initialize BaseException."),this.message=r,this.name=n}return t.prototype=new Error,t.constructor=t,t}();class aj extends q0{constructor(t,r){super(t,"PasswordException"),this.code=r}}class sj extends q0{constructor(t,r){super(t,"UnknownErrorException"),this.details=r}}class Uge extends q0{constructor(t){super(t,"InvalidPDFException")}}class Am extends q0{constructor(t){super(t,"MissingPDFException")}}class $x extends q0{constructor(t,r){super(t,"UnexpectedResponseException"),this.status=r}}class L2t extends q0{constructor(t){super(t,"FormatError")}}class Lm extends q0{constructor(t){super(t,"AbortException")}}function Wge(e){(typeof e!="object"||e?.length===void 0)&&Xn("Invalid argument for bytesToString");const t=e.length,r=8192;if(t<r)return String.fromCharCode.apply(null,e);const n=[];for(let o=0;o<t;o+=r){const i=Math.min(o+r,t),a=e.subarray(o,i);n.push(String.fromCharCode.apply(null,a))}return n.join("")}function Sx(e){typeof e!="string"&&Xn("Invalid argument for stringToBytes");const t=e.length,r=new Uint8Array(t);for(let n=0;n<t;++n)r[n]=e.charCodeAt(n)&255;return r}function D2t(e){return String.fromCharCode(e>>24&255,e>>16&255,e>>8&255,e&255)}function UO(e){const t=Object.create(null);for(const[r,n]of e)t[r]=n;return t}function M2t(){const e=new Uint8Array(4);return e[0]=1,new Uint32Array(e.buffer,0,1)[0]===1}function P2t(){try{return new Function(""),!0}catch{return!1}}class bs{static get isLittleEndian(){return vn(this,"isLittleEndian",M2t())}static get isEvalSupported(){return vn(this,"isEvalSupported",P2t())}static get isOffscreenCanvasSupported(){return vn(this,"isOffscreenCanvasSupported",typeof OffscreenCanvas<"u")}static get platform(){return typeof navigator<"u"&&typeof navigator?.platform=="string"?vn(this,"platform",{isMac:navigator.platform.includes("Mac")}):vn(this,"platform",{isMac:!1})}static get isCSSRoundSupported(){return vn(this,"isCSSRoundSupported",globalThis.CSS?.supports?.("width: round(1.5px, 1px)"))}}const aL=Array.from(Array(256).keys(),e=>e.toString(16).padStart(2,"0"));class lr{static makeHexColor(t,r,n){return`#${aL[t]}${aL[r]}${aL[n]}`}static scaleMinMax(t,r){let n;t[0]?(t[0]<0&&(n=r[0],r[0]=r[2],r[2]=n),r[0]*=t[0],r[2]*=t[0],t[3]<0&&(n=r[1],r[1]=r[3],r[3]=n),r[1]*=t[3],r[3]*=t[3]):(n=r[0],r[0]=r[1],r[1]=n,n=r[2],r[2]=r[3],r[3]=n,t[1]<0&&(n=r[1],r[1]=r[3],r[3]=n),r[1]*=t[1],r[3]*=t[1],t[2]<0&&(n=r[0],r[0]=r[2],r[2]=n),r[0]*=t[2],r[2]*=t[2]),r[0]+=t[4],r[1]+=t[5],r[2]+=t[4],r[3]+=t[5]}static transform(t,r){return[t[0]*r[0]+t[2]*r[1],t[1]*r[0]+t[3]*r[1],t[0]*r[2]+t[2]*r[3],t[1]*r[2]+t[3]*r[3],t[0]*r[4]+t[2]*r[5]+t[4],t[1]*r[4]+t[3]*r[5]+t[5]]}static applyTransform(t,r){const n=t[0]*r[0]+t[1]*r[2]+r[4],o=t[0]*r[1]+t[1]*r[3]+r[5];return[n,o]}static applyInverseTransform(t,r){const n=r[0]*r[3]-r[1]*r[2],o=(t[0]*r[3]-t[1]*r[2]+r[2]*r[5]-r[4]*r[3])/n,i=(-t[0]*r[1]+t[1]*r[0]+r[4]*r[1]-r[5]*r[0])/n;return[o,i]}static getAxialAlignedBoundingBox(t,r){const n=this.applyTransform(t,r),o=this.applyTransform(t.slice(2,4),r),i=this.applyTransform([t[0],t[3]],r),a=this.applyTransform([t[2],t[1]],r);return[Math.min(n[0],o[0],i[0],a[0]),Math.min(n[1],o[1],i[1],a[1]),Math.max(n[0],o[0],i[0],a[0]),Math.max(n[1],o[1],i[1],a[1])]}static inverseTransform(t){const r=t[0]*t[3]-t[1]*t[2];return[t[3]/r,-t[1]/r,-t[2]/r,t[0]/r,(t[2]*t[5]-t[4]*t[3])/r,(t[4]*t[1]-t[5]*t[0])/r]}static singularValueDecompose2dScale(t){const r=[t[0],t[2],t[1],t[3]],n=t[0]*r[0]+t[1]*r[2],o=t[0]*r[1]+t[1]*r[3],i=t[2]*r[0]+t[3]*r[2],a=t[2]*r[1]+t[3]*r[3],l=(n+a)/2,d=Math.sqrt((n+a)**2-4*(n*a-i*o))/2,u=l+d||1,p=l-d||1;return[Math.sqrt(u),Math.sqrt(p)]}static normalizeRect(t){const r=t.slice(0);return t[0]>t[2]&&(r[0]=t[2],r[2]=t[0]),t[1]>t[3]&&(r[1]=t[3],r[3]=t[1]),r}static intersect(t,r){const n=Math.max(Math.min(t[0],t[2]),Math.min(r[0],r[2])),o=Math.min(Math.max(t[0],t[2]),Math.max(r[0],r[2]));if(n>o)return null;const i=Math.max(Math.min(t[1],t[3]),Math.min(r[1],r[3])),a=Math.min(Math.max(t[1],t[3]),Math.max(r[1],r[3]));return i>a?null:[n,i,o,a]}static#e(t,r,n,o,i,a,l,d,u,p){if(u<=0||u>=1)return;const h=1-u,f=u*u,g=f*u,y=h*(h*(h*t+3*u*r)+3*f*n)+g*o,v=h*(h*(h*i+3*u*a)+3*f*l)+g*d;p[0]=Math.min(p[0],y),p[1]=Math.min(p[1],v),p[2]=Math.max(p[2],y),p[3]=Math.max(p[3],v)}static#t(t,r,n,o,i,a,l,d,u,p,h,f){if(Math.abs(u)<1e-12){Math.abs(p)>=1e-12&&this.#e(t,r,n,o,i,a,l,d,-h/p,f);return}const g=p**2-4*h*u;if(g<0)return;const y=Math.sqrt(g),v=2*u;this.#e(t,r,n,o,i,a,l,d,(-p+y)/v,f),this.#e(t,r,n,o,i,a,l,d,(-p-y)/v,f)}static bezierBoundingBox(t,r,n,o,i,a,l,d,u){return u?(u[0]=Math.min(u[0],t,l),u[1]=Math.min(u[1],r,d),u[2]=Math.max(u[2],t,l),u[3]=Math.max(u[3],r,d)):u=[Math.min(t,l),Math.min(r,d),Math.max(t,l),Math.max(r,d)],this.#t(t,n,i,l,r,o,a,d,3*(-t+3*(n-i)+l),6*(t-2*n+i),3*(n-t),u),this.#t(t,n,i,l,r,o,a,d,3*(-r+3*(o-a)+d),6*(r-2*o+a),3*(o-r),u),u}}function I2t(e){return decodeURIComponent(escape(e))}let sL=null,UQ=null;function j2t(e){return sL||(sL=/([\u00a0\u00b5\u037e\u0eb3\u2000-\u200a\u202f\u2126\ufb00-\ufb04\ufb06\ufb20-\ufb36\ufb38-\ufb3c\ufb3e\ufb40-\ufb41\ufb43-\ufb44\ufb46-\ufba1\ufba4-\ufba9\ufbae-\ufbb1\ufbd3-\ufbdc\ufbde-\ufbe7\ufbea-\ufbf8\ufbfc-\ufbfd\ufc00-\ufc5d\ufc64-\ufcf1\ufcf5-\ufd3d\ufd88\ufdf4\ufdfa-\ufdfb\ufe71\ufe77\ufe79\ufe7b\ufe7d]+)|(\ufb05+)/gu,UQ=new Map([["ſt","ſt"]])),e.replaceAll(sL,(t,r,n)=>r?r.normalize("NFKC"):UQ.get(n))}function R2t(){if(typeof crypto<"u"&&typeof crypto?.randomUUID=="function")return crypto.randomUUID();const e=new Uint8Array(32);if(typeof crypto<"u"&&typeof crypto?.getRandomValues=="function")crypto.getRandomValues(e);else for(let t=0;t<32;t++)e[t]=Math.floor(Math.random()*255);return Wge(e)}const Yge="pdfjs_internal_id_",mu={BEZIER_CURVE_TO:0,MOVE_TO:1,LINE_TO:2,QUADRATIC_CURVE_TO:3,RESTORE:4,SAVE:5,SCALE:6,TRANSFORM:7,TRANSLATE:8};class kx{constructor(){this.constructor===kx&&Xn("Cannot initialize BaseFilterFactory.")}addFilter(t){return"none"}addHCMFilter(t,r){return"none"}addAlphaFilter(t){return"none"}addLuminosityFilter(t){return"none"}addHighlightHCMFilter(t,r,n,o,i){return"none"}destroy(t=!1){}}class Ex{#e=!1;constructor({enableHWA:t=!1}={}){this.constructor===Ex&&Xn("Cannot initialize BaseCanvasFactory."),this.#e=t}create(t,r){if(t<=0||r<=0)throw new Error("Invalid canvas size");const n=this._createCanvas(t,r);return{canvas:n,context:n.getContext("2d",{willReadFrequently:!this.#e})}}reset(t,r,n){if(!t.canvas)throw new Error("Canvas is not specified");if(r<=0||n<=0)throw new Error("Invalid canvas size");t.canvas.width=r,t.canvas.height=n}destroy(t){if(!t.canvas)throw new Error("Canvas is not specified");t.canvas.width=0,t.canvas.height=0,t.canvas=null,t.context=null}_createCanvas(t,r){Xn("Abstract method `_createCanvas` called.")}}class _x{constructor({baseUrl:t=null,isCompressed:r=!0}){this.constructor===_x&&Xn("Cannot initialize BaseCMapReaderFactory."),this.baseUrl=t,this.isCompressed=r}async fetch({name:t}){if(!this.baseUrl)throw new Error('The CMap "baseUrl" parameter must be specified, ensure that the "cMapUrl" and "cMapPacked" API parameters are provided.');if(!t)throw new Error("CMap name must be specified.");const r=this.baseUrl+t+(this.isCompressed?".bcmap":""),n=this.isCompressed?ij.BINARY:ij.NONE;return this._fetchData(r,n).catch(o=>{throw new Error(`Unable to load ${this.isCompressed?"binary ":""}CMap at: ${r}`)})}_fetchData(t,r){Xn("Abstract method `_fetchData` called.")}}class Tx{constructor({baseUrl:t=null}){this.constructor===Tx&&Xn("Cannot initialize BaseStandardFontDataFactory."),this.baseUrl=t}async fetch({filename:t}){if(!this.baseUrl)throw new Error('The standard font "baseUrl" parameter must be specified, ensure that the "standardFontDataUrl" API parameter is provided.');if(!t)throw new Error("Font filename must be specified.");const r=`${this.baseUrl}${t}`;return this._fetchData(r).catch(n=>{throw new Error(`Unable to load font data at: ${r}`)})}_fetchData(t){Xn("Abstract method `_fetchData` called.")}}class WO{constructor(){this.constructor===WO&&Xn("Cannot initialize BaseSVGFactory.")}create(t,r,n=!1){if(t<=0||r<=0)throw new Error("Invalid SVG dimensions");const o=this._createSVG("svg:svg");return o.setAttribute("version","1.1"),n||(o.setAttribute("width",`${t}px`),o.setAttribute("height",`${r}px`)),o.setAttribute("preserveAspectRatio","none"),o.setAttribute("viewBox",`0 0 ${t} ${r}`),o}createElement(t){if(typeof t!="string")throw new Error("Invalid SVG element type");return this._createSVG(t)}_createSVG(t){Xn("Abstract method `_createSVG` called.")}}const Eu="http://www.w3.org/2000/svg";class Qf{static CSS=96;static PDF=72;static PDF_TO_CSS_UNITS=this.CSS/this.PDF}class F2t extends kx{#e;#t;#r;#o;#s;#n=0;constructor({docId:t,ownerDocument:r=globalThis.document}={}){super(),this.#r=t,this.#o=r}get#i(){return this.#e||=new Map}get#l(){return this.#s||=new Map}get#d(){if(!this.#t){const t=this.#o.createElement("div"),{style:r}=t;r.visibility="hidden",r.contain="strict",r.width=r.height=0,r.position="absolute",r.top=r.left=0,r.zIndex=-1;const n=this.#o.createElementNS(Eu,"svg");n.setAttribute("width",0),n.setAttribute("height",0),this.#t=this.#o.createElementNS(Eu,"defs"),t.append(n),n.append(this.#t),this.#o.body.append(t)}return this.#t}#u(t){if(t.length===1){const d=t[0],u=new Array(256);for(let h=0;h<256;h++)u[h]=d[h]/255;const p=u.join(",");return[p,p,p]}const[r,n,o]=t,i=new Array(256),a=new Array(256),l=new Array(256);for(let d=0;d<256;d++)i[d]=r[d]/255,a[d]=n[d]/255,l[d]=o[d]/255;return[i.join(","),a.join(","),l.join(",")]}addFilter(t){if(!t)return"none";let r=this.#i.get(t);if(r)return r;const[n,o,i]=this.#u(t),a=t.length===1?n:`${n}${o}${i}`;if(r=this.#i.get(a),r)return this.#i.set(t,r),r;const l=`g_${this.#r}_transfer_map_${this.#n++}`,d=`url(#${l})`;this.#i.set(t,d),this.#i.set(a,d);const u=this.#a(l);return this.#g(n,o,i,u),d}addHCMFilter(t,r){const n=`${t}-${r}`,o="base";let i=this.#l.get(o);if(i?.key===n||(i?(i.filter?.remove(),i.key=n,i.url="none",i.filter=null):(i={key:n,url:"none",filter:null},this.#l.set(o,i)),!t||!r))return i.url;const a=this.#v(t);t=lr.makeHexColor(...a);const l=this.#v(r);if(r=lr.makeHexColor(...l),this.#d.style.color="",t==="#000000"&&r==="#ffffff"||t===r)return i.url;const d=new Array(256);for(let g=0;g<=255;g++){const y=g/255;d[g]=y<=.03928?y/12.92:((y+.055)/1.055)**2.4}const u=d.join(","),p=`g_${this.#r}_hcm_filter`,h=i.filter=this.#a(p);this.#g(u,u,u,h),this.#c(h);const f=(g,y)=>{const v=a[g]/255,w=l[g]/255,x=new Array(y+1);for(let $=0;$<=y;$++)x[$]=v+$/y*(w-v);return x.join(",")};return this.#g(f(0,5),f(1,5),f(2,5),h),i.url=`url(#${p})`,i.url}addAlphaFilter(t){let r=this.#i.get(t);if(r)return r;const[n]=this.#u([t]),o=`alpha_${n}`;if(r=this.#i.get(o),r)return this.#i.set(t,r),r;const i=`g_${this.#r}_alpha_map_${this.#n++}`,a=`url(#${i})`;this.#i.set(t,a),this.#i.set(o,a);const l=this.#a(i);return this.#p(n,l),a}addLuminosityFilter(t){let r=this.#i.get(t||"luminosity");if(r)return r;let n,o;if(t?([n]=this.#u([t]),o=`luminosity_${n}`):o="luminosity",r=this.#i.get(o),r)return this.#i.set(t,r),r;const i=`g_${this.#r}_luminosity_map_${this.#n++}`,a=`url(#${i})`;this.#i.set(t,a),this.#i.set(o,a);const l=this.#a(i);return this.#h(l),t&&this.#p(n,l),a}addHighlightHCMFilter(t,r,n,o,i){const a=`${r}-${n}-${o}-${i}`;let l=this.#l.get(t);if(l?.key===a||(l?(l.filter?.remove(),l.key=a,l.url="none",l.filter=null):(l={key:a,url:"none",filter:null},this.#l.set(t,l)),!r||!n))return l.url;const[d,u]=[r,n].map(this.#v.bind(this));let p=Math.round(.2126*d[0]+.7152*d[1]+.0722*d[2]),h=Math.round(.2126*u[0]+.7152*u[1]+.0722*u[2]),[f,g]=[o,i].map(this.#v.bind(this));h<p&&([p,h,f,g]=[h,p,g,f]),this.#d.style.color="";const y=(x,$,S)=>{const k=new Array(256),T=(h-p)/S,E=x/255,A=($-x)/(255*S);let D=0;for(let P=0;P<=S;P++){const j=Math.round(p+P*T),B=E+P*A;for(let O=D;O<=j;O++)k[O]=B;D=j+1}for(let P=D;P<256;P++)k[P]=k[D-1];return k.join(",")},v=`g_${this.#r}_hcm_${t}_filter`,w=l.filter=this.#a(v);return this.#c(w),this.#g(y(f[0],g[0],5),y(f[1],g[1],5),y(f[2],g[2],5),w),l.url=`url(#${v})`,l.url}destroy(t=!1){t&&this.#l.size!==0||(this.#t&&(this.#t.parentNode.parentNode.remove(),this.#t=null),this.#e&&(this.#e.clear(),this.#e=null),this.#n=0)}#h(t){const r=this.#o.createElementNS(Eu,"feColorMatrix");r.setAttribute("type","matrix"),r.setAttribute("values","0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.3 0.59 0.11 0 0"),t.append(r)}#c(t){const r=this.#o.createElementNS(Eu,"feColorMatrix");r.setAttribute("type","matrix"),r.setAttribute("values","0.2126 0.7152 0.0722 0 0 0.2126 0.7152 0.0722 0 0 0.2126 0.7152 0.0722 0 0 0 0 0 1 0"),t.append(r)}#a(t){const r=this.#o.createElementNS(Eu,"filter");return r.setAttribute("color-interpolation-filters","sRGB"),r.setAttribute("id",t),this.#d.append(r),r}#m(t,r,n){const o=this.#o.createElementNS(Eu,r);o.setAttribute("type","discrete"),o.setAttribute("tableValues",n),t.append(o)}#g(t,r,n,o){const i=this.#o.createElementNS(Eu,"feComponentTransfer");o.append(i),this.#m(i,"feFuncR",t),this.#m(i,"feFuncG",r),this.#m(i,"feFuncB",n)}#p(t,r){const n=this.#o.createElementNS(Eu,"feComponentTransfer");r.append(n),this.#m(n,"feFuncA",t)}#v(t){return this.#d.style.color=t,KO(getComputedStyle(this.#d).getPropertyValue("color"))}}class O2t extends Ex{constructor({ownerDocument:t=globalThis.document,enableHWA:r=!1}={}){super({enableHWA:r}),this._document=t}_createCanvas(t,r){const n=this._document.createElement("canvas");return n.width=t,n.height=r,n}}async function Ax(e,t="text"){if(P5(e,document.baseURI)){const r=await fetch(e);if(!r.ok)throw new Error(r.statusText);switch(t){case"arraybuffer":return r.arrayBuffer();case"blob":return r.blob();case"json":return r.json()}return r.text()}return new Promise((r,n)=>{const o=new XMLHttpRequest;o.open("GET",e,!0),o.responseType=t,o.onreadystatechange=()=>{if(o.readyState===XMLHttpRequest.DONE){if(o.status===200||o.status===0){switch(t){case"arraybuffer":case"blob":case"json":r(o.response);return}r(o.responseText);return}n(new Error(o.statusText))}},o.send(null)})}class Gge extends _x{_fetchData(t,r){return Ax(t,this.isCompressed?"arraybuffer":"text").then(n=>({cMapData:n instanceof ArrayBuffer?new Uint8Array(n):Sx(n),compressionType:r}))}}class qge extends Tx{_fetchData(t){return Ax(t,"arraybuffer").then(r=>new Uint8Array(r))}}class YO extends WO{_createSVG(t){return document.createElementNS(Eu,t)}}class u6{constructor({viewBox:t,scale:r,rotation:n,offsetX:o=0,offsetY:i=0,dontFlip:a=!1}){this.viewBox=t,this.scale=r,this.rotation=n,this.offsetX=o,this.offsetY=i;const l=(t[2]+t[0])/2,d=(t[3]+t[1])/2;let u,p,h,f;switch(n%=360,n<0&&(n+=360),n){case 180:u=-1,p=0,h=0,f=1;break;case 90:u=0,p=1,h=1,f=0;break;case 270:u=0,p=-1,h=-1,f=0;break;case 0:u=1,p=0,h=0,f=-1;break;default:throw new Error("PageViewport: Invalid rotation, must be a multiple of 90 degrees.")}a&&(h=-h,f=-f);let g,y,v,w;u===0?(g=Math.abs(d-t[1])*r+o,y=Math.abs(l-t[0])*r+i,v=(t[3]-t[1])*r,w=(t[2]-t[0])*r):(g=Math.abs(l-t[0])*r+o,y=Math.abs(d-t[1])*r+i,v=(t[2]-t[0])*r,w=(t[3]-t[1])*r),this.transform=[u*r,p*r,h*r,f*r,g-u*r*l-h*r*d,y-p*r*l-f*r*d],this.width=v,this.height=w}get rawDims(){const{viewBox:t}=this;return vn(this,"rawDims",{pageWidth:t[2]-t[0],pageHeight:t[3]-t[1],pageX:t[0],pageY:t[1]})}clone({scale:t=this.scale,rotation:r=this.rotation,offsetX:n=this.offsetX,offsetY:o=this.offsetY,dontFlip:i=!1}={}){return new u6({viewBox:this.viewBox.slice(),scale:t,rotation:r,offsetX:n,offsetY:o,dontFlip:i})}convertToViewportPoint(t,r){return lr.applyTransform([t,r],this.transform)}convertToViewportRectangle(t){const r=lr.applyTransform([t[0],t[1]],this.transform),n=lr.applyTransform([t[2],t[3]],this.transform);return[r[0],r[1],n[0],n[1]]}convertToPdfPoint(t,r){return lr.applyInverseTransform([t,r],this.transform)}}class GO extends q0{constructor(t,r=0){super(t,"RenderingCancelledException"),this.extraDelay=r}}function qO(e){const t=e.length;let r=0;for(;r<t&&e[r].trim()==="";)r++;return e.substring(r,r+5).toLowerCase()==="data:"}function ZO(e){return typeof e=="string"&&/\.pdf$/i.test(e)}function N2t(e){return[e]=e.split(/[#?]/,1),e.substring(e.lastIndexOf("/")+1)}function z2t(e,t="document.pdf"){if(typeof e!="string")return t;if(qO(e))return Jr('getPdfFilenameFromUrl: ignore "data:"-URL for performance reasons.'),t;const r=/^(?:(?:[^:]+:)?\/\/[^/]+)?([^?#]*)(\?[^#]*)?(#.*)?$/,n=/[^/?#=]+\.pdf\b(?!.*\.pdf\b)/i,o=r.exec(e);let i=n.exec(o[1])||n.exec(o[2])||n.exec(o[3]);if(i&&(i=i[0],i.includes("%")))try{i=n.exec(decodeURIComponent(i))[0]}catch{}return i||t}class WQ{started=Object.create(null);times=[];time(t){t in this.started&&Jr(`Timer is already running for ${t}`),this.started[t]=Date.now()}timeEnd(t){t in this.started||Jr(`Timer has not been started for ${t}`),this.times.push({name:t,start:this.started[t],end:Date.now()}),delete this.started[t]}toString(){const t=[];let r=0;for(const{name:n}of this.times)r=Math.max(n.length,r);for(const{name:n,start:o,end:i}of this.times)t.push(`${n.padEnd(r)} ${i-o}ms
289
- `);return t.join("")}}function P5(e,t){try{const{protocol:r}=t?new URL(e,t):new URL(e);return r==="http:"||r==="https:"}catch{return!1}}function $s(e){e.preventDefault()}function Zge(e){console.log("Deprecated API usage: "+e)}let YQ;class Kge{static toDateObject(t){if(!t||typeof t!="string")return null;YQ||=new RegExp("^D:(\\d{4})(\\d{2})?(\\d{2})?(\\d{2})?(\\d{2})?(\\d{2})?([Z|+|-])?(\\d{2})?'?(\\d{2})?'?");const r=YQ.exec(t);if(!r)return null;const n=parseInt(r[1],10);let o=parseInt(r[2],10);o=o>=1&&o<=12?o-1:0;let i=parseInt(r[3],10);i=i>=1&&i<=31?i:1;let a=parseInt(r[4],10);a=a>=0&&a<=23?a:0;let l=parseInt(r[5],10);l=l>=0&&l<=59?l:0;let d=parseInt(r[6],10);d=d>=0&&d<=59?d:0;const u=r[7]||"Z";let p=parseInt(r[8],10);p=p>=0&&p<=23?p:0;let h=parseInt(r[9],10)||0;return h=h>=0&&h<=59?h:0,u==="-"?(a+=p,l+=h):u==="+"&&(a-=p,l-=h),new Date(Date.UTC(n,o,i,a,l,d))}}function B2t(e,{scale:t=1,rotation:r=0}){const{width:n,height:o}=e.attributes.style,i=[0,0,parseInt(n),parseInt(o)];return new u6({viewBox:i,scale:t,rotation:r})}function KO(e){if(e.startsWith("#")){const t=parseInt(e.slice(1),16);return[(t&16711680)>>16,(t&65280)>>8,t&255]}return e.startsWith("rgb(")?e.slice(4,-1).split(",").map(t=>parseInt(t)):e.startsWith("rgba(")?e.slice(5,-1).split(",").map(t=>parseInt(t)).slice(0,3):(Jr(`Not a valid color format: "${e}"`),[0,0,0])}function H2t(e){const t=document.createElement("span");t.style.visibility="hidden",document.body.append(t);for(const r of e.keys()){t.style.color=r;const n=window.getComputedStyle(t).color;e.set(r,KO(n))}t.remove()}function Io(e){const{a:t,b:r,c:n,d:o,e:i,f:a}=e.getTransform();return[t,r,n,o,i,a]}function fu(e){const{a:t,b:r,c:n,d:o,e:i,f:a}=e.getTransform().invertSelf();return[t,r,n,o,i,a]}function cm(e,t,r=!1,n=!0){if(t instanceof u6){const{pageWidth:o,pageHeight:i}=t.rawDims,{style:a}=e,l=bs.isCSSRoundSupported,d=`var(--scale-factor) * ${o}px`,u=`var(--scale-factor) * ${i}px`,p=l?`round(${d}, 1px)`:`calc(${d})`,h=l?`round(${u}, 1px)`:`calc(${u})`;!r||t.rotation%180===0?(a.width=p,a.height=h):(a.width=h,a.height=p)}n&&e.setAttribute("data-main-rotation",t.rotation)}class XO{#e=null;#t=null;#r;#o=null;constructor(t){this.#r=t}render(){const t=this.#e=document.createElement("div");t.className="editToolbar",t.setAttribute("role","toolbar");const r=this.#r._uiManager._signal;t.addEventListener("contextmenu",$s,{signal:r}),t.addEventListener("pointerdown",XO.#s,{signal:r});const n=this.#o=document.createElement("div");n.className="buttons",t.append(n);const o=this.#r.toolbarPosition;if(o){const{style:i}=t,a=this.#r._uiManager.direction==="ltr"?1-o[0]:o[0];i.insetInlineEnd=`${100*a}%`,i.top=`calc(${100*o[1]}% + var(--editor-toolbar-vert-offset))`}return this.#d(),t}static#s(t){t.stopPropagation()}#n(t){this.#r._focusEventsAllowed=!1,t.preventDefault(),t.stopPropagation()}#i(t){this.#r._focusEventsAllowed=!0,t.preventDefault(),t.stopPropagation()}#l(t){const r=this.#r._uiManager._signal;t.addEventListener("focusin",this.#n.bind(this),{capture:!0,signal:r}),t.addEventListener("focusout",this.#i.bind(this),{capture:!0,signal:r}),t.addEventListener("contextmenu",$s,{signal:r})}hide(){this.#e.classList.add("hidden"),this.#t?.hideDropdown()}show(){this.#e.classList.remove("hidden")}#d(){const t=document.createElement("button");t.className="delete",t.tabIndex=0,t.setAttribute("data-l10n-id",`pdfjs-editor-remove-${this.#r.editorType}-button`),this.#l(t),t.addEventListener("click",r=>{this.#r._uiManager.delete()},{signal:this.#r._uiManager._signal}),this.#o.append(t)}get#u(){const t=document.createElement("div");return t.className="divider",t}addAltTextButton(t){this.#l(t),this.#o.prepend(t,this.#u)}addColorPicker(t){this.#t=t;const r=t.renderButton();this.#l(r),this.#o.prepend(r,this.#u)}remove(){this.#e.remove(),this.#t?.destroy(),this.#t=null}}class V2t{#e=null;#t=null;#r;constructor(t){this.#r=t}#o(){const t=this.#t=document.createElement("div");t.className="editToolbar",t.setAttribute("role","toolbar"),t.addEventListener("contextmenu",$s,{signal:this.#r._signal});const r=this.#e=document.createElement("div");return r.className="buttons",t.append(r),this.#n(),t}#s(t,r){let n=0,o=0;for(const i of t){const a=i.y+i.height;if(a<n)continue;const l=i.x+(r?i.width:0);if(a>n){o=l,n=a;continue}r?l>o&&(o=l):l<o&&(o=l)}return[r?1-o:o,n]}show(t,r,n){const[o,i]=this.#s(r,n),{style:a}=this.#t||=this.#o();t.append(this.#t),a.insetInlineEnd=`${100*o}%`,a.top=`calc(${100*i}% + var(--editor-toolbar-vert-offset))`}hide(){this.#t.remove()}#n(){const t=document.createElement("button");t.className="highlightButton",t.tabIndex=0,t.setAttribute("data-l10n-id","pdfjs-highlight-floating-button1");const r=document.createElement("span");t.append(r),r.className="visuallyHidden",r.setAttribute("data-l10n-id","pdfjs-highlight-floating-button-label");const n=this.#r._signal;t.addEventListener("contextmenu",$s,{signal:n}),t.addEventListener("click",()=>{this.#r.highlightSelection("floating_button")},{signal:n}),this.#e.append(t)}}function ob(e,t,r){for(const n of r)t.addEventListener(n,e[n].bind(e))}function U2t(e){return Math.round(Math.min(255,Math.max(1,255*e))).toString(16).padStart(2,"0")}class W2t{#e=0;get id(){return`${$2t}${this.#e++}`}}class QO{#e=R2t();#t=0;#r=null;static get _isSVGFittingCanvas(){const t='data:image/svg+xml;charset=UTF-8,<svg viewBox="0 0 1 1" width="1" height="1" xmlns="http://www.w3.org/2000/svg"><rect width="1" height="1" style="fill:red;"/></svg>',n=new OffscreenCanvas(1,3).getContext("2d",{willReadFrequently:!0}),o=new Image;o.src=t;const i=o.decode().then(()=>(n.drawImage(o,0,0,1,1,0,0,1,3),new Uint32Array(n.getImageData(0,0,1,1).data.buffer)[0]===0));return vn(this,"_isSVGFittingCanvas",i)}async#o(t,r){this.#r||=new Map;let n=this.#r.get(t);if(n===null)return null;if(n?.bitmap)return n.refCounter+=1,n;try{n||={bitmap:null,id:`image_${this.#e}_${this.#t++}`,refCounter:0,isSvg:!1};let o;if(typeof r=="string"?(n.url=r,o=await Ax(r,"blob")):o=n.file=r,o.type==="image/svg+xml"){const i=QO._isSVGFittingCanvas,a=new FileReader,l=new Image,d=new Promise((u,p)=>{l.onload=()=>{n.bitmap=l,n.isSvg=!0,u()},a.onload=async()=>{const h=n.svgUrl=a.result;l.src=await i?`${h}#svgView(preserveAspectRatio(none))`:h},l.onerror=a.onerror=p});a.readAsDataURL(o),await d}else n.bitmap=await createImageBitmap(o);n.refCounter=1}catch(o){console.error(o),n=null}return this.#r.set(t,n),n&&this.#r.set(n.id,n),n}async getFromFile(t){const{lastModified:r,name:n,size:o,type:i}=t;return this.#o(`${r}_${n}_${o}_${i}`,t)}async getFromUrl(t){return this.#o(t,t)}async getFromId(t){this.#r||=new Map;const r=this.#r.get(t);return r?r.bitmap?(r.refCounter+=1,r):r.file?this.getFromFile(r.file):this.getFromUrl(r.url):null}getSvgUrl(t){const r=this.#r.get(t);return r?.isSvg?r.svgUrl:null}deleteId(t){this.#r||=new Map;const r=this.#r.get(t);r&&(r.refCounter-=1,r.refCounter===0&&(r.bitmap=null))}isValidId(t){return t.startsWith(`image_${this.#e}_`)}}class Y2t{#e=[];#t=!1;#r;#o=-1;constructor(t=128){this.#r=t}add({cmd:t,undo:r,post:n,mustExec:o,type:i=NaN,overwriteIfSameType:a=!1,keepUndo:l=!1}){if(o&&t(),this.#t)return;const d={cmd:t,undo:r,post:n,type:i};if(this.#o===-1){this.#e.length>0&&(this.#e.length=0),this.#o=0,this.#e.push(d);return}if(a&&this.#e[this.#o].type===i){l&&(d.undo=this.#e[this.#o].undo),this.#e[this.#o]=d;return}const u=this.#o+1;u===this.#r?this.#e.splice(0,1):(this.#o=u,u<this.#e.length&&this.#e.splice(u)),this.#e.push(d)}undo(){if(this.#o===-1)return;this.#t=!0;const{undo:t,post:r}=this.#e[this.#o];t(),r?.(),this.#t=!1,this.#o-=1}redo(){if(this.#o<this.#e.length-1){this.#o+=1,this.#t=!0;const{cmd:t,post:r}=this.#e[this.#o];t(),r?.(),this.#t=!1}}hasSomethingToUndo(){return this.#o!==-1}hasSomethingToRedo(){return this.#o<this.#e.length-1}destroy(){this.#e=null}}class p6{constructor(t){this.buffer=[],this.callbacks=new Map,this.allKeys=new Set;const{isMac:r}=bs.platform;for(const[n,o,i={}]of t)for(const a of n){const l=a.startsWith("mac+");r&&l?(this.callbacks.set(a.slice(4),{callback:o,options:i}),this.allKeys.add(a.split("+").at(-1))):!r&&!l&&(this.callbacks.set(a,{callback:o,options:i}),this.allKeys.add(a.split("+").at(-1)))}}#e(t){t.altKey&&this.buffer.push("alt"),t.ctrlKey&&this.buffer.push("ctrl"),t.metaKey&&this.buffer.push("meta"),t.shiftKey&&this.buffer.push("shift"),this.buffer.push(t.key);const r=this.buffer.join("+");return this.buffer.length=0,r}exec(t,r){if(!this.allKeys.has(r.key))return;const n=this.callbacks.get(this.#e(r));if(!n)return;const{callback:o,options:{bubbles:i=!1,args:a=[],checker:l=null}}=n;l&&!l(t,r)||(o.bind(t,...a,r)(),i||(r.stopPropagation(),r.preventDefault()))}}class JO{static _colorsMapping=new Map([["CanvasText",[0,0,0]],["Canvas",[255,255,255]]]);get _colors(){const t=new Map([["CanvasText",null],["Canvas",null]]);return H2t(t),vn(this,"_colors",t)}convert(t){const r=KO(t);if(!window.matchMedia("(forced-colors: active)").matches)return r;for(const[n,o]of this._colors)if(o.every((i,a)=>i===r[a]))return JO._colorsMapping.get(n);return r}getHexCode(t){const r=this._colors.get(t);return r?lr.makeHexColor(...r):t}}class I0{#e=new AbortController;#t=null;#r=new Map;#o=new Map;#s=null;#n=null;#i=null;#l=new Y2t;#d=0;#u=new Set;#h=null;#c=null;#a=new Set;#m=!1;#g=null;#p=null;#v=null;#f=!1;#b=null;#x=new W2t;#$=!1;#k=!1;#E=null;#L=null;#S=null;#w=hn.NONE;#y=new Set;#C=null;#_=null;#T=null;#M=this.blur.bind(this);#D=this.focus.bind(this);#j=this.copy.bind(this);#P=this.cut.bind(this);#R=this.paste.bind(this);#I=this.keydown.bind(this);#U=this.keyup.bind(this);#W=this.onEditingAction.bind(this);#H=this.onPageChanging.bind(this);#z=this.onScaleChanging.bind(this);#F=this.onRotationChanging.bind(this);#Z={isEditing:!1,isEmpty:!0,hasSomethingToUndo:!1,hasSomethingToRedo:!1,hasSelectedEditor:!1,hasSelectedText:!1};#V=[0,0];#O=null;#B=null;#K=null;static TRANSLATE_SMALL=1;static TRANSLATE_BIG=10;static get _keyboardManager(){const t=I0.prototype,r=a=>a.#B.contains(document.activeElement)&&document.activeElement.tagName!=="BUTTON"&&a.hasSomethingToControl(),n=(a,{target:l})=>{if(l instanceof HTMLInputElement){const{type:d}=l;return d!=="text"&&d!=="number"}return!0},o=this.TRANSLATE_SMALL,i=this.TRANSLATE_BIG;return vn(this,"_keyboardManager",new p6([[["ctrl+a","mac+meta+a"],t.selectAll,{checker:n}],[["ctrl+z","mac+meta+z"],t.undo,{checker:n}],[["ctrl+y","ctrl+shift+z","mac+meta+shift+z","ctrl+shift+Z","mac+meta+shift+Z"],t.redo,{checker:n}],[["Backspace","alt+Backspace","ctrl+Backspace","shift+Backspace","mac+Backspace","mac+alt+Backspace","mac+ctrl+Backspace","Delete","ctrl+Delete","shift+Delete","mac+Delete"],t.delete,{checker:n}],[["Enter","mac+Enter"],t.addNewEditorFromKeyboard,{checker:(a,{target:l})=>!(l instanceof HTMLButtonElement)&&a.#B.contains(l)&&!a.isEnterHandled}],[[" ","mac+ "],t.addNewEditorFromKeyboard,{checker:(a,{target:l})=>!(l instanceof HTMLButtonElement)&&a.#B.contains(document.activeElement)}],[["Escape","mac+Escape"],t.unselectAll],[["ArrowLeft","mac+ArrowLeft"],t.translateSelectedEditors,{args:[-o,0],checker:r}],[["ctrl+ArrowLeft","mac+shift+ArrowLeft"],t.translateSelectedEditors,{args:[-i,0],checker:r}],[["ArrowRight","mac+ArrowRight"],t.translateSelectedEditors,{args:[o,0],checker:r}],[["ctrl+ArrowRight","mac+shift+ArrowRight"],t.translateSelectedEditors,{args:[i,0],checker:r}],[["ArrowUp","mac+ArrowUp"],t.translateSelectedEditors,{args:[0,-o],checker:r}],[["ctrl+ArrowUp","mac+shift+ArrowUp"],t.translateSelectedEditors,{args:[0,-i],checker:r}],[["ArrowDown","mac+ArrowDown"],t.translateSelectedEditors,{args:[0,o],checker:r}],[["ctrl+ArrowDown","mac+shift+ArrowDown"],t.translateSelectedEditors,{args:[0,i],checker:r}]]))}constructor(t,r,n,o,i,a,l,d,u){this._signal=this.#e.signal,this.#B=t,this.#K=r,this.#s=n,this._eventBus=o,this._eventBus._on("editingaction",this.#W),this._eventBus._on("pagechanging",this.#H),this._eventBus._on("scalechanging",this.#z),this._eventBus._on("rotationchanging",this.#F),this.#oe(),this.#le(),this.#X(),this.#n=i.annotationStorage,this.#g=i.filterFactory,this.#_=a,this.#v=l||null,this.#m=d,this.#S=u||null,this.viewParameters={realScale:Qf.PDF_TO_CSS_UNITS,rotation:0},this.isShiftKeyDown=!1}destroy(){this.#e?.abort(),this.#e=null,this._signal=null,this._eventBus._off("editingaction",this.#W),this._eventBus._off("pagechanging",this.#H),this._eventBus._off("scalechanging",this.#z),this._eventBus._off("rotationchanging",this.#F);for(const t of this.#o.values())t.destroy();this.#o.clear(),this.#r.clear(),this.#a.clear(),this.#t=null,this.#y.clear(),this.#l.destroy(),this.#s?.destroy(),this.#b?.hide(),this.#b=null,this.#p&&(clearTimeout(this.#p),this.#p=null),this.#O&&(clearTimeout(this.#O),this.#O=null)}async mlGuess(t){return this.#S?.guess(t)||null}get hasMLManager(){return!!this.#S}get hcmFilter(){return vn(this,"hcmFilter",this.#_?this.#g.addHCMFilter(this.#_.foreground,this.#_.background):"none")}get direction(){return vn(this,"direction",getComputedStyle(this.#B).direction)}get highlightColors(){return vn(this,"highlightColors",this.#v?new Map(this.#v.split(",").map(t=>t.split("=").map(r=>r.trim()))):null)}get highlightColorNames(){return vn(this,"highlightColorNames",this.highlightColors?new Map(Array.from(this.highlightColors,t=>t.reverse())):null)}setMainHighlightColorPicker(t){this.#L=t}editAltText(t){this.#s?.editAltText(this,t)}onPageChanging({pageNumber:t}){this.#d=t-1}focusMainContainer(){this.#B.focus()}findParent(t,r){for(const n of this.#o.values()){const{x:o,y:i,width:a,height:l}=n.div.getBoundingClientRect();if(t>=o&&t<=o+a&&r>=i&&r<=i+l)return n}return null}disableUserSelect(t=!1){this.#K.classList.toggle("noUserSelect",t)}addShouldRescale(t){this.#a.add(t)}removeShouldRescale(t){this.#a.delete(t)}onScaleChanging({scale:t}){this.commitOrRemove(),this.viewParameters.realScale=t*Qf.PDF_TO_CSS_UNITS;for(const r of this.#a)r.onScaleChanging()}onRotationChanging({pagesRotation:t}){this.commitOrRemove(),this.viewParameters.rotation=t}#G({anchorNode:t}){return t.nodeType===Node.TEXT_NODE?t.parentElement:t}highlightSelection(t=""){const r=document.getSelection();if(!r||r.isCollapsed)return;const{anchorNode:n,anchorOffset:o,focusNode:i,focusOffset:a}=r,l=r.toString(),u=this.#G(r).closest(".textLayer"),p=this.getSelectionBoxes(u);if(p){r.empty(),this.#w===hn.NONE&&(this._eventBus.dispatch("showannotationeditorui",{source:this,mode:hn.HIGHLIGHT}),this.showAllEditors("highlight",!0,!0));for(const h of this.#o.values())if(h.hasTextLayer(u)){h.createAndAddNewEditor({x:0,y:0},!1,{methodOfCreation:t,boxes:p,anchorNode:n,anchorOffset:o,focusNode:i,focusOffset:a,text:l});break}}}#re(){const t=document.getSelection();if(!t||t.isCollapsed)return;const n=this.#G(t).closest(".textLayer"),o=this.getSelectionBoxes(n);o&&(this.#b||=new V2t(this),this.#b.show(n,o,this.direction==="ltr"))}addToAnnotationStorage(t){!t.isEmpty()&&this.#n&&!this.#n.has(t.id)&&this.#n.setValue(t.id,t)}#ne(){const t=document.getSelection();if(!t||t.isCollapsed){this.#C&&(this.#b?.hide(),this.#C=null,this.#A({hasSelectedText:!1}));return}const{anchorNode:r}=t;if(r===this.#C)return;if(!this.#G(t).closest(".textLayer")){this.#C&&(this.#b?.hide(),this.#C=null,this.#A({hasSelectedText:!1}));return}if(this.#b?.hide(),this.#C=r,this.#A({hasSelectedText:!0}),!(this.#w!==hn.HIGHLIGHT&&this.#w!==hn.NONE)&&(this.#w===hn.HIGHLIGHT&&this.showAllEditors("highlight",!0,!0),this.#f=this.isShiftKeyDown,!this.isShiftKeyDown)){const i=this._signal,a=l=>{l.type==="pointerup"&&l.button!==0||(window.removeEventListener("pointerup",a),window.removeEventListener("blur",a),l.type==="pointerup"&&this.#q("main_toolbar"))};window.addEventListener("pointerup",a,{signal:i}),window.addEventListener("blur",a,{signal:i})}}#q(t=""){this.#w===hn.HIGHLIGHT?this.highlightSelection(t):this.#m&&this.#re()}#oe(){document.addEventListener("selectionchange",this.#ne.bind(this),{signal:this._signal})}#ie(){const t=this._signal;window.addEventListener("focus",this.#D,{signal:t}),window.addEventListener("blur",this.#M,{signal:t})}#ae(){window.removeEventListener("focus",this.#D),window.removeEventListener("blur",this.#M)}blur(){if(this.isShiftKeyDown=!1,this.#f&&(this.#f=!1,this.#q("main_toolbar")),!this.hasSelection)return;const{activeElement:t}=document;for(const r of this.#y)if(r.div.contains(t)){this.#E=[r,t],r._focusEventsAllowed=!1;break}}focus(){if(!this.#E)return;const[t,r]=this.#E;this.#E=null,r.addEventListener("focusin",()=>{t._focusEventsAllowed=!0},{once:!0,signal:this._signal}),r.focus()}#X(){const t=this._signal;window.addEventListener("keydown",this.#I,{signal:t}),window.addEventListener("keyup",this.#U,{signal:t})}#se(){window.removeEventListener("keydown",this.#I),window.removeEventListener("keyup",this.#U)}#Q(){const t=this._signal;document.addEventListener("copy",this.#j,{signal:t}),document.addEventListener("cut",this.#P,{signal:t}),document.addEventListener("paste",this.#R,{signal:t})}#J(){document.removeEventListener("copy",this.#j),document.removeEventListener("cut",this.#P),document.removeEventListener("paste",this.#R)}#le(){const t=this._signal;document.addEventListener("dragover",this.dragOver.bind(this),{signal:t}),document.addEventListener("drop",this.drop.bind(this),{signal:t})}addEditListeners(){this.#X(),this.#Q()}removeEditListeners(){this.#se(),this.#J()}dragOver(t){for(const{type:r}of t.dataTransfer.items)for(const n of this.#c)if(n.isHandlingMimeForPasting(r)){t.dataTransfer.dropEffect="copy",t.preventDefault();return}}drop(t){for(const r of t.dataTransfer.items)for(const n of this.#c)if(n.isHandlingMimeForPasting(r.type)){n.paste(r,this.currentLayer),t.preventDefault();return}}copy(t){if(t.preventDefault(),this.#t?.commitOrRemove(),!this.hasSelection)return;const r=[];for(const n of this.#y){const o=n.serialize(!0);o&&r.push(o)}r.length!==0&&t.clipboardData.setData("application/pdfjs",JSON.stringify(r))}cut(t){this.copy(t),this.delete()}paste(t){t.preventDefault();const{clipboardData:r}=t;for(const i of r.items)for(const a of this.#c)if(a.isHandlingMimeForPasting(i.type)){a.paste(i,this.currentLayer);return}let n=r.getData("application/pdfjs");if(!n)return;try{n=JSON.parse(n)}catch(i){Jr(`paste: "${i.message}".`);return}if(!Array.isArray(n))return;this.unselectAll();const o=this.currentLayer;try{const i=[];for(const d of n){const u=o.deserialize(d);if(!u)return;i.push(u)}const a=()=>{for(const d of i)this.#ee(d);this.#te(i)},l=()=>{for(const d of i)d.remove()};this.addCommands({cmd:a,undo:l,mustExec:!0})}catch(i){Jr(`paste: "${i.message}".`)}}keydown(t){!this.isShiftKeyDown&&t.key==="Shift"&&(this.isShiftKeyDown=!0),this.#w!==hn.NONE&&!this.isEditorHandlingKeyboard&&I0._keyboardManager.exec(this,t)}keyup(t){this.isShiftKeyDown&&t.key==="Shift"&&(this.isShiftKeyDown=!1,this.#f&&(this.#f=!1,this.#q("main_toolbar")))}onEditingAction({name:t}){switch(t){case"undo":case"redo":case"delete":case"selectAll":this[t]();break;case"highlightSelection":this.highlightSelection("context_menu");break}}#A(t){Object.entries(t).some(([n,o])=>this.#Z[n]!==o)&&(this._eventBus.dispatch("annotationeditorstateschanged",{source:this,details:Object.assign(this.#Z,t)}),this.#w===hn.HIGHLIGHT&&t.hasSelectedEditor===!1&&this.#N([[Lr.HIGHLIGHT_FREE,!0]]))}#N(t){this._eventBus.dispatch("annotationeditorparamschanged",{source:this,details:t})}setEditingState(t){t?(this.#ie(),this.#Q(),this.#A({isEditing:this.#w!==hn.NONE,isEmpty:this.#Y(),hasSomethingToUndo:this.#l.hasSomethingToUndo(),hasSomethingToRedo:this.#l.hasSomethingToRedo(),hasSelectedEditor:!1})):(this.#ae(),this.#J(),this.#A({isEditing:!1}),this.disableUserSelect(!1))}registerEditorTypes(t){if(!this.#c){this.#c=t;for(const r of this.#c)this.#N(r.defaultPropertiesToUpdate)}}getId(){return this.#x.id}get currentLayer(){return this.#o.get(this.#d)}getLayer(t){return this.#o.get(t)}get currentPageIndex(){return this.#d}addLayer(t){this.#o.set(t.pageIndex,t),this.#$?t.enable():t.disable()}removeLayer(t){this.#o.delete(t.pageIndex)}updateMode(t,r=null,n=!1){if(this.#w!==t){if(this.#w=t,t===hn.NONE){this.setEditingState(!1),this.#de();return}this.setEditingState(!0),this.#ce(),this.unselectAll();for(const o of this.#o.values())o.updateMode(t);if(!r&&n){this.addNewEditorFromKeyboard();return}if(r){for(const o of this.#r.values())if(o.annotationElementId===r){this.setSelected(o),o.enterInEditMode();break}}}}addNewEditorFromKeyboard(){this.currentLayer.canCreateNewEmptyEditor()&&this.currentLayer.addNewEditor()}updateToolbar(t){t!==this.#w&&this._eventBus.dispatch("switchannotationeditormode",{source:this,mode:t})}updateParams(t,r){if(this.#c){switch(t){case Lr.CREATE:this.currentLayer.addNewEditor();return;case Lr.HIGHLIGHT_DEFAULT_COLOR:this.#L?.updateColor(r);break;case Lr.HIGHLIGHT_SHOW_ALL:this._eventBus.dispatch("reporttelemetry",{source:this,details:{type:"editing",data:{type:"highlight",action:"toggle_visibility"}}}),(this.#T||=new Map).set(t,r),this.showAllEditors("highlight",r);break}for(const n of this.#y)n.updateParams(t,r);for(const n of this.#c)n.updateDefaultParams(t,r)}}showAllEditors(t,r,n=!1){for(const i of this.#r.values())i.editorType===t&&i.show(r);(this.#T?.get(Lr.HIGHLIGHT_SHOW_ALL)??!0)!==r&&this.#N([[Lr.HIGHLIGHT_SHOW_ALL,r]])}enableWaiting(t=!1){if(this.#k!==t){this.#k=t;for(const r of this.#o.values())t?r.disableClick():r.enableClick(),r.div.classList.toggle("waiting",t)}}#ce(){if(!this.#$){this.#$=!0;for(const t of this.#o.values())t.enable();for(const t of this.#r.values())t.enable()}}#de(){if(this.unselectAll(),this.#$){this.#$=!1;for(const t of this.#o.values())t.disable();for(const t of this.#r.values())t.disable()}}getEditors(t){const r=[];for(const n of this.#r.values())n.pageIndex===t&&r.push(n);return r}getEditor(t){return this.#r.get(t)}addEditor(t){this.#r.set(t.id,t)}removeEditor(t){t.div.contains(document.activeElement)&&(this.#p&&clearTimeout(this.#p),this.#p=setTimeout(()=>{this.focusMainContainer(),this.#p=null},0)),this.#r.delete(t.id),this.unselect(t),(!t.annotationElementId||!this.#u.has(t.annotationElementId))&&this.#n?.remove(t.id)}addDeletedAnnotationElement(t){this.#u.add(t.annotationElementId),this.addChangedExistingAnnotation(t),t.deleted=!0}isDeletedAnnotationElement(t){return this.#u.has(t)}removeDeletedAnnotationElement(t){this.#u.delete(t.annotationElementId),this.removeChangedExistingAnnotation(t),t.deleted=!1}#ee(t){const r=this.#o.get(t.pageIndex);r?r.addOrRebuild(t):(this.addEditor(t),this.addToAnnotationStorage(t))}setActiveEditor(t){this.#t!==t&&(this.#t=t,t&&this.#N(t.propertiesToUpdate))}get#ue(){let t=null;for(t of this.#y);return t}updateUI(t){this.#ue===t&&this.#N(t.propertiesToUpdate)}toggleSelected(t){if(this.#y.has(t)){this.#y.delete(t),t.unselect(),this.#A({hasSelectedEditor:this.hasSelection});return}this.#y.add(t),t.select(),this.#N(t.propertiesToUpdate),this.#A({hasSelectedEditor:!0})}setSelected(t){for(const r of this.#y)r!==t&&r.unselect();this.#y.clear(),this.#y.add(t),t.select(),this.#N(t.propertiesToUpdate),this.#A({hasSelectedEditor:!0})}isSelected(t){return this.#y.has(t)}get firstSelectedEditor(){return this.#y.values().next().value}unselect(t){t.unselect(),this.#y.delete(t),this.#A({hasSelectedEditor:this.hasSelection})}get hasSelection(){return this.#y.size!==0}get isEnterHandled(){return this.#y.size===1&&this.firstSelectedEditor.isEnterHandled}undo(){this.#l.undo(),this.#A({hasSomethingToUndo:this.#l.hasSomethingToUndo(),hasSomethingToRedo:!0,isEmpty:this.#Y()})}redo(){this.#l.redo(),this.#A({hasSomethingToUndo:!0,hasSomethingToRedo:this.#l.hasSomethingToRedo(),isEmpty:this.#Y()})}addCommands(t){this.#l.add(t),this.#A({hasSomethingToUndo:!0,hasSomethingToRedo:!1,isEmpty:this.#Y()})}#Y(){if(this.#r.size===0)return!0;if(this.#r.size===1)for(const t of this.#r.values())return t.isEmpty();return!1}delete(){if(this.commitOrRemove(),!this.hasSelection)return;const t=[...this.#y],r=()=>{for(const o of t)o.remove()},n=()=>{for(const o of t)this.#ee(o)};this.addCommands({cmd:r,undo:n,mustExec:!0})}commitOrRemove(){this.#t?.commitOrRemove()}hasSomethingToControl(){return this.#t||this.hasSelection}#te(t){for(const r of this.#y)r.unselect();this.#y.clear();for(const r of t)r.isEmpty()||(this.#y.add(r),r.select());this.#A({hasSelectedEditor:this.hasSelection})}selectAll(){for(const t of this.#y)t.commit();this.#te(this.#r.values())}unselectAll(){if(!(this.#t&&(this.#t.commitOrRemove(),this.#w!==hn.NONE))&&this.hasSelection){for(const t of this.#y)t.unselect();this.#y.clear(),this.#A({hasSelectedEditor:!1})}}translateSelectedEditors(t,r,n=!1){if(n||this.commitOrRemove(),!this.hasSelection)return;this.#V[0]+=t,this.#V[1]+=r;const[o,i]=this.#V,a=[...this.#y],l=1e3;this.#O&&clearTimeout(this.#O),this.#O=setTimeout(()=>{this.#O=null,this.#V[0]=this.#V[1]=0,this.addCommands({cmd:()=>{for(const d of a)this.#r.has(d.id)&&d.translateInPage(o,i)},undo:()=>{for(const d of a)this.#r.has(d.id)&&d.translateInPage(-o,-i)},mustExec:!1})},l);for(const d of a)d.translateInPage(t,r)}setUpDragSession(){if(this.hasSelection){this.disableUserSelect(!0),this.#h=new Map;for(const t of this.#y)this.#h.set(t,{savedX:t.x,savedY:t.y,savedPageIndex:t.pageIndex,newX:0,newY:0,newPageIndex:-1})}}endDragSession(){if(!this.#h)return!1;this.disableUserSelect(!1);const t=this.#h;this.#h=null;let r=!1;for(const[{x:o,y:i,pageIndex:a},l]of t)l.newX=o,l.newY=i,l.newPageIndex=a,r||=o!==l.savedX||i!==l.savedY||a!==l.savedPageIndex;if(!r)return!1;const n=(o,i,a,l)=>{if(this.#r.has(o.id)){const d=this.#o.get(l);d?o._setParentAndPosition(d,i,a):(o.pageIndex=l,o.x=i,o.y=a)}};return this.addCommands({cmd:()=>{for(const[o,{newX:i,newY:a,newPageIndex:l}]of t)n(o,i,a,l)},undo:()=>{for(const[o,{savedX:i,savedY:a,savedPageIndex:l}]of t)n(o,i,a,l)},mustExec:!0}),!0}dragSelectedEditors(t,r){if(this.#h)for(const n of this.#h.keys())n.drag(t,r)}rebuild(t){if(t.parent===null){const r=this.getLayer(t.pageIndex);r?(r.changeParent(t),r.addOrRebuild(t)):(this.addEditor(t),this.addToAnnotationStorage(t),t.rebuild())}else t.parent.addOrRebuild(t)}get isEditorHandlingKeyboard(){return this.getActive()?.shouldGetKeyboardEvents()||this.#y.size===1&&this.firstSelectedEditor.shouldGetKeyboardEvents()}isActive(t){return this.#t===t}getActive(){return this.#t}getMode(){return this.#w}get imageManager(){return vn(this,"imageManager",new QO)}getSelectionBoxes(t){if(!t)return null;const r=document.getSelection();for(let u=0,p=r.rangeCount;u<p;u++)if(!t.contains(r.getRangeAt(u).commonAncestorContainer))return null;const{x:n,y:o,width:i,height:a}=t.getBoundingClientRect();let l;switch(t.getAttribute("data-main-rotation")){case"90":l=(u,p,h,f)=>({x:(p-o)/a,y:1-(u+h-n)/i,width:f/a,height:h/i});break;case"180":l=(u,p,h,f)=>({x:1-(u+h-n)/i,y:1-(p+f-o)/a,width:h/i,height:f/a});break;case"270":l=(u,p,h,f)=>({x:1-(p+f-o)/a,y:(u-n)/i,width:f/a,height:h/i});break;default:l=(u,p,h,f)=>({x:(u-n)/i,y:(p-o)/a,width:h/i,height:f/a});break}const d=[];for(let u=0,p=r.rangeCount;u<p;u++){const h=r.getRangeAt(u);if(!h.collapsed)for(const{x:f,y:g,width:y,height:v}of h.getClientRects())y===0||v===0||d.push(l(f,g,y,v))}return d.length===0?null:d}addChangedExistingAnnotation({annotationElementId:t,id:r}){(this.#i||=new Map).set(t,r)}removeChangedExistingAnnotation({annotationElementId:t}){this.#i?.delete(t)}renderAnnotationElement(t){const r=this.#i?.get(t.data.id);if(!r)return;const n=this.#n.getRawValue(r);n&&(this.#w===hn.NONE&&!n.hasBeenModified||n.renderAnnotationElement(t))}}class Hh{#e="";#t=!1;#r=null;#o=null;#s=null;#n=!1;#i=null;static _l10nPromise=null;constructor(t){this.#i=t}static initialize(t){Hh._l10nPromise||=t}async render(){const t=this.#r=document.createElement("button");t.className="altText";const r=await Hh._l10nPromise.get("pdfjs-editor-alt-text-button-label");t.textContent=r,t.setAttribute("aria-label",r),t.tabIndex="0";const n=this.#i._uiManager._signal;t.addEventListener("contextmenu",$s,{signal:n}),t.addEventListener("pointerdown",i=>i.stopPropagation(),{signal:n});const o=i=>{i.preventDefault(),this.#i._uiManager.editAltText(this.#i)};return t.addEventListener("click",o,{capture:!0,signal:n}),t.addEventListener("keydown",i=>{i.target===t&&i.key==="Enter"&&(this.#n=!0,o(i))},{signal:n}),await this.#l(),t}finish(){this.#r&&(this.#r.focus({focusVisible:this.#n}),this.#n=!1)}isEmpty(){return!this.#e&&!this.#t}get data(){return{altText:this.#e,decorative:this.#t}}set data({altText:t,decorative:r}){this.#e===t&&this.#t===r||(this.#e=t,this.#t=r,this.#l())}toggle(t=!1){this.#r&&(!t&&this.#s&&(clearTimeout(this.#s),this.#s=null),this.#r.disabled=!t)}destroy(){this.#r?.remove(),this.#r=null,this.#o=null}async#l(){const t=this.#r;if(!t)return;if(!this.#e&&!this.#t){t.classList.remove("done"),this.#o?.remove();return}t.classList.add("done"),Hh._l10nPromise.get("pdfjs-editor-alt-text-edit-button-label").then(o=>{t.setAttribute("aria-label",o)});let r=this.#o;if(!r){this.#o=r=document.createElement("span"),r.className="tooltip",r.setAttribute("role","tooltip");const o=r.id=`alt-text-tooltip-${this.#i.id}`;t.setAttribute("aria-describedby",o);const i=100,a=this.#i._uiManager._signal;a.addEventListener("abort",()=>{clearTimeout(this.#s),this.#s=null},{once:!0}),t.addEventListener("mouseenter",()=>{this.#s=setTimeout(()=>{this.#s=null,this.#o.classList.add("show"),this.#i._reportTelemetry({action:"alt_text_tooltip"})},i)},{signal:a}),t.addEventListener("mouseleave",()=>{this.#s&&(clearTimeout(this.#s),this.#s=null),this.#o?.classList.remove("show")},{signal:a})}r.innerText=this.#t?await Hh._l10nPromise.get("pdfjs-editor-alt-text-decorative-tooltip"):this.#e,r.parentNode||t.append(r),this.#i.getImageForAltText()?.setAttribute("aria-describedby",r.id)}}class Tr{#e=null;#t=null;#r=null;#o=!1;#s=!1;#n=null;#i=null;#l=this.focusin.bind(this);#d=this.focusout.bind(this);#u=null;#h="";#c=!1;#a=null;#m=!1;#g=!1;#p=!1;#v=null;#f=0;#b=0;#x=null;_initialOptions=Object.create(null);_isVisible=!0;_uiManager=null;_focusEventsAllowed=!0;_l10nPromise=null;#$=!1;#k=Tr._zIndex++;static _borderLineWidth=-1;static _colorManager=new JO;static _zIndex=1;static _telemetryTimeout=1e3;static get _resizerKeyboardManager(){const t=Tr.prototype._resizeWithKeyboard,r=I0.TRANSLATE_SMALL,n=I0.TRANSLATE_BIG;return vn(this,"_resizerKeyboardManager",new p6([[["ArrowLeft","mac+ArrowLeft"],t,{args:[-r,0]}],[["ctrl+ArrowLeft","mac+shift+ArrowLeft"],t,{args:[-n,0]}],[["ArrowRight","mac+ArrowRight"],t,{args:[r,0]}],[["ctrl+ArrowRight","mac+shift+ArrowRight"],t,{args:[n,0]}],[["ArrowUp","mac+ArrowUp"],t,{args:[0,-r]}],[["ctrl+ArrowUp","mac+shift+ArrowUp"],t,{args:[0,-n]}],[["ArrowDown","mac+ArrowDown"],t,{args:[0,r]}],[["ctrl+ArrowDown","mac+shift+ArrowDown"],t,{args:[0,n]}],[["Escape","mac+Escape"],Tr.prototype._stopResizingWithKeyboard]]))}constructor(t){this.constructor===Tr&&Xn("Cannot initialize AnnotationEditor."),this.parent=t.parent,this.id=t.id,this.width=this.height=null,this.pageIndex=t.parent.pageIndex,this.name=t.name,this.div=null,this._uiManager=t.uiManager,this.annotationElementId=null,this._willKeepAspectRatio=!1,this._initialOptions.isCentered=t.isCentered,this._structTreeParentId=null;const{rotation:r,rawDims:{pageWidth:n,pageHeight:o,pageX:i,pageY:a}}=this.parent.viewport;this.rotation=r,this.pageRotation=(360+r-this._uiManager.viewParameters.rotation)%360,this.pageDimensions=[n,o],this.pageTranslation=[i,a];const[l,d]=this.parentDimensions;this.x=t.x/l,this.y=t.y/d,this.isAttachedToDOM=!1,this.deleted=!1}get editorType(){return Object.getPrototypeOf(this).constructor._type}static get _defaultLineColor(){return vn(this,"_defaultLineColor",this._colorManager.getHexCode("CanvasText"))}static deleteAnnotationElement(t){const r=new G2t({id:t.parent.getNextId(),parent:t.parent,uiManager:t._uiManager});r.annotationElementId=t.annotationElementId,r.deleted=!0,r._uiManager.addToAnnotationStorage(r)}static initialize(t,r,n){if(Tr._l10nPromise||=new Map(["pdfjs-editor-alt-text-button-label","pdfjs-editor-alt-text-edit-button-label","pdfjs-editor-alt-text-decorative-tooltip","pdfjs-editor-resizer-label-topLeft","pdfjs-editor-resizer-label-topMiddle","pdfjs-editor-resizer-label-topRight","pdfjs-editor-resizer-label-middleRight","pdfjs-editor-resizer-label-bottomRight","pdfjs-editor-resizer-label-bottomMiddle","pdfjs-editor-resizer-label-bottomLeft","pdfjs-editor-resizer-label-middleLeft"].map(i=>[i,t.get(i.replaceAll(/([A-Z])/g,a=>`-${a.toLowerCase()}`))])),n?.strings)for(const i of n.strings)Tr._l10nPromise.set(i,t.get(i));if(Tr._borderLineWidth!==-1)return;const o=getComputedStyle(document.documentElement);Tr._borderLineWidth=parseFloat(o.getPropertyValue("--outline-width"))||0}static updateDefaultParams(t,r){}static get defaultPropertiesToUpdate(){return[]}static isHandlingMimeForPasting(t){return!1}static paste(t,r){Xn("Not implemented")}get propertiesToUpdate(){return[]}get _isDraggable(){return this.#$}set _isDraggable(t){this.#$=t,this.div?.classList.toggle("draggable",t)}get isEnterHandled(){return!0}center(){const[t,r]=this.pageDimensions;switch(this.parentRotation){case 90:this.x-=this.height*r/(t*2),this.y+=this.width*t/(r*2);break;case 180:this.x+=this.width/2,this.y+=this.height/2;break;case 270:this.x+=this.height*r/(t*2),this.y-=this.width*t/(r*2);break;default:this.x-=this.width/2,this.y-=this.height/2;break}this.fixAndSetPosition()}addCommands(t){this._uiManager.addCommands(t)}get currentLayer(){return this._uiManager.currentLayer}setInBackground(){this.div.style.zIndex=0}setInForeground(){this.div.style.zIndex=this.#k}setParent(t){t!==null?(this.pageIndex=t.pageIndex,this.pageDimensions=t.pageDimensions):this.#I(),this.parent=t}focusin(t){this._focusEventsAllowed&&(this.#c?this.#c=!1:this.parent.setSelected(this))}focusout(t){!this._focusEventsAllowed||!this.isAttachedToDOM||t.relatedTarget?.closest(`#${this.id}`)||(t.preventDefault(),this.parent?.isMultipleSelection||this.commitOrRemove())}commitOrRemove(){this.isEmpty()?this.remove():this.commit()}commit(){this.addToAnnotationStorage()}addToAnnotationStorage(){this._uiManager.addToAnnotationStorage(this)}setAt(t,r,n,o){const[i,a]=this.parentDimensions;[n,o]=this.screenToPageTranslation(n,o),this.x=(t+n)/i,this.y=(r+o)/a,this.fixAndSetPosition()}#E([t,r],n,o){[n,o]=this.screenToPageTranslation(n,o),this.x+=n/t,this.y+=o/r,this.fixAndSetPosition()}translate(t,r){this.#E(this.parentDimensions,t,r)}translateInPage(t,r){this.#a||=[this.x,this.y],this.#E(this.pageDimensions,t,r),this.div.scrollIntoView({block:"nearest"})}drag(t,r){this.#a||=[this.x,this.y];const[n,o]=this.parentDimensions;if(this.x+=t/n,this.y+=r/o,this.parent&&(this.x<0||this.x>1||this.y<0||this.y>1)){const{x:u,y:p}=this.div.getBoundingClientRect();this.parent.findNewParent(this,u,p)&&(this.x-=Math.floor(this.x),this.y-=Math.floor(this.y))}let{x:i,y:a}=this;const[l,d]=this.getBaseTranslation();i+=l,a+=d,this.div.style.left=`${(100*i).toFixed(2)}%`,this.div.style.top=`${(100*a).toFixed(2)}%`,this.div.scrollIntoView({block:"nearest"})}get _hasBeenMoved(){return!!this.#a&&(this.#a[0]!==this.x||this.#a[1]!==this.y)}getBaseTranslation(){const[t,r]=this.parentDimensions,{_borderLineWidth:n}=Tr,o=n/t,i=n/r;switch(this.rotation){case 90:return[-o,i];case 180:return[o,i];case 270:return[o,-i];default:return[-o,-i]}}get _mustFixPosition(){return!0}fixAndSetPosition(t=this.rotation){const[r,n]=this.pageDimensions;let{x:o,y:i,width:a,height:l}=this;if(a*=r,l*=n,o*=r,i*=n,this._mustFixPosition)switch(t){case 0:o=Math.max(0,Math.min(r-a,o)),i=Math.max(0,Math.min(n-l,i));break;case 90:o=Math.max(0,Math.min(r-l,o)),i=Math.min(n,Math.max(a,i));break;case 180:o=Math.min(r,Math.max(a,o)),i=Math.min(n,Math.max(l,i));break;case 270:o=Math.min(r,Math.max(l,o)),i=Math.max(0,Math.min(n-a,i));break}this.x=o/=r,this.y=i/=n;const[d,u]=this.getBaseTranslation();o+=d,i+=u;const{style:p}=this.div;p.left=`${(100*o).toFixed(2)}%`,p.top=`${(100*i).toFixed(2)}%`,this.moveInDOM()}static#L(t,r,n){switch(n){case 90:return[r,-t];case 180:return[-t,-r];case 270:return[-r,t];default:return[t,r]}}screenToPageTranslation(t,r){return Tr.#L(t,r,this.parentRotation)}pageTranslationToScreen(t,r){return Tr.#L(t,r,360-this.parentRotation)}#S(t){switch(t){case 90:{const[r,n]=this.pageDimensions;return[0,-r/n,n/r,0]}case 180:return[-1,0,0,-1];case 270:{const[r,n]=this.pageDimensions;return[0,r/n,-n/r,0]}default:return[1,0,0,1]}}get parentScale(){return this._uiManager.viewParameters.realScale}get parentRotation(){return(this._uiManager.viewParameters.rotation+this.pageRotation)%360}get parentDimensions(){const{parentScale:t,pageDimensions:[r,n]}=this,o=r*t,i=n*t;return bs.isCSSRoundSupported?[Math.round(o),Math.round(i)]:[o,i]}setDims(t,r){const[n,o]=this.parentDimensions;this.div.style.width=`${(100*t/n).toFixed(2)}%`,this.#s||(this.div.style.height=`${(100*r/o).toFixed(2)}%`)}fixDims(){const{style:t}=this.div,{height:r,width:n}=t,o=n.endsWith("%"),i=!this.#s&&r.endsWith("%");if(o&&i)return;const[a,l]=this.parentDimensions;o||(t.width=`${(100*parseFloat(n)/a).toFixed(2)}%`),!this.#s&&!i&&(t.height=`${(100*parseFloat(r)/l).toFixed(2)}%`)}getInitialTranslation(){return[0,0]}#w(){if(this.#n)return;this.#n=document.createElement("div"),this.#n.classList.add("resizers");const t=this._willKeepAspectRatio?["topLeft","topRight","bottomRight","bottomLeft"]:["topLeft","topMiddle","topRight","middleRight","bottomRight","bottomMiddle","bottomLeft","middleLeft"],r=this._uiManager._signal;for(const n of t){const o=document.createElement("div");this.#n.append(o),o.classList.add("resizer",n),o.setAttribute("data-resizer-name",n),o.addEventListener("pointerdown",this.#y.bind(this,n),{signal:r}),o.addEventListener("contextmenu",$s,{signal:r}),o.tabIndex=-1}this.div.prepend(this.#n)}#y(t,r){r.preventDefault();const{isMac:n}=bs.platform;if(r.button!==0||r.ctrlKey&&n)return;this.#r?.toggle(!1);const o=this.#_.bind(this,t),i=this._isDraggable;this._isDraggable=!1;const a=this._uiManager._signal,l={passive:!0,capture:!0,signal:a};this.parent.togglePointerEvents(!1),window.addEventListener("pointermove",o,l),window.addEventListener("contextmenu",$s,{signal:a});const d=this.x,u=this.y,p=this.width,h=this.height,f=this.parent.div.style.cursor,g=this.div.style.cursor;this.div.style.cursor=this.parent.div.style.cursor=window.getComputedStyle(r.target).cursor;const y=()=>{this.parent.togglePointerEvents(!0),this.#r?.toggle(!0),this._isDraggable=i,window.removeEventListener("pointerup",y),window.removeEventListener("blur",y),window.removeEventListener("pointermove",o,l),window.removeEventListener("contextmenu",$s),this.parent.div.style.cursor=f,this.div.style.cursor=g,this.#C(d,u,p,h)};window.addEventListener("pointerup",y,{signal:a}),window.addEventListener("blur",y,{signal:a})}#C(t,r,n,o){const i=this.x,a=this.y,l=this.width,d=this.height;i===t&&a===r&&l===n&&d===o||this.addCommands({cmd:()=>{this.width=l,this.height=d,this.x=i,this.y=a;const[u,p]=this.parentDimensions;this.setDims(u*l,p*d),this.fixAndSetPosition()},undo:()=>{this.width=n,this.height=o,this.x=t,this.y=r;const[u,p]=this.parentDimensions;this.setDims(u*n,p*o),this.fixAndSetPosition()},mustExec:!0})}#_(t,r){const[n,o]=this.parentDimensions,i=this.x,a=this.y,l=this.width,d=this.height,u=Tr.MIN_SIZE/n,p=Tr.MIN_SIZE/o,h=I=>Math.round(I*1e4)/1e4,f=this.#S(this.rotation),g=(I,L)=>[f[0]*I+f[2]*L,f[1]*I+f[3]*L],y=this.#S(360-this.rotation),v=(I,L)=>[y[0]*I+y[2]*L,y[1]*I+y[3]*L];let w,x,$=!1,S=!1;switch(t){case"topLeft":$=!0,w=(I,L)=>[0,0],x=(I,L)=>[I,L];break;case"topMiddle":w=(I,L)=>[I/2,0],x=(I,L)=>[I/2,L];break;case"topRight":$=!0,w=(I,L)=>[I,0],x=(I,L)=>[0,L];break;case"middleRight":S=!0,w=(I,L)=>[I,L/2],x=(I,L)=>[0,L/2];break;case"bottomRight":$=!0,w=(I,L)=>[I,L],x=(I,L)=>[0,0];break;case"bottomMiddle":w=(I,L)=>[I/2,L],x=(I,L)=>[I/2,0];break;case"bottomLeft":$=!0,w=(I,L)=>[0,L],x=(I,L)=>[I,0];break;case"middleLeft":S=!0,w=(I,L)=>[0,L/2],x=(I,L)=>[I,L/2];break}const k=w(l,d),T=x(l,d);let E=g(...T);const A=h(i+E[0]),D=h(a+E[1]);let P=1,j=1,[B,O]=this.screenToPageTranslation(r.movementX,r.movementY);if([B,O]=v(B/n,O/o),$){const I=Math.hypot(l,d);P=j=Math.max(Math.min(Math.hypot(T[0]-k[0]-B,T[1]-k[1]-O)/I,1/l,1/d),u/l,p/d)}else S?P=Math.max(u,Math.min(1,Math.abs(T[0]-k[0]-B)))/l:j=Math.max(p,Math.min(1,Math.abs(T[1]-k[1]-O)))/d;const q=h(l*P),W=h(d*j);E=g(...x(q,W));const F=A-E[0],V=D-E[1];this.width=q,this.height=W,this.x=F,this.y=V,this.setDims(n*q,o*W),this.fixAndSetPosition()}altTextFinish(){this.#r?.finish()}async addEditToolbar(){return this.#u||this.#g?this.#u:(this.#u=new XO(this),this.div.append(this.#u.render()),this.#r&&this.#u.addAltTextButton(await this.#r.render()),this.#u)}removeEditToolbar(){this.#u&&(this.#u.remove(),this.#u=null,this.#r?.destroy())}getClientDimensions(){return this.div.getBoundingClientRect()}async addAltTextButton(){this.#r||(Hh.initialize(Tr._l10nPromise),this.#r=new Hh(this),this.#e&&(this.#r.data=this.#e,this.#e=null),await this.addEditToolbar())}get altTextData(){return this.#r?.data}set altTextData(t){this.#r&&(this.#r.data=t)}hasAltText(){return!this.#r?.isEmpty()}render(){this.div=document.createElement("div"),this.div.setAttribute("data-editor-rotation",(360-this.rotation)%360),this.div.className=this.name,this.div.setAttribute("id",this.id),this.div.tabIndex=this.#o?-1:0,this._isVisible||this.div.classList.add("hidden"),this.setInForeground();const t=this._uiManager._signal;this.div.addEventListener("focusin",this.#l,{signal:t}),this.div.addEventListener("focusout",this.#d,{signal:t});const[r,n]=this.parentDimensions;this.parentRotation%180!==0&&(this.div.style.maxWidth=`${(100*n/r).toFixed(2)}%`,this.div.style.maxHeight=`${(100*r/n).toFixed(2)}%`);const[o,i]=this.getInitialTranslation();return this.translate(o,i),ob(this,this.div,["pointerdown"]),this.div}pointerdown(t){const{isMac:r}=bs.platform;if(t.button!==0||t.ctrlKey&&r){t.preventDefault();return}if(this.#c=!0,this._isDraggable){this.#M(t);return}this.#T(t)}#T(t){const{isMac:r}=bs.platform;t.ctrlKey&&!r||t.shiftKey||t.metaKey&&r?this.parent.toggleSelected(this):this.parent.setSelected(this)}#M(t){const r=this._uiManager.isSelected(this);this._uiManager.setUpDragSession();let n,o;const i=this._uiManager._signal;r&&(this.div.classList.add("moving"),n={passive:!0,capture:!0,signal:i},this.#f=t.clientX,this.#b=t.clientY,o=l=>{const{clientX:d,clientY:u}=l,[p,h]=this.screenToPageTranslation(d-this.#f,u-this.#b);this.#f=d,this.#b=u,this._uiManager.dragSelectedEditors(p,h)},window.addEventListener("pointermove",o,n));const a=()=>{window.removeEventListener("pointerup",a),window.removeEventListener("blur",a),r&&(this.div.classList.remove("moving"),window.removeEventListener("pointermove",o,n)),this.#c=!1,this._uiManager.endDragSession()||this.#T(t)};window.addEventListener("pointerup",a,{signal:i}),window.addEventListener("blur",a,{signal:i})}moveInDOM(){this.#v&&clearTimeout(this.#v),this.#v=setTimeout(()=>{this.#v=null,this.parent?.moveEditorInDOM(this)},0)}_setParentAndPosition(t,r,n){t.changeParent(this),this.x=r,this.y=n,this.fixAndSetPosition()}getRect(t,r,n=this.rotation){const o=this.parentScale,[i,a]=this.pageDimensions,[l,d]=this.pageTranslation,u=t/o,p=r/o,h=this.x*i,f=this.y*a,g=this.width*i,y=this.height*a;switch(n){case 0:return[h+u+l,a-f-p-y+d,h+u+g+l,a-f-p+d];case 90:return[h+p+l,a-f+u+d,h+p+y+l,a-f+u+g+d];case 180:return[h-u-g+l,a-f+p+d,h-u+l,a-f+p+y+d];case 270:return[h-p-y+l,a-f-u-g+d,h-p+l,a-f-u+d];default:throw new Error("Invalid rotation")}}getRectInCurrentCoords(t,r){const[n,o,i,a]=t,l=i-n,d=a-o;switch(this.rotation){case 0:return[n,r-a,l,d];case 90:return[n,r-o,d,l];case 180:return[i,r-o,l,d];case 270:return[i,r-a,d,l];default:throw new Error("Invalid rotation")}}onceAdded(){}isEmpty(){return!1}enableEditMode(){this.#g=!0}disableEditMode(){this.#g=!1}isInEditMode(){return this.#g}shouldGetKeyboardEvents(){return this.#p}needsToBeRebuilt(){return this.div&&!this.isAttachedToDOM}rebuild(){const t=this._uiManager._signal;this.div?.addEventListener("focusin",this.#l,{signal:t}),this.div?.addEventListener("focusout",this.#d,{signal:t})}rotate(t){}serialize(t=!1,r=null){Xn("An editor must be serializable")}static deserialize(t,r,n){const o=new this.prototype.constructor({parent:r,id:r.getNextId(),uiManager:n});o.rotation=t.rotation,o.#e=t.accessibilityData;const[i,a]=o.pageDimensions,[l,d,u,p]=o.getRectInCurrentCoords(t.rect,a);return o.x=l/i,o.y=d/a,o.width=u/i,o.height=p/a,o}get hasBeenModified(){return!!this.annotationElementId&&(this.deleted||this.serialize()!==null)}remove(){if(this.div.removeEventListener("focusin",this.#l),this.div.removeEventListener("focusout",this.#d),this.isEmpty()||this.commit(),this.parent?this.parent.remove(this):this._uiManager.removeEditor(this),this.#v&&(clearTimeout(this.#v),this.#v=null),this.#I(),this.removeEditToolbar(),this.#x){for(const t of this.#x.values())clearTimeout(t);this.#x=null}this.parent=null}get isResizable(){return!1}makeResizable(){this.isResizable&&(this.#w(),this.#n.classList.remove("hidden"),ob(this,this.div,["keydown"]))}get toolbarPosition(){return null}keydown(t){if(!this.isResizable||t.target!==this.div||t.key!=="Enter")return;this._uiManager.setSelected(this),this.#i={savedX:this.x,savedY:this.y,savedWidth:this.width,savedHeight:this.height};const r=this.#n.children;if(!this.#t){this.#t=Array.from(r);const a=this.#D.bind(this),l=this.#j.bind(this),d=this._uiManager._signal;for(const u of this.#t){const p=u.getAttribute("data-resizer-name");u.setAttribute("role","spinbutton"),u.addEventListener("keydown",a,{signal:d}),u.addEventListener("blur",l,{signal:d}),u.addEventListener("focus",this.#P.bind(this,p),{signal:d}),Tr._l10nPromise.get(`pdfjs-editor-resizer-label-${p}`).then(h=>u.setAttribute("aria-label",h))}}const n=this.#t[0];let o=0;for(const a of r){if(a===n)break;o++}const i=(360-this.rotation+this.parentRotation)%360/90*(this.#t.length/4);if(i!==o){if(i<o)for(let l=0;l<o-i;l++)this.#n.append(this.#n.firstChild);else if(i>o)for(let l=0;l<i-o;l++)this.#n.firstChild.before(this.#n.lastChild);let a=0;for(const l of r){const u=this.#t[a++].getAttribute("data-resizer-name");Tr._l10nPromise.get(`pdfjs-editor-resizer-label-${u}`).then(p=>l.setAttribute("aria-label",p))}}this.#R(0),this.#p=!0,this.#n.firstChild.focus({focusVisible:!0}),t.preventDefault(),t.stopImmediatePropagation()}#D(t){Tr._resizerKeyboardManager.exec(this,t)}#j(t){this.#p&&t.relatedTarget?.parentNode!==this.#n&&this.#I()}#P(t){this.#h=this.#p?t:""}#R(t){if(this.#t)for(const r of this.#t)r.tabIndex=t}_resizeWithKeyboard(t,r){this.#p&&this.#_(this.#h,{movementX:t,movementY:r})}#I(){if(this.#p=!1,this.#R(-1),this.#i){const{savedX:t,savedY:r,savedWidth:n,savedHeight:o}=this.#i;this.#C(t,r,n,o),this.#i=null}}_stopResizingWithKeyboard(){this.#I(),this.div.focus()}select(){if(this.makeResizable(),this.div?.classList.add("selectedEditor"),!this.#u){this.addEditToolbar().then(()=>{this.div?.classList.contains("selectedEditor")&&this.#u?.show()});return}this.#u?.show()}unselect(){this.#n?.classList.add("hidden"),this.div?.classList.remove("selectedEditor"),this.div?.contains(document.activeElement)&&this._uiManager.currentLayer.div.focus({preventScroll:!0}),this.#u?.hide()}updateParams(t,r){}disableEditing(){}enableEditing(){}enterInEditMode(){}getImageForAltText(){return null}get contentDiv(){return this.div}get isEditing(){return this.#m}set isEditing(t){this.#m=t,this.parent&&(t?(this.parent.setSelected(this),this.parent.setActiveEditor(this)):this.parent.setActiveEditor(null))}setAspectRatio(t,r){this.#s=!0;const n=t/r,{style:o}=this.div;o.aspectRatio=n,o.height="auto"}static get MIN_SIZE(){return 16}static canCreateNewEmptyEditor(){return!0}get telemetryInitialData(){return{action:"added"}}get telemetryFinalData(){return null}_reportTelemetry(t,r=!1){if(r){this.#x||=new Map;const{action:n}=t;let o=this.#x.get(n);o&&clearTimeout(o),o=setTimeout(()=>{this._reportTelemetry(t),this.#x.delete(n),this.#x.size===0&&(this.#x=null)},Tr._telemetryTimeout),this.#x.set(n,o);return}t.type||=this.editorType,this._uiManager._eventBus.dispatch("reporttelemetry",{source:this,details:{type:"editing",data:t}})}show(t=this._isVisible){this.div.classList.toggle("hidden",!t),this._isVisible=t}enable(){this.div&&(this.div.tabIndex=0),this.#o=!1}disable(){this.div&&(this.div.tabIndex=-1),this.#o=!0}renderAnnotationElement(t){let r=t.container.querySelector(".annotationContent");if(!r)r=document.createElement("div"),r.classList.add("annotationContent",this.editorType),t.container.prepend(r);else if(r.nodeName==="CANVAS"){const n=r;r=document.createElement("div"),r.classList.add("annotationContent",this.editorType),n.before(r)}return r}resetAnnotationElement(t){const{firstChild:r}=t.container;r.nodeName==="DIV"&&r.classList.contains("annotationContent")&&r.remove()}}class G2t extends Tr{constructor(t){super(t),this.annotationElementId=t.annotationElementId,this.deleted=!0}serialize(){return{id:this.annotationElementId,deleted:!0,pageIndex:this.pageIndex}}}const GQ=3285377520,gl=4294901760,qd=65535;class Xge{constructor(t){this.h1=t?t&4294967295:GQ,this.h2=t?t&4294967295:GQ}update(t){let r,n;if(typeof t=="string"){r=new Uint8Array(t.length*2),n=0;for(let v=0,w=t.length;v<w;v++){const x=t.charCodeAt(v);x<=255?r[n++]=x:(r[n++]=x>>>8,r[n++]=x&255)}}else if(ArrayBuffer.isView(t))r=t.slice(),n=r.byteLength;else throw new Error("Invalid data format, must be a string or TypedArray.");const o=n>>2,i=n-o*4,a=new Uint32Array(r.buffer,0,o);let l=0,d=0,u=this.h1,p=this.h2;const h=3432918353,f=461845907,g=h&qd,y=f&qd;for(let v=0;v<o;v++)v&1?(l=a[v],l=l*h&gl|l*g&qd,l=l<<15|l>>>17,l=l*f&gl|l*y&qd,u^=l,u=u<<13|u>>>19,u=u*5+3864292196):(d=a[v],d=d*h&gl|d*g&qd,d=d<<15|d>>>17,d=d*f&gl|d*y&qd,p^=d,p=p<<13|p>>>19,p=p*5+3864292196);switch(l=0,i){case 3:l^=r[o*4+2]<<16;case 2:l^=r[o*4+1]<<8;case 1:l^=r[o*4],l=l*h&gl|l*g&qd,l=l<<15|l>>>17,l=l*f&gl|l*y&qd,o&1?u^=l:p^=l}this.h1=u,this.h2=p}hexdigest(){let t=this.h1,r=this.h2;return t^=r>>>1,t=t*3981806797&gl|t*36045&qd,r=r*4283543511&gl|((r<<16|t>>>16)*2950163797&gl)>>>16,t^=r>>>1,t=t*444984403&gl|t*60499&qd,r=r*3301882366&gl|((r<<16|t>>>16)*3120437893&gl)>>>16,t^=r>>>1,(t>>>0).toString(16).padStart(8,"0")+(r>>>0).toString(16).padStart(8,"0")}}const lj=Object.freeze({map:null,hash:"",transfer:void 0});class eN{#e=!1;#t=new Map;constructor(){this.onSetModified=null,this.onResetModified=null,this.onAnnotationEditor=null}getValue(t,r){const n=this.#t.get(t);return n===void 0?r:Object.assign(r,n)}getRawValue(t){return this.#t.get(t)}remove(t){if(this.#t.delete(t),this.#t.size===0&&this.resetModified(),typeof this.onAnnotationEditor=="function"){for(const r of this.#t.values())if(r instanceof Tr)return;this.onAnnotationEditor(null)}}setValue(t,r){const n=this.#t.get(t);let o=!1;if(n!==void 0)for(const[i,a]of Object.entries(r))n[i]!==a&&(o=!0,n[i]=a);else o=!0,this.#t.set(t,r);o&&this.#r(),r instanceof Tr&&typeof this.onAnnotationEditor=="function"&&this.onAnnotationEditor(r.constructor._type)}has(t){return this.#t.has(t)}getAll(){return this.#t.size>0?UO(this.#t):null}setAll(t){for(const[r,n]of Object.entries(t))this.setValue(r,n)}get size(){return this.#t.size}#r(){this.#e||(this.#e=!0,typeof this.onSetModified=="function"&&this.onSetModified())}resetModified(){this.#e&&(this.#e=!1,typeof this.onResetModified=="function"&&this.onResetModified())}get print(){return new Qge(this)}get serializable(){if(this.#t.size===0)return lj;const t=new Map,r=new Xge,n=[],o=Object.create(null);let i=!1;for(const[a,l]of this.#t){const d=l instanceof Tr?l.serialize(!1,o):l;d&&(t.set(a,d),r.update(`${a}:${JSON.stringify(d)}`),i||=!!d.bitmap)}if(i)for(const a of t.values())a.bitmap&&n.push(a.bitmap);return t.size>0?{map:t,hash:r.hexdigest(),transfer:n}:lj}get editorStats(){let t=null;const r=new Map;for(const n of this.#t.values()){if(!(n instanceof Tr))continue;const o=n.telemetryFinalData;if(!o)continue;const{type:i}=o;r.has(i)||r.set(i,Object.getPrototypeOf(n).constructor),t||=Object.create(null);const a=t[i]||=new Map;for(const[l,d]of Object.entries(o)){if(l==="type")continue;let u=a.get(l);u||(u=new Map,a.set(l,u));const p=u.get(d)??0;u.set(d,p+1)}}for(const[n,o]of r)t[n]=o.computeTelemetryFinalData(t[n]);return t}}class Qge extends eN{#e;constructor(t){super();const{map:r,hash:n,transfer:o}=t.serializable,i=structuredClone(r,o?{transfer:o}:null);this.#e={map:i,hash:n,transfer:o}}get print(){Xn("Should not call PrintAnnotationStorage.print")}get serializable(){return this.#e}}class q2t{#e=new Set;constructor({ownerDocument:t=globalThis.document,styleElement:r=null}){this._document=t,this.nativeFontFaces=new Set,this.styleElement=null,this.loadingRequests=[],this.loadTestFontId=0}addNativeFontFace(t){this.nativeFontFaces.add(t),this._document.fonts.add(t)}removeNativeFontFace(t){this.nativeFontFaces.delete(t),this._document.fonts.delete(t)}insertRule(t){this.styleElement||(this.styleElement=this._document.createElement("style"),this._document.documentElement.getElementsByTagName("head")[0].append(this.styleElement));const r=this.styleElement.sheet;r.insertRule(t,r.cssRules.length)}clear(){for(const t of this.nativeFontFaces)this._document.fonts.delete(t);this.nativeFontFaces.clear(),this.#e.clear(),this.styleElement&&(this.styleElement.remove(),this.styleElement=null)}async loadSystemFont({systemFontInfo:t,_inspectFont:r}){if(!(!t||this.#e.has(t.loadedName))){if(Ai(!this.disableFontFace,"loadSystemFont shouldn't be called when `disableFontFace` is set."),this.isFontLoadingAPISupported){const{loadedName:n,src:o,style:i}=t,a=new FontFace(n,o,i);this.addNativeFontFace(a);try{await a.load(),this.#e.add(n),r?.(t)}catch{Jr(`Cannot load system font: ${t.baseFontName}, installing it could help to improve PDF rendering.`),this.removeNativeFontFace(a)}return}Xn("Not implemented: loadSystemFont without the Font Loading API.")}}async bind(t){if(t.attached||t.missingFile&&!t.systemFontInfo)return;if(t.attached=!0,t.systemFontInfo){await this.loadSystemFont(t);return}if(this.isFontLoadingAPISupported){const n=t.createNativeFontFace();if(n){this.addNativeFontFace(n);try{await n.loaded}catch(o){throw Jr(`Failed to load font '${n.family}': '${o}'.`),t.disableFontFace=!0,o}}return}const r=t.createFontFaceRule();if(r){if(this.insertRule(r),this.isSyncFontLoadingSupported)return;await new Promise(n=>{const o=this._queueLoadingCallback(n);this._prepareFontLoadEvent(t,o)})}}get isFontLoadingAPISupported(){const t=!!this._document?.fonts;return vn(this,"isFontLoadingAPISupported",t)}get isSyncFontLoadingSupported(){let t=!1;return(ka||typeof navigator<"u"&&typeof navigator?.userAgent=="string"&&/Mozilla\/5.0.*?rv:\d+.*? Gecko/.test(navigator.userAgent))&&(t=!0),vn(this,"isSyncFontLoadingSupported",t)}_queueLoadingCallback(t){function r(){for(Ai(!o.done,"completeRequest() cannot be called twice."),o.done=!0;n.length>0&&n[0].done;){const i=n.shift();setTimeout(i.callback,0)}}const{loadingRequests:n}=this,o={done:!1,complete:r,callback:t};return n.push(o),o}get _loadTestFont(){const t=atob("T1RUTwALAIAAAwAwQ0ZGIDHtZg4AAAOYAAAAgUZGVE1lkzZwAAAEHAAAABxHREVGABQAFQAABDgAAAAeT1MvMlYNYwkAAAEgAAAAYGNtYXABDQLUAAACNAAAAUJoZWFk/xVFDQAAALwAAAA2aGhlYQdkA+oAAAD0AAAAJGhtdHgD6AAAAAAEWAAAAAZtYXhwAAJQAAAAARgAAAAGbmFtZVjmdH4AAAGAAAAAsXBvc3T/hgAzAAADeAAAACAAAQAAAAEAALZRFsRfDzz1AAsD6AAAAADOBOTLAAAAAM4KHDwAAAAAA+gDIQAAAAgAAgAAAAAAAAABAAADIQAAAFoD6AAAAAAD6AABAAAAAAAAAAAAAAAAAAAAAQAAUAAAAgAAAAQD6AH0AAUAAAKKArwAAACMAooCvAAAAeAAMQECAAACAAYJAAAAAAAAAAAAAQAAAAAAAAAAAAAAAFBmRWQAwAAuAC4DIP84AFoDIQAAAAAAAQAAAAAAAAAAACAAIAABAAAADgCuAAEAAAAAAAAAAQAAAAEAAAAAAAEAAQAAAAEAAAAAAAIAAQAAAAEAAAAAAAMAAQAAAAEAAAAAAAQAAQAAAAEAAAAAAAUAAQAAAAEAAAAAAAYAAQAAAAMAAQQJAAAAAgABAAMAAQQJAAEAAgABAAMAAQQJAAIAAgABAAMAAQQJAAMAAgABAAMAAQQJAAQAAgABAAMAAQQJAAUAAgABAAMAAQQJAAYAAgABWABYAAAAAAAAAwAAAAMAAAAcAAEAAAAAADwAAwABAAAAHAAEACAAAAAEAAQAAQAAAC7//wAAAC7////TAAEAAAAAAAABBgAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMAAAAAAAD/gwAyAAAAAQAAAAAAAAAAAAAAAAAAAAABAAQEAAEBAQJYAAEBASH4DwD4GwHEAvgcA/gXBIwMAYuL+nz5tQXkD5j3CBLnEQACAQEBIVhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYAAABAQAADwACAQEEE/t3Dov6fAH6fAT+fPp8+nwHDosMCvm1Cvm1DAz6fBQAAAAAAAABAAAAAMmJbzEAAAAAzgTjFQAAAADOBOQpAAEAAAAAAAAADAAUAAQAAAABAAAAAgABAAAAAAAAAAAD6AAAAAAAAA==");return vn(this,"_loadTestFont",t)}_prepareFontLoadEvent(t,r){function n(k,T){return k.charCodeAt(T)<<24|k.charCodeAt(T+1)<<16|k.charCodeAt(T+2)<<8|k.charCodeAt(T+3)&255}function o(k,T,E,A){const D=k.substring(0,T),P=k.substring(T+E);return D+A+P}let i,a;const l=this._document.createElement("canvas");l.width=1,l.height=1;const d=l.getContext("2d");let u=0;function p(k,T){if(++u>30){Jr("Load test font never loaded."),T();return}if(d.font="30px "+k,d.fillText(".",0,20),d.getImageData(0,0,1,1).data[3]>0){T();return}setTimeout(p.bind(null,k,T))}const h=`lt${Date.now()}${this.loadTestFontId++}`;let f=this._loadTestFont;f=o(f,976,h.length,h);const y=16,v=1482184792;let w=n(f,y);for(i=0,a=h.length-3;i<a;i+=4)w=w-v+n(h,i)|0;i<h.length&&(w=w-v+n(h+"XXX",i)|0),f=o(f,y,4,D2t(w));const x=`url(data:font/opentype;base64,${btoa(f)});`,$=`@font-face {font-family:"${h}";src:${x}}`;this.insertRule($);const S=this._document.createElement("div");S.style.visibility="hidden",S.style.width=S.style.height="10px",S.style.position="absolute",S.style.top=S.style.left="0px";for(const k of[t.loadedName,h]){const T=this._document.createElement("span");T.textContent="Hi",T.style.fontFamily=k,S.append(T)}this._document.body.append(S),p(h,()=>{S.remove(),r.complete()})}}class Z2t{constructor(t,{disableFontFace:r=!1,inspectFont:n=null}){this.compiledGlyphs=Object.create(null);for(const o in t)this[o]=t[o];this.disableFontFace=r===!0,this._inspectFont=n}createNativeFontFace(){if(!this.data||this.disableFontFace)return null;let t;if(!this.cssFontInfo)t=new FontFace(this.loadedName,this.data,{});else{const r={weight:this.cssFontInfo.fontWeight};this.cssFontInfo.italicAngle&&(r.style=`oblique ${this.cssFontInfo.italicAngle}deg`),t=new FontFace(this.cssFontInfo.fontFamily,this.data,r)}return this._inspectFont?.(this),t}createFontFaceRule(){if(!this.data||this.disableFontFace)return null;const t=Wge(this.data),r=`url(data:${this.mimetype};base64,${btoa(t)});`;let n;if(!this.cssFontInfo)n=`@font-face {font-family:"${this.loadedName}";src:${r}}`;else{let o=`font-weight: ${this.cssFontInfo.fontWeight};`;this.cssFontInfo.italicAngle&&(o+=`font-style: oblique ${this.cssFontInfo.italicAngle}deg;`),n=`@font-face {font-family:"${this.cssFontInfo.fontFamily}";${o}src:${r}}`}return this._inspectFont?.(this,r),n}getPathGenerator(t,r){if(this.compiledGlyphs[r]!==void 0)return this.compiledGlyphs[r];let n;try{n=t.get(this.loadedName+"_path_"+r)}catch(i){Jr(`getPathGenerator - ignoring character: "${i}".`)}if(!Array.isArray(n)||n.length===0)return this.compiledGlyphs[r]=function(i,a){};const o=[];for(let i=0,a=n.length;i<a;)switch(n[i++]){case mu.BEZIER_CURVE_TO:{const[l,d,u,p,h,f]=n.slice(i,i+6);o.push(g=>g.bezierCurveTo(l,d,u,p,h,f)),i+=6}break;case mu.MOVE_TO:{const[l,d]=n.slice(i,i+2);o.push(u=>u.moveTo(l,d)),i+=2}break;case mu.LINE_TO:{const[l,d]=n.slice(i,i+2);o.push(u=>u.lineTo(l,d)),i+=2}break;case mu.QUADRATIC_CURVE_TO:{const[l,d,u,p]=n.slice(i,i+4);o.push(h=>h.quadraticCurveTo(l,d,u,p)),i+=4}break;case mu.RESTORE:o.push(l=>l.restore());break;case mu.SAVE:o.push(l=>l.save());break;case mu.SCALE:Ai(o.length===2,"Scale command is only valid at the third position.");break;case mu.TRANSFORM:{const[l,d,u,p,h,f]=n.slice(i,i+6);o.push(g=>g.transform(l,d,u,p,h,f)),i+=6}break;case mu.TRANSLATE:{const[l,d]=n.slice(i,i+2);o.push(u=>u.translate(l,d)),i+=2}break}return this.compiledGlyphs[r]=function(a,l){o[0](a),o[1](a),a.scale(l,-l);for(let d=2,u=o.length;d<u;d++)o[d](a)}}}if(ka){var cj=Promise.withResolvers(),dj=null;(async()=>{const t=await bt(()=>import("./empty-qC9xuHfK.js").then(l=>l.e),__vite__mapDeps([0,1,2])),r=await bt(()=>import("./index-Dvl7ZPqE.js").then(l=>l.i),__vite__mapDeps([3,1,4,5,6,7,8,9])),n=await bt(()=>import("./index-CGQmgJEE.js").then(l=>l.i),__vite__mapDeps([10,1,11,4,5,6,7,8,9])),o=await bt(()=>import("./url-BjWWFI3O.js").then(l=>l.u),__vite__mapDeps([12,1,9,7,5,6,8]));let i,a;return new Map(Object.entries({fs:t,http:r,https:n,url:o,canvas:i,path2d:a}))})().then(t=>{dj=t,cj.resolve()},t=>{Jr(`loadPackages: ${t}`),dj=new Map,cj.resolve()})}class F1{static get promise(){return cj.promise}static get(t){return dj?.get(t)}}const Jge=function(e){return F1.get("fs").promises.readFile(e).then(r=>new Uint8Array(r))};class K2t extends kx{}class X2t extends Ex{_createCanvas(t,r){return F1.get("canvas").createCanvas(t,r)}}class Q2t extends _x{_fetchData(t,r){return Jge(t).then(n=>({cMapData:n,compressionType:r}))}}class J2t extends Tx{_fetchData(t){return Jge(t)}}const Va={FILL:"Fill",STROKE:"Stroke",SHADING:"Shading"};function uj(e,t){if(!t)return;const r=t[2]-t[0],n=t[3]-t[1],o=new Path2D;o.rect(t[0],t[1],r,n),e.clip(o)}class h6{constructor(){this.constructor===h6&&Xn("Cannot initialize BaseShadingPattern.")}getPattern(){Xn("Abstract method `getPattern` called.")}}class e0t extends h6{constructor(t){super(),this._type=t[1],this._bbox=t[2],this._colorStops=t[3],this._p0=t[4],this._p1=t[5],this._r0=t[6],this._r1=t[7],this.matrix=null}_createGradient(t){let r;this._type==="axial"?r=t.createLinearGradient(this._p0[0],this._p0[1],this._p1[0],this._p1[1]):this._type==="radial"&&(r=t.createRadialGradient(this._p0[0],this._p0[1],this._r0,this._p1[0],this._p1[1],this._r1));for(const n of this._colorStops)r.addColorStop(n[0],n[1]);return r}getPattern(t,r,n,o){let i;if(o===Va.STROKE||o===Va.FILL){const a=r.current.getClippedPathBoundingBox(o,Io(t))||[0,0,0,0],l=Math.ceil(a[2]-a[0])||1,d=Math.ceil(a[3]-a[1])||1,u=r.cachedCanvases.getCanvas("pattern",l,d,!0),p=u.context;p.clearRect(0,0,p.canvas.width,p.canvas.height),p.beginPath(),p.rect(0,0,p.canvas.width,p.canvas.height),p.translate(-a[0],-a[1]),n=lr.transform(n,[1,0,0,1,a[0],a[1]]),p.transform(...r.baseTransform),this.matrix&&p.transform(...this.matrix),uj(p,this._bbox),p.fillStyle=this._createGradient(p),p.fill(),i=t.createPattern(u.canvas,"no-repeat");const h=new DOMMatrix(n);i.setTransform(h)}else uj(t,this._bbox),i=this._createGradient(t);return i}}function lL(e,t,r,n,o,i,a,l){const d=t.coords,u=t.colors,p=e.data,h=e.width*4;let f;d[r+1]>d[n+1]&&(f=r,r=n,n=f,f=i,i=a,a=f),d[n+1]>d[o+1]&&(f=n,n=o,o=f,f=a,a=l,l=f),d[r+1]>d[n+1]&&(f=r,r=n,n=f,f=i,i=a,a=f);const g=(d[r]+t.offsetX)*t.scaleX,y=(d[r+1]+t.offsetY)*t.scaleY,v=(d[n]+t.offsetX)*t.scaleX,w=(d[n+1]+t.offsetY)*t.scaleY,x=(d[o]+t.offsetX)*t.scaleX,$=(d[o+1]+t.offsetY)*t.scaleY;if(y>=$)return;const S=u[i],k=u[i+1],T=u[i+2],E=u[a],A=u[a+1],D=u[a+2],P=u[l],j=u[l+1],B=u[l+2],O=Math.round(y),q=Math.round($);let W,F,V,I,L,z,H,ee;for(let Z=O;Z<=q;Z++){if(Z<w){const ge=Z<y?0:(y-Z)/(y-w);W=g-(g-v)*ge,F=S-(S-E)*ge,V=k-(k-A)*ge,I=T-(T-D)*ge}else{let ge;Z>$?ge=1:w===$?ge=0:ge=(w-Z)/(w-$),W=v-(v-x)*ge,F=E-(E-P)*ge,V=A-(A-j)*ge,I=D-(D-B)*ge}let U;Z<y?U=0:Z>$?U=1:U=(y-Z)/(y-$),L=g-(g-x)*U,z=S-(S-P)*U,H=k-(k-j)*U,ee=T-(T-B)*U;const X=Math.round(Math.min(W,L)),Q=Math.round(Math.max(W,L));let oe=h*Z+X*4;for(let ge=X;ge<=Q;ge++)U=(W-ge)/(W-L),U<0?U=0:U>1&&(U=1),p[oe++]=F-(F-z)*U|0,p[oe++]=V-(V-H)*U|0,p[oe++]=I-(I-ee)*U|0,p[oe++]=255}}function t0t(e,t,r){const n=t.coords,o=t.colors;let i,a;switch(t.type){case"lattice":const l=t.verticesPerRow,d=Math.floor(n.length/l)-1,u=l-1;for(i=0;i<d;i++){let p=i*l;for(let h=0;h<u;h++,p++)lL(e,r,n[p],n[p+1],n[p+l],o[p],o[p+1],o[p+l]),lL(e,r,n[p+l+1],n[p+1],n[p+l],o[p+l+1],o[p+1],o[p+l])}break;case"triangles":for(i=0,a=n.length;i<a;i+=3)lL(e,r,n[i],n[i+1],n[i+2],o[i],o[i+1],o[i+2]);break;default:throw new Error("illegal figure")}}class r0t extends h6{constructor(t){super(),this._coords=t[2],this._colors=t[3],this._figures=t[4],this._bounds=t[5],this._bbox=t[7],this._background=t[8],this.matrix=null}_createMeshCanvas(t,r,n){const l=Math.floor(this._bounds[0]),d=Math.floor(this._bounds[1]),u=Math.ceil(this._bounds[2])-l,p=Math.ceil(this._bounds[3])-d,h=Math.min(Math.ceil(Math.abs(u*t[0]*1.1)),3e3),f=Math.min(Math.ceil(Math.abs(p*t[1]*1.1)),3e3),g=u/h,y=p/f,v={coords:this._coords,colors:this._colors,offsetX:-l,offsetY:-d,scaleX:1/g,scaleY:1/y},w=h+2*2,x=f+2*2,$=n.getCanvas("mesh",w,x,!1),S=$.context,k=S.createImageData(h,f);if(r){const E=k.data;for(let A=0,D=E.length;A<D;A+=4)E[A]=r[0],E[A+1]=r[1],E[A+2]=r[2],E[A+3]=255}for(const E of this._figures)t0t(k,E,v);return S.putImageData(k,2,2),{canvas:$.canvas,offsetX:l-2*g,offsetY:d-2*y,scaleX:g,scaleY:y}}getPattern(t,r,n,o){uj(t,this._bbox);let i;if(o===Va.SHADING)i=lr.singularValueDecompose2dScale(Io(t));else if(i=lr.singularValueDecompose2dScale(r.baseTransform),this.matrix){const l=lr.singularValueDecompose2dScale(this.matrix);i=[i[0]*l[0],i[1]*l[1]]}const a=this._createMeshCanvas(i,o===Va.SHADING?null:this._background,r.cachedCanvases);return o!==Va.SHADING&&(t.setTransform(...r.baseTransform),this.matrix&&t.transform(...this.matrix)),t.translate(a.offsetX,a.offsetY),t.scale(a.scaleX,a.scaleY),t.createPattern(a.canvas,"no-repeat")}}class n0t extends h6{getPattern(){return"hotpink"}}function o0t(e){switch(e[0]){case"RadialAxial":return new e0t(e);case"Mesh":return new r0t(e);case"Dummy":return new n0t}throw new Error(`Unknown IR type: ${e[0]}`)}const qQ={COLORED:1,UNCOLORED:2};class tN{static MAX_PATTERN_SIZE=3e3;constructor(t,r,n,o,i){this.operatorList=t[2],this.matrix=t[3],this.bbox=t[4],this.xstep=t[5],this.ystep=t[6],this.paintType=t[7],this.tilingType=t[8],this.color=r,this.ctx=n,this.canvasGraphicsFactory=o,this.baseTransform=i}createPatternCanvas(t){const r=this.operatorList,n=this.bbox,o=this.xstep,i=this.ystep,a=this.paintType,l=this.tilingType,d=this.color,u=this.canvasGraphicsFactory;Cx("TilingType: "+l);const p=n[0],h=n[1],f=n[2],g=n[3],y=lr.singularValueDecompose2dScale(this.matrix),v=lr.singularValueDecompose2dScale(this.baseTransform),w=[y[0]*v[0],y[1]*v[1]],x=this.getSizeAndScale(o,this.ctx.canvas.width,w[0]),$=this.getSizeAndScale(i,this.ctx.canvas.height,w[1]),S=t.cachedCanvases.getCanvas("pattern",x.size,$.size,!0),k=S.context,T=u.createCanvasGraphics(k);T.groupLevel=t.groupLevel,this.setFillAndStrokeStyleToContext(T,a,d);let E=p,A=h,D=f,P=g;return p<0&&(E=0,D+=Math.abs(p)),h<0&&(A=0,P+=Math.abs(h)),k.translate(-(x.scale*E),-($.scale*A)),T.transform(x.scale,0,0,$.scale,0,0),k.save(),this.clipBbox(T,E,A,D,P),T.baseTransform=Io(T.ctx),T.executeOperatorList(r),T.endDrawing(),{canvas:S.canvas,scaleX:x.scale,scaleY:$.scale,offsetX:E,offsetY:A}}getSizeAndScale(t,r,n){t=Math.abs(t);const o=Math.max(tN.MAX_PATTERN_SIZE,r);let i=Math.ceil(t*n);return i>=o?i=o:n=i/t,{scale:n,size:i}}clipBbox(t,r,n,o,i){const a=o-r,l=i-n;t.ctx.rect(r,n,a,l),t.current.updateRectMinMax(Io(t.ctx),[r,n,o,i]),t.clip(),t.endPath()}setFillAndStrokeStyleToContext(t,r,n){const o=t.ctx,i=t.current;switch(r){case qQ.COLORED:const a=this.ctx;o.fillStyle=a.fillStyle,o.strokeStyle=a.strokeStyle,i.fillColor=a.fillStyle,i.strokeColor=a.strokeStyle;break;case qQ.UNCOLORED:const l=lr.makeHexColor(n[0],n[1],n[2]);o.fillStyle=l,o.strokeStyle=l,i.fillColor=l,i.strokeColor=l;break;default:throw new L2t(`Unsupported paint type: ${r}`)}}getPattern(t,r,n,o){let i=n;o!==Va.SHADING&&(i=lr.transform(i,r.baseTransform),this.matrix&&(i=lr.transform(i,this.matrix)));const a=this.createPatternCanvas(r);let l=new DOMMatrix(i);l=l.translate(a.offsetX,a.offsetY),l=l.scale(1/a.scaleX,1/a.scaleY);const d=t.createPattern(a.canvas,"repeat");return d.setTransform(l),d}}function i0t({src:e,srcPos:t=0,dest:r,width:n,height:o,nonBlackColor:i=4294967295,inverseDecode:a=!1}){const l=bs.isLittleEndian?4278190080:255,[d,u]=a?[i,l]:[l,i],p=n>>3,h=n&7,f=e.length;r=new Uint32Array(r.buffer);let g=0;for(let y=0;y<o;y++){for(const w=t+p;t<w;t++){const x=t<f?e[t]:255;r[g++]=x&128?u:d,r[g++]=x&64?u:d,r[g++]=x&32?u:d,r[g++]=x&16?u:d,r[g++]=x&8?u:d,r[g++]=x&4?u:d,r[g++]=x&2?u:d,r[g++]=x&1?u:d}if(h===0)continue;const v=t<f?e[t++]:255;for(let w=0;w<h;w++)r[g++]=v&1<<7-w?u:d}return{srcPos:t,destPos:g}}const ZQ=16,KQ=100,a0t=15,XQ=10,QQ=1e3,us=16;function s0t(e,t){if(e._removeMirroring)throw new Error("Context is already forwarding operations.");e.__originalSave=e.save,e.__originalRestore=e.restore,e.__originalRotate=e.rotate,e.__originalScale=e.scale,e.__originalTranslate=e.translate,e.__originalTransform=e.transform,e.__originalSetTransform=e.setTransform,e.__originalResetTransform=e.resetTransform,e.__originalClip=e.clip,e.__originalMoveTo=e.moveTo,e.__originalLineTo=e.lineTo,e.__originalBezierCurveTo=e.bezierCurveTo,e.__originalRect=e.rect,e.__originalClosePath=e.closePath,e.__originalBeginPath=e.beginPath,e._removeMirroring=()=>{e.save=e.__originalSave,e.restore=e.__originalRestore,e.rotate=e.__originalRotate,e.scale=e.__originalScale,e.translate=e.__originalTranslate,e.transform=e.__originalTransform,e.setTransform=e.__originalSetTransform,e.resetTransform=e.__originalResetTransform,e.clip=e.__originalClip,e.moveTo=e.__originalMoveTo,e.lineTo=e.__originalLineTo,e.bezierCurveTo=e.__originalBezierCurveTo,e.rect=e.__originalRect,e.closePath=e.__originalClosePath,e.beginPath=e.__originalBeginPath,delete e._removeMirroring},e.save=function(){t.save(),this.__originalSave()},e.restore=function(){t.restore(),this.__originalRestore()},e.translate=function(n,o){t.translate(n,o),this.__originalTranslate(n,o)},e.scale=function(n,o){t.scale(n,o),this.__originalScale(n,o)},e.transform=function(n,o,i,a,l,d){t.transform(n,o,i,a,l,d),this.__originalTransform(n,o,i,a,l,d)},e.setTransform=function(n,o,i,a,l,d){t.setTransform(n,o,i,a,l,d),this.__originalSetTransform(n,o,i,a,l,d)},e.resetTransform=function(){t.resetTransform(),this.__originalResetTransform()},e.rotate=function(n){t.rotate(n),this.__originalRotate(n)},e.clip=function(n){t.clip(n),this.__originalClip(n)},e.moveTo=function(r,n){t.moveTo(r,n),this.__originalMoveTo(r,n)},e.lineTo=function(r,n){t.lineTo(r,n),this.__originalLineTo(r,n)},e.bezierCurveTo=function(r,n,o,i,a,l){t.bezierCurveTo(r,n,o,i,a,l),this.__originalBezierCurveTo(r,n,o,i,a,l)},e.rect=function(r,n,o,i){t.rect(r,n,o,i),this.__originalRect(r,n,o,i)},e.closePath=function(){t.closePath(),this.__originalClosePath()},e.beginPath=function(){t.beginPath(),this.__originalBeginPath()}}class l0t{constructor(t){this.canvasFactory=t,this.cache=Object.create(null)}getCanvas(t,r,n){let o;return this.cache[t]!==void 0?(o=this.cache[t],this.canvasFactory.reset(o,r,n)):(o=this.canvasFactory.create(r,n),this.cache[t]=o),o}delete(t){delete this.cache[t]}clear(){for(const t in this.cache){const r=this.cache[t];this.canvasFactory.destroy(r),delete this.cache[t]}}}function M9(e,t,r,n,o,i,a,l,d,u){const[p,h,f,g,y,v]=Io(e);if(h===0&&f===0){const $=a*p+y,S=Math.round($),k=l*g+v,T=Math.round(k),E=(a+d)*p+y,A=Math.abs(Math.round(E)-S)||1,D=(l+u)*g+v,P=Math.abs(Math.round(D)-T)||1;return e.setTransform(Math.sign(p),0,0,Math.sign(g),S,T),e.drawImage(t,r,n,o,i,0,0,A,P),e.setTransform(p,h,f,g,y,v),[A,P]}if(p===0&&g===0){const $=l*f+y,S=Math.round($),k=a*h+v,T=Math.round(k),E=(l+u)*f+y,A=Math.abs(Math.round(E)-S)||1,D=(a+d)*h+v,P=Math.abs(Math.round(D)-T)||1;return e.setTransform(0,Math.sign(h),Math.sign(f),0,S,T),e.drawImage(t,r,n,o,i,0,0,P,A),e.setTransform(p,h,f,g,y,v),[P,A]}e.drawImage(t,r,n,o,i,a,l,d,u);const w=Math.hypot(p,h),x=Math.hypot(f,g);return[w*d,x*u]}function c0t(e){const{width:t,height:r}=e;if(t>QQ||r>QQ)return null;const n=1e3,o=new Uint8Array([0,2,4,0,1,0,5,4,8,10,0,8,0,2,1,0]),i=t+1;let a=new Uint8Array(i*(r+1)),l,d,u;const p=t+7&-8;let h=new Uint8Array(p*r),f=0;for(const x of e.data){let $=128;for(;$>0;)h[f++]=x&$?0:255,$>>=1}let g=0;for(f=0,h[f]!==0&&(a[0]=1,++g),d=1;d<t;d++)h[f]!==h[f+1]&&(a[d]=h[f]?2:1,++g),f++;for(h[f]!==0&&(a[d]=2,++g),l=1;l<r;l++){f=l*p,u=l*i,h[f-p]!==h[f]&&(a[u]=h[f]?1:8,++g);let x=(h[f]?4:0)+(h[f-p]?8:0);for(d=1;d<t;d++)x=(x>>2)+(h[f+1]?4:0)+(h[f-p+1]?8:0),o[x]&&(a[u+d]=o[x],++g),f++;if(h[f-p]!==h[f]&&(a[u+d]=h[f]?2:4,++g),g>n)return null}for(f=p*(r-1),u=l*i,h[f]!==0&&(a[u]=8,++g),d=1;d<t;d++)h[f]!==h[f+1]&&(a[u+d]=h[f]?4:8,++g),f++;if(h[f]!==0&&(a[u+d]=4,++g),g>n)return null;const y=new Int32Array([0,i,-1,0,-i,0,0,0,1]),v=new Path2D;for(l=0;g&&l<=r;l++){let x=l*i;const $=x+t;for(;x<$&&!a[x];)x++;if(x===$)continue;v.moveTo(x%i,l);const S=x;let k=a[x];do{const T=y[k];do x+=T;while(!a[x]);const E=a[x];E!==5&&E!==10?(k=E,a[x]=0):(k=E&51*k>>4,a[x]&=k>>2|k<<2),v.lineTo(x%i,x/i|0),a[x]||--g}while(S!==x);--l}return h=null,a=null,function(x){x.save(),x.scale(1/t,-1/r),x.translate(0,-r),x.fill(v),x.beginPath(),x.restore()}}class JQ{constructor(t,r){this.alphaIsShape=!1,this.fontSize=0,this.fontSizeScale=1,this.textMatrix=Vge,this.textMatrixScale=1,this.fontMatrix=oj,this.leading=0,this.x=0,this.y=0,this.lineX=0,this.lineY=0,this.charSpacing=0,this.wordSpacing=0,this.textHScale=1,this.textRenderingMode=va.FILL,this.textRise=0,this.fillColor="#000000",this.strokeColor="#000000",this.patternFill=!1,this.fillAlpha=1,this.strokeAlpha=1,this.lineWidth=1,this.activeSMask=null,this.transferMaps="none",this.startNewPathAndClipBox([0,0,t,r])}clone(){const t=Object.create(this);return t.clipBox=this.clipBox.slice(),t}setCurrentPoint(t,r){this.x=t,this.y=r}updatePathMinMax(t,r,n){[r,n]=lr.applyTransform([r,n],t),this.minX=Math.min(this.minX,r),this.minY=Math.min(this.minY,n),this.maxX=Math.max(this.maxX,r),this.maxY=Math.max(this.maxY,n)}updateRectMinMax(t,r){const n=lr.applyTransform(r,t),o=lr.applyTransform(r.slice(2),t),i=lr.applyTransform([r[0],r[3]],t),a=lr.applyTransform([r[2],r[1]],t);this.minX=Math.min(this.minX,n[0],o[0],i[0],a[0]),this.minY=Math.min(this.minY,n[1],o[1],i[1],a[1]),this.maxX=Math.max(this.maxX,n[0],o[0],i[0],a[0]),this.maxY=Math.max(this.maxY,n[1],o[1],i[1],a[1])}updateScalingPathMinMax(t,r){lr.scaleMinMax(t,r),this.minX=Math.min(this.minX,r[0]),this.minY=Math.min(this.minY,r[1]),this.maxX=Math.max(this.maxX,r[2]),this.maxY=Math.max(this.maxY,r[3])}updateCurvePathMinMax(t,r,n,o,i,a,l,d,u,p){const h=lr.bezierBoundingBox(r,n,o,i,a,l,d,u,p);p||this.updateRectMinMax(t,h)}getPathBoundingBox(t=Va.FILL,r=null){const n=[this.minX,this.minY,this.maxX,this.maxY];if(t===Va.STROKE){r||Xn("Stroke bounding box must include transform.");const o=lr.singularValueDecompose2dScale(r),i=o[0]*this.lineWidth/2,a=o[1]*this.lineWidth/2;n[0]-=i,n[1]-=a,n[2]+=i,n[3]+=a}return n}updateClipFromPath(){const t=lr.intersect(this.clipBox,this.getPathBoundingBox());this.startNewPathAndClipBox(t||[0,0,0,0])}isEmptyClip(){return this.minX===1/0}startNewPathAndClipBox(t){this.clipBox=t,this.minX=1/0,this.minY=1/0,this.maxX=0,this.maxY=0}getClippedPathBoundingBox(t=Va.FILL,r=null){return lr.intersect(this.clipBox,this.getPathBoundingBox(t,r))}}function eJ(e,t){if(typeof ImageData<"u"&&t instanceof ImageData){e.putImageData(t,0,0);return}const r=t.height,n=t.width,o=r%us,i=(r-o)/us,a=o===0?i:i+1,l=e.createImageData(n,us);let d=0,u;const p=t.data,h=l.data;let f,g,y,v;if(t.kind===Iy.GRAYSCALE_1BPP){const w=p.byteLength,x=new Uint32Array(h.buffer,0,h.byteLength>>2),$=x.length,S=n+7>>3,k=4294967295,T=bs.isLittleEndian?4278190080:255;for(f=0;f<a;f++){for(y=f<i?us:o,u=0,g=0;g<y;g++){const E=w-d;let A=0;const D=E>S?n:E*8-7,P=D&-8;let j=0,B=0;for(;A<P;A+=8)B=p[d++],x[u++]=B&128?k:T,x[u++]=B&64?k:T,x[u++]=B&32?k:T,x[u++]=B&16?k:T,x[u++]=B&8?k:T,x[u++]=B&4?k:T,x[u++]=B&2?k:T,x[u++]=B&1?k:T;for(;A<D;A++)j===0&&(B=p[d++],j=128),x[u++]=B&j?k:T,j>>=1}for(;u<$;)x[u++]=0;e.putImageData(l,0,f*us)}}else if(t.kind===Iy.RGBA_32BPP){for(g=0,v=n*us*4,f=0;f<i;f++)h.set(p.subarray(d,d+v)),d+=v,e.putImageData(l,0,g),g+=us;f<a&&(v=n*o*4,h.set(p.subarray(d,d+v)),e.putImageData(l,0,g))}else if(t.kind===Iy.RGB_24BPP)for(y=us,v=n*y,f=0;f<a;f++){for(f>=i&&(y=o,v=n*y),u=0,g=v;g--;)h[u++]=p[d++],h[u++]=p[d++],h[u++]=p[d++],h[u++]=255;e.putImageData(l,0,f*us)}else throw new Error(`bad image kind: ${t.kind}`)}function tJ(e,t){if(t.bitmap){e.drawImage(t.bitmap,0,0);return}const r=t.height,n=t.width,o=r%us,i=(r-o)/us,a=o===0?i:i+1,l=e.createImageData(n,us);let d=0;const u=t.data,p=l.data;for(let h=0;h<a;h++){const f=h<i?us:o;({srcPos:d}=i0t({src:u,srcPos:d,dest:p,width:n,height:f,nonBlackColor:0})),e.putImageData(l,0,h*us)}}function H4(e,t){const r=["strokeStyle","fillStyle","fillRule","globalAlpha","lineWidth","lineCap","lineJoin","miterLimit","globalCompositeOperation","font","filter"];for(const n of r)e[n]!==void 0&&(t[n]=e[n]);e.setLineDash!==void 0&&(t.setLineDash(e.getLineDash()),t.lineDashOffset=e.lineDashOffset)}function P9(e){if(e.strokeStyle=e.fillStyle="#000000",e.fillRule="nonzero",e.globalAlpha=1,e.lineWidth=1,e.lineCap="butt",e.lineJoin="miter",e.miterLimit=10,e.globalCompositeOperation="source-over",e.font="10px sans-serif",e.setLineDash!==void 0&&(e.setLineDash([]),e.lineDashOffset=0),!ka){const{filter:t}=e;t!=="none"&&t!==""&&(e.filter="none")}}function rJ(e,t){if(t)return!0;const r=lr.singularValueDecompose2dScale(e);r[0]=Math.fround(r[0]),r[1]=Math.fround(r[1]);const n=Math.fround((globalThis.devicePixelRatio||1)*Qf.PDF_TO_CSS_UNITS);return r[0]<=n&&r[1]<=n}const d0t=["butt","round","square"],u0t=["miter","round","bevel"],p0t={},nJ={};class Ef{constructor(t,r,n,o,i,{optionalContentConfig:a,markedContentStack:l=null},d,u){this.ctx=t,this.current=new JQ(this.ctx.canvas.width,this.ctx.canvas.height),this.stateStack=[],this.pendingClip=null,this.pendingEOFill=!1,this.res=null,this.xobjs=null,this.commonObjs=r,this.objs=n,this.canvasFactory=o,this.filterFactory=i,this.groupStack=[],this.processingType3=null,this.baseTransform=null,this.baseTransformStack=[],this.groupLevel=0,this.smaskStack=[],this.smaskCounter=0,this.tempSMask=null,this.suspendedCtx=null,this.contentVisible=!0,this.markedContentStack=l||[],this.optionalContentConfig=a,this.cachedCanvases=new l0t(this.canvasFactory),this.cachedPatterns=new Map,this.annotationCanvasMap=d,this.viewportScale=1,this.outputScaleX=1,this.outputScaleY=1,this.pageColors=u,this._cachedScaleForStroking=[-1,0],this._cachedGetSinglePixelWidth=null,this._cachedBitmapsMap=new Map}getObject(t,r=null){return typeof t=="string"?t.startsWith("g_")?this.commonObjs.get(t):this.objs.get(t):r}beginDrawing({transform:t,viewport:r,transparency:n=!1,background:o=null}){const i=this.ctx.canvas.width,a=this.ctx.canvas.height,l=this.ctx.fillStyle;if(this.ctx.fillStyle=o||"#ffffff",this.ctx.fillRect(0,0,i,a),this.ctx.fillStyle=l,n){const d=this.cachedCanvases.getCanvas("transparent",i,a);this.compositeCtx=this.ctx,this.transparentCanvas=d.canvas,this.ctx=d.context,this.ctx.save(),this.ctx.transform(...Io(this.compositeCtx))}this.ctx.save(),P9(this.ctx),t&&(this.ctx.transform(...t),this.outputScaleX=t[0],this.outputScaleY=t[0]),this.ctx.transform(...r.transform),this.viewportScale=r.scale,this.baseTransform=Io(this.ctx)}executeOperatorList(t,r,n,o){const i=t.argsArray,a=t.fnArray;let l=r||0;const d=i.length;if(d===l)return l;const u=d-l>XQ&&typeof n=="function",p=u?Date.now()+a0t:0;let h=0;const f=this.commonObjs,g=this.objs;let y;for(;;){if(o!==void 0&&l===o.nextBreakPoint)return o.breakIt(l,n),l;if(y=a[l],y!==$c.dependency)this[y].apply(this,i[l]);else for(const v of i[l]){const w=v.startsWith("g_")?f:g;if(!w.has(v))return w.get(v,n),l}if(l++,l===d)return l;if(u&&++h>XQ){if(Date.now()>p)return n(),l;h=0}}}#e(){for(;this.stateStack.length||this.inSMaskMode;)this.restore();this.ctx.restore(),this.transparentCanvas&&(this.ctx=this.compositeCtx,this.ctx.save(),this.ctx.setTransform(1,0,0,1,0,0),this.ctx.drawImage(this.transparentCanvas,0,0),this.ctx.restore(),this.transparentCanvas=null)}endDrawing(){this.#e(),this.cachedCanvases.clear(),this.cachedPatterns.clear();for(const t of this._cachedBitmapsMap.values()){for(const r of t.values())typeof HTMLCanvasElement<"u"&&r instanceof HTMLCanvasElement&&(r.width=r.height=0);t.clear()}this._cachedBitmapsMap.clear(),this.#t()}#t(){if(this.pageColors){const t=this.filterFactory.addHCMFilter(this.pageColors.foreground,this.pageColors.background);if(t!=="none"){const r=this.ctx.filter;this.ctx.filter=t,this.ctx.drawImage(this.ctx.canvas,0,0),this.ctx.filter=r}}}_scaleImage(t,r){const n=t.width,o=t.height;let i=Math.max(Math.hypot(r[0],r[1]),1),a=Math.max(Math.hypot(r[2],r[3]),1),l=n,d=o,u="prescale1",p,h;for(;i>2&&l>1||a>2&&d>1;){let f=l,g=d;i>2&&l>1&&(f=l>=16384?Math.floor(l/2)-1||1:Math.ceil(l/2),i/=l/f),a>2&&d>1&&(g=d>=16384?Math.floor(d/2)-1||1:Math.ceil(d)/2,a/=d/g),p=this.cachedCanvases.getCanvas(u,f,g),h=p.context,h.clearRect(0,0,f,g),h.drawImage(t,0,0,l,d,0,0,f,g),t=p.canvas,l=f,d=g,u=u==="prescale1"?"prescale2":"prescale1"}return{img:t,paintWidth:l,paintHeight:d}}_createMaskCanvas(t){const r=this.ctx,{width:n,height:o}=t,i=this.current.fillColor,a=this.current.patternFill,l=Io(r);let d,u,p,h;if((t.bitmap||t.data)&&t.count>1){const D=t.bitmap||t.data.buffer;u=JSON.stringify(a?l:[l.slice(0,4),i]),d=this._cachedBitmapsMap.get(D),d||(d=new Map,this._cachedBitmapsMap.set(D,d));const P=d.get(u);if(P&&!a){const j=Math.round(Math.min(l[0],l[2])+l[4]),B=Math.round(Math.min(l[1],l[3])+l[5]);return{canvas:P,offsetX:j,offsetY:B}}p=P}p||(h=this.cachedCanvases.getCanvas("maskCanvas",n,o),tJ(h.context,t));let f=lr.transform(l,[1/n,0,0,-1/o,0,0]);f=lr.transform(f,[1,0,0,1,0,-o]);const[g,y,v,w]=lr.getAxialAlignedBoundingBox([0,0,n,o],f),x=Math.round(v-g)||1,$=Math.round(w-y)||1,S=this.cachedCanvases.getCanvas("fillCanvas",x,$),k=S.context,T=g,E=y;k.translate(-T,-E),k.transform(...f),p||(p=this._scaleImage(h.canvas,fu(k)),p=p.img,d&&a&&d.set(u,p)),k.imageSmoothingEnabled=rJ(Io(k),t.interpolate),M9(k,p,0,0,p.width,p.height,0,0,n,o),k.globalCompositeOperation="source-in";const A=lr.transform(fu(k),[1,0,0,1,-T,-E]);return k.fillStyle=a?i.getPattern(r,this,A,Va.FILL):i,k.fillRect(0,0,n,o),d&&!a&&(this.cachedCanvases.delete("fillCanvas"),d.set(u,S.canvas)),{canvas:S.canvas,offsetX:Math.round(T),offsetY:Math.round(E)}}setLineWidth(t){t!==this.current.lineWidth&&(this._cachedScaleForStroking[0]=-1),this.current.lineWidth=t,this.ctx.lineWidth=t}setLineCap(t){this.ctx.lineCap=d0t[t]}setLineJoin(t){this.ctx.lineJoin=u0t[t]}setMiterLimit(t){this.ctx.miterLimit=t}setDash(t,r){const n=this.ctx;n.setLineDash!==void 0&&(n.setLineDash(t),n.lineDashOffset=r)}setRenderingIntent(t){}setFlatness(t){}setGState(t){for(const[r,n]of t)switch(r){case"LW":this.setLineWidth(n);break;case"LC":this.setLineCap(n);break;case"LJ":this.setLineJoin(n);break;case"ML":this.setMiterLimit(n);break;case"D":this.setDash(n[0],n[1]);break;case"RI":this.setRenderingIntent(n);break;case"FL":this.setFlatness(n);break;case"Font":this.setFont(n[0],n[1]);break;case"CA":this.current.strokeAlpha=n;break;case"ca":this.current.fillAlpha=n,this.ctx.globalAlpha=n;break;case"BM":this.ctx.globalCompositeOperation=n;break;case"SMask":this.current.activeSMask=n?this.tempSMask:null,this.tempSMask=null,this.checkSMaskState();break;case"TR":this.ctx.filter=this.current.transferMaps=this.filterFactory.addFilter(n);break}}get inSMaskMode(){return!!this.suspendedCtx}checkSMaskState(){const t=this.inSMaskMode;this.current.activeSMask&&!t?this.beginSMaskMode():!this.current.activeSMask&&t&&this.endSMaskMode()}beginSMaskMode(){if(this.inSMaskMode)throw new Error("beginSMaskMode called while already in smask mode");const t=this.ctx.canvas.width,r=this.ctx.canvas.height,n="smaskGroupAt"+this.groupLevel,o=this.cachedCanvases.getCanvas(n,t,r);this.suspendedCtx=this.ctx,this.ctx=o.context;const i=this.ctx;i.setTransform(...Io(this.suspendedCtx)),H4(this.suspendedCtx,i),s0t(i,this.suspendedCtx),this.setGState([["BM","source-over"],["ca",1],["CA",1]])}endSMaskMode(){if(!this.inSMaskMode)throw new Error("endSMaskMode called while not in smask mode");this.ctx._removeMirroring(),H4(this.ctx,this.suspendedCtx),this.ctx=this.suspendedCtx,this.suspendedCtx=null}compose(t){if(!this.current.activeSMask)return;t?(t[0]=Math.floor(t[0]),t[1]=Math.floor(t[1]),t[2]=Math.ceil(t[2]),t[3]=Math.ceil(t[3])):t=[0,0,this.ctx.canvas.width,this.ctx.canvas.height];const r=this.current.activeSMask,n=this.suspendedCtx;this.composeSMask(n,r,this.ctx,t),this.ctx.save(),this.ctx.setTransform(1,0,0,1,0,0),this.ctx.clearRect(0,0,this.ctx.canvas.width,this.ctx.canvas.height),this.ctx.restore()}composeSMask(t,r,n,o){const i=o[0],a=o[1],l=o[2]-i,d=o[3]-a;l===0||d===0||(this.genericComposeSMask(r.context,n,l,d,r.subtype,r.backdrop,r.transferMap,i,a,r.offsetX,r.offsetY),t.save(),t.globalAlpha=1,t.globalCompositeOperation="source-over",t.setTransform(1,0,0,1,0,0),t.drawImage(n.canvas,0,0),t.restore())}genericComposeSMask(t,r,n,o,i,a,l,d,u,p,h){let f=t.canvas,g=d-p,y=u-h;if(a){if(g<0||y<0||g+n>f.width||y+o>f.height){const w=this.cachedCanvases.getCanvas("maskExtension",n,o),x=w.context;x.drawImage(f,-g,-y),a.some($=>$!==0)&&(x.globalCompositeOperation="destination-atop",x.fillStyle=lr.makeHexColor(...a),x.fillRect(0,0,n,o),x.globalCompositeOperation="source-over"),f=w.canvas,g=y=0}else if(a.some(w=>w!==0)){t.save(),t.globalAlpha=1,t.setTransform(1,0,0,1,0,0);const w=new Path2D;w.rect(g,y,n,o),t.clip(w),t.globalCompositeOperation="destination-atop",t.fillStyle=lr.makeHexColor(...a),t.fillRect(g,y,n,o),t.restore()}}r.save(),r.globalAlpha=1,r.setTransform(1,0,0,1,0,0),i==="Alpha"&&l?r.filter=this.filterFactory.addAlphaFilter(l):i==="Luminosity"&&(r.filter=this.filterFactory.addLuminosityFilter(l));const v=new Path2D;v.rect(d,u,n,o),r.clip(v),r.globalCompositeOperation="destination-in",r.drawImage(f,g,y,n,o,d,u,n,o),r.restore()}save(){this.inSMaskMode?(H4(this.ctx,this.suspendedCtx),this.suspendedCtx.save()):this.ctx.save();const t=this.current;this.stateStack.push(t),this.current=t.clone()}restore(){this.stateStack.length===0&&this.inSMaskMode&&this.endSMaskMode(),this.stateStack.length!==0&&(this.current=this.stateStack.pop(),this.inSMaskMode?(this.suspendedCtx.restore(),H4(this.suspendedCtx,this.ctx)):this.ctx.restore(),this.checkSMaskState(),this.pendingClip=null,this._cachedScaleForStroking[0]=-1,this._cachedGetSinglePixelWidth=null)}transform(t,r,n,o,i,a){this.ctx.transform(t,r,n,o,i,a),this._cachedScaleForStroking[0]=-1,this._cachedGetSinglePixelWidth=null}constructPath(t,r,n){const o=this.ctx,i=this.current;let a=i.x,l=i.y,d,u;const p=Io(o),h=p[0]===0&&p[3]===0||p[1]===0&&p[2]===0,f=h?n.slice(0):null;for(let g=0,y=0,v=t.length;g<v;g++)switch(t[g]|0){case $c.rectangle:a=r[y++],l=r[y++];const w=r[y++],x=r[y++],$=a+w,S=l+x;o.moveTo(a,l),w===0||x===0?o.lineTo($,S):(o.lineTo($,l),o.lineTo($,S),o.lineTo(a,S)),h||i.updateRectMinMax(p,[a,l,$,S]),o.closePath();break;case $c.moveTo:a=r[y++],l=r[y++],o.moveTo(a,l),h||i.updatePathMinMax(p,a,l);break;case $c.lineTo:a=r[y++],l=r[y++],o.lineTo(a,l),h||i.updatePathMinMax(p,a,l);break;case $c.curveTo:d=a,u=l,a=r[y+4],l=r[y+5],o.bezierCurveTo(r[y],r[y+1],r[y+2],r[y+3],a,l),i.updateCurvePathMinMax(p,d,u,r[y],r[y+1],r[y+2],r[y+3],a,l,f),y+=6;break;case $c.curveTo2:d=a,u=l,o.bezierCurveTo(a,l,r[y],r[y+1],r[y+2],r[y+3]),i.updateCurvePathMinMax(p,d,u,a,l,r[y],r[y+1],r[y+2],r[y+3],f),a=r[y+2],l=r[y+3],y+=4;break;case $c.curveTo3:d=a,u=l,a=r[y+2],l=r[y+3],o.bezierCurveTo(r[y],r[y+1],a,l,a,l),i.updateCurvePathMinMax(p,d,u,r[y],r[y+1],a,l,a,l,f),y+=4;break;case $c.closePath:o.closePath();break}h&&i.updateScalingPathMinMax(p,f),i.setCurrentPoint(a,l)}closePath(){this.ctx.closePath()}stroke(t=!0){const r=this.ctx,n=this.current.strokeColor;r.globalAlpha=this.current.strokeAlpha,this.contentVisible&&(typeof n=="object"&&n?.getPattern?(r.save(),r.strokeStyle=n.getPattern(r,this,fu(r),Va.STROKE),this.rescaleAndStroke(!1),r.restore()):this.rescaleAndStroke(!0)),t&&this.consumePath(this.current.getClippedPathBoundingBox()),r.globalAlpha=this.current.fillAlpha}closeStroke(){this.closePath(),this.stroke()}fill(t=!0){const r=this.ctx,n=this.current.fillColor,o=this.current.patternFill;let i=!1;o&&(r.save(),r.fillStyle=n.getPattern(r,this,fu(r),Va.FILL),i=!0);const a=this.current.getClippedPathBoundingBox();this.contentVisible&&a!==null&&(this.pendingEOFill?(r.fill("evenodd"),this.pendingEOFill=!1):r.fill()),i&&r.restore(),t&&this.consumePath(a)}eoFill(){this.pendingEOFill=!0,this.fill()}fillStroke(){this.fill(!1),this.stroke(!1),this.consumePath()}eoFillStroke(){this.pendingEOFill=!0,this.fillStroke()}closeFillStroke(){this.closePath(),this.fillStroke()}closeEOFillStroke(){this.pendingEOFill=!0,this.closePath(),this.fillStroke()}endPath(){this.consumePath()}clip(){this.pendingClip=p0t}eoClip(){this.pendingClip=nJ}beginText(){this.current.textMatrix=Vge,this.current.textMatrixScale=1,this.current.x=this.current.lineX=0,this.current.y=this.current.lineY=0}endText(){const t=this.pendingTextPaths,r=this.ctx;if(t===void 0){r.beginPath();return}r.save(),r.beginPath();for(const n of t)r.setTransform(...n.transform),r.translate(n.x,n.y),n.addToPath(r,n.fontSize);r.restore(),r.clip(),r.beginPath(),delete this.pendingTextPaths}setCharSpacing(t){this.current.charSpacing=t}setWordSpacing(t){this.current.wordSpacing=t}setHScale(t){this.current.textHScale=t/100}setLeading(t){this.current.leading=-t}setFont(t,r){const n=this.commonObjs.get(t),o=this.current;if(!n)throw new Error(`Can't find font for ${t}`);if(o.fontMatrix=n.fontMatrix||oj,(o.fontMatrix[0]===0||o.fontMatrix[3]===0)&&Jr("Invalid font matrix for font "+t),r<0?(r=-r,o.fontDirection=-1):o.fontDirection=1,this.current.font=n,this.current.fontSize=r,n.isType3Font)return;const i=n.loadedName||"sans-serif",a=n.systemFontInfo?.css||`"${i}", ${n.fallbackName}`;let l="normal";n.black?l="900":n.bold&&(l="bold");const d=n.italic?"italic":"normal";let u=r;r<ZQ?u=ZQ:r>KQ&&(u=KQ),this.current.fontSizeScale=r/u,this.ctx.font=`${d} ${l} ${u}px ${a}`}setTextRenderingMode(t){this.current.textRenderingMode=t}setTextRise(t){this.current.textRise=t}moveText(t,r){this.current.x=this.current.lineX+=t,this.current.y=this.current.lineY+=r}setLeadingMoveText(t,r){this.setLeading(-r),this.moveText(t,r)}setTextMatrix(t,r,n,o,i,a){this.current.textMatrix=[t,r,n,o,i,a],this.current.textMatrixScale=Math.hypot(t,r),this.current.x=this.current.lineX=0,this.current.y=this.current.lineY=0}nextLine(){this.moveText(0,this.current.leading)}paintChar(t,r,n,o){const i=this.ctx,a=this.current,l=a.font,d=a.textRenderingMode,u=a.fontSize/a.fontSizeScale,p=d&va.FILL_STROKE_MASK,h=!!(d&va.ADD_TO_PATH_FLAG),f=a.patternFill&&!l.missingFile;let g;(l.disableFontFace||h||f)&&(g=l.getPathGenerator(this.commonObjs,t)),l.disableFontFace||f?(i.save(),i.translate(r,n),i.beginPath(),g(i,u),o&&i.setTransform(...o),(p===va.FILL||p===va.FILL_STROKE)&&i.fill(),(p===va.STROKE||p===va.FILL_STROKE)&&i.stroke(),i.restore()):((p===va.FILL||p===va.FILL_STROKE)&&i.fillText(t,r,n),(p===va.STROKE||p===va.FILL_STROKE)&&i.strokeText(t,r,n)),h&&(this.pendingTextPaths||=[]).push({transform:Io(i),x:r,y:n,fontSize:u,addToPath:g})}get isFontSubpixelAAEnabled(){const{context:t}=this.cachedCanvases.getCanvas("isFontSubpixelAAEnabled",10,10);t.scale(1.5,1),t.fillText("I",0,10);const r=t.getImageData(0,0,10,10).data;let n=!1;for(let o=3;o<r.length;o+=4)if(r[o]>0&&r[o]<255){n=!0;break}return vn(this,"isFontSubpixelAAEnabled",n)}showText(t){const r=this.current,n=r.font;if(n.isType3Font)return this.showType3Text(t);const o=r.fontSize;if(o===0)return;const i=this.ctx,a=r.fontSizeScale,l=r.charSpacing,d=r.wordSpacing,u=r.fontDirection,p=r.textHScale*u,h=t.length,f=n.vertical,g=f?1:-1,y=n.defaultVMetrics,v=o*r.fontMatrix[0],w=r.textRenderingMode===va.FILL&&!n.disableFontFace&&!r.patternFill;i.save(),i.transform(...r.textMatrix),i.translate(r.x,r.y+r.textRise),u>0?i.scale(p,-1):i.scale(p,1);let x;if(r.patternFill){i.save();const E=r.fillColor.getPattern(i,this,fu(i),Va.FILL);x=Io(i),i.restore(),i.fillStyle=E}let $=r.lineWidth;const S=r.textMatrixScale;if(S===0||$===0){const E=r.textRenderingMode&va.FILL_STROKE_MASK;(E===va.STROKE||E===va.FILL_STROKE)&&($=this.getSinglePixelWidth())}else $/=S;if(a!==1&&(i.scale(a,a),$/=a),i.lineWidth=$,n.isInvalidPDFjsFont){const E=[];let A=0;for(const D of t)E.push(D.unicode),A+=D.width;i.fillText(E.join(""),0,0),r.x+=A*v*p,i.restore(),this.compose();return}let k=0,T;for(T=0;T<h;++T){const E=t[T];if(typeof E=="number"){k+=g*E*o/1e3;continue}let A=!1;const D=(E.isSpace?d:0)+l,P=E.fontChar,j=E.accent;let B,O,q=E.width;if(f){const F=E.vmetric||y,V=-(E.vmetric?F[1]:q*.5)*v,I=F[2]*v;q=F?-F[0]:q,B=V/a,O=(k+I)/a}else B=k/a,O=0;if(n.remeasure&&q>0){const F=i.measureText(P).width*1e3/o*a;if(q<F&&this.isFontSubpixelAAEnabled){const V=q/F;A=!0,i.save(),i.scale(V,1),B/=V}else q!==F&&(B+=(q-F)/2e3*o/a)}if(this.contentVisible&&(E.isInFont||n.missingFile)){if(w&&!j)i.fillText(P,B,O);else if(this.paintChar(P,B,O,x),j){const F=B+o*j.offset.x/a,V=O-o*j.offset.y/a;this.paintChar(j.fontChar,F,V,x)}}const W=f?q*v-D*u:q*v+D*u;k+=W,A&&i.restore()}f?r.y-=k:r.x+=k*p,i.restore(),this.compose()}showType3Text(t){const r=this.ctx,n=this.current,o=n.font,i=n.fontSize,a=n.fontDirection,l=o.vertical?1:-1,d=n.charSpacing,u=n.wordSpacing,p=n.textHScale*a,h=n.fontMatrix||oj,f=t.length,g=n.textRenderingMode===va.INVISIBLE;let y,v,w,x;if(!(g||i===0)){for(this._cachedScaleForStroking[0]=-1,this._cachedGetSinglePixelWidth=null,r.save(),r.transform(...n.textMatrix),r.translate(n.x,n.y),r.scale(p,a),y=0;y<f;++y){if(v=t[y],typeof v=="number"){x=l*v*i/1e3,this.ctx.translate(x,0),n.x+=x*p;continue}const $=(v.isSpace?u:0)+d,S=o.charProcOperatorList[v.operatorListId];if(!S){Jr(`Type3 character "${v.operatorListId}" is not available.`);continue}this.contentVisible&&(this.processingType3=v,this.save(),r.scale(i,i),r.transform(...h),this.executeOperatorList(S),this.restore()),w=lr.applyTransform([v.width,0],h)[0]*i+$,r.translate(w,0),n.x+=w*p}r.restore(),this.processingType3=null}}setCharWidth(t,r){}setCharWidthAndBounds(t,r,n,o,i,a){this.ctx.rect(n,o,i-n,a-o),this.ctx.clip(),this.endPath()}getColorN_Pattern(t){let r;if(t[0]==="TilingPattern"){const n=t[1],o=this.baseTransform||Io(this.ctx),i={createCanvasGraphics:a=>new Ef(a,this.commonObjs,this.objs,this.canvasFactory,this.filterFactory,{optionalContentConfig:this.optionalContentConfig,markedContentStack:this.markedContentStack})};r=new tN(t,n,this.ctx,i,o)}else r=this._getPattern(t[1],t[2]);return r}setStrokeColorN(){this.current.strokeColor=this.getColorN_Pattern(arguments)}setFillColorN(){this.current.fillColor=this.getColorN_Pattern(arguments),this.current.patternFill=!0}setStrokeRGBColor(t,r,n){const o=lr.makeHexColor(t,r,n);this.ctx.strokeStyle=o,this.current.strokeColor=o}setFillRGBColor(t,r,n){const o=lr.makeHexColor(t,r,n);this.ctx.fillStyle=o,this.current.fillColor=o,this.current.patternFill=!1}_getPattern(t,r=null){let n;return this.cachedPatterns.has(t)?n=this.cachedPatterns.get(t):(n=o0t(this.getObject(t)),this.cachedPatterns.set(t,n)),r&&(n.matrix=r),n}shadingFill(t){if(!this.contentVisible)return;const r=this.ctx;this.save();const n=this._getPattern(t);r.fillStyle=n.getPattern(r,this,fu(r),Va.SHADING);const o=fu(r);if(o){const{width:i,height:a}=r.canvas,[l,d,u,p]=lr.getAxialAlignedBoundingBox([0,0,i,a],o);this.ctx.fillRect(l,d,u-l,p-d)}else this.ctx.fillRect(-1e10,-1e10,2e10,2e10);this.compose(this.current.getClippedPathBoundingBox()),this.restore()}beginInlineImage(){Xn("Should not call beginInlineImage")}beginImageData(){Xn("Should not call beginImageData")}paintFormXObjectBegin(t,r){if(this.contentVisible&&(this.save(),this.baseTransformStack.push(this.baseTransform),t&&this.transform(...t),this.baseTransform=Io(this.ctx),r)){const n=r[2]-r[0],o=r[3]-r[1];this.ctx.rect(r[0],r[1],n,o),this.current.updateRectMinMax(Io(this.ctx),r),this.clip(),this.endPath()}}paintFormXObjectEnd(){this.contentVisible&&(this.restore(),this.baseTransform=this.baseTransformStack.pop())}beginGroup(t){if(!this.contentVisible)return;this.save(),this.inSMaskMode&&(this.endSMaskMode(),this.current.activeSMask=null);const r=this.ctx;t.isolated||Cx("TODO: Support non-isolated groups."),t.knockout&&Jr("Knockout groups not supported.");const n=Io(r);if(t.matrix&&r.transform(...t.matrix),!t.bbox)throw new Error("Bounding box is required.");let o=lr.getAxialAlignedBoundingBox(t.bbox,Io(r));const i=[0,0,r.canvas.width,r.canvas.height];o=lr.intersect(o,i)||[0,0,0,0];const a=Math.floor(o[0]),l=Math.floor(o[1]),d=Math.max(Math.ceil(o[2])-a,1),u=Math.max(Math.ceil(o[3])-l,1);this.current.startNewPathAndClipBox([0,0,d,u]);let p="groupAt"+this.groupLevel;t.smask&&(p+="_smask_"+this.smaskCounter++%2);const h=this.cachedCanvases.getCanvas(p,d,u),f=h.context;f.translate(-a,-l),f.transform(...n),t.smask?this.smaskStack.push({canvas:h.canvas,context:f,offsetX:a,offsetY:l,subtype:t.smask.subtype,backdrop:t.smask.backdrop,transferMap:t.smask.transferMap||null,startTransformInverse:null}):(r.setTransform(1,0,0,1,0,0),r.translate(a,l),r.save()),H4(r,f),this.ctx=f,this.setGState([["BM","source-over"],["ca",1],["CA",1]]),this.groupStack.push(r),this.groupLevel++}endGroup(t){if(!this.contentVisible)return;this.groupLevel--;const r=this.ctx,n=this.groupStack.pop();if(this.ctx=n,this.ctx.imageSmoothingEnabled=!1,t.smask)this.tempSMask=this.smaskStack.pop(),this.restore();else{this.ctx.restore();const o=Io(this.ctx);this.restore(),this.ctx.save(),this.ctx.setTransform(...o);const i=lr.getAxialAlignedBoundingBox([0,0,r.canvas.width,r.canvas.height],o);this.ctx.drawImage(r.canvas,0,0),this.ctx.restore(),this.compose(i)}}beginAnnotation(t,r,n,o,i){if(this.#e(),P9(this.ctx),this.ctx.save(),this.save(),this.baseTransform&&this.ctx.setTransform(...this.baseTransform),r){const a=r[2]-r[0],l=r[3]-r[1];if(i&&this.annotationCanvasMap){n=n.slice(),n[4]-=r[0],n[5]-=r[1],r=r.slice(),r[0]=r[1]=0,r[2]=a,r[3]=l;const[d,u]=lr.singularValueDecompose2dScale(Io(this.ctx)),{viewportScale:p}=this,h=Math.ceil(a*this.outputScaleX*p),f=Math.ceil(l*this.outputScaleY*p);this.annotationCanvas=this.canvasFactory.create(h,f);const{canvas:g,context:y}=this.annotationCanvas;this.annotationCanvasMap.set(t,g),this.annotationCanvas.savedCtx=this.ctx,this.ctx=y,this.ctx.save(),this.ctx.setTransform(d,0,0,-u,0,l*u),P9(this.ctx)}else P9(this.ctx),this.ctx.rect(r[0],r[1],a,l),this.ctx.clip(),this.endPath()}this.current=new JQ(this.ctx.canvas.width,this.ctx.canvas.height),this.transform(...n),this.transform(...o)}endAnnotation(){this.annotationCanvas&&(this.ctx.restore(),this.#t(),this.ctx=this.annotationCanvas.savedCtx,delete this.annotationCanvas.savedCtx,delete this.annotationCanvas)}paintImageMaskXObject(t){if(!this.contentVisible)return;const r=t.count;t=this.getObject(t.data,t),t.count=r;const n=this.ctx,o=this.processingType3;if(o&&(o.compiled===void 0&&(o.compiled=c0t(t)),o.compiled)){o.compiled(n);return}const i=this._createMaskCanvas(t),a=i.canvas;n.save(),n.setTransform(1,0,0,1,0,0),n.drawImage(a,i.offsetX,i.offsetY),n.restore(),this.compose()}paintImageMaskXObjectRepeat(t,r,n=0,o=0,i,a){if(!this.contentVisible)return;t=this.getObject(t.data,t);const l=this.ctx;l.save();const d=Io(l);l.transform(r,n,o,i,0,0);const u=this._createMaskCanvas(t);l.setTransform(1,0,0,1,u.offsetX-d[4],u.offsetY-d[5]);for(let p=0,h=a.length;p<h;p+=2){const f=lr.transform(d,[r,n,o,i,a[p],a[p+1]]),[g,y]=lr.applyTransform([0,0],f);l.drawImage(u.canvas,g,y)}l.restore(),this.compose()}paintImageMaskXObjectGroup(t){if(!this.contentVisible)return;const r=this.ctx,n=this.current.fillColor,o=this.current.patternFill;for(const i of t){const{data:a,width:l,height:d,transform:u}=i,p=this.cachedCanvases.getCanvas("maskCanvas",l,d),h=p.context;h.save();const f=this.getObject(a,i);tJ(h,f),h.globalCompositeOperation="source-in",h.fillStyle=o?n.getPattern(h,this,fu(r),Va.FILL):n,h.fillRect(0,0,l,d),h.restore(),r.save(),r.transform(...u),r.scale(1,-1),M9(r,p.canvas,0,0,l,d,0,-1,1,1),r.restore()}this.compose()}paintImageXObject(t){if(!this.contentVisible)return;const r=this.getObject(t);if(!r){Jr("Dependent image isn't ready yet");return}this.paintInlineImageXObject(r)}paintImageXObjectRepeat(t,r,n,o){if(!this.contentVisible)return;const i=this.getObject(t);if(!i){Jr("Dependent image isn't ready yet");return}const a=i.width,l=i.height,d=[];for(let u=0,p=o.length;u<p;u+=2)d.push({transform:[r,0,0,n,o[u],o[u+1]],x:0,y:0,w:a,h:l});this.paintInlineImageXObjectGroup(i,d)}applyTransferMapsToCanvas(t){return this.current.transferMaps!=="none"&&(t.filter=this.current.transferMaps,t.drawImage(t.canvas,0,0),t.filter="none"),t.canvas}applyTransferMapsToBitmap(t){if(this.current.transferMaps==="none")return t.bitmap;const{bitmap:r,width:n,height:o}=t,i=this.cachedCanvases.getCanvas("inlineImage",n,o),a=i.context;return a.filter=this.current.transferMaps,a.drawImage(r,0,0),a.filter="none",i.canvas}paintInlineImageXObject(t){if(!this.contentVisible)return;const r=t.width,n=t.height,o=this.ctx;if(this.save(),!ka){const{filter:l}=o;l!=="none"&&l!==""&&(o.filter="none")}o.scale(1/r,-1/n);let i;if(t.bitmap)i=this.applyTransferMapsToBitmap(t);else if(typeof HTMLElement=="function"&&t instanceof HTMLElement||!t.data)i=t;else{const d=this.cachedCanvases.getCanvas("inlineImage",r,n).context;eJ(d,t),i=this.applyTransferMapsToCanvas(d)}const a=this._scaleImage(i,fu(o));o.imageSmoothingEnabled=rJ(Io(o),t.interpolate),M9(o,a.img,0,0,a.paintWidth,a.paintHeight,0,-n,r,n),this.compose(),this.restore()}paintInlineImageXObjectGroup(t,r){if(!this.contentVisible)return;const n=this.ctx;let o;if(t.bitmap)o=t.bitmap;else{const i=t.width,a=t.height,d=this.cachedCanvases.getCanvas("inlineImage",i,a).context;eJ(d,t),o=this.applyTransferMapsToCanvas(d)}for(const i of r)n.save(),n.transform(...i.transform),n.scale(1,-1),M9(n,o,i.x,i.y,i.w,i.h,0,-1,1,1),n.restore();this.compose()}paintSolidColorImageMask(){this.contentVisible&&(this.ctx.fillRect(0,0,1,1),this.compose())}markPoint(t){}markPointProps(t,r){}beginMarkedContent(t){this.markedContentStack.push({visible:!0})}beginMarkedContentProps(t,r){t==="OC"?this.markedContentStack.push({visible:this.optionalContentConfig.isVisible(r)}):this.markedContentStack.push({visible:!0}),this.contentVisible=this.isContentVisible()}endMarkedContent(){this.markedContentStack.pop(),this.contentVisible=this.isContentVisible()}beginCompat(){}endCompat(){}consumePath(t){const r=this.current.isEmptyClip();this.pendingClip&&this.current.updateClipFromPath(),this.pendingClip||this.compose(t);const n=this.ctx;this.pendingClip&&(r||(this.pendingClip===nJ?n.clip("evenodd"):n.clip()),this.pendingClip=null),this.current.startNewPathAndClipBox(this.current.clipBox),n.beginPath()}getSinglePixelWidth(){if(!this._cachedGetSinglePixelWidth){const t=Io(this.ctx);if(t[1]===0&&t[2]===0)this._cachedGetSinglePixelWidth=1/Math.min(Math.abs(t[0]),Math.abs(t[3]));else{const r=Math.abs(t[0]*t[3]-t[2]*t[1]),n=Math.hypot(t[0],t[2]),o=Math.hypot(t[1],t[3]);this._cachedGetSinglePixelWidth=Math.max(n,o)/r}}return this._cachedGetSinglePixelWidth}getScaleForStroking(){if(this._cachedScaleForStroking[0]===-1){const{lineWidth:t}=this.current,{a:r,b:n,c:o,d:i}=this.ctx.getTransform();let a,l;if(n===0&&o===0){const d=Math.abs(r),u=Math.abs(i);if(d===u)if(t===0)a=l=1/d;else{const p=d*t;a=l=p<1?1/p:1}else if(t===0)a=1/d,l=1/u;else{const p=d*t,h=u*t;a=p<1?1/p:1,l=h<1?1/h:1}}else{const d=Math.abs(r*i-n*o),u=Math.hypot(r,n),p=Math.hypot(o,i);if(t===0)a=p/d,l=u/d;else{const h=t*d;a=p>h?p/h:1,l=u>h?u/h:1}}this._cachedScaleForStroking[0]=a,this._cachedScaleForStroking[1]=l}return this._cachedScaleForStroking}rescaleAndStroke(t){const{ctx:r}=this,{lineWidth:n}=this.current,[o,i]=this.getScaleForStroking();if(r.lineWidth=n||1,o===1&&i===1){r.stroke();return}const a=r.getLineDash();if(t&&r.save(),r.scale(o,i),a.length>0){const l=Math.max(o,i);r.setLineDash(a.map(d=>d/l)),r.lineDashOffset/=l}r.stroke(),t&&r.restore()}isContentVisible(){for(let t=this.markedContentStack.length-1;t>=0;t--)if(!this.markedContentStack[t].visible)return!1;return!0}}for(const e in $c)Ef.prototype[e]!==void 0&&(Ef.prototype[$c[e]]=Ef.prototype[e]);class E7{static#e=null;static#t="";static get workerPort(){return this.#e}static set workerPort(t){if(!(typeof Worker<"u"&&t instanceof Worker)&&t!==null)throw new Error("Invalid `workerPort` type.");this.#e=t}static get workerSrc(){return this.#t}static set workerSrc(t){if(typeof t!="string")throw new Error("Invalid `workerSrc` type.");this.#t=t}}const I9={DATA:1,ERROR:2},ai={CANCEL:1,CANCEL_COMPLETE:2,CLOSE:3,ENQUEUE:4,ERROR:5,PULL:6,PULL_COMPLETE:7,START_COMPLETE:8};function Is(e){switch(e instanceof Error||typeof e=="object"&&e!==null||Xn('wrapReason: Expected "reason" to be a (possibly cloned) Error.'),e.name){case"AbortException":return new Lm(e.message);case"MissingPDFException":return new Am(e.message);case"PasswordException":return new aj(e.message,e.code);case"UnexpectedResponseException":return new $x(e.message,e.status);case"UnknownErrorException":return new sj(e.message,e.details);default:return new sj(e.message,e.toString())}}class I5{constructor(t,r,n){this.sourceName=t,this.targetName=r,this.comObj=n,this.callbackId=1,this.streamId=1,this.streamSinks=Object.create(null),this.streamControllers=Object.create(null),this.callbackCapabilities=Object.create(null),this.actionHandler=Object.create(null),this._onComObjOnMessage=o=>{const i=o.data;if(i.targetName!==this.sourceName)return;if(i.stream){this.#t(i);return}if(i.callback){const l=i.callbackId,d=this.callbackCapabilities[l];if(!d)throw new Error(`Cannot resolve callback ${l}`);if(delete this.callbackCapabilities[l],i.callback===I9.DATA)d.resolve(i.data);else if(i.callback===I9.ERROR)d.reject(Is(i.reason));else throw new Error("Unexpected callback case");return}const a=this.actionHandler[i.action];if(!a)throw new Error(`Unknown action from worker: ${i.action}`);if(i.callbackId){const l=this.sourceName,d=i.sourceName;new Promise(function(u){u(a(i.data))}).then(function(u){n.postMessage({sourceName:l,targetName:d,callback:I9.DATA,callbackId:i.callbackId,data:u})},function(u){n.postMessage({sourceName:l,targetName:d,callback:I9.ERROR,callbackId:i.callbackId,reason:Is(u)})});return}if(i.streamId){this.#e(i);return}a(i.data)},n.addEventListener("message",this._onComObjOnMessage)}on(t,r){const n=this.actionHandler;if(n[t])throw new Error(`There is already an actionName called "${t}"`);n[t]=r}send(t,r,n){this.comObj.postMessage({sourceName:this.sourceName,targetName:this.targetName,action:t,data:r},n)}sendWithPromise(t,r,n){const o=this.callbackId++,i=Promise.withResolvers();this.callbackCapabilities[o]=i;try{this.comObj.postMessage({sourceName:this.sourceName,targetName:this.targetName,action:t,callbackId:o,data:r},n)}catch(a){i.reject(a)}return i.promise}sendWithStream(t,r,n,o){const i=this.streamId++,a=this.sourceName,l=this.targetName,d=this.comObj;return new ReadableStream({start:u=>{const p=Promise.withResolvers();return this.streamControllers[i]={controller:u,startCall:p,pullCall:null,cancelCall:null,isClosed:!1},d.postMessage({sourceName:a,targetName:l,action:t,streamId:i,data:r,desiredSize:u.desiredSize},o),p.promise},pull:u=>{const p=Promise.withResolvers();return this.streamControllers[i].pullCall=p,d.postMessage({sourceName:a,targetName:l,stream:ai.PULL,streamId:i,desiredSize:u.desiredSize}),p.promise},cancel:u=>{Ai(u instanceof Error,"cancel must have a valid reason");const p=Promise.withResolvers();return this.streamControllers[i].cancelCall=p,this.streamControllers[i].isClosed=!0,d.postMessage({sourceName:a,targetName:l,stream:ai.CANCEL,streamId:i,reason:Is(u)}),p.promise}},n)}#e(t){const r=t.streamId,n=this.sourceName,o=t.sourceName,i=this.comObj,a=this,l=this.actionHandler[t.action],d={enqueue(u,p=1,h){if(this.isCancelled)return;const f=this.desiredSize;this.desiredSize-=p,f>0&&this.desiredSize<=0&&(this.sinkCapability=Promise.withResolvers(),this.ready=this.sinkCapability.promise),i.postMessage({sourceName:n,targetName:o,stream:ai.ENQUEUE,streamId:r,chunk:u},h)},close(){this.isCancelled||(this.isCancelled=!0,i.postMessage({sourceName:n,targetName:o,stream:ai.CLOSE,streamId:r}),delete a.streamSinks[r])},error(u){Ai(u instanceof Error,"error must have a valid reason"),!this.isCancelled&&(this.isCancelled=!0,i.postMessage({sourceName:n,targetName:o,stream:ai.ERROR,streamId:r,reason:Is(u)}))},sinkCapability:Promise.withResolvers(),onPull:null,onCancel:null,isCancelled:!1,desiredSize:t.desiredSize,ready:null};d.sinkCapability.resolve(),d.ready=d.sinkCapability.promise,this.streamSinks[r]=d,new Promise(function(u){u(l(t.data,d))}).then(function(){i.postMessage({sourceName:n,targetName:o,stream:ai.START_COMPLETE,streamId:r,success:!0})},function(u){i.postMessage({sourceName:n,targetName:o,stream:ai.START_COMPLETE,streamId:r,reason:Is(u)})})}#t(t){const r=t.streamId,n=this.sourceName,o=t.sourceName,i=this.comObj,a=this.streamControllers[r],l=this.streamSinks[r];switch(t.stream){case ai.START_COMPLETE:t.success?a.startCall.resolve():a.startCall.reject(Is(t.reason));break;case ai.PULL_COMPLETE:t.success?a.pullCall.resolve():a.pullCall.reject(Is(t.reason));break;case ai.PULL:if(!l){i.postMessage({sourceName:n,targetName:o,stream:ai.PULL_COMPLETE,streamId:r,success:!0});break}l.desiredSize<=0&&t.desiredSize>0&&l.sinkCapability.resolve(),l.desiredSize=t.desiredSize,new Promise(function(d){d(l.onPull?.())}).then(function(){i.postMessage({sourceName:n,targetName:o,stream:ai.PULL_COMPLETE,streamId:r,success:!0})},function(d){i.postMessage({sourceName:n,targetName:o,stream:ai.PULL_COMPLETE,streamId:r,reason:Is(d)})});break;case ai.ENQUEUE:if(Ai(a,"enqueue should have stream controller"),a.isClosed)break;a.controller.enqueue(t.chunk);break;case ai.CLOSE:if(Ai(a,"close should have stream controller"),a.isClosed)break;a.isClosed=!0,a.controller.close(),this.#r(a,r);break;case ai.ERROR:Ai(a,"error should have stream controller"),a.controller.error(Is(t.reason)),this.#r(a,r);break;case ai.CANCEL_COMPLETE:t.success?a.cancelCall.resolve():a.cancelCall.reject(Is(t.reason)),this.#r(a,r);break;case ai.CANCEL:if(!l)break;new Promise(function(d){d(l.onCancel?.(Is(t.reason)))}).then(function(){i.postMessage({sourceName:n,targetName:o,stream:ai.CANCEL_COMPLETE,streamId:r,success:!0})},function(d){i.postMessage({sourceName:n,targetName:o,stream:ai.CANCEL_COMPLETE,streamId:r,reason:Is(d)})}),l.sinkCapability.reject(Is(t.reason)),l.isCancelled=!0,delete this.streamSinks[r];break;default:throw new Error("Unexpected stream case")}}async#r(t,r){await Promise.allSettled([t.startCall?.promise,t.pullCall?.promise,t.cancelCall?.promise]),delete this.streamControllers[r]}destroy(){this.comObj.removeEventListener("message",this._onComObjOnMessage)}}class h0t{#e;#t;constructor({parsedData:t,rawData:r}){this.#e=t,this.#t=r}getRaw(){return this.#t}get(t){return this.#e.get(t)??null}getAll(){return UO(this.#e)}has(t){return this.#e.has(t)}}const U2=Symbol("INTERNAL");class m0t{#e=!1;#t=!1;#r=!1;#o=!0;constructor(t,{name:r,intent:n,usage:o}){this.#e=!!(t&$l.DISPLAY),this.#t=!!(t&$l.PRINT),this.name=r,this.intent=n,this.usage=o}get visible(){if(this.#r)return this.#o;if(!this.#o)return!1;const{print:t,view:r}=this.usage;return this.#e?r?.viewState!=="OFF":this.#t?t?.printState!=="OFF":!0}_setVisible(t,r,n=!1){t!==U2&&Xn("Internal method `_setVisible` called."),this.#r=n,this.#o=r}}class f0t{#e=null;#t=new Map;#r=null;#o=null;constructor(t,r=$l.DISPLAY){if(this.renderingIntent=r,this.name=null,this.creator=null,t!==null){this.name=t.name,this.creator=t.creator,this.#o=t.order;for(const n of t.groups)this.#t.set(n.id,new m0t(r,n));if(t.baseState==="OFF")for(const n of this.#t.values())n._setVisible(U2,!1);for(const n of t.on)this.#t.get(n)._setVisible(U2,!0);for(const n of t.off)this.#t.get(n)._setVisible(U2,!1);this.#r=this.getHash()}}#s(t){const r=t.length;if(r<2)return!0;const n=t[0];for(let o=1;o<r;o++){const i=t[o];let a;if(Array.isArray(i))a=this.#s(i);else if(this.#t.has(i))a=this.#t.get(i).visible;else return Jr(`Optional content group not found: ${i}`),!0;switch(n){case"And":if(!a)return!1;break;case"Or":if(a)return!0;break;case"Not":return!a;default:return!0}}return n==="And"}isVisible(t){if(this.#t.size===0)return!0;if(!t)return Cx("Optional content group not defined."),!0;if(t.type==="OCG")return this.#t.has(t.id)?this.#t.get(t.id).visible:(Jr(`Optional content group not found: ${t.id}`),!0);if(t.type==="OCMD"){if(t.expression)return this.#s(t.expression);if(!t.policy||t.policy==="AnyOn"){for(const r of t.ids){if(!this.#t.has(r))return Jr(`Optional content group not found: ${r}`),!0;if(this.#t.get(r).visible)return!0}return!1}else if(t.policy==="AllOn"){for(const r of t.ids){if(!this.#t.has(r))return Jr(`Optional content group not found: ${r}`),!0;if(!this.#t.get(r).visible)return!1}return!0}else if(t.policy==="AnyOff"){for(const r of t.ids){if(!this.#t.has(r))return Jr(`Optional content group not found: ${r}`),!0;if(!this.#t.get(r).visible)return!0}return!1}else if(t.policy==="AllOff"){for(const r of t.ids){if(!this.#t.has(r))return Jr(`Optional content group not found: ${r}`),!0;if(this.#t.get(r).visible)return!1}return!0}return Jr(`Unknown optional content policy ${t.policy}.`),!0}return Jr(`Unknown group type ${t.type}.`),!0}setVisibility(t,r=!0){const n=this.#t.get(t);if(!n){Jr(`Optional content group not found: ${t}`);return}n._setVisible(U2,!!r,!0),this.#e=null}setOCGState({state:t,preserveRB:r}){let n;for(const o of t){switch(o){case"ON":case"OFF":case"Toggle":n=o;continue}const i=this.#t.get(o);if(i)switch(n){case"ON":i._setVisible(U2,!0);break;case"OFF":i._setVisible(U2,!1);break;case"Toggle":i._setVisible(U2,!i.visible);break}}this.#e=null}get hasInitialVisibility(){return this.#r===null||this.getHash()===this.#r}getOrder(){return this.#t.size?this.#o?this.#o.slice():[...this.#t.keys()]:null}getGroups(){return this.#t.size>0?UO(this.#t):null}getGroup(t){return this.#t.get(t)||null}getHash(){if(this.#e!==null)return this.#e;const t=new Xge;for(const[r,n]of this.#t)t.update(`${r}:${n.visible}`);return this.#e=t.hexdigest()}}class g0t{constructor(t,{disableRange:r=!1,disableStream:n=!1}){Ai(t,'PDFDataTransportStream - missing required "pdfDataRangeTransport" argument.');const{length:o,initialData:i,progressiveDone:a,contentDispositionFilename:l}=t;if(this._queuedChunks=[],this._progressiveDone=a,this._contentDispositionFilename=l,i?.length>0){const d=i instanceof Uint8Array&&i.byteLength===i.buffer.byteLength?i.buffer:new Uint8Array(i).buffer;this._queuedChunks.push(d)}this._pdfDataRangeTransport=t,this._isStreamingSupported=!n,this._isRangeSupported=!r,this._contentLength=o,this._fullRequestReader=null,this._rangeReaders=[],t.addRangeListener((d,u)=>{this._onReceiveData({begin:d,chunk:u})}),t.addProgressListener((d,u)=>{this._onProgress({loaded:d,total:u})}),t.addProgressiveReadListener(d=>{this._onReceiveData({chunk:d})}),t.addProgressiveDoneListener(()=>{this._onProgressiveDone()}),t.transportReady()}_onReceiveData({begin:t,chunk:r}){const n=r instanceof Uint8Array&&r.byteLength===r.buffer.byteLength?r.buffer:new Uint8Array(r).buffer;if(t===void 0)this._fullRequestReader?this._fullRequestReader._enqueue(n):this._queuedChunks.push(n);else{const o=this._rangeReaders.some(function(i){return i._begin!==t?!1:(i._enqueue(n),!0)});Ai(o,"_onReceiveData - no `PDFDataTransportStreamRangeReader` instance found.")}}get _progressiveDataLength(){return this._fullRequestReader?._loaded??0}_onProgress(t){t.total===void 0?this._rangeReaders[0]?.onProgress?.({loaded:t.loaded}):this._fullRequestReader?.onProgress?.({loaded:t.loaded,total:t.total})}_onProgressiveDone(){this._fullRequestReader?.progressiveDone(),this._progressiveDone=!0}_removeRangeReader(t){const r=this._rangeReaders.indexOf(t);r>=0&&this._rangeReaders.splice(r,1)}getFullReader(){Ai(!this._fullRequestReader,"PDFDataTransportStream.getFullReader can only be called once.");const t=this._queuedChunks;return this._queuedChunks=null,new y0t(this,t,this._progressiveDone,this._contentDispositionFilename)}getRangeReader(t,r){if(r<=this._progressiveDataLength)return null;const n=new v0t(this,t,r);return this._pdfDataRangeTransport.requestDataRange(t,r),this._rangeReaders.push(n),n}cancelAllRequests(t){this._fullRequestReader?.cancel(t);for(const r of this._rangeReaders.slice(0))r.cancel(t);this._pdfDataRangeTransport.abort()}}class y0t{constructor(t,r,n=!1,o=null){this._stream=t,this._done=n||!1,this._filename=ZO(o)?o:null,this._queuedChunks=r||[],this._loaded=0;for(const i of this._queuedChunks)this._loaded+=i.byteLength;this._requests=[],this._headersReady=Promise.resolve(),t._fullRequestReader=this,this.onProgress=null}_enqueue(t){this._done||(this._requests.length>0?this._requests.shift().resolve({value:t,done:!1}):this._queuedChunks.push(t),this._loaded+=t.byteLength)}get headersReady(){return this._headersReady}get filename(){return this._filename}get isRangeSupported(){return this._stream._isRangeSupported}get isStreamingSupported(){return this._stream._isStreamingSupported}get contentLength(){return this._stream._contentLength}async read(){if(this._queuedChunks.length>0)return{value:this._queuedChunks.shift(),done:!1};if(this._done)return{value:void 0,done:!0};const t=Promise.withResolvers();return this._requests.push(t),t.promise}cancel(t){this._done=!0;for(const r of this._requests)r.resolve({value:void 0,done:!0});this._requests.length=0}progressiveDone(){this._done||(this._done=!0)}}class v0t{constructor(t,r,n){this._stream=t,this._begin=r,this._end=n,this._queuedChunk=null,this._requests=[],this._done=!1,this.onProgress=null}_enqueue(t){if(!this._done){if(this._requests.length===0)this._queuedChunk=t;else{this._requests.shift().resolve({value:t,done:!1});for(const n of this._requests)n.resolve({value:void 0,done:!0});this._requests.length=0}this._done=!0,this._stream._removeRangeReader(this)}}get isStreamingSupported(){return!1}async read(){if(this._queuedChunk){const r=this._queuedChunk;return this._queuedChunk=null,{value:r,done:!1}}if(this._done)return{value:void 0,done:!0};const t=Promise.withResolvers();return this._requests.push(t),t.promise}cancel(t){this._done=!0;for(const r of this._requests)r.resolve({value:void 0,done:!0});this._requests.length=0,this._stream._removeRangeReader(this)}}function b0t(e){let t=!0,r=n("filename\\*","i").exec(e);if(r){r=r[1];let p=l(r);return p=unescape(p),p=d(p),p=u(p),i(p)}if(r=a(e),r){const p=u(r);return i(p)}if(r=n("filename","i").exec(e),r){r=r[1];let p=l(r);return p=u(p),i(p)}function n(p,h){return new RegExp("(?:^|;)\\s*"+p+'\\s*=\\s*([^";\\s][^;\\s]*|"(?:[^"\\\\]|\\\\"?)+"?)',h)}function o(p,h){if(p){if(!/^[\x00-\xFF]+$/.test(h))return h;try{const f=new TextDecoder(p,{fatal:!0}),g=Sx(h);h=f.decode(g),t=!1}catch{}}return h}function i(p){return t&&/[\x80-\xff]/.test(p)&&(p=o("utf-8",p),t&&(p=o("iso-8859-1",p))),p}function a(p){const h=[];let f;const g=n("filename\\*((?!0\\d)\\d+)(\\*?)","ig");for(;(f=g.exec(p))!==null;){let[,v,w,x]=f;if(v=parseInt(v,10),v in h){if(v===0)break;continue}h[v]=[w,x]}const y=[];for(let v=0;v<h.length&&v in h;++v){let[w,x]=h[v];x=l(x),w&&(x=unescape(x),v===0&&(x=d(x))),y.push(x)}return y.join("")}function l(p){if(p.startsWith('"')){const h=p.slice(1).split('\\"');for(let f=0;f<h.length;++f){const g=h[f].indexOf('"');g!==-1&&(h[f]=h[f].slice(0,g),h.length=f+1),h[f]=h[f].replaceAll(/\\(.)/g,"$1")}p=h.join('"')}return p}function d(p){const h=p.indexOf("'");if(h===-1)return p;const f=p.slice(0,h),y=p.slice(h+1).replace(/^[^']*'/,"");return o(f,y)}function u(p){return!p.startsWith("=?")||/[\x00-\x19\x80-\xff]/.test(p)?p:p.replaceAll(/=\?([\w-]*)\?([QqBb])\?((?:[^?]|\?(?!=))*)\?=/g,function(h,f,g,y){if(g==="q"||g==="Q")return y=y.replaceAll("_"," "),y=y.replaceAll(/=([0-9a-fA-F]{2})/g,function(v,w){return String.fromCharCode(parseInt(w,16))}),o(f,y);try{y=atob(y)}catch{}return o(f,y)})}return""}function rN({getResponseHeader:e,isHttp:t,rangeChunkSize:r,disableRange:n}){const o={allowRangeRequests:!1,suggestedLength:void 0},i=parseInt(e("Content-Length"),10);return!Number.isInteger(i)||(o.suggestedLength=i,i<=2*r)||n||!t||e("Accept-Ranges")!=="bytes"||(e("Content-Encoding")||"identity")!=="identity"||(o.allowRangeRequests=!0),o}function nN(e){const t=e("Content-Disposition");if(t){let r=b0t(t);if(r.includes("%"))try{r=decodeURIComponent(r)}catch{}if(ZO(r))return r}return null}function Lx(e,t){return e===404||e===0&&t.startsWith("file:")?new Am('Missing PDF "'+t+'".'):new $x(`Unexpected server response (${e}) while retrieving PDF "${t}".`,e)}function e4e(e){return e===200||e===206}function t4e(e,t,r){return{method:"GET",headers:e,signal:r.signal,mode:"cors",credentials:t?"include":"same-origin",redirect:"follow"}}function r4e(e){const t=new Headers;for(const r in e){const n=e[r];n!==void 0&&t.append(r,n)}return t}function n4e(e){return e instanceof Uint8Array?e.buffer:e instanceof ArrayBuffer?e:(Jr(`getArrayBuffer - unexpected data format: ${e}`),new Uint8Array(e).buffer)}class oJ{constructor(t){this.source=t,this.isHttp=/^https?:/i.test(t.url),this.httpHeaders=this.isHttp&&t.httpHeaders||{},this._fullRequestReader=null,this._rangeRequestReaders=[]}get _progressiveDataLength(){return this._fullRequestReader?._loaded??0}getFullReader(){return Ai(!this._fullRequestReader,"PDFFetchStream.getFullReader can only be called once."),this._fullRequestReader=new w0t(this),this._fullRequestReader}getRangeReader(t,r){if(r<=this._progressiveDataLength)return null;const n=new x0t(this,t,r);return this._rangeRequestReaders.push(n),n}cancelAllRequests(t){this._fullRequestReader?.cancel(t);for(const r of this._rangeRequestReaders.slice(0))r.cancel(t)}}class w0t{constructor(t){this._stream=t,this._reader=null,this._loaded=0,this._filename=null;const r=t.source;this._withCredentials=r.withCredentials||!1,this._contentLength=r.length,this._headersCapability=Promise.withResolvers(),this._disableRange=r.disableRange||!1,this._rangeChunkSize=r.rangeChunkSize,!this._rangeChunkSize&&!this._disableRange&&(this._disableRange=!0),this._abortController=new AbortController,this._isStreamingSupported=!r.disableStream,this._isRangeSupported=!r.disableRange,this._headers=r4e(this._stream.httpHeaders);const n=r.url;fetch(n,t4e(this._headers,this._withCredentials,this._abortController)).then(o=>{if(!e4e(o.status))throw Lx(o.status,n);this._reader=o.body.getReader(),this._headersCapability.resolve();const i=d=>o.headers.get(d),{allowRangeRequests:a,suggestedLength:l}=rN({getResponseHeader:i,isHttp:this._stream.isHttp,rangeChunkSize:this._rangeChunkSize,disableRange:this._disableRange});this._isRangeSupported=a,this._contentLength=l||this._contentLength,this._filename=nN(i),!this._isStreamingSupported&&this._isRangeSupported&&this.cancel(new Lm("Streaming is disabled."))}).catch(this._headersCapability.reject),this.onProgress=null}get headersReady(){return this._headersCapability.promise}get filename(){return this._filename}get contentLength(){return this._contentLength}get isRangeSupported(){return this._isRangeSupported}get isStreamingSupported(){return this._isStreamingSupported}async read(){await this._headersCapability.promise;const{value:t,done:r}=await this._reader.read();return r?{value:t,done:r}:(this._loaded+=t.byteLength,this.onProgress?.({loaded:this._loaded,total:this._contentLength}),{value:n4e(t),done:!1})}cancel(t){this._reader?.cancel(t),this._abortController.abort()}}class x0t{constructor(t,r,n){this._stream=t,this._reader=null,this._loaded=0;const o=t.source;this._withCredentials=o.withCredentials||!1,this._readCapability=Promise.withResolvers(),this._isStreamingSupported=!o.disableStream,this._abortController=new AbortController,this._headers=r4e(this._stream.httpHeaders),this._headers.append("Range",`bytes=${r}-${n-1}`);const i=o.url;fetch(i,t4e(this._headers,this._withCredentials,this._abortController)).then(a=>{if(!e4e(a.status))throw Lx(a.status,i);this._readCapability.resolve(),this._reader=a.body.getReader()}).catch(this._readCapability.reject),this.onProgress=null}get isStreamingSupported(){return this._isStreamingSupported}async read(){await this._readCapability.promise;const{value:t,done:r}=await this._reader.read();return r?{value:t,done:r}:(this._loaded+=t.byteLength,this.onProgress?.({loaded:this._loaded}),{value:n4e(t),done:!1})}cancel(t){this._reader?.cancel(t),this._abortController.abort()}}const cL=200,dL=206;function C0t(e){const t=e.response;return typeof t!="string"?t:Sx(t).buffer}class $0t{constructor(t,r={}){this.url=t,this.isHttp=/^https?:/i.test(t),this.httpHeaders=this.isHttp&&r.httpHeaders||Object.create(null),this.withCredentials=r.withCredentials||!1,this.currXhrId=0,this.pendingRequests=Object.create(null)}requestRange(t,r,n){const o={begin:t,end:r};for(const i in n)o[i]=n[i];return this.request(o)}requestFull(t){return this.request(t)}request(t){const r=new XMLHttpRequest,n=this.currXhrId++,o=this.pendingRequests[n]={xhr:r};r.open("GET",this.url),r.withCredentials=this.withCredentials;for(const i in this.httpHeaders){const a=this.httpHeaders[i];a!==void 0&&r.setRequestHeader(i,a)}return this.isHttp&&"begin"in t&&"end"in t?(r.setRequestHeader("Range",`bytes=${t.begin}-${t.end-1}`),o.expectedStatus=dL):o.expectedStatus=cL,r.responseType="arraybuffer",t.onError&&(r.onerror=function(i){t.onError(r.status)}),r.onreadystatechange=this.onStateChange.bind(this,n),r.onprogress=this.onProgress.bind(this,n),o.onHeadersReceived=t.onHeadersReceived,o.onDone=t.onDone,o.onError=t.onError,o.onProgress=t.onProgress,r.send(null),n}onProgress(t,r){const n=this.pendingRequests[t];n&&n.onProgress?.(r)}onStateChange(t,r){const n=this.pendingRequests[t];if(!n)return;const o=n.xhr;if(o.readyState>=2&&n.onHeadersReceived&&(n.onHeadersReceived(),delete n.onHeadersReceived),o.readyState!==4||!(t in this.pendingRequests))return;if(delete this.pendingRequests[t],o.status===0&&this.isHttp){n.onError?.(o.status);return}const i=o.status||cL;if(!(i===cL&&n.expectedStatus===dL)&&i!==n.expectedStatus){n.onError?.(o.status);return}const l=C0t(o);if(i===dL){const d=o.getResponseHeader("Content-Range"),u=/bytes (\d+)-(\d+)\/(\d+)/.exec(d);n.onDone({begin:parseInt(u[1],10),chunk:l})}else l?n.onDone({begin:0,chunk:l}):n.onError?.(o.status)}getRequestXhr(t){return this.pendingRequests[t].xhr}isPendingRequest(t){return t in this.pendingRequests}abortRequest(t){const r=this.pendingRequests[t].xhr;delete this.pendingRequests[t],r.abort()}}class S0t{constructor(t){this._source=t,this._manager=new $0t(t.url,{httpHeaders:t.httpHeaders,withCredentials:t.withCredentials}),this._rangeChunkSize=t.rangeChunkSize,this._fullRequestReader=null,this._rangeRequestReaders=[]}_onRangeRequestReaderClosed(t){const r=this._rangeRequestReaders.indexOf(t);r>=0&&this._rangeRequestReaders.splice(r,1)}getFullReader(){return Ai(!this._fullRequestReader,"PDFNetworkStream.getFullReader can only be called once."),this._fullRequestReader=new k0t(this._manager,this._source),this._fullRequestReader}getRangeReader(t,r){const n=new E0t(this._manager,t,r);return n.onClosed=this._onRangeRequestReaderClosed.bind(this),this._rangeRequestReaders.push(n),n}cancelAllRequests(t){this._fullRequestReader?.cancel(t);for(const r of this._rangeRequestReaders.slice(0))r.cancel(t)}}class k0t{constructor(t,r){this._manager=t;const n={onHeadersReceived:this._onHeadersReceived.bind(this),onDone:this._onDone.bind(this),onError:this._onError.bind(this),onProgress:this._onProgress.bind(this)};this._url=r.url,this._fullRequestId=t.requestFull(n),this._headersReceivedCapability=Promise.withResolvers(),this._disableRange=r.disableRange||!1,this._contentLength=r.length,this._rangeChunkSize=r.rangeChunkSize,!this._rangeChunkSize&&!this._disableRange&&(this._disableRange=!0),this._isStreamingSupported=!1,this._isRangeSupported=!1,this._cachedChunks=[],this._requests=[],this._done=!1,this._storedError=void 0,this._filename=null,this.onProgress=null}_onHeadersReceived(){const t=this._fullRequestId,r=this._manager.getRequestXhr(t),n=a=>r.getResponseHeader(a),{allowRangeRequests:o,suggestedLength:i}=rN({getResponseHeader:n,isHttp:this._manager.isHttp,rangeChunkSize:this._rangeChunkSize,disableRange:this._disableRange});o&&(this._isRangeSupported=!0),this._contentLength=i||this._contentLength,this._filename=nN(n),this._isRangeSupported&&this._manager.abortRequest(t),this._headersReceivedCapability.resolve()}_onDone(t){if(t&&(this._requests.length>0?this._requests.shift().resolve({value:t.chunk,done:!1}):this._cachedChunks.push(t.chunk)),this._done=!0,!(this._cachedChunks.length>0)){for(const r of this._requests)r.resolve({value:void 0,done:!0});this._requests.length=0}}_onError(t){this._storedError=Lx(t,this._url),this._headersReceivedCapability.reject(this._storedError);for(const r of this._requests)r.reject(this._storedError);this._requests.length=0,this._cachedChunks.length=0}_onProgress(t){this.onProgress?.({loaded:t.loaded,total:t.lengthComputable?t.total:this._contentLength})}get filename(){return this._filename}get isRangeSupported(){return this._isRangeSupported}get isStreamingSupported(){return this._isStreamingSupported}get contentLength(){return this._contentLength}get headersReady(){return this._headersReceivedCapability.promise}async read(){if(this._storedError)throw this._storedError;if(this._cachedChunks.length>0)return{value:this._cachedChunks.shift(),done:!1};if(this._done)return{value:void 0,done:!0};const t=Promise.withResolvers();return this._requests.push(t),t.promise}cancel(t){this._done=!0,this._headersReceivedCapability.reject(t);for(const r of this._requests)r.resolve({value:void 0,done:!0});this._requests.length=0,this._manager.isPendingRequest(this._fullRequestId)&&this._manager.abortRequest(this._fullRequestId),this._fullRequestReader=null}}class E0t{constructor(t,r,n){this._manager=t;const o={onDone:this._onDone.bind(this),onError:this._onError.bind(this),onProgress:this._onProgress.bind(this)};this._url=t.url,this._requestId=t.requestRange(r,n,o),this._requests=[],this._queuedChunk=null,this._done=!1,this._storedError=void 0,this.onProgress=null,this.onClosed=null}_close(){this.onClosed?.(this)}_onDone(t){const r=t.chunk;this._requests.length>0?this._requests.shift().resolve({value:r,done:!1}):this._queuedChunk=r,this._done=!0;for(const n of this._requests)n.resolve({value:void 0,done:!0});this._requests.length=0,this._close()}_onError(t){this._storedError=Lx(t,this._url);for(const r of this._requests)r.reject(this._storedError);this._requests.length=0,this._queuedChunk=null}_onProgress(t){this.isStreamingSupported||this.onProgress?.({loaded:t.loaded})}get isStreamingSupported(){return!1}async read(){if(this._storedError)throw this._storedError;if(this._queuedChunk!==null){const r=this._queuedChunk;return this._queuedChunk=null,{value:r,done:!1}}if(this._done)return{value:void 0,done:!0};const t=Promise.withResolvers();return this._requests.push(t),t.promise}cancel(t){this._done=!0;for(const r of this._requests)r.resolve({value:void 0,done:!0});this._requests.length=0,this._manager.isPendingRequest(this._requestId)&&this._manager.abortRequest(this._requestId),this._close()}}const o4e=/^file:\/\/\/[a-zA-Z]:\//;function _0t(e){const t=F1.get("url"),r=t.parse(e);return r.protocol==="file:"||r.host?r:/^[a-z]:[/\\]/i.test(e)?t.parse(`file:///${e}`):(r.host||(r.protocol="file:"),r)}class T0t{constructor(t){this.source=t,this.url=_0t(t.url),this.isHttp=this.url.protocol==="http:"||this.url.protocol==="https:",this.isFsUrl=this.url.protocol==="file:",this.httpHeaders=this.isHttp&&t.httpHeaders||{},this._fullRequestReader=null,this._rangeRequestReaders=[]}get _progressiveDataLength(){return this._fullRequestReader?._loaded??0}getFullReader(){return Ai(!this._fullRequestReader,"PDFNodeStream.getFullReader can only be called once."),this._fullRequestReader=this.isFsUrl?new D0t(this):new A0t(this),this._fullRequestReader}getRangeReader(t,r){if(r<=this._progressiveDataLength)return null;const n=this.isFsUrl?new M0t(this,t,r):new L0t(this,t,r);return this._rangeRequestReaders.push(n),n}cancelAllRequests(t){this._fullRequestReader?.cancel(t);for(const r of this._rangeRequestReaders.slice(0))r.cancel(t)}}class i4e{constructor(t){this._url=t.url,this._done=!1,this._storedError=null,this.onProgress=null;const r=t.source;this._contentLength=r.length,this._loaded=0,this._filename=null,this._disableRange=r.disableRange||!1,this._rangeChunkSize=r.rangeChunkSize,!this._rangeChunkSize&&!this._disableRange&&(this._disableRange=!0),this._isStreamingSupported=!r.disableStream,this._isRangeSupported=!r.disableRange,this._readableStream=null,this._readCapability=Promise.withResolvers(),this._headersCapability=Promise.withResolvers()}get headersReady(){return this._headersCapability.promise}get filename(){return this._filename}get contentLength(){return this._contentLength}get isRangeSupported(){return this._isRangeSupported}get isStreamingSupported(){return this._isStreamingSupported}async read(){if(await this._readCapability.promise,this._done)return{value:void 0,done:!0};if(this._storedError)throw this._storedError;const t=this._readableStream.read();return t===null?(this._readCapability=Promise.withResolvers(),this.read()):(this._loaded+=t.length,this.onProgress?.({loaded:this._loaded,total:this._contentLength}),{value:new Uint8Array(t).buffer,done:!1})}cancel(t){if(!this._readableStream){this._error(t);return}this._readableStream.destroy(t)}_error(t){this._storedError=t,this._readCapability.resolve()}_setReadableStream(t){this._readableStream=t,t.on("readable",()=>{this._readCapability.resolve()}),t.on("end",()=>{t.destroy(),this._done=!0,this._readCapability.resolve()}),t.on("error",r=>{this._error(r)}),!this._isStreamingSupported&&this._isRangeSupported&&this._error(new Lm("streaming is disabled")),this._storedError&&this._readableStream.destroy(this._storedError)}}class a4e{constructor(t){this._url=t.url,this._done=!1,this._storedError=null,this.onProgress=null,this._loaded=0,this._readableStream=null,this._readCapability=Promise.withResolvers();const r=t.source;this._isStreamingSupported=!r.disableStream}get isStreamingSupported(){return this._isStreamingSupported}async read(){if(await this._readCapability.promise,this._done)return{value:void 0,done:!0};if(this._storedError)throw this._storedError;const t=this._readableStream.read();return t===null?(this._readCapability=Promise.withResolvers(),this.read()):(this._loaded+=t.length,this.onProgress?.({loaded:this._loaded}),{value:new Uint8Array(t).buffer,done:!1})}cancel(t){if(!this._readableStream){this._error(t);return}this._readableStream.destroy(t)}_error(t){this._storedError=t,this._readCapability.resolve()}_setReadableStream(t){this._readableStream=t,t.on("readable",()=>{this._readCapability.resolve()}),t.on("end",()=>{t.destroy(),this._done=!0,this._readCapability.resolve()}),t.on("error",r=>{this._error(r)}),this._storedError&&this._readableStream.destroy(this._storedError)}}function ib(e,t){return{protocol:e.protocol,auth:e.auth,host:e.hostname,port:e.port,path:e.path,method:"GET",headers:t}}class A0t extends i4e{constructor(t){super(t);const r=n=>{if(n.statusCode===404){const l=new Am(`Missing PDF "${this._url}".`);this._storedError=l,this._headersCapability.reject(l);return}this._headersCapability.resolve(),this._setReadableStream(n);const o=l=>this._readableStream.headers[l.toLowerCase()],{allowRangeRequests:i,suggestedLength:a}=rN({getResponseHeader:o,isHttp:t.isHttp,rangeChunkSize:this._rangeChunkSize,disableRange:this._disableRange});this._isRangeSupported=i,this._contentLength=a||this._contentLength,this._filename=nN(o)};if(this._request=null,this._url.protocol==="http:"){const n=F1.get("http");this._request=n.request(ib(this._url,t.httpHeaders),r)}else{const n=F1.get("https");this._request=n.request(ib(this._url,t.httpHeaders),r)}this._request.on("error",n=>{this._storedError=n,this._headersCapability.reject(n)}),this._request.end()}}class L0t extends a4e{constructor(t,r,n){super(t),this._httpHeaders={};for(const i in t.httpHeaders){const a=t.httpHeaders[i];a!==void 0&&(this._httpHeaders[i]=a)}this._httpHeaders.Range=`bytes=${r}-${n-1}`;const o=i=>{if(i.statusCode===404){const a=new Am(`Missing PDF "${this._url}".`);this._storedError=a;return}this._setReadableStream(i)};if(this._request=null,this._url.protocol==="http:"){const i=F1.get("http");this._request=i.request(ib(this._url,this._httpHeaders),o)}else{const i=F1.get("https");this._request=i.request(ib(this._url,this._httpHeaders),o)}this._request.on("error",i=>{this._storedError=i}),this._request.end()}}class D0t extends i4e{constructor(t){super(t);let r=decodeURIComponent(this._url.path);o4e.test(this._url.href)&&(r=r.replace(/^\//,""));const n=F1.get("fs");n.promises.lstat(r).then(o=>{this._contentLength=o.size,this._setReadableStream(n.createReadStream(r)),this._headersCapability.resolve()},o=>{o.code==="ENOENT"&&(o=new Am(`Missing PDF "${r}".`)),this._storedError=o,this._headersCapability.reject(o)})}}class M0t extends a4e{constructor(t,r,n){super(t);let o=decodeURIComponent(this._url.path);o4e.test(this._url.href)&&(o=o.replace(/^\//,""));const i=F1.get("fs");this._setReadableStream(i.createReadStream(o,{start:r,end:n-1}))}}const P0t=1e5,as=30,I0t=.8;let ab=class Qd{#e=Promise.withResolvers();#t=null;#r=!1;#o=!!globalThis.FontInspector?.enabled;#s=null;#n=null;#i=0;#l=0;#d=null;#u=null;#h=0;#c=0;#a=Object.create(null);#m=[];#g=null;#p=[];#v=new WeakMap;#f=null;static#b=new Map;static#x=new Map;static#$=null;static#k=new Set;constructor({textContentSource:t,container:r,viewport:n}){if(t instanceof ReadableStream)this.#g=t;else if(typeof t=="object")this.#g=new ReadableStream({start(d){d.enqueue(t),d.close()}});else throw new Error('No "textContentSource" parameter specified.');this.#t=this.#u=r,this.#c=n.scale*(globalThis.devicePixelRatio||1),this.#h=n.rotation,this.#n={prevFontSize:null,prevFontFamily:null,div:null,properties:null,ctx:null};const{pageWidth:o,pageHeight:i,pageX:a,pageY:l}=n.rawDims;this.#f=[1,0,0,-1,-a,l+i],this.#l=o,this.#i=i,Qd.#y(),cm(r,n),this.#e.promise.catch(()=>{}).then(()=>{Qd.#k.delete(this),this.#n=null,this.#a=null})}render(){const t=()=>{this.#d.read().then(({value:r,done:n})=>{if(n){this.#e.resolve();return}this.#s??=r.lang,Object.assign(this.#a,r.styles),this.#E(r.items),t()},this.#e.reject)};return this.#d=this.#g.getReader(),Qd.#k.add(this),t(),this.#e.promise}update({viewport:t,onBefore:r=null}){const n=t.scale*(globalThis.devicePixelRatio||1),o=t.rotation;if(o!==this.#h&&(r?.(),this.#h=o,cm(this.#u,{rotation:o})),n!==this.#c){r?.(),this.#c=n;const i={prevFontSize:null,prevFontFamily:null,div:null,properties:null,ctx:Qd.#w(this.#s)};for(const a of this.#p)i.properties=this.#v.get(a),i.div=a,this.#S(i)}}cancel(){const t=new Lm("TextLayer task cancelled.");this.#d?.cancel(t).catch(()=>{}),this.#d=null,this.#e.reject(t)}get textDivs(){return this.#p}get textContentItemsStr(){return this.#m}#E(t){if(this.#r)return;this.#n.ctx??=Qd.#w(this.#s);const r=this.#p,n=this.#m;for(const o of t){if(r.length>P0t){Jr("Ignoring additional textDivs for performance reasons."),this.#r=!0;return}if(o.str===void 0){if(o.type==="beginMarkedContentProps"||o.type==="beginMarkedContent"){const i=this.#t;this.#t=document.createElement("span"),this.#t.classList.add("markedContent"),o.id!==null&&this.#t.setAttribute("id",`${o.id}`),i.append(this.#t)}else o.type==="endMarkedContent"&&(this.#t=this.#t.parentNode);continue}n.push(o.str),this.#L(o)}}#L(t){const r=document.createElement("span"),n={angle:0,canvasWidth:0,hasText:t.str!=="",hasEOL:t.hasEOL,fontSize:0};this.#p.push(r);const o=lr.transform(this.#f,t.transform);let i=Math.atan2(o[1],o[0]);const a=this.#a[t.fontName];a.vertical&&(i+=Math.PI/2);const l=this.#o&&a.fontSubstitution||a.fontFamily,d=Math.hypot(o[2],o[3]),u=d*Qd.#C(l,this.#s);let p,h;i===0?(p=o[4],h=o[5]-u):(p=o[4]+u*Math.sin(i),h=o[5]-u*Math.cos(i));const f="calc(var(--scale-factor)*",g=r.style;this.#t===this.#u?(g.left=`${(100*p/this.#l).toFixed(2)}%`,g.top=`${(100*h/this.#i).toFixed(2)}%`):(g.left=`${f}${p.toFixed(2)}px)`,g.top=`${f}${h.toFixed(2)}px)`),g.fontSize=`${f}${(Qd.#$*d).toFixed(2)}px)`,g.fontFamily=l,n.fontSize=d,r.setAttribute("role","presentation"),r.textContent=t.str,r.dir=t.dir,this.#o&&(r.dataset.fontName=a.fontSubstitutionLoadedName||t.fontName),i!==0&&(n.angle=i*(180/Math.PI));let y=!1;if(t.str.length>1)y=!0;else if(t.str!==" "&&t.transform[0]!==t.transform[3]){const v=Math.abs(t.transform[0]),w=Math.abs(t.transform[3]);v!==w&&Math.max(v,w)/Math.min(v,w)>1.5&&(y=!0)}if(y&&(n.canvasWidth=a.vertical?t.height:t.width),this.#v.set(r,n),this.#n.div=r,this.#n.properties=n,this.#S(this.#n),n.hasText&&this.#t.append(r),n.hasEOL){const v=document.createElement("br");v.setAttribute("role","presentation"),this.#t.append(v)}}#S(t){const{div:r,properties:n,ctx:o,prevFontSize:i,prevFontFamily:a}=t,{style:l}=r;let d="";if(Qd.#$>1&&(d=`scale(${1/Qd.#$})`),n.canvasWidth!==0&&n.hasText){const{fontFamily:u}=l,{canvasWidth:p,fontSize:h}=n;(i!==h||a!==u)&&(o.font=`${h*this.#c}px ${u}`,t.prevFontSize=h,t.prevFontFamily=u);const{width:f}=o.measureText(r.textContent);f>0&&(d=`scaleX(${p*this.#c/f}) ${d}`)}n.angle!==0&&(d=`rotate(${n.angle}deg) ${d}`),d.length>0&&(l.transform=d)}static cleanup(){if(!(this.#k.size>0)){this.#b.clear();for(const{canvas:t}of this.#x.values())t.remove();this.#x.clear()}}static#w(t=null){let r=this.#x.get(t||="");if(!r){const n=document.createElement("canvas");n.className="hiddenCanvasElement",n.lang=t,document.body.append(n),r=n.getContext("2d",{alpha:!1,willReadFrequently:!0}),this.#x.set(t,r)}return r}static#y(){if(this.#$!==null)return;const t=document.createElement("div");t.style.opacity=0,t.style.lineHeight=1,t.style.fontSize="1px",t.textContent="X",document.body.append(t),this.#$=t.getBoundingClientRect().height,t.remove()}static#C(t,r){const n=this.#b.get(t);if(n)return n;const o=this.#w(r),i=o.font;o.canvas.width=o.canvas.height=as,o.font=`${as}px ${t}`;const a=o.measureText("");let l=a.fontBoundingBoxAscent,d=Math.abs(a.fontBoundingBoxDescent);if(l){const h=l/(l+d);return this.#b.set(t,h),o.canvas.width=o.canvas.height=0,o.font=i,h}o.strokeStyle="red",o.clearRect(0,0,as,as),o.strokeText("g",0,0);let u=o.getImageData(0,0,as,as).data;d=0;for(let h=u.length-1-3;h>=0;h-=4)if(u[h]>0){d=Math.ceil(h/4/as);break}o.clearRect(0,0,as,as),o.strokeText("A",0,as),u=o.getImageData(0,0,as,as).data,l=0;for(let h=0,f=u.length;h<f;h+=4)if(u[h]>0){l=as-Math.floor(h/4/as);break}o.canvas.width=o.canvas.height=0,o.font=i;const p=l?l/(l+d):I0t;return this.#b.set(t,p),p}};function j0t(){Zge("`renderTextLayer`, please use `TextLayer` instead.");const{textContentSource:e,container:t,viewport:r,...n}=arguments[0],o=Object.keys(n);o.length>0&&Jr("Ignoring `renderTextLayer` parameters: "+o.join(", "));const i=new ab({textContentSource:e,container:t,viewport:r}),{textDivs:a,textContentItemsStr:l}=i;return{promise:i.render(),textDivs:a,textContentItemsStr:l}}function R0t(){Zge("`updateTextLayer`, please use `TextLayer` instead.")}class _7{static textContent(t){const r=[],n={items:r,styles:Object.create(null)};function o(i){if(!i)return;let a=null;const l=i.name;if(l==="#text")a=i.value;else if(_7.shouldBuildText(l))i?.attributes?.textContent?a=i.attributes.textContent:i.value&&(a=i.value);else return;if(a!==null&&r.push({str:a}),!!i.children)for(const d of i.children)o(d)}return o(t),n}static shouldBuildText(t){return!(t==="textarea"||t==="input"||t==="option"||t==="select")}}const F0t=65536,O0t=100,N0t=5e3,z0t=ka?X2t:O2t,B0t=ka?Q2t:Gge,H0t=ka?K2t:F2t,V0t=ka?J2t:qge;function U0t(e={}){typeof e=="string"||e instanceof URL?e={url:e}:(e instanceof ArrayBuffer||ArrayBuffer.isView(e))&&(e={data:e});const t=new oN,{docId:r}=t,n=e.url?W0t(e.url):null,o=e.data?Y0t(e.data):null,i=e.httpHeaders||null,a=e.withCredentials===!0,l=e.password??null,d=e.range instanceof s4e?e.range:null,u=Number.isInteger(e.rangeChunkSize)&&e.rangeChunkSize>0?e.rangeChunkSize:F0t;let p=e.worker instanceof kl?e.worker:null;const h=e.verbosity,f=typeof e.docBaseUrl=="string"&&!qO(e.docBaseUrl)?e.docBaseUrl:null,g=typeof e.cMapUrl=="string"?e.cMapUrl:null,y=e.cMapPacked!==!1,v=e.CMapReaderFactory||B0t,w=typeof e.standardFontDataUrl=="string"?e.standardFontDataUrl:null,x=e.StandardFontDataFactory||V0t,$=e.stopAtErrors!==!0,S=Number.isInteger(e.maxImageSize)&&e.maxImageSize>-1?e.maxImageSize:-1,k=e.isEvalSupported!==!1,T=typeof e.isOffscreenCanvasSupported=="boolean"?e.isOffscreenCanvasSupported:!ka,E=Number.isInteger(e.canvasMaxAreaInBytes)?e.canvasMaxAreaInBytes:-1,A=typeof e.disableFontFace=="boolean"?e.disableFontFace:ka,D=e.fontExtraProperties===!0,P=e.enableXfa===!0,j=e.ownerDocument||globalThis.document,B=e.disableRange===!0,O=e.disableStream===!0,q=e.disableAutoFetch===!0,W=e.pdfBug===!0,F=e.enableHWA===!0,V=d?d.length:e.length??NaN,I=typeof e.useSystemFonts=="boolean"?e.useSystemFonts:!ka&&!A,L=typeof e.useWorkerFetch=="boolean"?e.useWorkerFetch:v===Gge&&x===qge&&g&&w&&P5(g,document.baseURI)&&P5(w,document.baseURI),z=e.canvasFactory||new z0t({ownerDocument:j,enableHWA:F}),H=e.filterFactory||new H0t({docId:r,ownerDocument:j}),ee=null;E2t(h);const Z={canvasFactory:z,filterFactory:H};if(L||(Z.cMapReaderFactory=new v({baseUrl:g,isCompressed:y}),Z.standardFontDataFactory=new x({baseUrl:w})),!p){const Q={verbosity:h,port:E7.workerPort};p=Q.port?kl.fromPort(Q):new kl(Q),t._worker=p}const U={docId:r,apiVersion:"4.4.168",data:o,password:l,disableAutoFetch:q,rangeChunkSize:u,length:V,docBaseUrl:f,enableXfa:P,evaluatorOptions:{maxImageSize:S,disableFontFace:A,ignoreErrors:$,isEvalSupported:k,isOffscreenCanvasSupported:T,canvasMaxAreaInBytes:E,fontExtraProperties:D,useSystemFonts:I,cMapUrl:L?g:null,standardFontDataUrl:L?w:null}},X={disableFontFace:A,fontExtraProperties:D,ownerDocument:j,pdfBug:W,styleElement:ee,loadingParams:{disableAutoFetch:q,enableXfa:P}};return p.promise.then(function(){if(t.destroyed)throw new Error("Loading aborted");if(p.destroyed)throw new Error("Worker was destroyed");const Q=p.messageHandler.sendWithPromise("GetDocRequest",U,o?[o.buffer]:null);let oe;if(d)oe=new g0t(d,{disableRange:B,disableStream:O});else if(!o){if(!n)throw new Error("getDocument - no `url` parameter provided.");oe=(le=>ka?function(){return typeof fetch<"u"&&typeof Response<"u"&&"body"in Response.prototype}()&&P5(le.url)?new oJ(le):new T0t(le):P5(le.url)?new oJ(le):new S0t(le))({url:n,length:V,httpHeaders:i,withCredentials:a,rangeChunkSize:u,disableRange:B,disableStream:O})}return Q.then(ge=>{if(t.destroyed)throw new Error("Loading aborted");if(p.destroyed)throw new Error("Worker was destroyed");const le=new I5(r,ge,p.port),se=new K0t(le,t,oe,X,Z);t._transport=se,le.send("Ready",null)})}).catch(t._capability.reject),t}function W0t(e){if(e instanceof URL)return e.href;try{return new URL(e,window.location).href}catch{if(ka&&typeof e=="string")return e}throw new Error("Invalid PDF url data: either string or URL-object is expected in the url property.")}function Y0t(e){if(ka&&typeof ev<"u"&&e instanceof ev)throw new Error("Please provide binary data as `Uint8Array`, rather than `Buffer`.");if(e instanceof Uint8Array&&e.byteLength===e.buffer.byteLength)return e;if(typeof e=="string")return Sx(e);if(e instanceof ArrayBuffer||ArrayBuffer.isView(e)||typeof e=="object"&&!isNaN(e?.length))return new Uint8Array(e);throw new Error("Invalid PDF binary data: either TypedArray, string, or array-like object is expected in the data property.")}function iJ(e){return typeof e=="object"&&Number.isInteger(e?.num)&&e.num>=0&&Number.isInteger(e?.gen)&&e.gen>=0}class oN{static#e=0;constructor(){this._capability=Promise.withResolvers(),this._transport=null,this._worker=null,this.docId=`d${oN.#e++}`,this.destroyed=!1,this.onPassword=null,this.onProgress=null}get promise(){return this._capability.promise}async destroy(){this.destroyed=!0;try{this._worker?.port&&(this._worker._pendingDestroy=!0),await this._transport?.destroy()}catch(t){throw this._worker?.port&&delete this._worker._pendingDestroy,t}this._transport=null,this._worker&&(this._worker.destroy(),this._worker=null)}}let s4e=class{constructor(t,r,n=!1,o=null){this.length=t,this.initialData=r,this.progressiveDone=n,this.contentDispositionFilename=o,this._rangeListeners=[],this._progressListeners=[],this._progressiveReadListeners=[],this._progressiveDoneListeners=[],this._readyCapability=Promise.withResolvers()}addRangeListener(t){this._rangeListeners.push(t)}addProgressListener(t){this._progressListeners.push(t)}addProgressiveReadListener(t){this._progressiveReadListeners.push(t)}addProgressiveDoneListener(t){this._progressiveDoneListeners.push(t)}onDataRange(t,r){for(const n of this._rangeListeners)n(t,r)}onDataProgress(t,r){this._readyCapability.promise.then(()=>{for(const n of this._progressListeners)n(t,r)})}onDataProgressiveRead(t){this._readyCapability.promise.then(()=>{for(const r of this._progressiveReadListeners)r(t)})}onDataProgressiveDone(){this._readyCapability.promise.then(()=>{for(const t of this._progressiveDoneListeners)t()})}transportReady(){this._readyCapability.resolve()}requestDataRange(t,r){Xn("Abstract method PDFDataRangeTransport.requestDataRange")}abort(){}};class G0t{constructor(t,r){this._pdfInfo=t,this._transport=r}get annotationStorage(){return this._transport.annotationStorage}get filterFactory(){return this._transport.filterFactory}get numPages(){return this._pdfInfo.numPages}get fingerprints(){return this._pdfInfo.fingerprints}get isPureXfa(){return vn(this,"isPureXfa",!!this._transport._htmlForXfa)}get allXfaHtml(){return this._transport._htmlForXfa}getPage(t){return this._transport.getPage(t)}getPageIndex(t){return this._transport.getPageIndex(t)}getDestinations(){return this._transport.getDestinations()}getDestination(t){return this._transport.getDestination(t)}getPageLabels(){return this._transport.getPageLabels()}getPageLayout(){return this._transport.getPageLayout()}getPageMode(){return this._transport.getPageMode()}getViewerPreferences(){return this._transport.getViewerPreferences()}getOpenAction(){return this._transport.getOpenAction()}getAttachments(){return this._transport.getAttachments()}getJSActions(){return this._transport.getDocJSActions()}getOutline(){return this._transport.getOutline()}getOptionalContentConfig({intent:t="display"}={}){const{renderingIntent:r}=this._transport.getRenderingIntent(t);return this._transport.getOptionalContentConfig(r)}getPermissions(){return this._transport.getPermissions()}getMetadata(){return this._transport.getMetadata()}getMarkInfo(){return this._transport.getMarkInfo()}getData(){return this._transport.getData()}saveDocument(){return this._transport.saveDocument()}getDownloadInfo(){return this._transport.downloadInfoCapability.promise}cleanup(t=!1){return this._transport.startCleanup(t||this.isPureXfa)}destroy(){return this.loadingTask.destroy()}cachedPageNumber(t){return this._transport.cachedPageNumber(t)}get loadingParams(){return this._transport.loadingParams}get loadingTask(){return this._transport.loadingTask}getFieldObjects(){return this._transport.getFieldObjects()}hasJSActions(){return this._transport.hasJSActions()}getCalculationOrderIds(){return this._transport.getCalculationOrderIds()}}class q0t{#e=null;#t=!1;constructor(t,r,n,o=!1){this._pageIndex=t,this._pageInfo=r,this._transport=n,this._stats=o?new WQ:null,this._pdfBug=o,this.commonObjs=n.commonObjs,this.objs=new l4e,this._maybeCleanupAfterRender=!1,this._intentStates=new Map,this.destroyed=!1}get pageNumber(){return this._pageIndex+1}get rotate(){return this._pageInfo.rotate}get ref(){return this._pageInfo.ref}get userUnit(){return this._pageInfo.userUnit}get view(){return this._pageInfo.view}getViewport({scale:t,rotation:r=this.rotate,offsetX:n=0,offsetY:o=0,dontFlip:i=!1}={}){return new u6({viewBox:this.view,scale:t,rotation:r,offsetX:n,offsetY:o,dontFlip:i})}getAnnotations({intent:t="display"}={}){const{renderingIntent:r}=this._transport.getRenderingIntent(t);return this._transport.getAnnotations(this._pageIndex,r)}getJSActions(){return this._transport.getPageJSActions(this._pageIndex)}get filterFactory(){return this._transport.filterFactory}get isPureXfa(){return vn(this,"isPureXfa",!!this._transport._htmlForXfa)}async getXfa(){return this._transport._htmlForXfa?.children[this._pageIndex]||null}render({canvasContext:t,viewport:r,intent:n="display",annotationMode:o=X2.ENABLE,transform:i=null,background:a=null,optionalContentConfigPromise:l=null,annotationCanvasMap:d=null,pageColors:u=null,printAnnotationStorage:p=null}){this._stats?.time("Overall");const h=this._transport.getRenderingIntent(n,o,p),{renderingIntent:f,cacheKey:g}=h;this.#t=!1,this.#o(),l||=this._transport.getOptionalContentConfig(f);let y=this._intentStates.get(g);y||(y=Object.create(null),this._intentStates.set(g,y)),y.streamReaderCancelTimeout&&(clearTimeout(y.streamReaderCancelTimeout),y.streamReaderCancelTimeout=null);const v=!!(f&$l.PRINT);y.displayReadyCapability||(y.displayReadyCapability=Promise.withResolvers(),y.operatorList={fnArray:[],argsArray:[],lastChunk:!1,separateAnnots:null},this._stats?.time("Page Request"),this._pumpOperatorList(h));const w=S=>{y.renderTasks.delete(x),(this._maybeCleanupAfterRender||v)&&(this.#t=!0),this.#r(!v),S?(x.capability.reject(S),this._abortOperatorList({intentState:y,reason:S instanceof Error?S:new Error(S)})):x.capability.resolve(),this._stats&&(this._stats.timeEnd("Rendering"),this._stats.timeEnd("Overall"),globalThis.Stats?.enabled&&globalThis.Stats.add(this.pageNumber,this._stats))},x=new hf({callback:w,params:{canvasContext:t,viewport:r,transform:i,background:a},objs:this.objs,commonObjs:this.commonObjs,annotationCanvasMap:d,operatorList:y.operatorList,pageIndex:this._pageIndex,canvasFactory:this._transport.canvasFactory,filterFactory:this._transport.filterFactory,useRequestAnimationFrame:!v,pdfBug:this._pdfBug,pageColors:u});(y.renderTasks||=new Set).add(x);const $=x.task;return Promise.all([y.displayReadyCapability.promise,l]).then(([S,k])=>{if(this.destroyed){w();return}if(this._stats?.time("Rendering"),!(k.renderingIntent&f))throw new Error("Must use the same `intent`-argument when calling the `PDFPageProxy.render` and `PDFDocumentProxy.getOptionalContentConfig` methods.");x.initializeGraphics({transparency:S,optionalContentConfig:k}),x.operatorListChanged()}).catch(w),$}getOperatorList({intent:t="display",annotationMode:r=X2.ENABLE,printAnnotationStorage:n=null}={}){function o(){a.operatorList.lastChunk&&(a.opListReadCapability.resolve(a.operatorList),a.renderTasks.delete(l))}const i=this._transport.getRenderingIntent(t,r,n,!0);let a=this._intentStates.get(i.cacheKey);a||(a=Object.create(null),this._intentStates.set(i.cacheKey,a));let l;return a.opListReadCapability||(l=Object.create(null),l.operatorListChanged=o,a.opListReadCapability=Promise.withResolvers(),(a.renderTasks||=new Set).add(l),a.operatorList={fnArray:[],argsArray:[],lastChunk:!1,separateAnnots:null},this._stats?.time("Page Request"),this._pumpOperatorList(i)),a.opListReadCapability.promise}streamTextContent({includeMarkedContent:t=!1,disableNormalization:r=!1}={}){return this._transport.messageHandler.sendWithStream("GetTextContent",{pageIndex:this._pageIndex,includeMarkedContent:t===!0,disableNormalization:r===!0},{highWaterMark:100,size(o){return o.items.length}})}getTextContent(t={}){if(this._transport._htmlForXfa)return this.getXfa().then(n=>_7.textContent(n));const r=this.streamTextContent(t);return new Promise(function(n,o){function i(){a.read().then(function({value:d,done:u}){if(u){n(l);return}l.lang??=d.lang,Object.assign(l.styles,d.styles),l.items.push(...d.items),i()},o)}const a=r.getReader(),l={items:[],styles:Object.create(null),lang:null};i()})}getStructTree(){return this._transport.getStructTree(this._pageIndex)}_destroy(){this.destroyed=!0;const t=[];for(const r of this._intentStates.values())if(this._abortOperatorList({intentState:r,reason:new Error("Page was destroyed."),force:!0}),!r.opListReadCapability)for(const n of r.renderTasks)t.push(n.completed),n.cancel();return this.objs.clear(),this.#t=!1,this.#o(),Promise.all(t)}cleanup(t=!1){this.#t=!0;const r=this.#r(!1);return t&&r&&(this._stats&&=new WQ),r}#r(t=!1){if(this.#o(),!this.#t||this.destroyed)return!1;if(t)return this.#e=setTimeout(()=>{this.#e=null,this.#r(!1)},N0t),!1;for(const{renderTasks:r,operatorList:n}of this._intentStates.values())if(r.size>0||!n.lastChunk)return!1;return this._intentStates.clear(),this.objs.clear(),this.#t=!1,!0}#o(){this.#e&&(clearTimeout(this.#e),this.#e=null)}_startRenderPage(t,r){const n=this._intentStates.get(r);n&&(this._stats?.timeEnd("Page Request"),n.displayReadyCapability?.resolve(t))}_renderPageChunk(t,r){for(let n=0,o=t.length;n<o;n++)r.operatorList.fnArray.push(t.fnArray[n]),r.operatorList.argsArray.push(t.argsArray[n]);r.operatorList.lastChunk=t.lastChunk,r.operatorList.separateAnnots=t.separateAnnots;for(const n of r.renderTasks)n.operatorListChanged();t.lastChunk&&this.#r(!0)}_pumpOperatorList({renderingIntent:t,cacheKey:r,annotationStorageSerializable:n}){const{map:o,transfer:i}=n,l=this._transport.messageHandler.sendWithStream("GetOperatorList",{pageIndex:this._pageIndex,intent:t,cacheKey:r,annotationStorage:o},i).getReader(),d=this._intentStates.get(r);d.streamReader=l;const u=()=>{l.read().then(({value:p,done:h})=>{if(h){d.streamReader=null;return}this._transport.destroyed||(this._renderPageChunk(p,d),u())},p=>{if(d.streamReader=null,!this._transport.destroyed){if(d.operatorList){d.operatorList.lastChunk=!0;for(const h of d.renderTasks)h.operatorListChanged();this.#r(!0)}if(d.displayReadyCapability)d.displayReadyCapability.reject(p);else if(d.opListReadCapability)d.opListReadCapability.reject(p);else throw p}})};u()}_abortOperatorList({intentState:t,reason:r,force:n=!1}){if(t.streamReader){if(t.streamReaderCancelTimeout&&(clearTimeout(t.streamReaderCancelTimeout),t.streamReaderCancelTimeout=null),!n){if(t.renderTasks.size>0)return;if(r instanceof GO){let o=O0t;r.extraDelay>0&&r.extraDelay<1e3&&(o+=r.extraDelay),t.streamReaderCancelTimeout=setTimeout(()=>{t.streamReaderCancelTimeout=null,this._abortOperatorList({intentState:t,reason:r,force:!0})},o);return}}if(t.streamReader.cancel(new Lm(r.message)).catch(()=>{}),t.streamReader=null,!this._transport.destroyed){for(const[o,i]of this._intentStates)if(i===t){this._intentStates.delete(o);break}this.cleanup()}}}get stats(){return this._stats}}class Z0t{#e=new Set;#t=Promise.resolve();postMessage(t,r){const n={data:structuredClone(t,r?{transfer:r}:null)};this.#t.then(()=>{for(const o of this.#e)o.call(this,n)})}addEventListener(t,r){this.#e.add(r)}removeEventListener(t,r){this.#e.delete(r)}terminate(){this.#e.clear()}}const Pu={isWorkerDisabled:!1,fakeWorkerId:0};ka&&(Pu.isWorkerDisabled=!0,E7.workerSrc||="./pdf.worker.mjs"),Pu.isSameOrigin=function(e,t){let r;try{if(r=new URL(e),!r.origin||r.origin==="null")return!1}catch{return!1}const n=new URL(t,r);return r.origin===n.origin},Pu.createCDNWrapper=function(e){const t=`await import("${e}");`;return URL.createObjectURL(new Blob([t],{type:"text/javascript"}))};class kl{static#e;constructor({name:t=null,port:r=null,verbosity:n=_2t()}={}){if(this.name=t,this.destroyed=!1,this.verbosity=n,this._readyCapability=Promise.withResolvers(),this._port=null,this._webWorker=null,this._messageHandler=null,r){if(kl.#e?.has(r))throw new Error("Cannot use more than one PDFWorker per port.");(kl.#e||=new WeakMap).set(r,this),this._initializeFromPort(r);return}this._initialize()}get promise(){return ka?Promise.all([F1.promise,this._readyCapability.promise]):this._readyCapability.promise}#t(){this._readyCapability.resolve(),this._messageHandler.send("configure",{verbosity:this.verbosity})}get port(){return this._port}get messageHandler(){return this._messageHandler}_initializeFromPort(t){this._port=t,this._messageHandler=new I5("main","worker",t),this._messageHandler.on("ready",function(){}),this.#t()}_initialize(){if(Pu.isWorkerDisabled||kl.#r){this._setupFakeWorker();return}let{workerSrc:t}=kl;try{Pu.isSameOrigin(window.location.href,t)||(t=Pu.createCDNWrapper(new URL(t,window.location).href));const r=new Worker(t,{type:"module"}),n=new I5("main","worker",r),o=()=>{i.abort(),n.destroy(),r.terminate(),this.destroyed?this._readyCapability.reject(new Error("Worker was destroyed")):this._setupFakeWorker()},i=new AbortController;r.addEventListener("error",()=>{this._webWorker||o()},{signal:i.signal}),n.on("test",l=>{if(i.abort(),this.destroyed||!l){o();return}this._messageHandler=n,this._port=r,this._webWorker=r,this.#t()}),n.on("ready",l=>{if(i.abort(),this.destroyed){o();return}try{a()}catch{this._setupFakeWorker()}});const a=()=>{const l=new Uint8Array;n.send("test",l,[l.buffer])};a();return}catch{Cx("The worker has been disabled.")}this._setupFakeWorker()}_setupFakeWorker(){Pu.isWorkerDisabled||(Jr("Setting up fake worker."),Pu.isWorkerDisabled=!0),kl._setupFakeWorkerGlobal.then(t=>{if(this.destroyed){this._readyCapability.reject(new Error("Worker was destroyed"));return}const r=new Z0t;this._port=r;const n=`fake${Pu.fakeWorkerId++}`,o=new I5(n+"_worker",n,r);t.setup(o,r),this._messageHandler=new I5(n,n+"_worker",r),this.#t()}).catch(t=>{this._readyCapability.reject(new Error(`Setting up fake worker failed: "${t.message}".`))})}destroy(){this.destroyed=!0,this._webWorker&&(this._webWorker.terminate(),this._webWorker=null),kl.#e?.delete(this._port),this._port=null,this._messageHandler&&(this._messageHandler.destroy(),this._messageHandler=null)}static fromPort(t){if(!t?.port)throw new Error("PDFWorker.fromPort - invalid method signature.");const r=this.#e?.get(t.port);if(r){if(r._pendingDestroy)throw new Error("PDFWorker.fromPort - the worker is being destroyed.\nPlease remember to await `PDFDocumentLoadingTask.destroy()`-calls.");return r}return new kl(t)}static get workerSrc(){if(E7.workerSrc)return E7.workerSrc;throw new Error('No "GlobalWorkerOptions.workerSrc" specified.')}static get#r(){try{return globalThis.pdfjsWorker?.WorkerMessageHandler||null}catch{return null}}static get _setupFakeWorkerGlobal(){return vn(this,"_setupFakeWorkerGlobal",(async()=>this.#r?this.#r:(await import(this.workerSrc)).WorkerMessageHandler)())}}class K0t{#e=new Map;#t=new Map;#r=new Map;#o=new Map;#s=null;constructor(t,r,n,o,i){this.messageHandler=t,this.loadingTask=r,this.commonObjs=new l4e,this.fontLoader=new q2t({ownerDocument:o.ownerDocument,styleElement:o.styleElement}),this.loadingParams=o.loadingParams,this._params=o,this.canvasFactory=i.canvasFactory,this.filterFactory=i.filterFactory,this.cMapReaderFactory=i.cMapReaderFactory,this.standardFontDataFactory=i.standardFontDataFactory,this.destroyed=!1,this.destroyCapability=null,this._networkStream=n,this._fullReader=null,this._lastProgress=null,this.downloadInfoCapability=Promise.withResolvers(),this.setupMessageHandler()}#n(t,r=null){const n=this.#e.get(t);if(n)return n;const o=this.messageHandler.sendWithPromise(t,r);return this.#e.set(t,o),o}get annotationStorage(){return vn(this,"annotationStorage",new eN)}getRenderingIntent(t,r=X2.ENABLE,n=null,o=!1){let i=$l.DISPLAY,a=lj;switch(t){case"any":i=$l.ANY;break;case"display":break;case"print":i=$l.PRINT;break;default:Jr(`getRenderingIntent - invalid intent: ${t}`)}switch(r){case X2.DISABLE:i+=$l.ANNOTATIONS_DISABLE;break;case X2.ENABLE:break;case X2.ENABLE_FORMS:i+=$l.ANNOTATIONS_FORMS;break;case X2.ENABLE_STORAGE:i+=$l.ANNOTATIONS_STORAGE,a=(i&$l.PRINT&&n instanceof Qge?n:this.annotationStorage).serializable;break;default:Jr(`getRenderingIntent - invalid annotationMode: ${r}`)}return o&&(i+=$l.OPLIST),{renderingIntent:i,cacheKey:`${i}_${a.hash}`,annotationStorageSerializable:a}}destroy(){if(this.destroyCapability)return this.destroyCapability.promise;this.destroyed=!0,this.destroyCapability=Promise.withResolvers(),this.#s?.reject(new Error("Worker was destroyed during onPassword callback"));const t=[];for(const n of this.#t.values())t.push(n._destroy());this.#t.clear(),this.#r.clear(),this.#o.clear(),this.hasOwnProperty("annotationStorage")&&this.annotationStorage.resetModified();const r=this.messageHandler.sendWithPromise("Terminate",null);return t.push(r),Promise.all(t).then(()=>{this.commonObjs.clear(),this.fontLoader.clear(),this.#e.clear(),this.filterFactory.destroy(),ab.cleanup(),this._networkStream?.cancelAllRequests(new Lm("Worker was terminated.")),this.messageHandler&&(this.messageHandler.destroy(),this.messageHandler=null),this.destroyCapability.resolve()},this.destroyCapability.reject),this.destroyCapability.promise}setupMessageHandler(){const{messageHandler:t,loadingTask:r}=this;t.on("GetReader",(n,o)=>{Ai(this._networkStream,"GetReader - no `IPDFStream` instance available."),this._fullReader=this._networkStream.getFullReader(),this._fullReader.onProgress=i=>{this._lastProgress={loaded:i.loaded,total:i.total}},o.onPull=()=>{this._fullReader.read().then(function({value:i,done:a}){if(a){o.close();return}Ai(i instanceof ArrayBuffer,"GetReader - expected an ArrayBuffer."),o.enqueue(new Uint8Array(i),1,[i])}).catch(i=>{o.error(i)})},o.onCancel=i=>{this._fullReader.cancel(i),o.ready.catch(a=>{if(!this.destroyed)throw a})}}),t.on("ReaderHeadersReady",n=>{const o=Promise.withResolvers(),i=this._fullReader;return i.headersReady.then(()=>{(!i.isStreamingSupported||!i.isRangeSupported)&&(this._lastProgress&&r.onProgress?.(this._lastProgress),i.onProgress=a=>{r.onProgress?.({loaded:a.loaded,total:a.total})}),o.resolve({isStreamingSupported:i.isStreamingSupported,isRangeSupported:i.isRangeSupported,contentLength:i.contentLength})},o.reject),o.promise}),t.on("GetRangeReader",(n,o)=>{Ai(this._networkStream,"GetRangeReader - no `IPDFStream` instance available.");const i=this._networkStream.getRangeReader(n.begin,n.end);if(!i){o.close();return}o.onPull=()=>{i.read().then(function({value:a,done:l}){if(l){o.close();return}Ai(a instanceof ArrayBuffer,"GetRangeReader - expected an ArrayBuffer."),o.enqueue(new Uint8Array(a),1,[a])}).catch(a=>{o.error(a)})},o.onCancel=a=>{i.cancel(a),o.ready.catch(l=>{if(!this.destroyed)throw l})}}),t.on("GetDoc",({pdfInfo:n})=>{this._numPages=n.numPages,this._htmlForXfa=n.htmlForXfa,delete n.htmlForXfa,r._capability.resolve(new G0t(n,this))}),t.on("DocException",function(n){let o;switch(n.name){case"PasswordException":o=new aj(n.message,n.code);break;case"InvalidPDFException":o=new Uge(n.message);break;case"MissingPDFException":o=new Am(n.message);break;case"UnexpectedResponseException":o=new $x(n.message,n.status);break;case"UnknownErrorException":o=new sj(n.message,n.details);break;default:Xn("DocException - expected a valid Error.")}r._capability.reject(o)}),t.on("PasswordRequest",n=>{if(this.#s=Promise.withResolvers(),r.onPassword){const o=i=>{i instanceof Error?this.#s.reject(i):this.#s.resolve({password:i})};try{r.onPassword(o,n.code)}catch(i){this.#s.reject(i)}}else this.#s.reject(new aj(n.message,n.code));return this.#s.promise}),t.on("DataLoaded",n=>{r.onProgress?.({loaded:n.length,total:n.length}),this.downloadInfoCapability.resolve(n)}),t.on("StartRenderPage",n=>{if(this.destroyed)return;this.#t.get(n.pageIndex)._startRenderPage(n.transparency,n.cacheKey)}),t.on("commonobj",([n,o,i])=>{if(this.destroyed||this.commonObjs.has(n))return null;switch(o){case"Font":const{disableFontFace:a,fontExtraProperties:l,pdfBug:d}=this._params;if("error"in i){const f=i.error;Jr(`Error during font loading: ${f}`),this.commonObjs.resolve(n,f);break}const u=d&&globalThis.FontInspector?.enabled?(f,g)=>globalThis.FontInspector.fontAdded(f,g):null,p=new Z2t(i,{disableFontFace:a,inspectFont:u});this.fontLoader.bind(p).catch(()=>t.sendWithPromise("FontFallback",{id:n})).finally(()=>{!l&&p.data&&(p.data=null),this.commonObjs.resolve(n,p)});break;case"CopyLocalImage":const{imageRef:h}=i;Ai(h,"The imageRef must be defined.");for(const f of this.#t.values())for(const[,g]of f.objs)if(g?.ref===h)return g.dataLen?(this.commonObjs.resolve(n,structuredClone(g)),g.dataLen):null;break;case"FontPath":case"Image":case"Pattern":this.commonObjs.resolve(n,i);break;default:throw new Error(`Got unknown common object type ${o}`)}return null}),t.on("obj",([n,o,i,a])=>{if(this.destroyed)return;const l=this.#t.get(o);if(!l.objs.has(n)){if(l._intentStates.size===0){a?.bitmap?.close();return}switch(i){case"Image":l.objs.resolve(n,a),a?.dataLen>C2t&&(l._maybeCleanupAfterRender=!0);break;case"Pattern":l.objs.resolve(n,a);break;default:throw new Error(`Got unknown object type ${i}`)}}}),t.on("DocProgress",n=>{this.destroyed||r.onProgress?.({loaded:n.loaded,total:n.total})}),t.on("FetchBuiltInCMap",n=>this.destroyed?Promise.reject(new Error("Worker was destroyed.")):this.cMapReaderFactory?this.cMapReaderFactory.fetch(n):Promise.reject(new Error("CMapReaderFactory not initialized, see the `useWorkerFetch` parameter."))),t.on("FetchStandardFontData",n=>this.destroyed?Promise.reject(new Error("Worker was destroyed.")):this.standardFontDataFactory?this.standardFontDataFactory.fetch(n):Promise.reject(new Error("StandardFontDataFactory not initialized, see the `useWorkerFetch` parameter.")))}getData(){return this.messageHandler.sendWithPromise("GetData",null)}saveDocument(){this.annotationStorage.size<=0&&Jr("saveDocument called while `annotationStorage` is empty, please use the getData-method instead.");const{map:t,transfer:r}=this.annotationStorage.serializable;return this.messageHandler.sendWithPromise("SaveDocument",{isPureXfa:!!this._htmlForXfa,numPages:this._numPages,annotationStorage:t,filename:this._fullReader?.filename??null},r).finally(()=>{this.annotationStorage.resetModified()})}getPage(t){if(!Number.isInteger(t)||t<=0||t>this._numPages)return Promise.reject(new Error("Invalid page request."));const r=t-1,n=this.#r.get(r);if(n)return n;const o=this.messageHandler.sendWithPromise("GetPage",{pageIndex:r}).then(i=>{if(this.destroyed)throw new Error("Transport destroyed");i.refStr&&this.#o.set(i.refStr,t);const a=new q0t(r,i,this,this._params.pdfBug);return this.#t.set(r,a),a});return this.#r.set(r,o),o}getPageIndex(t){return iJ(t)?this.messageHandler.sendWithPromise("GetPageIndex",{num:t.num,gen:t.gen}):Promise.reject(new Error("Invalid pageIndex request."))}getAnnotations(t,r){return this.messageHandler.sendWithPromise("GetAnnotations",{pageIndex:t,intent:r})}getFieldObjects(){return this.#n("GetFieldObjects")}hasJSActions(){return this.#n("HasJSActions")}getCalculationOrderIds(){return this.messageHandler.sendWithPromise("GetCalculationOrderIds",null)}getDestinations(){return this.messageHandler.sendWithPromise("GetDestinations",null)}getDestination(t){return typeof t!="string"?Promise.reject(new Error("Invalid destination request.")):this.messageHandler.sendWithPromise("GetDestination",{id:t})}getPageLabels(){return this.messageHandler.sendWithPromise("GetPageLabels",null)}getPageLayout(){return this.messageHandler.sendWithPromise("GetPageLayout",null)}getPageMode(){return this.messageHandler.sendWithPromise("GetPageMode",null)}getViewerPreferences(){return this.messageHandler.sendWithPromise("GetViewerPreferences",null)}getOpenAction(){return this.messageHandler.sendWithPromise("GetOpenAction",null)}getAttachments(){return this.messageHandler.sendWithPromise("GetAttachments",null)}getDocJSActions(){return this.#n("GetDocJSActions")}getPageJSActions(t){return this.messageHandler.sendWithPromise("GetPageJSActions",{pageIndex:t})}getStructTree(t){return this.messageHandler.sendWithPromise("GetStructTree",{pageIndex:t})}getOutline(){return this.messageHandler.sendWithPromise("GetOutline",null)}getOptionalContentConfig(t){return this.#n("GetOptionalContentConfig").then(r=>new f0t(r,t))}getPermissions(){return this.messageHandler.sendWithPromise("GetPermissions",null)}getMetadata(){const t="GetMetadata",r=this.#e.get(t);if(r)return r;const n=this.messageHandler.sendWithPromise(t,null).then(o=>({info:o[0],metadata:o[1]?new h0t(o[1]):null,contentDispositionFilename:this._fullReader?.filename??null,contentLength:this._fullReader?.contentLength??null}));return this.#e.set(t,n),n}getMarkInfo(){return this.messageHandler.sendWithPromise("GetMarkInfo",null)}async startCleanup(t=!1){if(!this.destroyed){await this.messageHandler.sendWithPromise("Cleanup",null);for(const r of this.#t.values())if(!r.cleanup())throw new Error(`startCleanup: Page ${r.pageNumber} is currently rendering.`);this.commonObjs.clear(),t||this.fontLoader.clear(),this.#e.clear(),this.filterFactory.destroy(!0),ab.cleanup()}}cachedPageNumber(t){if(!iJ(t))return null;const r=t.gen===0?`${t.num}R`:`${t.num}R${t.gen}`;return this.#o.get(r)??null}}const j9=Symbol("INITIAL_DATA");class l4e{#e=Object.create(null);#t(t){return this.#e[t]||={...Promise.withResolvers(),data:j9}}get(t,r=null){if(r){const o=this.#t(t);return o.promise.then(()=>r(o.data)),null}const n=this.#e[t];if(!n||n.data===j9)throw new Error(`Requesting object that isn't resolved yet ${t}.`);return n.data}has(t){const r=this.#e[t];return!!r&&r.data!==j9}resolve(t,r=null){const n=this.#t(t);n.data=r,n.resolve()}clear(){for(const t in this.#e){const{data:r}=this.#e[t];r?.bitmap?.close()}this.#e=Object.create(null)}*[Symbol.iterator](){for(const t in this.#e){const{data:r}=this.#e[t];r!==j9&&(yield[t,r])}}}class X0t{#e=null;constructor(t){this.#e=t,this.onContinue=null}get promise(){return this.#e.capability.promise}cancel(t=0){this.#e.cancel(null,t)}get separateAnnots(){const{separateAnnots:t}=this.#e.operatorList;if(!t)return!1;const{annotationCanvasMap:r}=this.#e;return t.form||t.canvas&&r?.size>0}}class hf{#e=null;static#t=new WeakSet;constructor({callback:t,params:r,objs:n,commonObjs:o,annotationCanvasMap:i,operatorList:a,pageIndex:l,canvasFactory:d,filterFactory:u,useRequestAnimationFrame:p=!1,pdfBug:h=!1,pageColors:f=null}){this.callback=t,this.params=r,this.objs=n,this.commonObjs=o,this.annotationCanvasMap=i,this.operatorListIdx=null,this.operatorList=a,this._pageIndex=l,this.canvasFactory=d,this.filterFactory=u,this._pdfBug=h,this.pageColors=f,this.running=!1,this.graphicsReadyCallback=null,this.graphicsReady=!1,this._useRequestAnimationFrame=p===!0&&typeof window<"u",this.cancelled=!1,this.capability=Promise.withResolvers(),this.task=new X0t(this),this._cancelBound=this.cancel.bind(this),this._continueBound=this._continue.bind(this),this._scheduleNextBound=this._scheduleNext.bind(this),this._nextBound=this._next.bind(this),this._canvas=r.canvasContext.canvas}get completed(){return this.capability.promise.catch(function(){})}initializeGraphics({transparency:t=!1,optionalContentConfig:r}){if(this.cancelled)return;if(this._canvas){if(hf.#t.has(this._canvas))throw new Error("Cannot use the same canvas during multiple render() operations. Use different canvas or ensure previous operations were cancelled or completed.");hf.#t.add(this._canvas)}this._pdfBug&&globalThis.StepperManager?.enabled&&(this.stepper=globalThis.StepperManager.create(this._pageIndex),this.stepper.init(this.operatorList),this.stepper.nextBreakPoint=this.stepper.getNextBreakPoint());const{canvasContext:n,viewport:o,transform:i,background:a}=this.params;this.gfx=new Ef(n,this.commonObjs,this.objs,this.canvasFactory,this.filterFactory,{optionalContentConfig:r},this.annotationCanvasMap,this.pageColors),this.gfx.beginDrawing({transform:i,viewport:o,transparency:t,background:a}),this.operatorListIdx=0,this.graphicsReady=!0,this.graphicsReadyCallback?.()}cancel(t=null,r=0){this.running=!1,this.cancelled=!0,this.gfx?.endDrawing(),this.#e&&(window.cancelAnimationFrame(this.#e),this.#e=null),hf.#t.delete(this._canvas),this.callback(t||new GO(`Rendering cancelled, page ${this._pageIndex+1}`,r))}operatorListChanged(){if(!this.graphicsReady){this.graphicsReadyCallback||=this._continueBound;return}this.stepper?.updateOperatorList(this.operatorList),!this.running&&this._continue()}_continue(){this.running=!0,!this.cancelled&&(this.task.onContinue?this.task.onContinue(this._scheduleNextBound):this._scheduleNext())}_scheduleNext(){this._useRequestAnimationFrame?this.#e=window.requestAnimationFrame(()=>{this.#e=null,this._nextBound().catch(this._cancelBound)}):Promise.resolve().then(this._nextBound).catch(this._cancelBound)}async _next(){this.cancelled||(this.operatorListIdx=this.gfx.executeOperatorList(this.operatorList,this.operatorListIdx,this._continueBound,this.stepper),this.operatorListIdx===this.operatorList.argsArray.length&&(this.running=!1,this.operatorList.lastChunk&&(this.gfx.endDrawing(),hf.#t.delete(this._canvas),this.callback())))}}const Q0t="4.4.168",J0t="19fbc8998";function aJ(e){return Math.floor(Math.max(0,Math.min(1,e))*255).toString(16).padStart(2,"0")}function V4(e){return Math.max(0,Math.min(255,255*e))}class sJ{static CMYK_G([t,r,n,o]){return["G",1-Math.min(1,.3*t+.59*n+.11*r+o)]}static G_CMYK([t]){return["CMYK",0,0,0,1-t]}static G_RGB([t]){return["RGB",t,t,t]}static G_rgb([t]){return t=V4(t),[t,t,t]}static G_HTML([t]){const r=aJ(t);return`#${r}${r}${r}`}static RGB_G([t,r,n]){return["G",.3*t+.59*r+.11*n]}static RGB_rgb(t){return t.map(V4)}static RGB_HTML(t){return`#${t.map(aJ).join("")}`}static T_HTML(){return"#00000000"}static T_rgb(){return[null]}static CMYK_RGB([t,r,n,o]){return["RGB",1-Math.min(1,t+o),1-Math.min(1,n+o),1-Math.min(1,r+o)]}static CMYK_rgb([t,r,n,o]){return[V4(1-Math.min(1,t+o)),V4(1-Math.min(1,n+o)),V4(1-Math.min(1,r+o))]}static CMYK_HTML(t){const r=this.CMYK_RGB(t).slice(1);return this.RGB_HTML(r)}static RGB_CMYK([t,r,n]){const o=1-t,i=1-r,a=1-n,l=Math.min(o,i,a);return["CMYK",o,i,a,l]}}class c4e{static setupStorage(t,r,n,o,i){const a=o.getValue(r,{value:null});switch(n.name){case"textarea":if(a.value!==null&&(t.textContent=a.value),i==="print")break;t.addEventListener("input",l=>{o.setValue(r,{value:l.target.value})});break;case"input":if(n.attributes.type==="radio"||n.attributes.type==="checkbox"){if(a.value===n.attributes.xfaOn?t.setAttribute("checked",!0):a.value===n.attributes.xfaOff&&t.removeAttribute("checked"),i==="print")break;t.addEventListener("change",l=>{o.setValue(r,{value:l.target.checked?l.target.getAttribute("xfaOn"):l.target.getAttribute("xfaOff")})})}else{if(a.value!==null&&t.setAttribute("value",a.value),i==="print")break;t.addEventListener("input",l=>{o.setValue(r,{value:l.target.value})})}break;case"select":if(a.value!==null){t.setAttribute("value",a.value);for(const l of n.children)l.attributes.value===a.value?l.attributes.selected=!0:l.attributes.hasOwnProperty("selected")&&delete l.attributes.selected}t.addEventListener("input",l=>{const d=l.target.options,u=d.selectedIndex===-1?"":d[d.selectedIndex].value;o.setValue(r,{value:u})});break}}static setAttributes({html:t,element:r,storage:n=null,intent:o,linkService:i}){const{attributes:a}=r,l=t instanceof HTMLAnchorElement;a.type==="radio"&&(a.name=`${a.name}-${o}`);for(const[d,u]of Object.entries(a))if(u!=null)switch(d){case"class":u.length&&t.setAttribute(d,u.join(" "));break;case"dataId":break;case"id":t.setAttribute("data-element-id",u);break;case"style":Object.assign(t.style,u);break;case"textContent":t.textContent=u;break;default:(!l||d!=="href"&&d!=="newWindow")&&t.setAttribute(d,u)}l&&i.addLinkAttributes(t,a.href,a.newWindow),n&&a.dataId&&this.setupStorage(t,a.dataId,r,n)}static render(t){const r=t.annotationStorage,n=t.linkService,o=t.xfaHtml,i=t.intent||"display",a=document.createElement(o.name);o.attributes&&this.setAttributes({html:a,element:o,intent:i,linkService:n});const l=i!=="richText",d=t.div;if(d.append(a),t.viewport){const h=`matrix(${t.viewport.transform.join(",")})`;d.style.transform=h}l&&d.setAttribute("class","xfaLayer xfaFont");const u=[];if(o.children.length===0){if(o.value){const h=document.createTextNode(o.value);a.append(h),l&&_7.shouldBuildText(o.name)&&u.push(h)}return{textDivs:u}}const p=[[o,-1,a]];for(;p.length>0;){const[h,f,g]=p.at(-1);if(f+1===h.children.length){p.pop();continue}const y=h.children[++p.at(-1)[1]];if(y===null)continue;const{name:v}=y;if(v==="#text"){const x=document.createTextNode(y.value);u.push(x),g.append(x);continue}const w=y?.attributes?.xmlns?document.createElementNS(y.attributes.xmlns,v):document.createElement(v);if(g.append(w),y.attributes&&this.setAttributes({html:w,element:y,storage:r,intent:i,linkService:n}),y.children?.length>0)p.push([y,-1,w]);else if(y.value){const x=document.createTextNode(y.value);l&&_7.shouldBuildText(v)&&u.push(x),w.append(x)}}for(const h of d.querySelectorAll(".xfaNonInteractive input, .xfaNonInteractive textarea"))h.setAttribute("readOnly",!0);return{textDivs:u}}static update(t){const r=`matrix(${t.viewport.transform.join(",")})`;t.div.style.transform=r,t.div.hidden=!1}}const m6=1e3,ept=9,dm=new WeakSet;function e2(e){return{width:e[2]-e[0],height:e[3]-e[1]}}class tpt{static create(t){switch(t.data.annotationType){case Si.LINK:return new d4e(t);case Si.TEXT:return new rpt(t);case Si.WIDGET:switch(t.data.fieldType){case"Tx":return new npt(t);case"Btn":return t.data.radioButton?new u4e(t):t.data.checkBox?new ipt(t):new apt(t);case"Ch":return new spt(t);case"Sig":return new opt(t)}return new Dm(t);case Si.POPUP:return new pj(t);case Si.FREETEXT:return new p4e(t);case Si.LINE:return new cpt(t);case Si.SQUARE:return new dpt(t);case Si.CIRCLE:return new upt(t);case Si.POLYLINE:return new h4e(t);case Si.CARET:return new hpt(t);case Si.INK:return new m4e(t);case Si.POLYGON:return new ppt(t);case Si.HIGHLIGHT:return new mpt(t);case Si.UNDERLINE:return new fpt(t);case Si.SQUIGGLY:return new gpt(t);case Si.STRIKEOUT:return new ypt(t);case Si.STAMP:return new f4e(t);case Si.FILEATTACHMENT:return new vpt(t);default:return new ti(t)}}}class ti{#e=null;#t=!1;#r=null;constructor(t,{isRenderable:r=!1,ignoreBorder:n=!1,createQuadrilaterals:o=!1}={}){this.isRenderable=r,this.data=t.data,this.layer=t.layer,this.linkService=t.linkService,this.downloadManager=t.downloadManager,this.imageResourcesPath=t.imageResourcesPath,this.renderForms=t.renderForms,this.svgFactory=t.svgFactory,this.annotationStorage=t.annotationStorage,this.enableScripting=t.enableScripting,this.hasJSActions=t.hasJSActions,this._fieldObjects=t.fieldObjects,this.parent=t.parent,r&&(this.container=this._createContainer(n)),o&&this._createQuadrilaterals()}static _hasPopupData({titleObj:t,contentsObj:r,richText:n}){return!!(t?.str||r?.str||n?.str)}get hasPopupData(){return ti._hasPopupData(this.data)}updateEdited(t){if(!this.container)return;this.#e||={rect:this.data.rect.slice(0)};const{rect:r}=t;r&&this.#o(r),this.#r?.popup.updateEdited(t)}resetEdited(){this.#e&&(this.#o(this.#e.rect),this.#r?.popup.resetEdited(),this.#e=null)}#o(t){const{container:{style:r},data:{rect:n,rotation:o},parent:{viewport:{rawDims:{pageWidth:i,pageHeight:a,pageX:l,pageY:d}}}}=this;n?.splice(0,4,...t);const{width:u,height:p}=e2(t);r.left=`${100*(t[0]-l)/i}%`,r.top=`${100*(a-t[3]+d)/a}%`,o===0?(r.width=`${100*u/i}%`,r.height=`${100*p/a}%`):this.setRotation(o)}_createContainer(t){const{data:r,parent:{page:n,viewport:o}}=this,i=document.createElement("section");i.setAttribute("data-annotation-id",r.id),this instanceof Dm||(i.tabIndex=m6);const{style:a}=i;if(a.zIndex=this.parent.zIndex++,r.popupRef&&i.setAttribute("aria-haspopup","dialog"),r.alternativeText&&(i.title=r.alternativeText),r.noRotate&&i.classList.add("norotate"),!r.rect||this instanceof pj){const{rotation:v}=r;return!r.hasOwnCanvas&&v!==0&&this.setRotation(v,i),i}const{width:l,height:d}=e2(r.rect);if(!t&&r.borderStyle.width>0){a.borderWidth=`${r.borderStyle.width}px`;const v=r.borderStyle.horizontalCornerRadius,w=r.borderStyle.verticalCornerRadius;if(v>0||w>0){const $=`calc(${v}px * var(--scale-factor)) / calc(${w}px * var(--scale-factor))`;a.borderRadius=$}else if(this instanceof u4e){const $=`calc(${l}px * var(--scale-factor)) / calc(${d}px * var(--scale-factor))`;a.borderRadius=$}switch(r.borderStyle.style){case B4.SOLID:a.borderStyle="solid";break;case B4.DASHED:a.borderStyle="dashed";break;case B4.BEVELED:Jr("Unimplemented border style: beveled");break;case B4.INSET:Jr("Unimplemented border style: inset");break;case B4.UNDERLINE:a.borderBottomStyle="solid";break}const x=r.borderColor||null;x?(this.#t=!0,a.borderColor=lr.makeHexColor(x[0]|0,x[1]|0,x[2]|0)):a.borderWidth=0}const u=lr.normalizeRect([r.rect[0],n.view[3]-r.rect[1]+n.view[1],r.rect[2],n.view[3]-r.rect[3]+n.view[1]]),{pageWidth:p,pageHeight:h,pageX:f,pageY:g}=o.rawDims;a.left=`${100*(u[0]-f)/p}%`,a.top=`${100*(u[1]-g)/h}%`;const{rotation:y}=r;return r.hasOwnCanvas||y===0?(a.width=`${100*l/p}%`,a.height=`${100*d/h}%`):this.setRotation(y,i),i}setRotation(t,r=this.container){if(!this.data.rect)return;const{pageWidth:n,pageHeight:o}=this.parent.viewport.rawDims,{width:i,height:a}=e2(this.data.rect);let l,d;t%180===0?(l=100*i/n,d=100*a/o):(l=100*a/n,d=100*i/o),r.style.width=`${l}%`,r.style.height=`${d}%`,r.setAttribute("data-main-rotation",(360-t)%360)}get _commonActions(){const t=(r,n,o)=>{const i=o.detail[r],a=i[0],l=i.slice(1);o.target.style[n]=sJ[`${a}_HTML`](l),this.annotationStorage.setValue(this.data.id,{[n]:sJ[`${a}_rgb`](l)})};return vn(this,"_commonActions",{display:r=>{const{display:n}=r.detail,o=n%2===1;this.container.style.visibility=o?"hidden":"visible",this.annotationStorage.setValue(this.data.id,{noView:o,noPrint:n===1||n===2})},print:r=>{this.annotationStorage.setValue(this.data.id,{noPrint:!r.detail.print})},hidden:r=>{const{hidden:n}=r.detail;this.container.style.visibility=n?"hidden":"visible",this.annotationStorage.setValue(this.data.id,{noPrint:n,noView:n})},focus:r=>{setTimeout(()=>r.target.focus({preventScroll:!1}),0)},userName:r=>{r.target.title=r.detail.userName},readonly:r=>{r.target.disabled=r.detail.readonly},required:r=>{this._setRequired(r.target,r.detail.required)},bgColor:r=>{t("bgColor","backgroundColor",r)},fillColor:r=>{t("fillColor","backgroundColor",r)},fgColor:r=>{t("fgColor","color",r)},textColor:r=>{t("textColor","color",r)},borderColor:r=>{t("borderColor","borderColor",r)},strokeColor:r=>{t("strokeColor","borderColor",r)},rotation:r=>{const n=r.detail.rotation;this.setRotation(n),this.annotationStorage.setValue(this.data.id,{rotation:n})}})}_dispatchEventFromSandbox(t,r){const n=this._commonActions;for(const o of Object.keys(r.detail))(t[o]||n[o])?.(r)}_setDefaultPropertiesFromJS(t){if(!this.enableScripting)return;const r=this.annotationStorage.getRawValue(this.data.id);if(!r)return;const n=this._commonActions;for(const[o,i]of Object.entries(r)){const a=n[o];if(a){const l={detail:{[o]:i},target:t};a(l),delete r[o]}}}_createQuadrilaterals(){if(!this.container)return;const{quadPoints:t}=this.data;if(!t)return;const[r,n,o,i]=this.data.rect.map(v=>Math.fround(v));if(t.length===8){const[v,w,x,$]=t.subarray(2,6);if(o===v&&i===w&&r===x&&n===$)return}const{style:a}=this.container;let l;if(this.#t){const{borderColor:v,borderWidth:w}=a;a.borderWidth=0,l=["url('data:image/svg+xml;utf8,",'<svg xmlns="http://www.w3.org/2000/svg"',' preserveAspectRatio="none" viewBox="0 0 1 1">',`<g fill="transparent" stroke="${v}" stroke-width="${w}">`],this.container.classList.add("hasBorder")}const d=o-r,u=i-n,{svgFactory:p}=this,h=p.createElement("svg");h.classList.add("quadrilateralsContainer"),h.setAttribute("width",0),h.setAttribute("height",0);const f=p.createElement("defs");h.append(f);const g=p.createElement("clipPath"),y=`clippath_${this.data.id}`;g.setAttribute("id",y),g.setAttribute("clipPathUnits","objectBoundingBox"),f.append(g);for(let v=2,w=t.length;v<w;v+=8){const x=t[v],$=t[v+1],S=t[v+2],k=t[v+3],T=p.createElement("rect"),E=(S-r)/d,A=(i-$)/u,D=(x-S)/d,P=($-k)/u;T.setAttribute("x",E),T.setAttribute("y",A),T.setAttribute("width",D),T.setAttribute("height",P),g.append(T),l?.push(`<rect vector-effect="non-scaling-stroke" x="${E}" y="${A}" width="${D}" height="${P}"/>`)}this.#t&&(l.push("</g></svg>')"),a.backgroundImage=l.join("")),this.container.append(h),this.container.style.clipPath=`url(#${y})`}_createPopup(){const{container:t,data:r}=this;t.setAttribute("aria-haspopup","dialog");const n=this.#r=new pj({data:{color:r.color,titleObj:r.titleObj,modificationDate:r.modificationDate,contentsObj:r.contentsObj,richText:r.richText,parentRect:r.rect,borderStyle:0,id:`popup_${r.id}`,rotation:r.rotation},parent:this.parent,elements:[this]});this.parent.div.append(n.render())}render(){Xn("Abstract method `AnnotationElement.render` called")}_getElementsByName(t,r=null){const n=[];if(this._fieldObjects){const o=this._fieldObjects[t];if(o)for(const{page:i,id:a,exportValues:l}of o){if(i===-1||a===r)continue;const d=typeof l=="string"?l:null,u=document.querySelector(`[data-element-id="${a}"]`);if(u&&!dm.has(u)){Jr(`_getElementsByName - element not allowed: ${a}`);continue}n.push({id:a,exportValue:d,domElement:u})}return n}for(const o of document.getElementsByName(t)){const{exportValue:i}=o,a=o.getAttribute("data-element-id");a!==r&&dm.has(o)&&n.push({id:a,exportValue:i,domElement:o})}return n}show(){this.container&&(this.container.hidden=!1),this.popup?.maybeShow()}hide(){this.container&&(this.container.hidden=!0),this.popup?.forceHide()}getElementsToTriggerPopup(){return this.container}addHighlightArea(){const t=this.getElementsToTriggerPopup();if(Array.isArray(t))for(const r of t)r.classList.add("highlightArea");else t.classList.add("highlightArea")}get _isEditable(){return!1}_editOnDoubleClick(){if(!this._isEditable)return;const{annotationEditorType:t,data:{id:r}}=this;this.container.addEventListener("dblclick",()=>{this.linkService.eventBus?.dispatch("switchannotationeditormode",{source:this,mode:t,editId:r})})}}class d4e extends ti{constructor(t,r=null){super(t,{isRenderable:!0,ignoreBorder:!!r?.ignoreBorder,createQuadrilaterals:!0}),this.isTooltipOnly=t.data.isTooltipOnly}render(){const{data:t,linkService:r}=this,n=document.createElement("a");n.setAttribute("data-element-id",t.id);let o=!1;return t.url?(r.addLinkAttributes(n,t.url,t.newWindow),o=!0):t.action?(this._bindNamedAction(n,t.action),o=!0):t.attachment?(this.#t(n,t.attachment,t.attachmentDest),o=!0):t.setOCGState?(this.#r(n,t.setOCGState),o=!0):t.dest?(this._bindLink(n,t.dest),o=!0):(t.actions&&(t.actions.Action||t.actions["Mouse Up"]||t.actions["Mouse Down"])&&this.enableScripting&&this.hasJSActions&&(this._bindJSAction(n,t),o=!0),t.resetForm?(this._bindResetFormAction(n,t.resetForm),o=!0):this.isTooltipOnly&&!o&&(this._bindLink(n,""),o=!0)),this.container.classList.add("linkAnnotation"),o&&this.container.append(n),this.container}#e(){this.container.setAttribute("data-internal-link","")}_bindLink(t,r){t.href=this.linkService.getDestinationHash(r),t.onclick=()=>(r&&this.linkService.goToDestination(r),!1),(r||r==="")&&this.#e()}_bindNamedAction(t,r){t.href=this.linkService.getAnchorUrl(""),t.onclick=()=>(this.linkService.executeNamedAction(r),!1),this.#e()}#t(t,r,n=null){t.href=this.linkService.getAnchorUrl(""),r.description&&(t.title=r.description),t.onclick=()=>(this.downloadManager?.openOrDownloadData(r.content,r.filename,n),!1),this.#e()}#r(t,r){t.href=this.linkService.getAnchorUrl(""),t.onclick=()=>(this.linkService.executeSetOCGState(r),!1),this.#e()}_bindJSAction(t,r){t.href=this.linkService.getAnchorUrl("");const n=new Map([["Action","onclick"],["Mouse Up","onmouseup"],["Mouse Down","onmousedown"]]);for(const o of Object.keys(r.actions)){const i=n.get(o);i&&(t[i]=()=>(this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:r.id,name:o}}),!1))}t.onclick||(t.onclick=()=>!1),this.#e()}_bindResetFormAction(t,r){const n=t.onclick;if(n||(t.href=this.linkService.getAnchorUrl("")),this.#e(),!this._fieldObjects){Jr('_bindResetFormAction - "resetForm" action not supported, ensure that the `fieldObjects` parameter is provided.'),n||(t.onclick=()=>!1);return}t.onclick=()=>{n?.();const{fields:o,refs:i,include:a}=r,l=[];if(o.length!==0||i.length!==0){const p=new Set(i);for(const h of o){const f=this._fieldObjects[h]||[];for(const{id:g}of f)p.add(g)}for(const h of Object.values(this._fieldObjects))for(const f of h)p.has(f.id)===a&&l.push(f)}else for(const p of Object.values(this._fieldObjects))l.push(...p);const d=this.annotationStorage,u=[];for(const p of l){const{id:h}=p;switch(u.push(h),p.type){case"text":{const g=p.defaultValue||"";d.setValue(h,{value:g});break}case"checkbox":case"radiobutton":{const g=p.defaultValue===p.exportValues;d.setValue(h,{value:g});break}case"combobox":case"listbox":{const g=p.defaultValue||"";d.setValue(h,{value:g});break}default:continue}const f=document.querySelector(`[data-element-id="${h}"]`);if(f){if(!dm.has(f)){Jr(`_bindResetFormAction - element not allowed: ${h}`);continue}}else continue;f.dispatchEvent(new Event("resetform"))}return this.enableScripting&&this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:"app",ids:u,name:"ResetForm"}}),!1}}}class rpt extends ti{constructor(t){super(t,{isRenderable:!0})}render(){this.container.classList.add("textAnnotation");const t=document.createElement("img");return t.src=this.imageResourcesPath+"annotation-"+this.data.name.toLowerCase()+".svg",t.setAttribute("data-l10n-id","pdfjs-text-annotation-type"),t.setAttribute("data-l10n-args",JSON.stringify({type:this.data.name})),!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container.append(t),this.container}}class Dm extends ti{render(){return this.container}showElementAndHideCanvas(t){this.data.hasOwnCanvas&&(t.previousSibling?.nodeName==="CANVAS"&&(t.previousSibling.hidden=!0),t.hidden=!1)}_getKeyModifier(t){return bs.platform.isMac?t.metaKey:t.ctrlKey}_setEventListener(t,r,n,o,i){n.includes("mouse")?t.addEventListener(n,a=>{this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:this.data.id,name:o,value:i(a),shift:a.shiftKey,modifier:this._getKeyModifier(a)}})}):t.addEventListener(n,a=>{if(n==="blur"){if(!r.focused||!a.relatedTarget)return;r.focused=!1}else if(n==="focus"){if(r.focused)return;r.focused=!0}i&&this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:this.data.id,name:o,value:i(a)}})})}_setEventListeners(t,r,n,o){for(const[i,a]of n)(a==="Action"||this.data.actions?.[a])&&((a==="Focus"||a==="Blur")&&(r||={focused:!1}),this._setEventListener(t,r,i,a,o),a==="Focus"&&!this.data.actions?.Blur?this._setEventListener(t,r,"blur","Blur",null):a==="Blur"&&!this.data.actions?.Focus&&this._setEventListener(t,r,"focus","Focus",null))}_setBackgroundColor(t){const r=this.data.backgroundColor||null;t.style.backgroundColor=r===null?"transparent":lr.makeHexColor(r[0],r[1],r[2])}_setTextStyle(t){const r=["left","center","right"],{fontColor:n}=this.data.defaultAppearanceData,o=this.data.defaultAppearanceData.fontSize||ept,i=t.style;let a;const l=2,d=u=>Math.round(10*u)/10;if(this.data.multiLine){const u=Math.abs(this.data.rect[3]-this.data.rect[1]-l),p=Math.round(u/(iL*o))||1,h=u/p;a=Math.min(o,d(h/iL))}else{const u=Math.abs(this.data.rect[3]-this.data.rect[1]-l);a=Math.min(o,d(u/iL))}i.fontSize=`calc(${a}px * var(--scale-factor))`,i.color=lr.makeHexColor(n[0],n[1],n[2]),this.data.textAlignment!==null&&(i.textAlign=r[this.data.textAlignment])}_setRequired(t,r){r?t.setAttribute("required",!0):t.removeAttribute("required"),t.setAttribute("aria-required",r)}}class npt extends Dm{constructor(t){const r=t.renderForms||t.data.hasOwnCanvas||!t.data.hasAppearance&&!!t.data.fieldValue;super(t,{isRenderable:r})}setPropertyOnSiblings(t,r,n,o){const i=this.annotationStorage;for(const a of this._getElementsByName(t.name,t.id))a.domElement&&(a.domElement[r]=n),i.setValue(a.id,{[o]:n})}render(){const t=this.annotationStorage,r=this.data.id;this.container.classList.add("textWidgetAnnotation");let n=null;if(this.renderForms){const o=t.getValue(r,{value:this.data.fieldValue});let i=o.value||"";const a=t.getValue(r,{charLimit:this.data.maxLen}).charLimit;a&&i.length>a&&(i=i.slice(0,a));let l=o.formattedValue||this.data.textContent?.join(`
289
+ `);return t.join("")}}function P5(e,t){try{const{protocol:r}=t?new URL(e,t):new URL(e);return r==="http:"||r==="https:"}catch{return!1}}function $s(e){e.preventDefault()}function Zge(e){console.log("Deprecated API usage: "+e)}let YQ;class Kge{static toDateObject(t){if(!t||typeof t!="string")return null;YQ||=new RegExp("^D:(\\d{4})(\\d{2})?(\\d{2})?(\\d{2})?(\\d{2})?(\\d{2})?([Z|+|-])?(\\d{2})?'?(\\d{2})?'?");const r=YQ.exec(t);if(!r)return null;const n=parseInt(r[1],10);let o=parseInt(r[2],10);o=o>=1&&o<=12?o-1:0;let i=parseInt(r[3],10);i=i>=1&&i<=31?i:1;let a=parseInt(r[4],10);a=a>=0&&a<=23?a:0;let l=parseInt(r[5],10);l=l>=0&&l<=59?l:0;let d=parseInt(r[6],10);d=d>=0&&d<=59?d:0;const u=r[7]||"Z";let p=parseInt(r[8],10);p=p>=0&&p<=23?p:0;let h=parseInt(r[9],10)||0;return h=h>=0&&h<=59?h:0,u==="-"?(a+=p,l+=h):u==="+"&&(a-=p,l-=h),new Date(Date.UTC(n,o,i,a,l,d))}}function B2t(e,{scale:t=1,rotation:r=0}){const{width:n,height:o}=e.attributes.style,i=[0,0,parseInt(n),parseInt(o)];return new u6({viewBox:i,scale:t,rotation:r})}function KO(e){if(e.startsWith("#")){const t=parseInt(e.slice(1),16);return[(t&16711680)>>16,(t&65280)>>8,t&255]}return e.startsWith("rgb(")?e.slice(4,-1).split(",").map(t=>parseInt(t)):e.startsWith("rgba(")?e.slice(5,-1).split(",").map(t=>parseInt(t)).slice(0,3):(Jr(`Not a valid color format: "${e}"`),[0,0,0])}function H2t(e){const t=document.createElement("span");t.style.visibility="hidden",document.body.append(t);for(const r of e.keys()){t.style.color=r;const n=window.getComputedStyle(t).color;e.set(r,KO(n))}t.remove()}function Io(e){const{a:t,b:r,c:n,d:o,e:i,f:a}=e.getTransform();return[t,r,n,o,i,a]}function fu(e){const{a:t,b:r,c:n,d:o,e:i,f:a}=e.getTransform().invertSelf();return[t,r,n,o,i,a]}function cm(e,t,r=!1,n=!0){if(t instanceof u6){const{pageWidth:o,pageHeight:i}=t.rawDims,{style:a}=e,l=bs.isCSSRoundSupported,d=`var(--scale-factor) * ${o}px`,u=`var(--scale-factor) * ${i}px`,p=l?`round(${d}, 1px)`:`calc(${d})`,h=l?`round(${u}, 1px)`:`calc(${u})`;!r||t.rotation%180===0?(a.width=p,a.height=h):(a.width=h,a.height=p)}n&&e.setAttribute("data-main-rotation",t.rotation)}class XO{#e=null;#t=null;#r;#o=null;constructor(t){this.#r=t}render(){const t=this.#e=document.createElement("div");t.className="editToolbar",t.setAttribute("role","toolbar");const r=this.#r._uiManager._signal;t.addEventListener("contextmenu",$s,{signal:r}),t.addEventListener("pointerdown",XO.#s,{signal:r});const n=this.#o=document.createElement("div");n.className="buttons",t.append(n);const o=this.#r.toolbarPosition;if(o){const{style:i}=t,a=this.#r._uiManager.direction==="ltr"?1-o[0]:o[0];i.insetInlineEnd=`${100*a}%`,i.top=`calc(${100*o[1]}% + var(--editor-toolbar-vert-offset))`}return this.#d(),t}static#s(t){t.stopPropagation()}#n(t){this.#r._focusEventsAllowed=!1,t.preventDefault(),t.stopPropagation()}#i(t){this.#r._focusEventsAllowed=!0,t.preventDefault(),t.stopPropagation()}#l(t){const r=this.#r._uiManager._signal;t.addEventListener("focusin",this.#n.bind(this),{capture:!0,signal:r}),t.addEventListener("focusout",this.#i.bind(this),{capture:!0,signal:r}),t.addEventListener("contextmenu",$s,{signal:r})}hide(){this.#e.classList.add("hidden"),this.#t?.hideDropdown()}show(){this.#e.classList.remove("hidden")}#d(){const t=document.createElement("button");t.className="delete",t.tabIndex=0,t.setAttribute("data-l10n-id",`pdfjs-editor-remove-${this.#r.editorType}-button`),this.#l(t),t.addEventListener("click",r=>{this.#r._uiManager.delete()},{signal:this.#r._uiManager._signal}),this.#o.append(t)}get#u(){const t=document.createElement("div");return t.className="divider",t}addAltTextButton(t){this.#l(t),this.#o.prepend(t,this.#u)}addColorPicker(t){this.#t=t;const r=t.renderButton();this.#l(r),this.#o.prepend(r,this.#u)}remove(){this.#e.remove(),this.#t?.destroy(),this.#t=null}}class V2t{#e=null;#t=null;#r;constructor(t){this.#r=t}#o(){const t=this.#t=document.createElement("div");t.className="editToolbar",t.setAttribute("role","toolbar"),t.addEventListener("contextmenu",$s,{signal:this.#r._signal});const r=this.#e=document.createElement("div");return r.className="buttons",t.append(r),this.#n(),t}#s(t,r){let n=0,o=0;for(const i of t){const a=i.y+i.height;if(a<n)continue;const l=i.x+(r?i.width:0);if(a>n){o=l,n=a;continue}r?l>o&&(o=l):l<o&&(o=l)}return[r?1-o:o,n]}show(t,r,n){const[o,i]=this.#s(r,n),{style:a}=this.#t||=this.#o();t.append(this.#t),a.insetInlineEnd=`${100*o}%`,a.top=`calc(${100*i}% + var(--editor-toolbar-vert-offset))`}hide(){this.#t.remove()}#n(){const t=document.createElement("button");t.className="highlightButton",t.tabIndex=0,t.setAttribute("data-l10n-id","pdfjs-highlight-floating-button1");const r=document.createElement("span");t.append(r),r.className="visuallyHidden",r.setAttribute("data-l10n-id","pdfjs-highlight-floating-button-label");const n=this.#r._signal;t.addEventListener("contextmenu",$s,{signal:n}),t.addEventListener("click",()=>{this.#r.highlightSelection("floating_button")},{signal:n}),this.#e.append(t)}}function ob(e,t,r){for(const n of r)t.addEventListener(n,e[n].bind(e))}function U2t(e){return Math.round(Math.min(255,Math.max(1,255*e))).toString(16).padStart(2,"0")}class W2t{#e=0;get id(){return`${$2t}${this.#e++}`}}class QO{#e=R2t();#t=0;#r=null;static get _isSVGFittingCanvas(){const t='data:image/svg+xml;charset=UTF-8,<svg viewBox="0 0 1 1" width="1" height="1" xmlns="http://www.w3.org/2000/svg"><rect width="1" height="1" style="fill:red;"/></svg>',n=new OffscreenCanvas(1,3).getContext("2d",{willReadFrequently:!0}),o=new Image;o.src=t;const i=o.decode().then(()=>(n.drawImage(o,0,0,1,1,0,0,1,3),new Uint32Array(n.getImageData(0,0,1,1).data.buffer)[0]===0));return vn(this,"_isSVGFittingCanvas",i)}async#o(t,r){this.#r||=new Map;let n=this.#r.get(t);if(n===null)return null;if(n?.bitmap)return n.refCounter+=1,n;try{n||={bitmap:null,id:`image_${this.#e}_${this.#t++}`,refCounter:0,isSvg:!1};let o;if(typeof r=="string"?(n.url=r,o=await Ax(r,"blob")):o=n.file=r,o.type==="image/svg+xml"){const i=QO._isSVGFittingCanvas,a=new FileReader,l=new Image,d=new Promise((u,p)=>{l.onload=()=>{n.bitmap=l,n.isSvg=!0,u()},a.onload=async()=>{const h=n.svgUrl=a.result;l.src=await i?`${h}#svgView(preserveAspectRatio(none))`:h},l.onerror=a.onerror=p});a.readAsDataURL(o),await d}else n.bitmap=await createImageBitmap(o);n.refCounter=1}catch(o){console.error(o),n=null}return this.#r.set(t,n),n&&this.#r.set(n.id,n),n}async getFromFile(t){const{lastModified:r,name:n,size:o,type:i}=t;return this.#o(`${r}_${n}_${o}_${i}`,t)}async getFromUrl(t){return this.#o(t,t)}async getFromId(t){this.#r||=new Map;const r=this.#r.get(t);return r?r.bitmap?(r.refCounter+=1,r):r.file?this.getFromFile(r.file):this.getFromUrl(r.url):null}getSvgUrl(t){const r=this.#r.get(t);return r?.isSvg?r.svgUrl:null}deleteId(t){this.#r||=new Map;const r=this.#r.get(t);r&&(r.refCounter-=1,r.refCounter===0&&(r.bitmap=null))}isValidId(t){return t.startsWith(`image_${this.#e}_`)}}class Y2t{#e=[];#t=!1;#r;#o=-1;constructor(t=128){this.#r=t}add({cmd:t,undo:r,post:n,mustExec:o,type:i=NaN,overwriteIfSameType:a=!1,keepUndo:l=!1}){if(o&&t(),this.#t)return;const d={cmd:t,undo:r,post:n,type:i};if(this.#o===-1){this.#e.length>0&&(this.#e.length=0),this.#o=0,this.#e.push(d);return}if(a&&this.#e[this.#o].type===i){l&&(d.undo=this.#e[this.#o].undo),this.#e[this.#o]=d;return}const u=this.#o+1;u===this.#r?this.#e.splice(0,1):(this.#o=u,u<this.#e.length&&this.#e.splice(u)),this.#e.push(d)}undo(){if(this.#o===-1)return;this.#t=!0;const{undo:t,post:r}=this.#e[this.#o];t(),r?.(),this.#t=!1,this.#o-=1}redo(){if(this.#o<this.#e.length-1){this.#o+=1,this.#t=!0;const{cmd:t,post:r}=this.#e[this.#o];t(),r?.(),this.#t=!1}}hasSomethingToUndo(){return this.#o!==-1}hasSomethingToRedo(){return this.#o<this.#e.length-1}destroy(){this.#e=null}}class p6{constructor(t){this.buffer=[],this.callbacks=new Map,this.allKeys=new Set;const{isMac:r}=bs.platform;for(const[n,o,i={}]of t)for(const a of n){const l=a.startsWith("mac+");r&&l?(this.callbacks.set(a.slice(4),{callback:o,options:i}),this.allKeys.add(a.split("+").at(-1))):!r&&!l&&(this.callbacks.set(a,{callback:o,options:i}),this.allKeys.add(a.split("+").at(-1)))}}#e(t){t.altKey&&this.buffer.push("alt"),t.ctrlKey&&this.buffer.push("ctrl"),t.metaKey&&this.buffer.push("meta"),t.shiftKey&&this.buffer.push("shift"),this.buffer.push(t.key);const r=this.buffer.join("+");return this.buffer.length=0,r}exec(t,r){if(!this.allKeys.has(r.key))return;const n=this.callbacks.get(this.#e(r));if(!n)return;const{callback:o,options:{bubbles:i=!1,args:a=[],checker:l=null}}=n;l&&!l(t,r)||(o.bind(t,...a,r)(),i||(r.stopPropagation(),r.preventDefault()))}}class JO{static _colorsMapping=new Map([["CanvasText",[0,0,0]],["Canvas",[255,255,255]]]);get _colors(){const t=new Map([["CanvasText",null],["Canvas",null]]);return H2t(t),vn(this,"_colors",t)}convert(t){const r=KO(t);if(!window.matchMedia("(forced-colors: active)").matches)return r;for(const[n,o]of this._colors)if(o.every((i,a)=>i===r[a]))return JO._colorsMapping.get(n);return r}getHexCode(t){const r=this._colors.get(t);return r?lr.makeHexColor(...r):t}}class I0{#e=new AbortController;#t=null;#r=new Map;#o=new Map;#s=null;#n=null;#i=null;#l=new Y2t;#d=0;#u=new Set;#h=null;#c=null;#a=new Set;#m=!1;#g=null;#p=null;#v=null;#f=!1;#b=null;#x=new W2t;#$=!1;#k=!1;#E=null;#L=null;#S=null;#w=hn.NONE;#y=new Set;#C=null;#_=null;#T=null;#M=this.blur.bind(this);#D=this.focus.bind(this);#j=this.copy.bind(this);#P=this.cut.bind(this);#R=this.paste.bind(this);#I=this.keydown.bind(this);#U=this.keyup.bind(this);#W=this.onEditingAction.bind(this);#H=this.onPageChanging.bind(this);#z=this.onScaleChanging.bind(this);#F=this.onRotationChanging.bind(this);#Z={isEditing:!1,isEmpty:!0,hasSomethingToUndo:!1,hasSomethingToRedo:!1,hasSelectedEditor:!1,hasSelectedText:!1};#V=[0,0];#O=null;#B=null;#K=null;static TRANSLATE_SMALL=1;static TRANSLATE_BIG=10;static get _keyboardManager(){const t=I0.prototype,r=a=>a.#B.contains(document.activeElement)&&document.activeElement.tagName!=="BUTTON"&&a.hasSomethingToControl(),n=(a,{target:l})=>{if(l instanceof HTMLInputElement){const{type:d}=l;return d!=="text"&&d!=="number"}return!0},o=this.TRANSLATE_SMALL,i=this.TRANSLATE_BIG;return vn(this,"_keyboardManager",new p6([[["ctrl+a","mac+meta+a"],t.selectAll,{checker:n}],[["ctrl+z","mac+meta+z"],t.undo,{checker:n}],[["ctrl+y","ctrl+shift+z","mac+meta+shift+z","ctrl+shift+Z","mac+meta+shift+Z"],t.redo,{checker:n}],[["Backspace","alt+Backspace","ctrl+Backspace","shift+Backspace","mac+Backspace","mac+alt+Backspace","mac+ctrl+Backspace","Delete","ctrl+Delete","shift+Delete","mac+Delete"],t.delete,{checker:n}],[["Enter","mac+Enter"],t.addNewEditorFromKeyboard,{checker:(a,{target:l})=>!(l instanceof HTMLButtonElement)&&a.#B.contains(l)&&!a.isEnterHandled}],[[" ","mac+ "],t.addNewEditorFromKeyboard,{checker:(a,{target:l})=>!(l instanceof HTMLButtonElement)&&a.#B.contains(document.activeElement)}],[["Escape","mac+Escape"],t.unselectAll],[["ArrowLeft","mac+ArrowLeft"],t.translateSelectedEditors,{args:[-o,0],checker:r}],[["ctrl+ArrowLeft","mac+shift+ArrowLeft"],t.translateSelectedEditors,{args:[-i,0],checker:r}],[["ArrowRight","mac+ArrowRight"],t.translateSelectedEditors,{args:[o,0],checker:r}],[["ctrl+ArrowRight","mac+shift+ArrowRight"],t.translateSelectedEditors,{args:[i,0],checker:r}],[["ArrowUp","mac+ArrowUp"],t.translateSelectedEditors,{args:[0,-o],checker:r}],[["ctrl+ArrowUp","mac+shift+ArrowUp"],t.translateSelectedEditors,{args:[0,-i],checker:r}],[["ArrowDown","mac+ArrowDown"],t.translateSelectedEditors,{args:[0,o],checker:r}],[["ctrl+ArrowDown","mac+shift+ArrowDown"],t.translateSelectedEditors,{args:[0,i],checker:r}]]))}constructor(t,r,n,o,i,a,l,d,u){this._signal=this.#e.signal,this.#B=t,this.#K=r,this.#s=n,this._eventBus=o,this._eventBus._on("editingaction",this.#W),this._eventBus._on("pagechanging",this.#H),this._eventBus._on("scalechanging",this.#z),this._eventBus._on("rotationchanging",this.#F),this.#oe(),this.#le(),this.#X(),this.#n=i.annotationStorage,this.#g=i.filterFactory,this.#_=a,this.#v=l||null,this.#m=d,this.#S=u||null,this.viewParameters={realScale:Qf.PDF_TO_CSS_UNITS,rotation:0},this.isShiftKeyDown=!1}destroy(){this.#e?.abort(),this.#e=null,this._signal=null,this._eventBus._off("editingaction",this.#W),this._eventBus._off("pagechanging",this.#H),this._eventBus._off("scalechanging",this.#z),this._eventBus._off("rotationchanging",this.#F);for(const t of this.#o.values())t.destroy();this.#o.clear(),this.#r.clear(),this.#a.clear(),this.#t=null,this.#y.clear(),this.#l.destroy(),this.#s?.destroy(),this.#b?.hide(),this.#b=null,this.#p&&(clearTimeout(this.#p),this.#p=null),this.#O&&(clearTimeout(this.#O),this.#O=null)}async mlGuess(t){return this.#S?.guess(t)||null}get hasMLManager(){return!!this.#S}get hcmFilter(){return vn(this,"hcmFilter",this.#_?this.#g.addHCMFilter(this.#_.foreground,this.#_.background):"none")}get direction(){return vn(this,"direction",getComputedStyle(this.#B).direction)}get highlightColors(){return vn(this,"highlightColors",this.#v?new Map(this.#v.split(",").map(t=>t.split("=").map(r=>r.trim()))):null)}get highlightColorNames(){return vn(this,"highlightColorNames",this.highlightColors?new Map(Array.from(this.highlightColors,t=>t.reverse())):null)}setMainHighlightColorPicker(t){this.#L=t}editAltText(t){this.#s?.editAltText(this,t)}onPageChanging({pageNumber:t}){this.#d=t-1}focusMainContainer(){this.#B.focus()}findParent(t,r){for(const n of this.#o.values()){const{x:o,y:i,width:a,height:l}=n.div.getBoundingClientRect();if(t>=o&&t<=o+a&&r>=i&&r<=i+l)return n}return null}disableUserSelect(t=!1){this.#K.classList.toggle("noUserSelect",t)}addShouldRescale(t){this.#a.add(t)}removeShouldRescale(t){this.#a.delete(t)}onScaleChanging({scale:t}){this.commitOrRemove(),this.viewParameters.realScale=t*Qf.PDF_TO_CSS_UNITS;for(const r of this.#a)r.onScaleChanging()}onRotationChanging({pagesRotation:t}){this.commitOrRemove(),this.viewParameters.rotation=t}#G({anchorNode:t}){return t.nodeType===Node.TEXT_NODE?t.parentElement:t}highlightSelection(t=""){const r=document.getSelection();if(!r||r.isCollapsed)return;const{anchorNode:n,anchorOffset:o,focusNode:i,focusOffset:a}=r,l=r.toString(),u=this.#G(r).closest(".textLayer"),p=this.getSelectionBoxes(u);if(p){r.empty(),this.#w===hn.NONE&&(this._eventBus.dispatch("showannotationeditorui",{source:this,mode:hn.HIGHLIGHT}),this.showAllEditors("highlight",!0,!0));for(const h of this.#o.values())if(h.hasTextLayer(u)){h.createAndAddNewEditor({x:0,y:0},!1,{methodOfCreation:t,boxes:p,anchorNode:n,anchorOffset:o,focusNode:i,focusOffset:a,text:l});break}}}#re(){const t=document.getSelection();if(!t||t.isCollapsed)return;const n=this.#G(t).closest(".textLayer"),o=this.getSelectionBoxes(n);o&&(this.#b||=new V2t(this),this.#b.show(n,o,this.direction==="ltr"))}addToAnnotationStorage(t){!t.isEmpty()&&this.#n&&!this.#n.has(t.id)&&this.#n.setValue(t.id,t)}#ne(){const t=document.getSelection();if(!t||t.isCollapsed){this.#C&&(this.#b?.hide(),this.#C=null,this.#A({hasSelectedText:!1}));return}const{anchorNode:r}=t;if(r===this.#C)return;if(!this.#G(t).closest(".textLayer")){this.#C&&(this.#b?.hide(),this.#C=null,this.#A({hasSelectedText:!1}));return}if(this.#b?.hide(),this.#C=r,this.#A({hasSelectedText:!0}),!(this.#w!==hn.HIGHLIGHT&&this.#w!==hn.NONE)&&(this.#w===hn.HIGHLIGHT&&this.showAllEditors("highlight",!0,!0),this.#f=this.isShiftKeyDown,!this.isShiftKeyDown)){const i=this._signal,a=l=>{l.type==="pointerup"&&l.button!==0||(window.removeEventListener("pointerup",a),window.removeEventListener("blur",a),l.type==="pointerup"&&this.#q("main_toolbar"))};window.addEventListener("pointerup",a,{signal:i}),window.addEventListener("blur",a,{signal:i})}}#q(t=""){this.#w===hn.HIGHLIGHT?this.highlightSelection(t):this.#m&&this.#re()}#oe(){document.addEventListener("selectionchange",this.#ne.bind(this),{signal:this._signal})}#ie(){const t=this._signal;window.addEventListener("focus",this.#D,{signal:t}),window.addEventListener("blur",this.#M,{signal:t})}#ae(){window.removeEventListener("focus",this.#D),window.removeEventListener("blur",this.#M)}blur(){if(this.isShiftKeyDown=!1,this.#f&&(this.#f=!1,this.#q("main_toolbar")),!this.hasSelection)return;const{activeElement:t}=document;for(const r of this.#y)if(r.div.contains(t)){this.#E=[r,t],r._focusEventsAllowed=!1;break}}focus(){if(!this.#E)return;const[t,r]=this.#E;this.#E=null,r.addEventListener("focusin",()=>{t._focusEventsAllowed=!0},{once:!0,signal:this._signal}),r.focus()}#X(){const t=this._signal;window.addEventListener("keydown",this.#I,{signal:t}),window.addEventListener("keyup",this.#U,{signal:t})}#se(){window.removeEventListener("keydown",this.#I),window.removeEventListener("keyup",this.#U)}#Q(){const t=this._signal;document.addEventListener("copy",this.#j,{signal:t}),document.addEventListener("cut",this.#P,{signal:t}),document.addEventListener("paste",this.#R,{signal:t})}#J(){document.removeEventListener("copy",this.#j),document.removeEventListener("cut",this.#P),document.removeEventListener("paste",this.#R)}#le(){const t=this._signal;document.addEventListener("dragover",this.dragOver.bind(this),{signal:t}),document.addEventListener("drop",this.drop.bind(this),{signal:t})}addEditListeners(){this.#X(),this.#Q()}removeEditListeners(){this.#se(),this.#J()}dragOver(t){for(const{type:r}of t.dataTransfer.items)for(const n of this.#c)if(n.isHandlingMimeForPasting(r)){t.dataTransfer.dropEffect="copy",t.preventDefault();return}}drop(t){for(const r of t.dataTransfer.items)for(const n of this.#c)if(n.isHandlingMimeForPasting(r.type)){n.paste(r,this.currentLayer),t.preventDefault();return}}copy(t){if(t.preventDefault(),this.#t?.commitOrRemove(),!this.hasSelection)return;const r=[];for(const n of this.#y){const o=n.serialize(!0);o&&r.push(o)}r.length!==0&&t.clipboardData.setData("application/pdfjs",JSON.stringify(r))}cut(t){this.copy(t),this.delete()}paste(t){t.preventDefault();const{clipboardData:r}=t;for(const i of r.items)for(const a of this.#c)if(a.isHandlingMimeForPasting(i.type)){a.paste(i,this.currentLayer);return}let n=r.getData("application/pdfjs");if(!n)return;try{n=JSON.parse(n)}catch(i){Jr(`paste: "${i.message}".`);return}if(!Array.isArray(n))return;this.unselectAll();const o=this.currentLayer;try{const i=[];for(const d of n){const u=o.deserialize(d);if(!u)return;i.push(u)}const a=()=>{for(const d of i)this.#ee(d);this.#te(i)},l=()=>{for(const d of i)d.remove()};this.addCommands({cmd:a,undo:l,mustExec:!0})}catch(i){Jr(`paste: "${i.message}".`)}}keydown(t){!this.isShiftKeyDown&&t.key==="Shift"&&(this.isShiftKeyDown=!0),this.#w!==hn.NONE&&!this.isEditorHandlingKeyboard&&I0._keyboardManager.exec(this,t)}keyup(t){this.isShiftKeyDown&&t.key==="Shift"&&(this.isShiftKeyDown=!1,this.#f&&(this.#f=!1,this.#q("main_toolbar")))}onEditingAction({name:t}){switch(t){case"undo":case"redo":case"delete":case"selectAll":this[t]();break;case"highlightSelection":this.highlightSelection("context_menu");break}}#A(t){Object.entries(t).some(([n,o])=>this.#Z[n]!==o)&&(this._eventBus.dispatch("annotationeditorstateschanged",{source:this,details:Object.assign(this.#Z,t)}),this.#w===hn.HIGHLIGHT&&t.hasSelectedEditor===!1&&this.#N([[Lr.HIGHLIGHT_FREE,!0]]))}#N(t){this._eventBus.dispatch("annotationeditorparamschanged",{source:this,details:t})}setEditingState(t){t?(this.#ie(),this.#Q(),this.#A({isEditing:this.#w!==hn.NONE,isEmpty:this.#Y(),hasSomethingToUndo:this.#l.hasSomethingToUndo(),hasSomethingToRedo:this.#l.hasSomethingToRedo(),hasSelectedEditor:!1})):(this.#ae(),this.#J(),this.#A({isEditing:!1}),this.disableUserSelect(!1))}registerEditorTypes(t){if(!this.#c){this.#c=t;for(const r of this.#c)this.#N(r.defaultPropertiesToUpdate)}}getId(){return this.#x.id}get currentLayer(){return this.#o.get(this.#d)}getLayer(t){return this.#o.get(t)}get currentPageIndex(){return this.#d}addLayer(t){this.#o.set(t.pageIndex,t),this.#$?t.enable():t.disable()}removeLayer(t){this.#o.delete(t.pageIndex)}updateMode(t,r=null,n=!1){if(this.#w!==t){if(this.#w=t,t===hn.NONE){this.setEditingState(!1),this.#de();return}this.setEditingState(!0),this.#ce(),this.unselectAll();for(const o of this.#o.values())o.updateMode(t);if(!r&&n){this.addNewEditorFromKeyboard();return}if(r){for(const o of this.#r.values())if(o.annotationElementId===r){this.setSelected(o),o.enterInEditMode();break}}}}addNewEditorFromKeyboard(){this.currentLayer.canCreateNewEmptyEditor()&&this.currentLayer.addNewEditor()}updateToolbar(t){t!==this.#w&&this._eventBus.dispatch("switchannotationeditormode",{source:this,mode:t})}updateParams(t,r){if(this.#c){switch(t){case Lr.CREATE:this.currentLayer.addNewEditor();return;case Lr.HIGHLIGHT_DEFAULT_COLOR:this.#L?.updateColor(r);break;case Lr.HIGHLIGHT_SHOW_ALL:this._eventBus.dispatch("reporttelemetry",{source:this,details:{type:"editing",data:{type:"highlight",action:"toggle_visibility"}}}),(this.#T||=new Map).set(t,r),this.showAllEditors("highlight",r);break}for(const n of this.#y)n.updateParams(t,r);for(const n of this.#c)n.updateDefaultParams(t,r)}}showAllEditors(t,r,n=!1){for(const i of this.#r.values())i.editorType===t&&i.show(r);(this.#T?.get(Lr.HIGHLIGHT_SHOW_ALL)??!0)!==r&&this.#N([[Lr.HIGHLIGHT_SHOW_ALL,r]])}enableWaiting(t=!1){if(this.#k!==t){this.#k=t;for(const r of this.#o.values())t?r.disableClick():r.enableClick(),r.div.classList.toggle("waiting",t)}}#ce(){if(!this.#$){this.#$=!0;for(const t of this.#o.values())t.enable();for(const t of this.#r.values())t.enable()}}#de(){if(this.unselectAll(),this.#$){this.#$=!1;for(const t of this.#o.values())t.disable();for(const t of this.#r.values())t.disable()}}getEditors(t){const r=[];for(const n of this.#r.values())n.pageIndex===t&&r.push(n);return r}getEditor(t){return this.#r.get(t)}addEditor(t){this.#r.set(t.id,t)}removeEditor(t){t.div.contains(document.activeElement)&&(this.#p&&clearTimeout(this.#p),this.#p=setTimeout(()=>{this.focusMainContainer(),this.#p=null},0)),this.#r.delete(t.id),this.unselect(t),(!t.annotationElementId||!this.#u.has(t.annotationElementId))&&this.#n?.remove(t.id)}addDeletedAnnotationElement(t){this.#u.add(t.annotationElementId),this.addChangedExistingAnnotation(t),t.deleted=!0}isDeletedAnnotationElement(t){return this.#u.has(t)}removeDeletedAnnotationElement(t){this.#u.delete(t.annotationElementId),this.removeChangedExistingAnnotation(t),t.deleted=!1}#ee(t){const r=this.#o.get(t.pageIndex);r?r.addOrRebuild(t):(this.addEditor(t),this.addToAnnotationStorage(t))}setActiveEditor(t){this.#t!==t&&(this.#t=t,t&&this.#N(t.propertiesToUpdate))}get#ue(){let t=null;for(t of this.#y);return t}updateUI(t){this.#ue===t&&this.#N(t.propertiesToUpdate)}toggleSelected(t){if(this.#y.has(t)){this.#y.delete(t),t.unselect(),this.#A({hasSelectedEditor:this.hasSelection});return}this.#y.add(t),t.select(),this.#N(t.propertiesToUpdate),this.#A({hasSelectedEditor:!0})}setSelected(t){for(const r of this.#y)r!==t&&r.unselect();this.#y.clear(),this.#y.add(t),t.select(),this.#N(t.propertiesToUpdate),this.#A({hasSelectedEditor:!0})}isSelected(t){return this.#y.has(t)}get firstSelectedEditor(){return this.#y.values().next().value}unselect(t){t.unselect(),this.#y.delete(t),this.#A({hasSelectedEditor:this.hasSelection})}get hasSelection(){return this.#y.size!==0}get isEnterHandled(){return this.#y.size===1&&this.firstSelectedEditor.isEnterHandled}undo(){this.#l.undo(),this.#A({hasSomethingToUndo:this.#l.hasSomethingToUndo(),hasSomethingToRedo:!0,isEmpty:this.#Y()})}redo(){this.#l.redo(),this.#A({hasSomethingToUndo:!0,hasSomethingToRedo:this.#l.hasSomethingToRedo(),isEmpty:this.#Y()})}addCommands(t){this.#l.add(t),this.#A({hasSomethingToUndo:!0,hasSomethingToRedo:!1,isEmpty:this.#Y()})}#Y(){if(this.#r.size===0)return!0;if(this.#r.size===1)for(const t of this.#r.values())return t.isEmpty();return!1}delete(){if(this.commitOrRemove(),!this.hasSelection)return;const t=[...this.#y],r=()=>{for(const o of t)o.remove()},n=()=>{for(const o of t)this.#ee(o)};this.addCommands({cmd:r,undo:n,mustExec:!0})}commitOrRemove(){this.#t?.commitOrRemove()}hasSomethingToControl(){return this.#t||this.hasSelection}#te(t){for(const r of this.#y)r.unselect();this.#y.clear();for(const r of t)r.isEmpty()||(this.#y.add(r),r.select());this.#A({hasSelectedEditor:this.hasSelection})}selectAll(){for(const t of this.#y)t.commit();this.#te(this.#r.values())}unselectAll(){if(!(this.#t&&(this.#t.commitOrRemove(),this.#w!==hn.NONE))&&this.hasSelection){for(const t of this.#y)t.unselect();this.#y.clear(),this.#A({hasSelectedEditor:!1})}}translateSelectedEditors(t,r,n=!1){if(n||this.commitOrRemove(),!this.hasSelection)return;this.#V[0]+=t,this.#V[1]+=r;const[o,i]=this.#V,a=[...this.#y],l=1e3;this.#O&&clearTimeout(this.#O),this.#O=setTimeout(()=>{this.#O=null,this.#V[0]=this.#V[1]=0,this.addCommands({cmd:()=>{for(const d of a)this.#r.has(d.id)&&d.translateInPage(o,i)},undo:()=>{for(const d of a)this.#r.has(d.id)&&d.translateInPage(-o,-i)},mustExec:!1})},l);for(const d of a)d.translateInPage(t,r)}setUpDragSession(){if(this.hasSelection){this.disableUserSelect(!0),this.#h=new Map;for(const t of this.#y)this.#h.set(t,{savedX:t.x,savedY:t.y,savedPageIndex:t.pageIndex,newX:0,newY:0,newPageIndex:-1})}}endDragSession(){if(!this.#h)return!1;this.disableUserSelect(!1);const t=this.#h;this.#h=null;let r=!1;for(const[{x:o,y:i,pageIndex:a},l]of t)l.newX=o,l.newY=i,l.newPageIndex=a,r||=o!==l.savedX||i!==l.savedY||a!==l.savedPageIndex;if(!r)return!1;const n=(o,i,a,l)=>{if(this.#r.has(o.id)){const d=this.#o.get(l);d?o._setParentAndPosition(d,i,a):(o.pageIndex=l,o.x=i,o.y=a)}};return this.addCommands({cmd:()=>{for(const[o,{newX:i,newY:a,newPageIndex:l}]of t)n(o,i,a,l)},undo:()=>{for(const[o,{savedX:i,savedY:a,savedPageIndex:l}]of t)n(o,i,a,l)},mustExec:!0}),!0}dragSelectedEditors(t,r){if(this.#h)for(const n of this.#h.keys())n.drag(t,r)}rebuild(t){if(t.parent===null){const r=this.getLayer(t.pageIndex);r?(r.changeParent(t),r.addOrRebuild(t)):(this.addEditor(t),this.addToAnnotationStorage(t),t.rebuild())}else t.parent.addOrRebuild(t)}get isEditorHandlingKeyboard(){return this.getActive()?.shouldGetKeyboardEvents()||this.#y.size===1&&this.firstSelectedEditor.shouldGetKeyboardEvents()}isActive(t){return this.#t===t}getActive(){return this.#t}getMode(){return this.#w}get imageManager(){return vn(this,"imageManager",new QO)}getSelectionBoxes(t){if(!t)return null;const r=document.getSelection();for(let u=0,p=r.rangeCount;u<p;u++)if(!t.contains(r.getRangeAt(u).commonAncestorContainer))return null;const{x:n,y:o,width:i,height:a}=t.getBoundingClientRect();let l;switch(t.getAttribute("data-main-rotation")){case"90":l=(u,p,h,f)=>({x:(p-o)/a,y:1-(u+h-n)/i,width:f/a,height:h/i});break;case"180":l=(u,p,h,f)=>({x:1-(u+h-n)/i,y:1-(p+f-o)/a,width:h/i,height:f/a});break;case"270":l=(u,p,h,f)=>({x:1-(p+f-o)/a,y:(u-n)/i,width:f/a,height:h/i});break;default:l=(u,p,h,f)=>({x:(u-n)/i,y:(p-o)/a,width:h/i,height:f/a});break}const d=[];for(let u=0,p=r.rangeCount;u<p;u++){const h=r.getRangeAt(u);if(!h.collapsed)for(const{x:f,y:g,width:y,height:v}of h.getClientRects())y===0||v===0||d.push(l(f,g,y,v))}return d.length===0?null:d}addChangedExistingAnnotation({annotationElementId:t,id:r}){(this.#i||=new Map).set(t,r)}removeChangedExistingAnnotation({annotationElementId:t}){this.#i?.delete(t)}renderAnnotationElement(t){const r=this.#i?.get(t.data.id);if(!r)return;const n=this.#n.getRawValue(r);n&&(this.#w===hn.NONE&&!n.hasBeenModified||n.renderAnnotationElement(t))}}class Hh{#e="";#t=!1;#r=null;#o=null;#s=null;#n=!1;#i=null;static _l10nPromise=null;constructor(t){this.#i=t}static initialize(t){Hh._l10nPromise||=t}async render(){const t=this.#r=document.createElement("button");t.className="altText";const r=await Hh._l10nPromise.get("pdfjs-editor-alt-text-button-label");t.textContent=r,t.setAttribute("aria-label",r),t.tabIndex="0";const n=this.#i._uiManager._signal;t.addEventListener("contextmenu",$s,{signal:n}),t.addEventListener("pointerdown",i=>i.stopPropagation(),{signal:n});const o=i=>{i.preventDefault(),this.#i._uiManager.editAltText(this.#i)};return t.addEventListener("click",o,{capture:!0,signal:n}),t.addEventListener("keydown",i=>{i.target===t&&i.key==="Enter"&&(this.#n=!0,o(i))},{signal:n}),await this.#l(),t}finish(){this.#r&&(this.#r.focus({focusVisible:this.#n}),this.#n=!1)}isEmpty(){return!this.#e&&!this.#t}get data(){return{altText:this.#e,decorative:this.#t}}set data({altText:t,decorative:r}){this.#e===t&&this.#t===r||(this.#e=t,this.#t=r,this.#l())}toggle(t=!1){this.#r&&(!t&&this.#s&&(clearTimeout(this.#s),this.#s=null),this.#r.disabled=!t)}destroy(){this.#r?.remove(),this.#r=null,this.#o=null}async#l(){const t=this.#r;if(!t)return;if(!this.#e&&!this.#t){t.classList.remove("done"),this.#o?.remove();return}t.classList.add("done"),Hh._l10nPromise.get("pdfjs-editor-alt-text-edit-button-label").then(o=>{t.setAttribute("aria-label",o)});let r=this.#o;if(!r){this.#o=r=document.createElement("span"),r.className="tooltip",r.setAttribute("role","tooltip");const o=r.id=`alt-text-tooltip-${this.#i.id}`;t.setAttribute("aria-describedby",o);const i=100,a=this.#i._uiManager._signal;a.addEventListener("abort",()=>{clearTimeout(this.#s),this.#s=null},{once:!0}),t.addEventListener("mouseenter",()=>{this.#s=setTimeout(()=>{this.#s=null,this.#o.classList.add("show"),this.#i._reportTelemetry({action:"alt_text_tooltip"})},i)},{signal:a}),t.addEventListener("mouseleave",()=>{this.#s&&(clearTimeout(this.#s),this.#s=null),this.#o?.classList.remove("show")},{signal:a})}r.innerText=this.#t?await Hh._l10nPromise.get("pdfjs-editor-alt-text-decorative-tooltip"):this.#e,r.parentNode||t.append(r),this.#i.getImageForAltText()?.setAttribute("aria-describedby",r.id)}}class Tr{#e=null;#t=null;#r=null;#o=!1;#s=!1;#n=null;#i=null;#l=this.focusin.bind(this);#d=this.focusout.bind(this);#u=null;#h="";#c=!1;#a=null;#m=!1;#g=!1;#p=!1;#v=null;#f=0;#b=0;#x=null;_initialOptions=Object.create(null);_isVisible=!0;_uiManager=null;_focusEventsAllowed=!0;_l10nPromise=null;#$=!1;#k=Tr._zIndex++;static _borderLineWidth=-1;static _colorManager=new JO;static _zIndex=1;static _telemetryTimeout=1e3;static get _resizerKeyboardManager(){const t=Tr.prototype._resizeWithKeyboard,r=I0.TRANSLATE_SMALL,n=I0.TRANSLATE_BIG;return vn(this,"_resizerKeyboardManager",new p6([[["ArrowLeft","mac+ArrowLeft"],t,{args:[-r,0]}],[["ctrl+ArrowLeft","mac+shift+ArrowLeft"],t,{args:[-n,0]}],[["ArrowRight","mac+ArrowRight"],t,{args:[r,0]}],[["ctrl+ArrowRight","mac+shift+ArrowRight"],t,{args:[n,0]}],[["ArrowUp","mac+ArrowUp"],t,{args:[0,-r]}],[["ctrl+ArrowUp","mac+shift+ArrowUp"],t,{args:[0,-n]}],[["ArrowDown","mac+ArrowDown"],t,{args:[0,r]}],[["ctrl+ArrowDown","mac+shift+ArrowDown"],t,{args:[0,n]}],[["Escape","mac+Escape"],Tr.prototype._stopResizingWithKeyboard]]))}constructor(t){this.constructor===Tr&&Xn("Cannot initialize AnnotationEditor."),this.parent=t.parent,this.id=t.id,this.width=this.height=null,this.pageIndex=t.parent.pageIndex,this.name=t.name,this.div=null,this._uiManager=t.uiManager,this.annotationElementId=null,this._willKeepAspectRatio=!1,this._initialOptions.isCentered=t.isCentered,this._structTreeParentId=null;const{rotation:r,rawDims:{pageWidth:n,pageHeight:o,pageX:i,pageY:a}}=this.parent.viewport;this.rotation=r,this.pageRotation=(360+r-this._uiManager.viewParameters.rotation)%360,this.pageDimensions=[n,o],this.pageTranslation=[i,a];const[l,d]=this.parentDimensions;this.x=t.x/l,this.y=t.y/d,this.isAttachedToDOM=!1,this.deleted=!1}get editorType(){return Object.getPrototypeOf(this).constructor._type}static get _defaultLineColor(){return vn(this,"_defaultLineColor",this._colorManager.getHexCode("CanvasText"))}static deleteAnnotationElement(t){const r=new G2t({id:t.parent.getNextId(),parent:t.parent,uiManager:t._uiManager});r.annotationElementId=t.annotationElementId,r.deleted=!0,r._uiManager.addToAnnotationStorage(r)}static initialize(t,r,n){if(Tr._l10nPromise||=new Map(["pdfjs-editor-alt-text-button-label","pdfjs-editor-alt-text-edit-button-label","pdfjs-editor-alt-text-decorative-tooltip","pdfjs-editor-resizer-label-topLeft","pdfjs-editor-resizer-label-topMiddle","pdfjs-editor-resizer-label-topRight","pdfjs-editor-resizer-label-middleRight","pdfjs-editor-resizer-label-bottomRight","pdfjs-editor-resizer-label-bottomMiddle","pdfjs-editor-resizer-label-bottomLeft","pdfjs-editor-resizer-label-middleLeft"].map(i=>[i,t.get(i.replaceAll(/([A-Z])/g,a=>`-${a.toLowerCase()}`))])),n?.strings)for(const i of n.strings)Tr._l10nPromise.set(i,t.get(i));if(Tr._borderLineWidth!==-1)return;const o=getComputedStyle(document.documentElement);Tr._borderLineWidth=parseFloat(o.getPropertyValue("--outline-width"))||0}static updateDefaultParams(t,r){}static get defaultPropertiesToUpdate(){return[]}static isHandlingMimeForPasting(t){return!1}static paste(t,r){Xn("Not implemented")}get propertiesToUpdate(){return[]}get _isDraggable(){return this.#$}set _isDraggable(t){this.#$=t,this.div?.classList.toggle("draggable",t)}get isEnterHandled(){return!0}center(){const[t,r]=this.pageDimensions;switch(this.parentRotation){case 90:this.x-=this.height*r/(t*2),this.y+=this.width*t/(r*2);break;case 180:this.x+=this.width/2,this.y+=this.height/2;break;case 270:this.x+=this.height*r/(t*2),this.y-=this.width*t/(r*2);break;default:this.x-=this.width/2,this.y-=this.height/2;break}this.fixAndSetPosition()}addCommands(t){this._uiManager.addCommands(t)}get currentLayer(){return this._uiManager.currentLayer}setInBackground(){this.div.style.zIndex=0}setInForeground(){this.div.style.zIndex=this.#k}setParent(t){t!==null?(this.pageIndex=t.pageIndex,this.pageDimensions=t.pageDimensions):this.#I(),this.parent=t}focusin(t){this._focusEventsAllowed&&(this.#c?this.#c=!1:this.parent.setSelected(this))}focusout(t){!this._focusEventsAllowed||!this.isAttachedToDOM||t.relatedTarget?.closest(`#${this.id}`)||(t.preventDefault(),this.parent?.isMultipleSelection||this.commitOrRemove())}commitOrRemove(){this.isEmpty()?this.remove():this.commit()}commit(){this.addToAnnotationStorage()}addToAnnotationStorage(){this._uiManager.addToAnnotationStorage(this)}setAt(t,r,n,o){const[i,a]=this.parentDimensions;[n,o]=this.screenToPageTranslation(n,o),this.x=(t+n)/i,this.y=(r+o)/a,this.fixAndSetPosition()}#E([t,r],n,o){[n,o]=this.screenToPageTranslation(n,o),this.x+=n/t,this.y+=o/r,this.fixAndSetPosition()}translate(t,r){this.#E(this.parentDimensions,t,r)}translateInPage(t,r){this.#a||=[this.x,this.y],this.#E(this.pageDimensions,t,r),this.div.scrollIntoView({block:"nearest"})}drag(t,r){this.#a||=[this.x,this.y];const[n,o]=this.parentDimensions;if(this.x+=t/n,this.y+=r/o,this.parent&&(this.x<0||this.x>1||this.y<0||this.y>1)){const{x:u,y:p}=this.div.getBoundingClientRect();this.parent.findNewParent(this,u,p)&&(this.x-=Math.floor(this.x),this.y-=Math.floor(this.y))}let{x:i,y:a}=this;const[l,d]=this.getBaseTranslation();i+=l,a+=d,this.div.style.left=`${(100*i).toFixed(2)}%`,this.div.style.top=`${(100*a).toFixed(2)}%`,this.div.scrollIntoView({block:"nearest"})}get _hasBeenMoved(){return!!this.#a&&(this.#a[0]!==this.x||this.#a[1]!==this.y)}getBaseTranslation(){const[t,r]=this.parentDimensions,{_borderLineWidth:n}=Tr,o=n/t,i=n/r;switch(this.rotation){case 90:return[-o,i];case 180:return[o,i];case 270:return[o,-i];default:return[-o,-i]}}get _mustFixPosition(){return!0}fixAndSetPosition(t=this.rotation){const[r,n]=this.pageDimensions;let{x:o,y:i,width:a,height:l}=this;if(a*=r,l*=n,o*=r,i*=n,this._mustFixPosition)switch(t){case 0:o=Math.max(0,Math.min(r-a,o)),i=Math.max(0,Math.min(n-l,i));break;case 90:o=Math.max(0,Math.min(r-l,o)),i=Math.min(n,Math.max(a,i));break;case 180:o=Math.min(r,Math.max(a,o)),i=Math.min(n,Math.max(l,i));break;case 270:o=Math.min(r,Math.max(l,o)),i=Math.max(0,Math.min(n-a,i));break}this.x=o/=r,this.y=i/=n;const[d,u]=this.getBaseTranslation();o+=d,i+=u;const{style:p}=this.div;p.left=`${(100*o).toFixed(2)}%`,p.top=`${(100*i).toFixed(2)}%`,this.moveInDOM()}static#L(t,r,n){switch(n){case 90:return[r,-t];case 180:return[-t,-r];case 270:return[-r,t];default:return[t,r]}}screenToPageTranslation(t,r){return Tr.#L(t,r,this.parentRotation)}pageTranslationToScreen(t,r){return Tr.#L(t,r,360-this.parentRotation)}#S(t){switch(t){case 90:{const[r,n]=this.pageDimensions;return[0,-r/n,n/r,0]}case 180:return[-1,0,0,-1];case 270:{const[r,n]=this.pageDimensions;return[0,r/n,-n/r,0]}default:return[1,0,0,1]}}get parentScale(){return this._uiManager.viewParameters.realScale}get parentRotation(){return(this._uiManager.viewParameters.rotation+this.pageRotation)%360}get parentDimensions(){const{parentScale:t,pageDimensions:[r,n]}=this,o=r*t,i=n*t;return bs.isCSSRoundSupported?[Math.round(o),Math.round(i)]:[o,i]}setDims(t,r){const[n,o]=this.parentDimensions;this.div.style.width=`${(100*t/n).toFixed(2)}%`,this.#s||(this.div.style.height=`${(100*r/o).toFixed(2)}%`)}fixDims(){const{style:t}=this.div,{height:r,width:n}=t,o=n.endsWith("%"),i=!this.#s&&r.endsWith("%");if(o&&i)return;const[a,l]=this.parentDimensions;o||(t.width=`${(100*parseFloat(n)/a).toFixed(2)}%`),!this.#s&&!i&&(t.height=`${(100*parseFloat(r)/l).toFixed(2)}%`)}getInitialTranslation(){return[0,0]}#w(){if(this.#n)return;this.#n=document.createElement("div"),this.#n.classList.add("resizers");const t=this._willKeepAspectRatio?["topLeft","topRight","bottomRight","bottomLeft"]:["topLeft","topMiddle","topRight","middleRight","bottomRight","bottomMiddle","bottomLeft","middleLeft"],r=this._uiManager._signal;for(const n of t){const o=document.createElement("div");this.#n.append(o),o.classList.add("resizer",n),o.setAttribute("data-resizer-name",n),o.addEventListener("pointerdown",this.#y.bind(this,n),{signal:r}),o.addEventListener("contextmenu",$s,{signal:r}),o.tabIndex=-1}this.div.prepend(this.#n)}#y(t,r){r.preventDefault();const{isMac:n}=bs.platform;if(r.button!==0||r.ctrlKey&&n)return;this.#r?.toggle(!1);const o=this.#_.bind(this,t),i=this._isDraggable;this._isDraggable=!1;const a=this._uiManager._signal,l={passive:!0,capture:!0,signal:a};this.parent.togglePointerEvents(!1),window.addEventListener("pointermove",o,l),window.addEventListener("contextmenu",$s,{signal:a});const d=this.x,u=this.y,p=this.width,h=this.height,f=this.parent.div.style.cursor,g=this.div.style.cursor;this.div.style.cursor=this.parent.div.style.cursor=window.getComputedStyle(r.target).cursor;const y=()=>{this.parent.togglePointerEvents(!0),this.#r?.toggle(!0),this._isDraggable=i,window.removeEventListener("pointerup",y),window.removeEventListener("blur",y),window.removeEventListener("pointermove",o,l),window.removeEventListener("contextmenu",$s),this.parent.div.style.cursor=f,this.div.style.cursor=g,this.#C(d,u,p,h)};window.addEventListener("pointerup",y,{signal:a}),window.addEventListener("blur",y,{signal:a})}#C(t,r,n,o){const i=this.x,a=this.y,l=this.width,d=this.height;i===t&&a===r&&l===n&&d===o||this.addCommands({cmd:()=>{this.width=l,this.height=d,this.x=i,this.y=a;const[u,p]=this.parentDimensions;this.setDims(u*l,p*d),this.fixAndSetPosition()},undo:()=>{this.width=n,this.height=o,this.x=t,this.y=r;const[u,p]=this.parentDimensions;this.setDims(u*n,p*o),this.fixAndSetPosition()},mustExec:!0})}#_(t,r){const[n,o]=this.parentDimensions,i=this.x,a=this.y,l=this.width,d=this.height,u=Tr.MIN_SIZE/n,p=Tr.MIN_SIZE/o,h=I=>Math.round(I*1e4)/1e4,f=this.#S(this.rotation),g=(I,L)=>[f[0]*I+f[2]*L,f[1]*I+f[3]*L],y=this.#S(360-this.rotation),v=(I,L)=>[y[0]*I+y[2]*L,y[1]*I+y[3]*L];let w,x,$=!1,S=!1;switch(t){case"topLeft":$=!0,w=(I,L)=>[0,0],x=(I,L)=>[I,L];break;case"topMiddle":w=(I,L)=>[I/2,0],x=(I,L)=>[I/2,L];break;case"topRight":$=!0,w=(I,L)=>[I,0],x=(I,L)=>[0,L];break;case"middleRight":S=!0,w=(I,L)=>[I,L/2],x=(I,L)=>[0,L/2];break;case"bottomRight":$=!0,w=(I,L)=>[I,L],x=(I,L)=>[0,0];break;case"bottomMiddle":w=(I,L)=>[I/2,L],x=(I,L)=>[I/2,0];break;case"bottomLeft":$=!0,w=(I,L)=>[0,L],x=(I,L)=>[I,0];break;case"middleLeft":S=!0,w=(I,L)=>[0,L/2],x=(I,L)=>[I,L/2];break}const k=w(l,d),T=x(l,d);let E=g(...T);const A=h(i+E[0]),D=h(a+E[1]);let P=1,j=1,[B,O]=this.screenToPageTranslation(r.movementX,r.movementY);if([B,O]=v(B/n,O/o),$){const I=Math.hypot(l,d);P=j=Math.max(Math.min(Math.hypot(T[0]-k[0]-B,T[1]-k[1]-O)/I,1/l,1/d),u/l,p/d)}else S?P=Math.max(u,Math.min(1,Math.abs(T[0]-k[0]-B)))/l:j=Math.max(p,Math.min(1,Math.abs(T[1]-k[1]-O)))/d;const q=h(l*P),W=h(d*j);E=g(...x(q,W));const F=A-E[0],V=D-E[1];this.width=q,this.height=W,this.x=F,this.y=V,this.setDims(n*q,o*W),this.fixAndSetPosition()}altTextFinish(){this.#r?.finish()}async addEditToolbar(){return this.#u||this.#g?this.#u:(this.#u=new XO(this),this.div.append(this.#u.render()),this.#r&&this.#u.addAltTextButton(await this.#r.render()),this.#u)}removeEditToolbar(){this.#u&&(this.#u.remove(),this.#u=null,this.#r?.destroy())}getClientDimensions(){return this.div.getBoundingClientRect()}async addAltTextButton(){this.#r||(Hh.initialize(Tr._l10nPromise),this.#r=new Hh(this),this.#e&&(this.#r.data=this.#e,this.#e=null),await this.addEditToolbar())}get altTextData(){return this.#r?.data}set altTextData(t){this.#r&&(this.#r.data=t)}hasAltText(){return!this.#r?.isEmpty()}render(){this.div=document.createElement("div"),this.div.setAttribute("data-editor-rotation",(360-this.rotation)%360),this.div.className=this.name,this.div.setAttribute("id",this.id),this.div.tabIndex=this.#o?-1:0,this._isVisible||this.div.classList.add("hidden"),this.setInForeground();const t=this._uiManager._signal;this.div.addEventListener("focusin",this.#l,{signal:t}),this.div.addEventListener("focusout",this.#d,{signal:t});const[r,n]=this.parentDimensions;this.parentRotation%180!==0&&(this.div.style.maxWidth=`${(100*n/r).toFixed(2)}%`,this.div.style.maxHeight=`${(100*r/n).toFixed(2)}%`);const[o,i]=this.getInitialTranslation();return this.translate(o,i),ob(this,this.div,["pointerdown"]),this.div}pointerdown(t){const{isMac:r}=bs.platform;if(t.button!==0||t.ctrlKey&&r){t.preventDefault();return}if(this.#c=!0,this._isDraggable){this.#M(t);return}this.#T(t)}#T(t){const{isMac:r}=bs.platform;t.ctrlKey&&!r||t.shiftKey||t.metaKey&&r?this.parent.toggleSelected(this):this.parent.setSelected(this)}#M(t){const r=this._uiManager.isSelected(this);this._uiManager.setUpDragSession();let n,o;const i=this._uiManager._signal;r&&(this.div.classList.add("moving"),n={passive:!0,capture:!0,signal:i},this.#f=t.clientX,this.#b=t.clientY,o=l=>{const{clientX:d,clientY:u}=l,[p,h]=this.screenToPageTranslation(d-this.#f,u-this.#b);this.#f=d,this.#b=u,this._uiManager.dragSelectedEditors(p,h)},window.addEventListener("pointermove",o,n));const a=()=>{window.removeEventListener("pointerup",a),window.removeEventListener("blur",a),r&&(this.div.classList.remove("moving"),window.removeEventListener("pointermove",o,n)),this.#c=!1,this._uiManager.endDragSession()||this.#T(t)};window.addEventListener("pointerup",a,{signal:i}),window.addEventListener("blur",a,{signal:i})}moveInDOM(){this.#v&&clearTimeout(this.#v),this.#v=setTimeout(()=>{this.#v=null,this.parent?.moveEditorInDOM(this)},0)}_setParentAndPosition(t,r,n){t.changeParent(this),this.x=r,this.y=n,this.fixAndSetPosition()}getRect(t,r,n=this.rotation){const o=this.parentScale,[i,a]=this.pageDimensions,[l,d]=this.pageTranslation,u=t/o,p=r/o,h=this.x*i,f=this.y*a,g=this.width*i,y=this.height*a;switch(n){case 0:return[h+u+l,a-f-p-y+d,h+u+g+l,a-f-p+d];case 90:return[h+p+l,a-f+u+d,h+p+y+l,a-f+u+g+d];case 180:return[h-u-g+l,a-f+p+d,h-u+l,a-f+p+y+d];case 270:return[h-p-y+l,a-f-u-g+d,h-p+l,a-f-u+d];default:throw new Error("Invalid rotation")}}getRectInCurrentCoords(t,r){const[n,o,i,a]=t,l=i-n,d=a-o;switch(this.rotation){case 0:return[n,r-a,l,d];case 90:return[n,r-o,d,l];case 180:return[i,r-o,l,d];case 270:return[i,r-a,d,l];default:throw new Error("Invalid rotation")}}onceAdded(){}isEmpty(){return!1}enableEditMode(){this.#g=!0}disableEditMode(){this.#g=!1}isInEditMode(){return this.#g}shouldGetKeyboardEvents(){return this.#p}needsToBeRebuilt(){return this.div&&!this.isAttachedToDOM}rebuild(){const t=this._uiManager._signal;this.div?.addEventListener("focusin",this.#l,{signal:t}),this.div?.addEventListener("focusout",this.#d,{signal:t})}rotate(t){}serialize(t=!1,r=null){Xn("An editor must be serializable")}static deserialize(t,r,n){const o=new this.prototype.constructor({parent:r,id:r.getNextId(),uiManager:n});o.rotation=t.rotation,o.#e=t.accessibilityData;const[i,a]=o.pageDimensions,[l,d,u,p]=o.getRectInCurrentCoords(t.rect,a);return o.x=l/i,o.y=d/a,o.width=u/i,o.height=p/a,o}get hasBeenModified(){return!!this.annotationElementId&&(this.deleted||this.serialize()!==null)}remove(){if(this.div.removeEventListener("focusin",this.#l),this.div.removeEventListener("focusout",this.#d),this.isEmpty()||this.commit(),this.parent?this.parent.remove(this):this._uiManager.removeEditor(this),this.#v&&(clearTimeout(this.#v),this.#v=null),this.#I(),this.removeEditToolbar(),this.#x){for(const t of this.#x.values())clearTimeout(t);this.#x=null}this.parent=null}get isResizable(){return!1}makeResizable(){this.isResizable&&(this.#w(),this.#n.classList.remove("hidden"),ob(this,this.div,["keydown"]))}get toolbarPosition(){return null}keydown(t){if(!this.isResizable||t.target!==this.div||t.key!=="Enter")return;this._uiManager.setSelected(this),this.#i={savedX:this.x,savedY:this.y,savedWidth:this.width,savedHeight:this.height};const r=this.#n.children;if(!this.#t){this.#t=Array.from(r);const a=this.#D.bind(this),l=this.#j.bind(this),d=this._uiManager._signal;for(const u of this.#t){const p=u.getAttribute("data-resizer-name");u.setAttribute("role","spinbutton"),u.addEventListener("keydown",a,{signal:d}),u.addEventListener("blur",l,{signal:d}),u.addEventListener("focus",this.#P.bind(this,p),{signal:d}),Tr._l10nPromise.get(`pdfjs-editor-resizer-label-${p}`).then(h=>u.setAttribute("aria-label",h))}}const n=this.#t[0];let o=0;for(const a of r){if(a===n)break;o++}const i=(360-this.rotation+this.parentRotation)%360/90*(this.#t.length/4);if(i!==o){if(i<o)for(let l=0;l<o-i;l++)this.#n.append(this.#n.firstChild);else if(i>o)for(let l=0;l<i-o;l++)this.#n.firstChild.before(this.#n.lastChild);let a=0;for(const l of r){const u=this.#t[a++].getAttribute("data-resizer-name");Tr._l10nPromise.get(`pdfjs-editor-resizer-label-${u}`).then(p=>l.setAttribute("aria-label",p))}}this.#R(0),this.#p=!0,this.#n.firstChild.focus({focusVisible:!0}),t.preventDefault(),t.stopImmediatePropagation()}#D(t){Tr._resizerKeyboardManager.exec(this,t)}#j(t){this.#p&&t.relatedTarget?.parentNode!==this.#n&&this.#I()}#P(t){this.#h=this.#p?t:""}#R(t){if(this.#t)for(const r of this.#t)r.tabIndex=t}_resizeWithKeyboard(t,r){this.#p&&this.#_(this.#h,{movementX:t,movementY:r})}#I(){if(this.#p=!1,this.#R(-1),this.#i){const{savedX:t,savedY:r,savedWidth:n,savedHeight:o}=this.#i;this.#C(t,r,n,o),this.#i=null}}_stopResizingWithKeyboard(){this.#I(),this.div.focus()}select(){if(this.makeResizable(),this.div?.classList.add("selectedEditor"),!this.#u){this.addEditToolbar().then(()=>{this.div?.classList.contains("selectedEditor")&&this.#u?.show()});return}this.#u?.show()}unselect(){this.#n?.classList.add("hidden"),this.div?.classList.remove("selectedEditor"),this.div?.contains(document.activeElement)&&this._uiManager.currentLayer.div.focus({preventScroll:!0}),this.#u?.hide()}updateParams(t,r){}disableEditing(){}enableEditing(){}enterInEditMode(){}getImageForAltText(){return null}get contentDiv(){return this.div}get isEditing(){return this.#m}set isEditing(t){this.#m=t,this.parent&&(t?(this.parent.setSelected(this),this.parent.setActiveEditor(this)):this.parent.setActiveEditor(null))}setAspectRatio(t,r){this.#s=!0;const n=t/r,{style:o}=this.div;o.aspectRatio=n,o.height="auto"}static get MIN_SIZE(){return 16}static canCreateNewEmptyEditor(){return!0}get telemetryInitialData(){return{action:"added"}}get telemetryFinalData(){return null}_reportTelemetry(t,r=!1){if(r){this.#x||=new Map;const{action:n}=t;let o=this.#x.get(n);o&&clearTimeout(o),o=setTimeout(()=>{this._reportTelemetry(t),this.#x.delete(n),this.#x.size===0&&(this.#x=null)},Tr._telemetryTimeout),this.#x.set(n,o);return}t.type||=this.editorType,this._uiManager._eventBus.dispatch("reporttelemetry",{source:this,details:{type:"editing",data:t}})}show(t=this._isVisible){this.div.classList.toggle("hidden",!t),this._isVisible=t}enable(){this.div&&(this.div.tabIndex=0),this.#o=!1}disable(){this.div&&(this.div.tabIndex=-1),this.#o=!0}renderAnnotationElement(t){let r=t.container.querySelector(".annotationContent");if(!r)r=document.createElement("div"),r.classList.add("annotationContent",this.editorType),t.container.prepend(r);else if(r.nodeName==="CANVAS"){const n=r;r=document.createElement("div"),r.classList.add("annotationContent",this.editorType),n.before(r)}return r}resetAnnotationElement(t){const{firstChild:r}=t.container;r.nodeName==="DIV"&&r.classList.contains("annotationContent")&&r.remove()}}class G2t extends Tr{constructor(t){super(t),this.annotationElementId=t.annotationElementId,this.deleted=!0}serialize(){return{id:this.annotationElementId,deleted:!0,pageIndex:this.pageIndex}}}const GQ=3285377520,gl=4294901760,qd=65535;class Xge{constructor(t){this.h1=t?t&4294967295:GQ,this.h2=t?t&4294967295:GQ}update(t){let r,n;if(typeof t=="string"){r=new Uint8Array(t.length*2),n=0;for(let v=0,w=t.length;v<w;v++){const x=t.charCodeAt(v);x<=255?r[n++]=x:(r[n++]=x>>>8,r[n++]=x&255)}}else if(ArrayBuffer.isView(t))r=t.slice(),n=r.byteLength;else throw new Error("Invalid data format, must be a string or TypedArray.");const o=n>>2,i=n-o*4,a=new Uint32Array(r.buffer,0,o);let l=0,d=0,u=this.h1,p=this.h2;const h=3432918353,f=461845907,g=h&qd,y=f&qd;for(let v=0;v<o;v++)v&1?(l=a[v],l=l*h&gl|l*g&qd,l=l<<15|l>>>17,l=l*f&gl|l*y&qd,u^=l,u=u<<13|u>>>19,u=u*5+3864292196):(d=a[v],d=d*h&gl|d*g&qd,d=d<<15|d>>>17,d=d*f&gl|d*y&qd,p^=d,p=p<<13|p>>>19,p=p*5+3864292196);switch(l=0,i){case 3:l^=r[o*4+2]<<16;case 2:l^=r[o*4+1]<<8;case 1:l^=r[o*4],l=l*h&gl|l*g&qd,l=l<<15|l>>>17,l=l*f&gl|l*y&qd,o&1?u^=l:p^=l}this.h1=u,this.h2=p}hexdigest(){let t=this.h1,r=this.h2;return t^=r>>>1,t=t*3981806797&gl|t*36045&qd,r=r*4283543511&gl|((r<<16|t>>>16)*2950163797&gl)>>>16,t^=r>>>1,t=t*444984403&gl|t*60499&qd,r=r*3301882366&gl|((r<<16|t>>>16)*3120437893&gl)>>>16,t^=r>>>1,(t>>>0).toString(16).padStart(8,"0")+(r>>>0).toString(16).padStart(8,"0")}}const lj=Object.freeze({map:null,hash:"",transfer:void 0});class eN{#e=!1;#t=new Map;constructor(){this.onSetModified=null,this.onResetModified=null,this.onAnnotationEditor=null}getValue(t,r){const n=this.#t.get(t);return n===void 0?r:Object.assign(r,n)}getRawValue(t){return this.#t.get(t)}remove(t){if(this.#t.delete(t),this.#t.size===0&&this.resetModified(),typeof this.onAnnotationEditor=="function"){for(const r of this.#t.values())if(r instanceof Tr)return;this.onAnnotationEditor(null)}}setValue(t,r){const n=this.#t.get(t);let o=!1;if(n!==void 0)for(const[i,a]of Object.entries(r))n[i]!==a&&(o=!0,n[i]=a);else o=!0,this.#t.set(t,r);o&&this.#r(),r instanceof Tr&&typeof this.onAnnotationEditor=="function"&&this.onAnnotationEditor(r.constructor._type)}has(t){return this.#t.has(t)}getAll(){return this.#t.size>0?UO(this.#t):null}setAll(t){for(const[r,n]of Object.entries(t))this.setValue(r,n)}get size(){return this.#t.size}#r(){this.#e||(this.#e=!0,typeof this.onSetModified=="function"&&this.onSetModified())}resetModified(){this.#e&&(this.#e=!1,typeof this.onResetModified=="function"&&this.onResetModified())}get print(){return new Qge(this)}get serializable(){if(this.#t.size===0)return lj;const t=new Map,r=new Xge,n=[],o=Object.create(null);let i=!1;for(const[a,l]of this.#t){const d=l instanceof Tr?l.serialize(!1,o):l;d&&(t.set(a,d),r.update(`${a}:${JSON.stringify(d)}`),i||=!!d.bitmap)}if(i)for(const a of t.values())a.bitmap&&n.push(a.bitmap);return t.size>0?{map:t,hash:r.hexdigest(),transfer:n}:lj}get editorStats(){let t=null;const r=new Map;for(const n of this.#t.values()){if(!(n instanceof Tr))continue;const o=n.telemetryFinalData;if(!o)continue;const{type:i}=o;r.has(i)||r.set(i,Object.getPrototypeOf(n).constructor),t||=Object.create(null);const a=t[i]||=new Map;for(const[l,d]of Object.entries(o)){if(l==="type")continue;let u=a.get(l);u||(u=new Map,a.set(l,u));const p=u.get(d)??0;u.set(d,p+1)}}for(const[n,o]of r)t[n]=o.computeTelemetryFinalData(t[n]);return t}}class Qge extends eN{#e;constructor(t){super();const{map:r,hash:n,transfer:o}=t.serializable,i=structuredClone(r,o?{transfer:o}:null);this.#e={map:i,hash:n,transfer:o}}get print(){Xn("Should not call PrintAnnotationStorage.print")}get serializable(){return this.#e}}class q2t{#e=new Set;constructor({ownerDocument:t=globalThis.document,styleElement:r=null}){this._document=t,this.nativeFontFaces=new Set,this.styleElement=null,this.loadingRequests=[],this.loadTestFontId=0}addNativeFontFace(t){this.nativeFontFaces.add(t),this._document.fonts.add(t)}removeNativeFontFace(t){this.nativeFontFaces.delete(t),this._document.fonts.delete(t)}insertRule(t){this.styleElement||(this.styleElement=this._document.createElement("style"),this._document.documentElement.getElementsByTagName("head")[0].append(this.styleElement));const r=this.styleElement.sheet;r.insertRule(t,r.cssRules.length)}clear(){for(const t of this.nativeFontFaces)this._document.fonts.delete(t);this.nativeFontFaces.clear(),this.#e.clear(),this.styleElement&&(this.styleElement.remove(),this.styleElement=null)}async loadSystemFont({systemFontInfo:t,_inspectFont:r}){if(!(!t||this.#e.has(t.loadedName))){if(Ai(!this.disableFontFace,"loadSystemFont shouldn't be called when `disableFontFace` is set."),this.isFontLoadingAPISupported){const{loadedName:n,src:o,style:i}=t,a=new FontFace(n,o,i);this.addNativeFontFace(a);try{await a.load(),this.#e.add(n),r?.(t)}catch{Jr(`Cannot load system font: ${t.baseFontName}, installing it could help to improve PDF rendering.`),this.removeNativeFontFace(a)}return}Xn("Not implemented: loadSystemFont without the Font Loading API.")}}async bind(t){if(t.attached||t.missingFile&&!t.systemFontInfo)return;if(t.attached=!0,t.systemFontInfo){await this.loadSystemFont(t);return}if(this.isFontLoadingAPISupported){const n=t.createNativeFontFace();if(n){this.addNativeFontFace(n);try{await n.loaded}catch(o){throw Jr(`Failed to load font '${n.family}': '${o}'.`),t.disableFontFace=!0,o}}return}const r=t.createFontFaceRule();if(r){if(this.insertRule(r),this.isSyncFontLoadingSupported)return;await new Promise(n=>{const o=this._queueLoadingCallback(n);this._prepareFontLoadEvent(t,o)})}}get isFontLoadingAPISupported(){const t=!!this._document?.fonts;return vn(this,"isFontLoadingAPISupported",t)}get isSyncFontLoadingSupported(){let t=!1;return(ka||typeof navigator<"u"&&typeof navigator?.userAgent=="string"&&/Mozilla\/5.0.*?rv:\d+.*? Gecko/.test(navigator.userAgent))&&(t=!0),vn(this,"isSyncFontLoadingSupported",t)}_queueLoadingCallback(t){function r(){for(Ai(!o.done,"completeRequest() cannot be called twice."),o.done=!0;n.length>0&&n[0].done;){const i=n.shift();setTimeout(i.callback,0)}}const{loadingRequests:n}=this,o={done:!1,complete:r,callback:t};return n.push(o),o}get _loadTestFont(){const t=atob("T1RUTwALAIAAAwAwQ0ZGIDHtZg4AAAOYAAAAgUZGVE1lkzZwAAAEHAAAABxHREVGABQAFQAABDgAAAAeT1MvMlYNYwkAAAEgAAAAYGNtYXABDQLUAAACNAAAAUJoZWFk/xVFDQAAALwAAAA2aGhlYQdkA+oAAAD0AAAAJGhtdHgD6AAAAAAEWAAAAAZtYXhwAAJQAAAAARgAAAAGbmFtZVjmdH4AAAGAAAAAsXBvc3T/hgAzAAADeAAAACAAAQAAAAEAALZRFsRfDzz1AAsD6AAAAADOBOTLAAAAAM4KHDwAAAAAA+gDIQAAAAgAAgAAAAAAAAABAAADIQAAAFoD6AAAAAAD6AABAAAAAAAAAAAAAAAAAAAAAQAAUAAAAgAAAAQD6AH0AAUAAAKKArwAAACMAooCvAAAAeAAMQECAAACAAYJAAAAAAAAAAAAAQAAAAAAAAAAAAAAAFBmRWQAwAAuAC4DIP84AFoDIQAAAAAAAQAAAAAAAAAAACAAIAABAAAADgCuAAEAAAAAAAAAAQAAAAEAAAAAAAEAAQAAAAEAAAAAAAIAAQAAAAEAAAAAAAMAAQAAAAEAAAAAAAQAAQAAAAEAAAAAAAUAAQAAAAEAAAAAAAYAAQAAAAMAAQQJAAAAAgABAAMAAQQJAAEAAgABAAMAAQQJAAIAAgABAAMAAQQJAAMAAgABAAMAAQQJAAQAAgABAAMAAQQJAAUAAgABAAMAAQQJAAYAAgABWABYAAAAAAAAAwAAAAMAAAAcAAEAAAAAADwAAwABAAAAHAAEACAAAAAEAAQAAQAAAC7//wAAAC7////TAAEAAAAAAAABBgAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMAAAAAAAD/gwAyAAAAAQAAAAAAAAAAAAAAAAAAAAABAAQEAAEBAQJYAAEBASH4DwD4GwHEAvgcA/gXBIwMAYuL+nz5tQXkD5j3CBLnEQACAQEBIVhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYAAABAQAADwACAQEEE/t3Dov6fAH6fAT+fPp8+nwHDosMCvm1Cvm1DAz6fBQAAAAAAAABAAAAAMmJbzEAAAAAzgTjFQAAAADOBOQpAAEAAAAAAAAADAAUAAQAAAABAAAAAgABAAAAAAAAAAAD6AAAAAAAAA==");return vn(this,"_loadTestFont",t)}_prepareFontLoadEvent(t,r){function n(k,T){return k.charCodeAt(T)<<24|k.charCodeAt(T+1)<<16|k.charCodeAt(T+2)<<8|k.charCodeAt(T+3)&255}function o(k,T,E,A){const D=k.substring(0,T),P=k.substring(T+E);return D+A+P}let i,a;const l=this._document.createElement("canvas");l.width=1,l.height=1;const d=l.getContext("2d");let u=0;function p(k,T){if(++u>30){Jr("Load test font never loaded."),T();return}if(d.font="30px "+k,d.fillText(".",0,20),d.getImageData(0,0,1,1).data[3]>0){T();return}setTimeout(p.bind(null,k,T))}const h=`lt${Date.now()}${this.loadTestFontId++}`;let f=this._loadTestFont;f=o(f,976,h.length,h);const y=16,v=1482184792;let w=n(f,y);for(i=0,a=h.length-3;i<a;i+=4)w=w-v+n(h,i)|0;i<h.length&&(w=w-v+n(h+"XXX",i)|0),f=o(f,y,4,D2t(w));const x=`url(data:font/opentype;base64,${btoa(f)});`,$=`@font-face {font-family:"${h}";src:${x}}`;this.insertRule($);const S=this._document.createElement("div");S.style.visibility="hidden",S.style.width=S.style.height="10px",S.style.position="absolute",S.style.top=S.style.left="0px";for(const k of[t.loadedName,h]){const T=this._document.createElement("span");T.textContent="Hi",T.style.fontFamily=k,S.append(T)}this._document.body.append(S),p(h,()=>{S.remove(),r.complete()})}}class Z2t{constructor(t,{disableFontFace:r=!1,inspectFont:n=null}){this.compiledGlyphs=Object.create(null);for(const o in t)this[o]=t[o];this.disableFontFace=r===!0,this._inspectFont=n}createNativeFontFace(){if(!this.data||this.disableFontFace)return null;let t;if(!this.cssFontInfo)t=new FontFace(this.loadedName,this.data,{});else{const r={weight:this.cssFontInfo.fontWeight};this.cssFontInfo.italicAngle&&(r.style=`oblique ${this.cssFontInfo.italicAngle}deg`),t=new FontFace(this.cssFontInfo.fontFamily,this.data,r)}return this._inspectFont?.(this),t}createFontFaceRule(){if(!this.data||this.disableFontFace)return null;const t=Wge(this.data),r=`url(data:${this.mimetype};base64,${btoa(t)});`;let n;if(!this.cssFontInfo)n=`@font-face {font-family:"${this.loadedName}";src:${r}}`;else{let o=`font-weight: ${this.cssFontInfo.fontWeight};`;this.cssFontInfo.italicAngle&&(o+=`font-style: oblique ${this.cssFontInfo.italicAngle}deg;`),n=`@font-face {font-family:"${this.cssFontInfo.fontFamily}";${o}src:${r}}`}return this._inspectFont?.(this,r),n}getPathGenerator(t,r){if(this.compiledGlyphs[r]!==void 0)return this.compiledGlyphs[r];let n;try{n=t.get(this.loadedName+"_path_"+r)}catch(i){Jr(`getPathGenerator - ignoring character: "${i}".`)}if(!Array.isArray(n)||n.length===0)return this.compiledGlyphs[r]=function(i,a){};const o=[];for(let i=0,a=n.length;i<a;)switch(n[i++]){case mu.BEZIER_CURVE_TO:{const[l,d,u,p,h,f]=n.slice(i,i+6);o.push(g=>g.bezierCurveTo(l,d,u,p,h,f)),i+=6}break;case mu.MOVE_TO:{const[l,d]=n.slice(i,i+2);o.push(u=>u.moveTo(l,d)),i+=2}break;case mu.LINE_TO:{const[l,d]=n.slice(i,i+2);o.push(u=>u.lineTo(l,d)),i+=2}break;case mu.QUADRATIC_CURVE_TO:{const[l,d,u,p]=n.slice(i,i+4);o.push(h=>h.quadraticCurveTo(l,d,u,p)),i+=4}break;case mu.RESTORE:o.push(l=>l.restore());break;case mu.SAVE:o.push(l=>l.save());break;case mu.SCALE:Ai(o.length===2,"Scale command is only valid at the third position.");break;case mu.TRANSFORM:{const[l,d,u,p,h,f]=n.slice(i,i+6);o.push(g=>g.transform(l,d,u,p,h,f)),i+=6}break;case mu.TRANSLATE:{const[l,d]=n.slice(i,i+2);o.push(u=>u.translate(l,d)),i+=2}break}return this.compiledGlyphs[r]=function(a,l){o[0](a),o[1](a),a.scale(l,-l);for(let d=2,u=o.length;d<u;d++)o[d](a)}}}if(ka){var cj=Promise.withResolvers(),dj=null;(async()=>{const t=await bt(()=>import("./empty-B0QxjPHg.js").then(l=>l.e),__vite__mapDeps([0,1,2])),r=await bt(()=>import("./index-QkeEXb1H.js").then(l=>l.i),__vite__mapDeps([3,1,4,5,6,7,8,9])),n=await bt(()=>import("./index-Bl0eTNht.js").then(l=>l.i),__vite__mapDeps([10,1,11,4,5,6,7,8,9])),o=await bt(()=>import("./url-DI6ZTkbp.js").then(l=>l.u),__vite__mapDeps([12,1,9,7,5,6,8]));let i,a;return new Map(Object.entries({fs:t,http:r,https:n,url:o,canvas:i,path2d:a}))})().then(t=>{dj=t,cj.resolve()},t=>{Jr(`loadPackages: ${t}`),dj=new Map,cj.resolve()})}class F1{static get promise(){return cj.promise}static get(t){return dj?.get(t)}}const Jge=function(e){return F1.get("fs").promises.readFile(e).then(r=>new Uint8Array(r))};class K2t extends kx{}class X2t extends Ex{_createCanvas(t,r){return F1.get("canvas").createCanvas(t,r)}}class Q2t extends _x{_fetchData(t,r){return Jge(t).then(n=>({cMapData:n,compressionType:r}))}}class J2t extends Tx{_fetchData(t){return Jge(t)}}const Va={FILL:"Fill",STROKE:"Stroke",SHADING:"Shading"};function uj(e,t){if(!t)return;const r=t[2]-t[0],n=t[3]-t[1],o=new Path2D;o.rect(t[0],t[1],r,n),e.clip(o)}class h6{constructor(){this.constructor===h6&&Xn("Cannot initialize BaseShadingPattern.")}getPattern(){Xn("Abstract method `getPattern` called.")}}class e0t extends h6{constructor(t){super(),this._type=t[1],this._bbox=t[2],this._colorStops=t[3],this._p0=t[4],this._p1=t[5],this._r0=t[6],this._r1=t[7],this.matrix=null}_createGradient(t){let r;this._type==="axial"?r=t.createLinearGradient(this._p0[0],this._p0[1],this._p1[0],this._p1[1]):this._type==="radial"&&(r=t.createRadialGradient(this._p0[0],this._p0[1],this._r0,this._p1[0],this._p1[1],this._r1));for(const n of this._colorStops)r.addColorStop(n[0],n[1]);return r}getPattern(t,r,n,o){let i;if(o===Va.STROKE||o===Va.FILL){const a=r.current.getClippedPathBoundingBox(o,Io(t))||[0,0,0,0],l=Math.ceil(a[2]-a[0])||1,d=Math.ceil(a[3]-a[1])||1,u=r.cachedCanvases.getCanvas("pattern",l,d,!0),p=u.context;p.clearRect(0,0,p.canvas.width,p.canvas.height),p.beginPath(),p.rect(0,0,p.canvas.width,p.canvas.height),p.translate(-a[0],-a[1]),n=lr.transform(n,[1,0,0,1,a[0],a[1]]),p.transform(...r.baseTransform),this.matrix&&p.transform(...this.matrix),uj(p,this._bbox),p.fillStyle=this._createGradient(p),p.fill(),i=t.createPattern(u.canvas,"no-repeat");const h=new DOMMatrix(n);i.setTransform(h)}else uj(t,this._bbox),i=this._createGradient(t);return i}}function lL(e,t,r,n,o,i,a,l){const d=t.coords,u=t.colors,p=e.data,h=e.width*4;let f;d[r+1]>d[n+1]&&(f=r,r=n,n=f,f=i,i=a,a=f),d[n+1]>d[o+1]&&(f=n,n=o,o=f,f=a,a=l,l=f),d[r+1]>d[n+1]&&(f=r,r=n,n=f,f=i,i=a,a=f);const g=(d[r]+t.offsetX)*t.scaleX,y=(d[r+1]+t.offsetY)*t.scaleY,v=(d[n]+t.offsetX)*t.scaleX,w=(d[n+1]+t.offsetY)*t.scaleY,x=(d[o]+t.offsetX)*t.scaleX,$=(d[o+1]+t.offsetY)*t.scaleY;if(y>=$)return;const S=u[i],k=u[i+1],T=u[i+2],E=u[a],A=u[a+1],D=u[a+2],P=u[l],j=u[l+1],B=u[l+2],O=Math.round(y),q=Math.round($);let W,F,V,I,L,z,H,ee;for(let Z=O;Z<=q;Z++){if(Z<w){const ge=Z<y?0:(y-Z)/(y-w);W=g-(g-v)*ge,F=S-(S-E)*ge,V=k-(k-A)*ge,I=T-(T-D)*ge}else{let ge;Z>$?ge=1:w===$?ge=0:ge=(w-Z)/(w-$),W=v-(v-x)*ge,F=E-(E-P)*ge,V=A-(A-j)*ge,I=D-(D-B)*ge}let U;Z<y?U=0:Z>$?U=1:U=(y-Z)/(y-$),L=g-(g-x)*U,z=S-(S-P)*U,H=k-(k-j)*U,ee=T-(T-B)*U;const X=Math.round(Math.min(W,L)),Q=Math.round(Math.max(W,L));let oe=h*Z+X*4;for(let ge=X;ge<=Q;ge++)U=(W-ge)/(W-L),U<0?U=0:U>1&&(U=1),p[oe++]=F-(F-z)*U|0,p[oe++]=V-(V-H)*U|0,p[oe++]=I-(I-ee)*U|0,p[oe++]=255}}function t0t(e,t,r){const n=t.coords,o=t.colors;let i,a;switch(t.type){case"lattice":const l=t.verticesPerRow,d=Math.floor(n.length/l)-1,u=l-1;for(i=0;i<d;i++){let p=i*l;for(let h=0;h<u;h++,p++)lL(e,r,n[p],n[p+1],n[p+l],o[p],o[p+1],o[p+l]),lL(e,r,n[p+l+1],n[p+1],n[p+l],o[p+l+1],o[p+1],o[p+l])}break;case"triangles":for(i=0,a=n.length;i<a;i+=3)lL(e,r,n[i],n[i+1],n[i+2],o[i],o[i+1],o[i+2]);break;default:throw new Error("illegal figure")}}class r0t extends h6{constructor(t){super(),this._coords=t[2],this._colors=t[3],this._figures=t[4],this._bounds=t[5],this._bbox=t[7],this._background=t[8],this.matrix=null}_createMeshCanvas(t,r,n){const l=Math.floor(this._bounds[0]),d=Math.floor(this._bounds[1]),u=Math.ceil(this._bounds[2])-l,p=Math.ceil(this._bounds[3])-d,h=Math.min(Math.ceil(Math.abs(u*t[0]*1.1)),3e3),f=Math.min(Math.ceil(Math.abs(p*t[1]*1.1)),3e3),g=u/h,y=p/f,v={coords:this._coords,colors:this._colors,offsetX:-l,offsetY:-d,scaleX:1/g,scaleY:1/y},w=h+2*2,x=f+2*2,$=n.getCanvas("mesh",w,x,!1),S=$.context,k=S.createImageData(h,f);if(r){const E=k.data;for(let A=0,D=E.length;A<D;A+=4)E[A]=r[0],E[A+1]=r[1],E[A+2]=r[2],E[A+3]=255}for(const E of this._figures)t0t(k,E,v);return S.putImageData(k,2,2),{canvas:$.canvas,offsetX:l-2*g,offsetY:d-2*y,scaleX:g,scaleY:y}}getPattern(t,r,n,o){uj(t,this._bbox);let i;if(o===Va.SHADING)i=lr.singularValueDecompose2dScale(Io(t));else if(i=lr.singularValueDecompose2dScale(r.baseTransform),this.matrix){const l=lr.singularValueDecompose2dScale(this.matrix);i=[i[0]*l[0],i[1]*l[1]]}const a=this._createMeshCanvas(i,o===Va.SHADING?null:this._background,r.cachedCanvases);return o!==Va.SHADING&&(t.setTransform(...r.baseTransform),this.matrix&&t.transform(...this.matrix)),t.translate(a.offsetX,a.offsetY),t.scale(a.scaleX,a.scaleY),t.createPattern(a.canvas,"no-repeat")}}class n0t extends h6{getPattern(){return"hotpink"}}function o0t(e){switch(e[0]){case"RadialAxial":return new e0t(e);case"Mesh":return new r0t(e);case"Dummy":return new n0t}throw new Error(`Unknown IR type: ${e[0]}`)}const qQ={COLORED:1,UNCOLORED:2};class tN{static MAX_PATTERN_SIZE=3e3;constructor(t,r,n,o,i){this.operatorList=t[2],this.matrix=t[3],this.bbox=t[4],this.xstep=t[5],this.ystep=t[6],this.paintType=t[7],this.tilingType=t[8],this.color=r,this.ctx=n,this.canvasGraphicsFactory=o,this.baseTransform=i}createPatternCanvas(t){const r=this.operatorList,n=this.bbox,o=this.xstep,i=this.ystep,a=this.paintType,l=this.tilingType,d=this.color,u=this.canvasGraphicsFactory;Cx("TilingType: "+l);const p=n[0],h=n[1],f=n[2],g=n[3],y=lr.singularValueDecompose2dScale(this.matrix),v=lr.singularValueDecompose2dScale(this.baseTransform),w=[y[0]*v[0],y[1]*v[1]],x=this.getSizeAndScale(o,this.ctx.canvas.width,w[0]),$=this.getSizeAndScale(i,this.ctx.canvas.height,w[1]),S=t.cachedCanvases.getCanvas("pattern",x.size,$.size,!0),k=S.context,T=u.createCanvasGraphics(k);T.groupLevel=t.groupLevel,this.setFillAndStrokeStyleToContext(T,a,d);let E=p,A=h,D=f,P=g;return p<0&&(E=0,D+=Math.abs(p)),h<0&&(A=0,P+=Math.abs(h)),k.translate(-(x.scale*E),-($.scale*A)),T.transform(x.scale,0,0,$.scale,0,0),k.save(),this.clipBbox(T,E,A,D,P),T.baseTransform=Io(T.ctx),T.executeOperatorList(r),T.endDrawing(),{canvas:S.canvas,scaleX:x.scale,scaleY:$.scale,offsetX:E,offsetY:A}}getSizeAndScale(t,r,n){t=Math.abs(t);const o=Math.max(tN.MAX_PATTERN_SIZE,r);let i=Math.ceil(t*n);return i>=o?i=o:n=i/t,{scale:n,size:i}}clipBbox(t,r,n,o,i){const a=o-r,l=i-n;t.ctx.rect(r,n,a,l),t.current.updateRectMinMax(Io(t.ctx),[r,n,o,i]),t.clip(),t.endPath()}setFillAndStrokeStyleToContext(t,r,n){const o=t.ctx,i=t.current;switch(r){case qQ.COLORED:const a=this.ctx;o.fillStyle=a.fillStyle,o.strokeStyle=a.strokeStyle,i.fillColor=a.fillStyle,i.strokeColor=a.strokeStyle;break;case qQ.UNCOLORED:const l=lr.makeHexColor(n[0],n[1],n[2]);o.fillStyle=l,o.strokeStyle=l,i.fillColor=l,i.strokeColor=l;break;default:throw new L2t(`Unsupported paint type: ${r}`)}}getPattern(t,r,n,o){let i=n;o!==Va.SHADING&&(i=lr.transform(i,r.baseTransform),this.matrix&&(i=lr.transform(i,this.matrix)));const a=this.createPatternCanvas(r);let l=new DOMMatrix(i);l=l.translate(a.offsetX,a.offsetY),l=l.scale(1/a.scaleX,1/a.scaleY);const d=t.createPattern(a.canvas,"repeat");return d.setTransform(l),d}}function i0t({src:e,srcPos:t=0,dest:r,width:n,height:o,nonBlackColor:i=4294967295,inverseDecode:a=!1}){const l=bs.isLittleEndian?4278190080:255,[d,u]=a?[i,l]:[l,i],p=n>>3,h=n&7,f=e.length;r=new Uint32Array(r.buffer);let g=0;for(let y=0;y<o;y++){for(const w=t+p;t<w;t++){const x=t<f?e[t]:255;r[g++]=x&128?u:d,r[g++]=x&64?u:d,r[g++]=x&32?u:d,r[g++]=x&16?u:d,r[g++]=x&8?u:d,r[g++]=x&4?u:d,r[g++]=x&2?u:d,r[g++]=x&1?u:d}if(h===0)continue;const v=t<f?e[t++]:255;for(let w=0;w<h;w++)r[g++]=v&1<<7-w?u:d}return{srcPos:t,destPos:g}}const ZQ=16,KQ=100,a0t=15,XQ=10,QQ=1e3,us=16;function s0t(e,t){if(e._removeMirroring)throw new Error("Context is already forwarding operations.");e.__originalSave=e.save,e.__originalRestore=e.restore,e.__originalRotate=e.rotate,e.__originalScale=e.scale,e.__originalTranslate=e.translate,e.__originalTransform=e.transform,e.__originalSetTransform=e.setTransform,e.__originalResetTransform=e.resetTransform,e.__originalClip=e.clip,e.__originalMoveTo=e.moveTo,e.__originalLineTo=e.lineTo,e.__originalBezierCurveTo=e.bezierCurveTo,e.__originalRect=e.rect,e.__originalClosePath=e.closePath,e.__originalBeginPath=e.beginPath,e._removeMirroring=()=>{e.save=e.__originalSave,e.restore=e.__originalRestore,e.rotate=e.__originalRotate,e.scale=e.__originalScale,e.translate=e.__originalTranslate,e.transform=e.__originalTransform,e.setTransform=e.__originalSetTransform,e.resetTransform=e.__originalResetTransform,e.clip=e.__originalClip,e.moveTo=e.__originalMoveTo,e.lineTo=e.__originalLineTo,e.bezierCurveTo=e.__originalBezierCurveTo,e.rect=e.__originalRect,e.closePath=e.__originalClosePath,e.beginPath=e.__originalBeginPath,delete e._removeMirroring},e.save=function(){t.save(),this.__originalSave()},e.restore=function(){t.restore(),this.__originalRestore()},e.translate=function(n,o){t.translate(n,o),this.__originalTranslate(n,o)},e.scale=function(n,o){t.scale(n,o),this.__originalScale(n,o)},e.transform=function(n,o,i,a,l,d){t.transform(n,o,i,a,l,d),this.__originalTransform(n,o,i,a,l,d)},e.setTransform=function(n,o,i,a,l,d){t.setTransform(n,o,i,a,l,d),this.__originalSetTransform(n,o,i,a,l,d)},e.resetTransform=function(){t.resetTransform(),this.__originalResetTransform()},e.rotate=function(n){t.rotate(n),this.__originalRotate(n)},e.clip=function(n){t.clip(n),this.__originalClip(n)},e.moveTo=function(r,n){t.moveTo(r,n),this.__originalMoveTo(r,n)},e.lineTo=function(r,n){t.lineTo(r,n),this.__originalLineTo(r,n)},e.bezierCurveTo=function(r,n,o,i,a,l){t.bezierCurveTo(r,n,o,i,a,l),this.__originalBezierCurveTo(r,n,o,i,a,l)},e.rect=function(r,n,o,i){t.rect(r,n,o,i),this.__originalRect(r,n,o,i)},e.closePath=function(){t.closePath(),this.__originalClosePath()},e.beginPath=function(){t.beginPath(),this.__originalBeginPath()}}class l0t{constructor(t){this.canvasFactory=t,this.cache=Object.create(null)}getCanvas(t,r,n){let o;return this.cache[t]!==void 0?(o=this.cache[t],this.canvasFactory.reset(o,r,n)):(o=this.canvasFactory.create(r,n),this.cache[t]=o),o}delete(t){delete this.cache[t]}clear(){for(const t in this.cache){const r=this.cache[t];this.canvasFactory.destroy(r),delete this.cache[t]}}}function M9(e,t,r,n,o,i,a,l,d,u){const[p,h,f,g,y,v]=Io(e);if(h===0&&f===0){const $=a*p+y,S=Math.round($),k=l*g+v,T=Math.round(k),E=(a+d)*p+y,A=Math.abs(Math.round(E)-S)||1,D=(l+u)*g+v,P=Math.abs(Math.round(D)-T)||1;return e.setTransform(Math.sign(p),0,0,Math.sign(g),S,T),e.drawImage(t,r,n,o,i,0,0,A,P),e.setTransform(p,h,f,g,y,v),[A,P]}if(p===0&&g===0){const $=l*f+y,S=Math.round($),k=a*h+v,T=Math.round(k),E=(l+u)*f+y,A=Math.abs(Math.round(E)-S)||1,D=(a+d)*h+v,P=Math.abs(Math.round(D)-T)||1;return e.setTransform(0,Math.sign(h),Math.sign(f),0,S,T),e.drawImage(t,r,n,o,i,0,0,P,A),e.setTransform(p,h,f,g,y,v),[P,A]}e.drawImage(t,r,n,o,i,a,l,d,u);const w=Math.hypot(p,h),x=Math.hypot(f,g);return[w*d,x*u]}function c0t(e){const{width:t,height:r}=e;if(t>QQ||r>QQ)return null;const n=1e3,o=new Uint8Array([0,2,4,0,1,0,5,4,8,10,0,8,0,2,1,0]),i=t+1;let a=new Uint8Array(i*(r+1)),l,d,u;const p=t+7&-8;let h=new Uint8Array(p*r),f=0;for(const x of e.data){let $=128;for(;$>0;)h[f++]=x&$?0:255,$>>=1}let g=0;for(f=0,h[f]!==0&&(a[0]=1,++g),d=1;d<t;d++)h[f]!==h[f+1]&&(a[d]=h[f]?2:1,++g),f++;for(h[f]!==0&&(a[d]=2,++g),l=1;l<r;l++){f=l*p,u=l*i,h[f-p]!==h[f]&&(a[u]=h[f]?1:8,++g);let x=(h[f]?4:0)+(h[f-p]?8:0);for(d=1;d<t;d++)x=(x>>2)+(h[f+1]?4:0)+(h[f-p+1]?8:0),o[x]&&(a[u+d]=o[x],++g),f++;if(h[f-p]!==h[f]&&(a[u+d]=h[f]?2:4,++g),g>n)return null}for(f=p*(r-1),u=l*i,h[f]!==0&&(a[u]=8,++g),d=1;d<t;d++)h[f]!==h[f+1]&&(a[u+d]=h[f]?4:8,++g),f++;if(h[f]!==0&&(a[u+d]=4,++g),g>n)return null;const y=new Int32Array([0,i,-1,0,-i,0,0,0,1]),v=new Path2D;for(l=0;g&&l<=r;l++){let x=l*i;const $=x+t;for(;x<$&&!a[x];)x++;if(x===$)continue;v.moveTo(x%i,l);const S=x;let k=a[x];do{const T=y[k];do x+=T;while(!a[x]);const E=a[x];E!==5&&E!==10?(k=E,a[x]=0):(k=E&51*k>>4,a[x]&=k>>2|k<<2),v.lineTo(x%i,x/i|0),a[x]||--g}while(S!==x);--l}return h=null,a=null,function(x){x.save(),x.scale(1/t,-1/r),x.translate(0,-r),x.fill(v),x.beginPath(),x.restore()}}class JQ{constructor(t,r){this.alphaIsShape=!1,this.fontSize=0,this.fontSizeScale=1,this.textMatrix=Vge,this.textMatrixScale=1,this.fontMatrix=oj,this.leading=0,this.x=0,this.y=0,this.lineX=0,this.lineY=0,this.charSpacing=0,this.wordSpacing=0,this.textHScale=1,this.textRenderingMode=va.FILL,this.textRise=0,this.fillColor="#000000",this.strokeColor="#000000",this.patternFill=!1,this.fillAlpha=1,this.strokeAlpha=1,this.lineWidth=1,this.activeSMask=null,this.transferMaps="none",this.startNewPathAndClipBox([0,0,t,r])}clone(){const t=Object.create(this);return t.clipBox=this.clipBox.slice(),t}setCurrentPoint(t,r){this.x=t,this.y=r}updatePathMinMax(t,r,n){[r,n]=lr.applyTransform([r,n],t),this.minX=Math.min(this.minX,r),this.minY=Math.min(this.minY,n),this.maxX=Math.max(this.maxX,r),this.maxY=Math.max(this.maxY,n)}updateRectMinMax(t,r){const n=lr.applyTransform(r,t),o=lr.applyTransform(r.slice(2),t),i=lr.applyTransform([r[0],r[3]],t),a=lr.applyTransform([r[2],r[1]],t);this.minX=Math.min(this.minX,n[0],o[0],i[0],a[0]),this.minY=Math.min(this.minY,n[1],o[1],i[1],a[1]),this.maxX=Math.max(this.maxX,n[0],o[0],i[0],a[0]),this.maxY=Math.max(this.maxY,n[1],o[1],i[1],a[1])}updateScalingPathMinMax(t,r){lr.scaleMinMax(t,r),this.minX=Math.min(this.minX,r[0]),this.minY=Math.min(this.minY,r[1]),this.maxX=Math.max(this.maxX,r[2]),this.maxY=Math.max(this.maxY,r[3])}updateCurvePathMinMax(t,r,n,o,i,a,l,d,u,p){const h=lr.bezierBoundingBox(r,n,o,i,a,l,d,u,p);p||this.updateRectMinMax(t,h)}getPathBoundingBox(t=Va.FILL,r=null){const n=[this.minX,this.minY,this.maxX,this.maxY];if(t===Va.STROKE){r||Xn("Stroke bounding box must include transform.");const o=lr.singularValueDecompose2dScale(r),i=o[0]*this.lineWidth/2,a=o[1]*this.lineWidth/2;n[0]-=i,n[1]-=a,n[2]+=i,n[3]+=a}return n}updateClipFromPath(){const t=lr.intersect(this.clipBox,this.getPathBoundingBox());this.startNewPathAndClipBox(t||[0,0,0,0])}isEmptyClip(){return this.minX===1/0}startNewPathAndClipBox(t){this.clipBox=t,this.minX=1/0,this.minY=1/0,this.maxX=0,this.maxY=0}getClippedPathBoundingBox(t=Va.FILL,r=null){return lr.intersect(this.clipBox,this.getPathBoundingBox(t,r))}}function eJ(e,t){if(typeof ImageData<"u"&&t instanceof ImageData){e.putImageData(t,0,0);return}const r=t.height,n=t.width,o=r%us,i=(r-o)/us,a=o===0?i:i+1,l=e.createImageData(n,us);let d=0,u;const p=t.data,h=l.data;let f,g,y,v;if(t.kind===Iy.GRAYSCALE_1BPP){const w=p.byteLength,x=new Uint32Array(h.buffer,0,h.byteLength>>2),$=x.length,S=n+7>>3,k=4294967295,T=bs.isLittleEndian?4278190080:255;for(f=0;f<a;f++){for(y=f<i?us:o,u=0,g=0;g<y;g++){const E=w-d;let A=0;const D=E>S?n:E*8-7,P=D&-8;let j=0,B=0;for(;A<P;A+=8)B=p[d++],x[u++]=B&128?k:T,x[u++]=B&64?k:T,x[u++]=B&32?k:T,x[u++]=B&16?k:T,x[u++]=B&8?k:T,x[u++]=B&4?k:T,x[u++]=B&2?k:T,x[u++]=B&1?k:T;for(;A<D;A++)j===0&&(B=p[d++],j=128),x[u++]=B&j?k:T,j>>=1}for(;u<$;)x[u++]=0;e.putImageData(l,0,f*us)}}else if(t.kind===Iy.RGBA_32BPP){for(g=0,v=n*us*4,f=0;f<i;f++)h.set(p.subarray(d,d+v)),d+=v,e.putImageData(l,0,g),g+=us;f<a&&(v=n*o*4,h.set(p.subarray(d,d+v)),e.putImageData(l,0,g))}else if(t.kind===Iy.RGB_24BPP)for(y=us,v=n*y,f=0;f<a;f++){for(f>=i&&(y=o,v=n*y),u=0,g=v;g--;)h[u++]=p[d++],h[u++]=p[d++],h[u++]=p[d++],h[u++]=255;e.putImageData(l,0,f*us)}else throw new Error(`bad image kind: ${t.kind}`)}function tJ(e,t){if(t.bitmap){e.drawImage(t.bitmap,0,0);return}const r=t.height,n=t.width,o=r%us,i=(r-o)/us,a=o===0?i:i+1,l=e.createImageData(n,us);let d=0;const u=t.data,p=l.data;for(let h=0;h<a;h++){const f=h<i?us:o;({srcPos:d}=i0t({src:u,srcPos:d,dest:p,width:n,height:f,nonBlackColor:0})),e.putImageData(l,0,h*us)}}function H4(e,t){const r=["strokeStyle","fillStyle","fillRule","globalAlpha","lineWidth","lineCap","lineJoin","miterLimit","globalCompositeOperation","font","filter"];for(const n of r)e[n]!==void 0&&(t[n]=e[n]);e.setLineDash!==void 0&&(t.setLineDash(e.getLineDash()),t.lineDashOffset=e.lineDashOffset)}function P9(e){if(e.strokeStyle=e.fillStyle="#000000",e.fillRule="nonzero",e.globalAlpha=1,e.lineWidth=1,e.lineCap="butt",e.lineJoin="miter",e.miterLimit=10,e.globalCompositeOperation="source-over",e.font="10px sans-serif",e.setLineDash!==void 0&&(e.setLineDash([]),e.lineDashOffset=0),!ka){const{filter:t}=e;t!=="none"&&t!==""&&(e.filter="none")}}function rJ(e,t){if(t)return!0;const r=lr.singularValueDecompose2dScale(e);r[0]=Math.fround(r[0]),r[1]=Math.fround(r[1]);const n=Math.fround((globalThis.devicePixelRatio||1)*Qf.PDF_TO_CSS_UNITS);return r[0]<=n&&r[1]<=n}const d0t=["butt","round","square"],u0t=["miter","round","bevel"],p0t={},nJ={};class Ef{constructor(t,r,n,o,i,{optionalContentConfig:a,markedContentStack:l=null},d,u){this.ctx=t,this.current=new JQ(this.ctx.canvas.width,this.ctx.canvas.height),this.stateStack=[],this.pendingClip=null,this.pendingEOFill=!1,this.res=null,this.xobjs=null,this.commonObjs=r,this.objs=n,this.canvasFactory=o,this.filterFactory=i,this.groupStack=[],this.processingType3=null,this.baseTransform=null,this.baseTransformStack=[],this.groupLevel=0,this.smaskStack=[],this.smaskCounter=0,this.tempSMask=null,this.suspendedCtx=null,this.contentVisible=!0,this.markedContentStack=l||[],this.optionalContentConfig=a,this.cachedCanvases=new l0t(this.canvasFactory),this.cachedPatterns=new Map,this.annotationCanvasMap=d,this.viewportScale=1,this.outputScaleX=1,this.outputScaleY=1,this.pageColors=u,this._cachedScaleForStroking=[-1,0],this._cachedGetSinglePixelWidth=null,this._cachedBitmapsMap=new Map}getObject(t,r=null){return typeof t=="string"?t.startsWith("g_")?this.commonObjs.get(t):this.objs.get(t):r}beginDrawing({transform:t,viewport:r,transparency:n=!1,background:o=null}){const i=this.ctx.canvas.width,a=this.ctx.canvas.height,l=this.ctx.fillStyle;if(this.ctx.fillStyle=o||"#ffffff",this.ctx.fillRect(0,0,i,a),this.ctx.fillStyle=l,n){const d=this.cachedCanvases.getCanvas("transparent",i,a);this.compositeCtx=this.ctx,this.transparentCanvas=d.canvas,this.ctx=d.context,this.ctx.save(),this.ctx.transform(...Io(this.compositeCtx))}this.ctx.save(),P9(this.ctx),t&&(this.ctx.transform(...t),this.outputScaleX=t[0],this.outputScaleY=t[0]),this.ctx.transform(...r.transform),this.viewportScale=r.scale,this.baseTransform=Io(this.ctx)}executeOperatorList(t,r,n,o){const i=t.argsArray,a=t.fnArray;let l=r||0;const d=i.length;if(d===l)return l;const u=d-l>XQ&&typeof n=="function",p=u?Date.now()+a0t:0;let h=0;const f=this.commonObjs,g=this.objs;let y;for(;;){if(o!==void 0&&l===o.nextBreakPoint)return o.breakIt(l,n),l;if(y=a[l],y!==$c.dependency)this[y].apply(this,i[l]);else for(const v of i[l]){const w=v.startsWith("g_")?f:g;if(!w.has(v))return w.get(v,n),l}if(l++,l===d)return l;if(u&&++h>XQ){if(Date.now()>p)return n(),l;h=0}}}#e(){for(;this.stateStack.length||this.inSMaskMode;)this.restore();this.ctx.restore(),this.transparentCanvas&&(this.ctx=this.compositeCtx,this.ctx.save(),this.ctx.setTransform(1,0,0,1,0,0),this.ctx.drawImage(this.transparentCanvas,0,0),this.ctx.restore(),this.transparentCanvas=null)}endDrawing(){this.#e(),this.cachedCanvases.clear(),this.cachedPatterns.clear();for(const t of this._cachedBitmapsMap.values()){for(const r of t.values())typeof HTMLCanvasElement<"u"&&r instanceof HTMLCanvasElement&&(r.width=r.height=0);t.clear()}this._cachedBitmapsMap.clear(),this.#t()}#t(){if(this.pageColors){const t=this.filterFactory.addHCMFilter(this.pageColors.foreground,this.pageColors.background);if(t!=="none"){const r=this.ctx.filter;this.ctx.filter=t,this.ctx.drawImage(this.ctx.canvas,0,0),this.ctx.filter=r}}}_scaleImage(t,r){const n=t.width,o=t.height;let i=Math.max(Math.hypot(r[0],r[1]),1),a=Math.max(Math.hypot(r[2],r[3]),1),l=n,d=o,u="prescale1",p,h;for(;i>2&&l>1||a>2&&d>1;){let f=l,g=d;i>2&&l>1&&(f=l>=16384?Math.floor(l/2)-1||1:Math.ceil(l/2),i/=l/f),a>2&&d>1&&(g=d>=16384?Math.floor(d/2)-1||1:Math.ceil(d)/2,a/=d/g),p=this.cachedCanvases.getCanvas(u,f,g),h=p.context,h.clearRect(0,0,f,g),h.drawImage(t,0,0,l,d,0,0,f,g),t=p.canvas,l=f,d=g,u=u==="prescale1"?"prescale2":"prescale1"}return{img:t,paintWidth:l,paintHeight:d}}_createMaskCanvas(t){const r=this.ctx,{width:n,height:o}=t,i=this.current.fillColor,a=this.current.patternFill,l=Io(r);let d,u,p,h;if((t.bitmap||t.data)&&t.count>1){const D=t.bitmap||t.data.buffer;u=JSON.stringify(a?l:[l.slice(0,4),i]),d=this._cachedBitmapsMap.get(D),d||(d=new Map,this._cachedBitmapsMap.set(D,d));const P=d.get(u);if(P&&!a){const j=Math.round(Math.min(l[0],l[2])+l[4]),B=Math.round(Math.min(l[1],l[3])+l[5]);return{canvas:P,offsetX:j,offsetY:B}}p=P}p||(h=this.cachedCanvases.getCanvas("maskCanvas",n,o),tJ(h.context,t));let f=lr.transform(l,[1/n,0,0,-1/o,0,0]);f=lr.transform(f,[1,0,0,1,0,-o]);const[g,y,v,w]=lr.getAxialAlignedBoundingBox([0,0,n,o],f),x=Math.round(v-g)||1,$=Math.round(w-y)||1,S=this.cachedCanvases.getCanvas("fillCanvas",x,$),k=S.context,T=g,E=y;k.translate(-T,-E),k.transform(...f),p||(p=this._scaleImage(h.canvas,fu(k)),p=p.img,d&&a&&d.set(u,p)),k.imageSmoothingEnabled=rJ(Io(k),t.interpolate),M9(k,p,0,0,p.width,p.height,0,0,n,o),k.globalCompositeOperation="source-in";const A=lr.transform(fu(k),[1,0,0,1,-T,-E]);return k.fillStyle=a?i.getPattern(r,this,A,Va.FILL):i,k.fillRect(0,0,n,o),d&&!a&&(this.cachedCanvases.delete("fillCanvas"),d.set(u,S.canvas)),{canvas:S.canvas,offsetX:Math.round(T),offsetY:Math.round(E)}}setLineWidth(t){t!==this.current.lineWidth&&(this._cachedScaleForStroking[0]=-1),this.current.lineWidth=t,this.ctx.lineWidth=t}setLineCap(t){this.ctx.lineCap=d0t[t]}setLineJoin(t){this.ctx.lineJoin=u0t[t]}setMiterLimit(t){this.ctx.miterLimit=t}setDash(t,r){const n=this.ctx;n.setLineDash!==void 0&&(n.setLineDash(t),n.lineDashOffset=r)}setRenderingIntent(t){}setFlatness(t){}setGState(t){for(const[r,n]of t)switch(r){case"LW":this.setLineWidth(n);break;case"LC":this.setLineCap(n);break;case"LJ":this.setLineJoin(n);break;case"ML":this.setMiterLimit(n);break;case"D":this.setDash(n[0],n[1]);break;case"RI":this.setRenderingIntent(n);break;case"FL":this.setFlatness(n);break;case"Font":this.setFont(n[0],n[1]);break;case"CA":this.current.strokeAlpha=n;break;case"ca":this.current.fillAlpha=n,this.ctx.globalAlpha=n;break;case"BM":this.ctx.globalCompositeOperation=n;break;case"SMask":this.current.activeSMask=n?this.tempSMask:null,this.tempSMask=null,this.checkSMaskState();break;case"TR":this.ctx.filter=this.current.transferMaps=this.filterFactory.addFilter(n);break}}get inSMaskMode(){return!!this.suspendedCtx}checkSMaskState(){const t=this.inSMaskMode;this.current.activeSMask&&!t?this.beginSMaskMode():!this.current.activeSMask&&t&&this.endSMaskMode()}beginSMaskMode(){if(this.inSMaskMode)throw new Error("beginSMaskMode called while already in smask mode");const t=this.ctx.canvas.width,r=this.ctx.canvas.height,n="smaskGroupAt"+this.groupLevel,o=this.cachedCanvases.getCanvas(n,t,r);this.suspendedCtx=this.ctx,this.ctx=o.context;const i=this.ctx;i.setTransform(...Io(this.suspendedCtx)),H4(this.suspendedCtx,i),s0t(i,this.suspendedCtx),this.setGState([["BM","source-over"],["ca",1],["CA",1]])}endSMaskMode(){if(!this.inSMaskMode)throw new Error("endSMaskMode called while not in smask mode");this.ctx._removeMirroring(),H4(this.ctx,this.suspendedCtx),this.ctx=this.suspendedCtx,this.suspendedCtx=null}compose(t){if(!this.current.activeSMask)return;t?(t[0]=Math.floor(t[0]),t[1]=Math.floor(t[1]),t[2]=Math.ceil(t[2]),t[3]=Math.ceil(t[3])):t=[0,0,this.ctx.canvas.width,this.ctx.canvas.height];const r=this.current.activeSMask,n=this.suspendedCtx;this.composeSMask(n,r,this.ctx,t),this.ctx.save(),this.ctx.setTransform(1,0,0,1,0,0),this.ctx.clearRect(0,0,this.ctx.canvas.width,this.ctx.canvas.height),this.ctx.restore()}composeSMask(t,r,n,o){const i=o[0],a=o[1],l=o[2]-i,d=o[3]-a;l===0||d===0||(this.genericComposeSMask(r.context,n,l,d,r.subtype,r.backdrop,r.transferMap,i,a,r.offsetX,r.offsetY),t.save(),t.globalAlpha=1,t.globalCompositeOperation="source-over",t.setTransform(1,0,0,1,0,0),t.drawImage(n.canvas,0,0),t.restore())}genericComposeSMask(t,r,n,o,i,a,l,d,u,p,h){let f=t.canvas,g=d-p,y=u-h;if(a){if(g<0||y<0||g+n>f.width||y+o>f.height){const w=this.cachedCanvases.getCanvas("maskExtension",n,o),x=w.context;x.drawImage(f,-g,-y),a.some($=>$!==0)&&(x.globalCompositeOperation="destination-atop",x.fillStyle=lr.makeHexColor(...a),x.fillRect(0,0,n,o),x.globalCompositeOperation="source-over"),f=w.canvas,g=y=0}else if(a.some(w=>w!==0)){t.save(),t.globalAlpha=1,t.setTransform(1,0,0,1,0,0);const w=new Path2D;w.rect(g,y,n,o),t.clip(w),t.globalCompositeOperation="destination-atop",t.fillStyle=lr.makeHexColor(...a),t.fillRect(g,y,n,o),t.restore()}}r.save(),r.globalAlpha=1,r.setTransform(1,0,0,1,0,0),i==="Alpha"&&l?r.filter=this.filterFactory.addAlphaFilter(l):i==="Luminosity"&&(r.filter=this.filterFactory.addLuminosityFilter(l));const v=new Path2D;v.rect(d,u,n,o),r.clip(v),r.globalCompositeOperation="destination-in",r.drawImage(f,g,y,n,o,d,u,n,o),r.restore()}save(){this.inSMaskMode?(H4(this.ctx,this.suspendedCtx),this.suspendedCtx.save()):this.ctx.save();const t=this.current;this.stateStack.push(t),this.current=t.clone()}restore(){this.stateStack.length===0&&this.inSMaskMode&&this.endSMaskMode(),this.stateStack.length!==0&&(this.current=this.stateStack.pop(),this.inSMaskMode?(this.suspendedCtx.restore(),H4(this.suspendedCtx,this.ctx)):this.ctx.restore(),this.checkSMaskState(),this.pendingClip=null,this._cachedScaleForStroking[0]=-1,this._cachedGetSinglePixelWidth=null)}transform(t,r,n,o,i,a){this.ctx.transform(t,r,n,o,i,a),this._cachedScaleForStroking[0]=-1,this._cachedGetSinglePixelWidth=null}constructPath(t,r,n){const o=this.ctx,i=this.current;let a=i.x,l=i.y,d,u;const p=Io(o),h=p[0]===0&&p[3]===0||p[1]===0&&p[2]===0,f=h?n.slice(0):null;for(let g=0,y=0,v=t.length;g<v;g++)switch(t[g]|0){case $c.rectangle:a=r[y++],l=r[y++];const w=r[y++],x=r[y++],$=a+w,S=l+x;o.moveTo(a,l),w===0||x===0?o.lineTo($,S):(o.lineTo($,l),o.lineTo($,S),o.lineTo(a,S)),h||i.updateRectMinMax(p,[a,l,$,S]),o.closePath();break;case $c.moveTo:a=r[y++],l=r[y++],o.moveTo(a,l),h||i.updatePathMinMax(p,a,l);break;case $c.lineTo:a=r[y++],l=r[y++],o.lineTo(a,l),h||i.updatePathMinMax(p,a,l);break;case $c.curveTo:d=a,u=l,a=r[y+4],l=r[y+5],o.bezierCurveTo(r[y],r[y+1],r[y+2],r[y+3],a,l),i.updateCurvePathMinMax(p,d,u,r[y],r[y+1],r[y+2],r[y+3],a,l,f),y+=6;break;case $c.curveTo2:d=a,u=l,o.bezierCurveTo(a,l,r[y],r[y+1],r[y+2],r[y+3]),i.updateCurvePathMinMax(p,d,u,a,l,r[y],r[y+1],r[y+2],r[y+3],f),a=r[y+2],l=r[y+3],y+=4;break;case $c.curveTo3:d=a,u=l,a=r[y+2],l=r[y+3],o.bezierCurveTo(r[y],r[y+1],a,l,a,l),i.updateCurvePathMinMax(p,d,u,r[y],r[y+1],a,l,a,l,f),y+=4;break;case $c.closePath:o.closePath();break}h&&i.updateScalingPathMinMax(p,f),i.setCurrentPoint(a,l)}closePath(){this.ctx.closePath()}stroke(t=!0){const r=this.ctx,n=this.current.strokeColor;r.globalAlpha=this.current.strokeAlpha,this.contentVisible&&(typeof n=="object"&&n?.getPattern?(r.save(),r.strokeStyle=n.getPattern(r,this,fu(r),Va.STROKE),this.rescaleAndStroke(!1),r.restore()):this.rescaleAndStroke(!0)),t&&this.consumePath(this.current.getClippedPathBoundingBox()),r.globalAlpha=this.current.fillAlpha}closeStroke(){this.closePath(),this.stroke()}fill(t=!0){const r=this.ctx,n=this.current.fillColor,o=this.current.patternFill;let i=!1;o&&(r.save(),r.fillStyle=n.getPattern(r,this,fu(r),Va.FILL),i=!0);const a=this.current.getClippedPathBoundingBox();this.contentVisible&&a!==null&&(this.pendingEOFill?(r.fill("evenodd"),this.pendingEOFill=!1):r.fill()),i&&r.restore(),t&&this.consumePath(a)}eoFill(){this.pendingEOFill=!0,this.fill()}fillStroke(){this.fill(!1),this.stroke(!1),this.consumePath()}eoFillStroke(){this.pendingEOFill=!0,this.fillStroke()}closeFillStroke(){this.closePath(),this.fillStroke()}closeEOFillStroke(){this.pendingEOFill=!0,this.closePath(),this.fillStroke()}endPath(){this.consumePath()}clip(){this.pendingClip=p0t}eoClip(){this.pendingClip=nJ}beginText(){this.current.textMatrix=Vge,this.current.textMatrixScale=1,this.current.x=this.current.lineX=0,this.current.y=this.current.lineY=0}endText(){const t=this.pendingTextPaths,r=this.ctx;if(t===void 0){r.beginPath();return}r.save(),r.beginPath();for(const n of t)r.setTransform(...n.transform),r.translate(n.x,n.y),n.addToPath(r,n.fontSize);r.restore(),r.clip(),r.beginPath(),delete this.pendingTextPaths}setCharSpacing(t){this.current.charSpacing=t}setWordSpacing(t){this.current.wordSpacing=t}setHScale(t){this.current.textHScale=t/100}setLeading(t){this.current.leading=-t}setFont(t,r){const n=this.commonObjs.get(t),o=this.current;if(!n)throw new Error(`Can't find font for ${t}`);if(o.fontMatrix=n.fontMatrix||oj,(o.fontMatrix[0]===0||o.fontMatrix[3]===0)&&Jr("Invalid font matrix for font "+t),r<0?(r=-r,o.fontDirection=-1):o.fontDirection=1,this.current.font=n,this.current.fontSize=r,n.isType3Font)return;const i=n.loadedName||"sans-serif",a=n.systemFontInfo?.css||`"${i}", ${n.fallbackName}`;let l="normal";n.black?l="900":n.bold&&(l="bold");const d=n.italic?"italic":"normal";let u=r;r<ZQ?u=ZQ:r>KQ&&(u=KQ),this.current.fontSizeScale=r/u,this.ctx.font=`${d} ${l} ${u}px ${a}`}setTextRenderingMode(t){this.current.textRenderingMode=t}setTextRise(t){this.current.textRise=t}moveText(t,r){this.current.x=this.current.lineX+=t,this.current.y=this.current.lineY+=r}setLeadingMoveText(t,r){this.setLeading(-r),this.moveText(t,r)}setTextMatrix(t,r,n,o,i,a){this.current.textMatrix=[t,r,n,o,i,a],this.current.textMatrixScale=Math.hypot(t,r),this.current.x=this.current.lineX=0,this.current.y=this.current.lineY=0}nextLine(){this.moveText(0,this.current.leading)}paintChar(t,r,n,o){const i=this.ctx,a=this.current,l=a.font,d=a.textRenderingMode,u=a.fontSize/a.fontSizeScale,p=d&va.FILL_STROKE_MASK,h=!!(d&va.ADD_TO_PATH_FLAG),f=a.patternFill&&!l.missingFile;let g;(l.disableFontFace||h||f)&&(g=l.getPathGenerator(this.commonObjs,t)),l.disableFontFace||f?(i.save(),i.translate(r,n),i.beginPath(),g(i,u),o&&i.setTransform(...o),(p===va.FILL||p===va.FILL_STROKE)&&i.fill(),(p===va.STROKE||p===va.FILL_STROKE)&&i.stroke(),i.restore()):((p===va.FILL||p===va.FILL_STROKE)&&i.fillText(t,r,n),(p===va.STROKE||p===va.FILL_STROKE)&&i.strokeText(t,r,n)),h&&(this.pendingTextPaths||=[]).push({transform:Io(i),x:r,y:n,fontSize:u,addToPath:g})}get isFontSubpixelAAEnabled(){const{context:t}=this.cachedCanvases.getCanvas("isFontSubpixelAAEnabled",10,10);t.scale(1.5,1),t.fillText("I",0,10);const r=t.getImageData(0,0,10,10).data;let n=!1;for(let o=3;o<r.length;o+=4)if(r[o]>0&&r[o]<255){n=!0;break}return vn(this,"isFontSubpixelAAEnabled",n)}showText(t){const r=this.current,n=r.font;if(n.isType3Font)return this.showType3Text(t);const o=r.fontSize;if(o===0)return;const i=this.ctx,a=r.fontSizeScale,l=r.charSpacing,d=r.wordSpacing,u=r.fontDirection,p=r.textHScale*u,h=t.length,f=n.vertical,g=f?1:-1,y=n.defaultVMetrics,v=o*r.fontMatrix[0],w=r.textRenderingMode===va.FILL&&!n.disableFontFace&&!r.patternFill;i.save(),i.transform(...r.textMatrix),i.translate(r.x,r.y+r.textRise),u>0?i.scale(p,-1):i.scale(p,1);let x;if(r.patternFill){i.save();const E=r.fillColor.getPattern(i,this,fu(i),Va.FILL);x=Io(i),i.restore(),i.fillStyle=E}let $=r.lineWidth;const S=r.textMatrixScale;if(S===0||$===0){const E=r.textRenderingMode&va.FILL_STROKE_MASK;(E===va.STROKE||E===va.FILL_STROKE)&&($=this.getSinglePixelWidth())}else $/=S;if(a!==1&&(i.scale(a,a),$/=a),i.lineWidth=$,n.isInvalidPDFjsFont){const E=[];let A=0;for(const D of t)E.push(D.unicode),A+=D.width;i.fillText(E.join(""),0,0),r.x+=A*v*p,i.restore(),this.compose();return}let k=0,T;for(T=0;T<h;++T){const E=t[T];if(typeof E=="number"){k+=g*E*o/1e3;continue}let A=!1;const D=(E.isSpace?d:0)+l,P=E.fontChar,j=E.accent;let B,O,q=E.width;if(f){const F=E.vmetric||y,V=-(E.vmetric?F[1]:q*.5)*v,I=F[2]*v;q=F?-F[0]:q,B=V/a,O=(k+I)/a}else B=k/a,O=0;if(n.remeasure&&q>0){const F=i.measureText(P).width*1e3/o*a;if(q<F&&this.isFontSubpixelAAEnabled){const V=q/F;A=!0,i.save(),i.scale(V,1),B/=V}else q!==F&&(B+=(q-F)/2e3*o/a)}if(this.contentVisible&&(E.isInFont||n.missingFile)){if(w&&!j)i.fillText(P,B,O);else if(this.paintChar(P,B,O,x),j){const F=B+o*j.offset.x/a,V=O-o*j.offset.y/a;this.paintChar(j.fontChar,F,V,x)}}const W=f?q*v-D*u:q*v+D*u;k+=W,A&&i.restore()}f?r.y-=k:r.x+=k*p,i.restore(),this.compose()}showType3Text(t){const r=this.ctx,n=this.current,o=n.font,i=n.fontSize,a=n.fontDirection,l=o.vertical?1:-1,d=n.charSpacing,u=n.wordSpacing,p=n.textHScale*a,h=n.fontMatrix||oj,f=t.length,g=n.textRenderingMode===va.INVISIBLE;let y,v,w,x;if(!(g||i===0)){for(this._cachedScaleForStroking[0]=-1,this._cachedGetSinglePixelWidth=null,r.save(),r.transform(...n.textMatrix),r.translate(n.x,n.y),r.scale(p,a),y=0;y<f;++y){if(v=t[y],typeof v=="number"){x=l*v*i/1e3,this.ctx.translate(x,0),n.x+=x*p;continue}const $=(v.isSpace?u:0)+d,S=o.charProcOperatorList[v.operatorListId];if(!S){Jr(`Type3 character "${v.operatorListId}" is not available.`);continue}this.contentVisible&&(this.processingType3=v,this.save(),r.scale(i,i),r.transform(...h),this.executeOperatorList(S),this.restore()),w=lr.applyTransform([v.width,0],h)[0]*i+$,r.translate(w,0),n.x+=w*p}r.restore(),this.processingType3=null}}setCharWidth(t,r){}setCharWidthAndBounds(t,r,n,o,i,a){this.ctx.rect(n,o,i-n,a-o),this.ctx.clip(),this.endPath()}getColorN_Pattern(t){let r;if(t[0]==="TilingPattern"){const n=t[1],o=this.baseTransform||Io(this.ctx),i={createCanvasGraphics:a=>new Ef(a,this.commonObjs,this.objs,this.canvasFactory,this.filterFactory,{optionalContentConfig:this.optionalContentConfig,markedContentStack:this.markedContentStack})};r=new tN(t,n,this.ctx,i,o)}else r=this._getPattern(t[1],t[2]);return r}setStrokeColorN(){this.current.strokeColor=this.getColorN_Pattern(arguments)}setFillColorN(){this.current.fillColor=this.getColorN_Pattern(arguments),this.current.patternFill=!0}setStrokeRGBColor(t,r,n){const o=lr.makeHexColor(t,r,n);this.ctx.strokeStyle=o,this.current.strokeColor=o}setFillRGBColor(t,r,n){const o=lr.makeHexColor(t,r,n);this.ctx.fillStyle=o,this.current.fillColor=o,this.current.patternFill=!1}_getPattern(t,r=null){let n;return this.cachedPatterns.has(t)?n=this.cachedPatterns.get(t):(n=o0t(this.getObject(t)),this.cachedPatterns.set(t,n)),r&&(n.matrix=r),n}shadingFill(t){if(!this.contentVisible)return;const r=this.ctx;this.save();const n=this._getPattern(t);r.fillStyle=n.getPattern(r,this,fu(r),Va.SHADING);const o=fu(r);if(o){const{width:i,height:a}=r.canvas,[l,d,u,p]=lr.getAxialAlignedBoundingBox([0,0,i,a],o);this.ctx.fillRect(l,d,u-l,p-d)}else this.ctx.fillRect(-1e10,-1e10,2e10,2e10);this.compose(this.current.getClippedPathBoundingBox()),this.restore()}beginInlineImage(){Xn("Should not call beginInlineImage")}beginImageData(){Xn("Should not call beginImageData")}paintFormXObjectBegin(t,r){if(this.contentVisible&&(this.save(),this.baseTransformStack.push(this.baseTransform),t&&this.transform(...t),this.baseTransform=Io(this.ctx),r)){const n=r[2]-r[0],o=r[3]-r[1];this.ctx.rect(r[0],r[1],n,o),this.current.updateRectMinMax(Io(this.ctx),r),this.clip(),this.endPath()}}paintFormXObjectEnd(){this.contentVisible&&(this.restore(),this.baseTransform=this.baseTransformStack.pop())}beginGroup(t){if(!this.contentVisible)return;this.save(),this.inSMaskMode&&(this.endSMaskMode(),this.current.activeSMask=null);const r=this.ctx;t.isolated||Cx("TODO: Support non-isolated groups."),t.knockout&&Jr("Knockout groups not supported.");const n=Io(r);if(t.matrix&&r.transform(...t.matrix),!t.bbox)throw new Error("Bounding box is required.");let o=lr.getAxialAlignedBoundingBox(t.bbox,Io(r));const i=[0,0,r.canvas.width,r.canvas.height];o=lr.intersect(o,i)||[0,0,0,0];const a=Math.floor(o[0]),l=Math.floor(o[1]),d=Math.max(Math.ceil(o[2])-a,1),u=Math.max(Math.ceil(o[3])-l,1);this.current.startNewPathAndClipBox([0,0,d,u]);let p="groupAt"+this.groupLevel;t.smask&&(p+="_smask_"+this.smaskCounter++%2);const h=this.cachedCanvases.getCanvas(p,d,u),f=h.context;f.translate(-a,-l),f.transform(...n),t.smask?this.smaskStack.push({canvas:h.canvas,context:f,offsetX:a,offsetY:l,subtype:t.smask.subtype,backdrop:t.smask.backdrop,transferMap:t.smask.transferMap||null,startTransformInverse:null}):(r.setTransform(1,0,0,1,0,0),r.translate(a,l),r.save()),H4(r,f),this.ctx=f,this.setGState([["BM","source-over"],["ca",1],["CA",1]]),this.groupStack.push(r),this.groupLevel++}endGroup(t){if(!this.contentVisible)return;this.groupLevel--;const r=this.ctx,n=this.groupStack.pop();if(this.ctx=n,this.ctx.imageSmoothingEnabled=!1,t.smask)this.tempSMask=this.smaskStack.pop(),this.restore();else{this.ctx.restore();const o=Io(this.ctx);this.restore(),this.ctx.save(),this.ctx.setTransform(...o);const i=lr.getAxialAlignedBoundingBox([0,0,r.canvas.width,r.canvas.height],o);this.ctx.drawImage(r.canvas,0,0),this.ctx.restore(),this.compose(i)}}beginAnnotation(t,r,n,o,i){if(this.#e(),P9(this.ctx),this.ctx.save(),this.save(),this.baseTransform&&this.ctx.setTransform(...this.baseTransform),r){const a=r[2]-r[0],l=r[3]-r[1];if(i&&this.annotationCanvasMap){n=n.slice(),n[4]-=r[0],n[5]-=r[1],r=r.slice(),r[0]=r[1]=0,r[2]=a,r[3]=l;const[d,u]=lr.singularValueDecompose2dScale(Io(this.ctx)),{viewportScale:p}=this,h=Math.ceil(a*this.outputScaleX*p),f=Math.ceil(l*this.outputScaleY*p);this.annotationCanvas=this.canvasFactory.create(h,f);const{canvas:g,context:y}=this.annotationCanvas;this.annotationCanvasMap.set(t,g),this.annotationCanvas.savedCtx=this.ctx,this.ctx=y,this.ctx.save(),this.ctx.setTransform(d,0,0,-u,0,l*u),P9(this.ctx)}else P9(this.ctx),this.ctx.rect(r[0],r[1],a,l),this.ctx.clip(),this.endPath()}this.current=new JQ(this.ctx.canvas.width,this.ctx.canvas.height),this.transform(...n),this.transform(...o)}endAnnotation(){this.annotationCanvas&&(this.ctx.restore(),this.#t(),this.ctx=this.annotationCanvas.savedCtx,delete this.annotationCanvas.savedCtx,delete this.annotationCanvas)}paintImageMaskXObject(t){if(!this.contentVisible)return;const r=t.count;t=this.getObject(t.data,t),t.count=r;const n=this.ctx,o=this.processingType3;if(o&&(o.compiled===void 0&&(o.compiled=c0t(t)),o.compiled)){o.compiled(n);return}const i=this._createMaskCanvas(t),a=i.canvas;n.save(),n.setTransform(1,0,0,1,0,0),n.drawImage(a,i.offsetX,i.offsetY),n.restore(),this.compose()}paintImageMaskXObjectRepeat(t,r,n=0,o=0,i,a){if(!this.contentVisible)return;t=this.getObject(t.data,t);const l=this.ctx;l.save();const d=Io(l);l.transform(r,n,o,i,0,0);const u=this._createMaskCanvas(t);l.setTransform(1,0,0,1,u.offsetX-d[4],u.offsetY-d[5]);for(let p=0,h=a.length;p<h;p+=2){const f=lr.transform(d,[r,n,o,i,a[p],a[p+1]]),[g,y]=lr.applyTransform([0,0],f);l.drawImage(u.canvas,g,y)}l.restore(),this.compose()}paintImageMaskXObjectGroup(t){if(!this.contentVisible)return;const r=this.ctx,n=this.current.fillColor,o=this.current.patternFill;for(const i of t){const{data:a,width:l,height:d,transform:u}=i,p=this.cachedCanvases.getCanvas("maskCanvas",l,d),h=p.context;h.save();const f=this.getObject(a,i);tJ(h,f),h.globalCompositeOperation="source-in",h.fillStyle=o?n.getPattern(h,this,fu(r),Va.FILL):n,h.fillRect(0,0,l,d),h.restore(),r.save(),r.transform(...u),r.scale(1,-1),M9(r,p.canvas,0,0,l,d,0,-1,1,1),r.restore()}this.compose()}paintImageXObject(t){if(!this.contentVisible)return;const r=this.getObject(t);if(!r){Jr("Dependent image isn't ready yet");return}this.paintInlineImageXObject(r)}paintImageXObjectRepeat(t,r,n,o){if(!this.contentVisible)return;const i=this.getObject(t);if(!i){Jr("Dependent image isn't ready yet");return}const a=i.width,l=i.height,d=[];for(let u=0,p=o.length;u<p;u+=2)d.push({transform:[r,0,0,n,o[u],o[u+1]],x:0,y:0,w:a,h:l});this.paintInlineImageXObjectGroup(i,d)}applyTransferMapsToCanvas(t){return this.current.transferMaps!=="none"&&(t.filter=this.current.transferMaps,t.drawImage(t.canvas,0,0),t.filter="none"),t.canvas}applyTransferMapsToBitmap(t){if(this.current.transferMaps==="none")return t.bitmap;const{bitmap:r,width:n,height:o}=t,i=this.cachedCanvases.getCanvas("inlineImage",n,o),a=i.context;return a.filter=this.current.transferMaps,a.drawImage(r,0,0),a.filter="none",i.canvas}paintInlineImageXObject(t){if(!this.contentVisible)return;const r=t.width,n=t.height,o=this.ctx;if(this.save(),!ka){const{filter:l}=o;l!=="none"&&l!==""&&(o.filter="none")}o.scale(1/r,-1/n);let i;if(t.bitmap)i=this.applyTransferMapsToBitmap(t);else if(typeof HTMLElement=="function"&&t instanceof HTMLElement||!t.data)i=t;else{const d=this.cachedCanvases.getCanvas("inlineImage",r,n).context;eJ(d,t),i=this.applyTransferMapsToCanvas(d)}const a=this._scaleImage(i,fu(o));o.imageSmoothingEnabled=rJ(Io(o),t.interpolate),M9(o,a.img,0,0,a.paintWidth,a.paintHeight,0,-n,r,n),this.compose(),this.restore()}paintInlineImageXObjectGroup(t,r){if(!this.contentVisible)return;const n=this.ctx;let o;if(t.bitmap)o=t.bitmap;else{const i=t.width,a=t.height,d=this.cachedCanvases.getCanvas("inlineImage",i,a).context;eJ(d,t),o=this.applyTransferMapsToCanvas(d)}for(const i of r)n.save(),n.transform(...i.transform),n.scale(1,-1),M9(n,o,i.x,i.y,i.w,i.h,0,-1,1,1),n.restore();this.compose()}paintSolidColorImageMask(){this.contentVisible&&(this.ctx.fillRect(0,0,1,1),this.compose())}markPoint(t){}markPointProps(t,r){}beginMarkedContent(t){this.markedContentStack.push({visible:!0})}beginMarkedContentProps(t,r){t==="OC"?this.markedContentStack.push({visible:this.optionalContentConfig.isVisible(r)}):this.markedContentStack.push({visible:!0}),this.contentVisible=this.isContentVisible()}endMarkedContent(){this.markedContentStack.pop(),this.contentVisible=this.isContentVisible()}beginCompat(){}endCompat(){}consumePath(t){const r=this.current.isEmptyClip();this.pendingClip&&this.current.updateClipFromPath(),this.pendingClip||this.compose(t);const n=this.ctx;this.pendingClip&&(r||(this.pendingClip===nJ?n.clip("evenodd"):n.clip()),this.pendingClip=null),this.current.startNewPathAndClipBox(this.current.clipBox),n.beginPath()}getSinglePixelWidth(){if(!this._cachedGetSinglePixelWidth){const t=Io(this.ctx);if(t[1]===0&&t[2]===0)this._cachedGetSinglePixelWidth=1/Math.min(Math.abs(t[0]),Math.abs(t[3]));else{const r=Math.abs(t[0]*t[3]-t[2]*t[1]),n=Math.hypot(t[0],t[2]),o=Math.hypot(t[1],t[3]);this._cachedGetSinglePixelWidth=Math.max(n,o)/r}}return this._cachedGetSinglePixelWidth}getScaleForStroking(){if(this._cachedScaleForStroking[0]===-1){const{lineWidth:t}=this.current,{a:r,b:n,c:o,d:i}=this.ctx.getTransform();let a,l;if(n===0&&o===0){const d=Math.abs(r),u=Math.abs(i);if(d===u)if(t===0)a=l=1/d;else{const p=d*t;a=l=p<1?1/p:1}else if(t===0)a=1/d,l=1/u;else{const p=d*t,h=u*t;a=p<1?1/p:1,l=h<1?1/h:1}}else{const d=Math.abs(r*i-n*o),u=Math.hypot(r,n),p=Math.hypot(o,i);if(t===0)a=p/d,l=u/d;else{const h=t*d;a=p>h?p/h:1,l=u>h?u/h:1}}this._cachedScaleForStroking[0]=a,this._cachedScaleForStroking[1]=l}return this._cachedScaleForStroking}rescaleAndStroke(t){const{ctx:r}=this,{lineWidth:n}=this.current,[o,i]=this.getScaleForStroking();if(r.lineWidth=n||1,o===1&&i===1){r.stroke();return}const a=r.getLineDash();if(t&&r.save(),r.scale(o,i),a.length>0){const l=Math.max(o,i);r.setLineDash(a.map(d=>d/l)),r.lineDashOffset/=l}r.stroke(),t&&r.restore()}isContentVisible(){for(let t=this.markedContentStack.length-1;t>=0;t--)if(!this.markedContentStack[t].visible)return!1;return!0}}for(const e in $c)Ef.prototype[e]!==void 0&&(Ef.prototype[$c[e]]=Ef.prototype[e]);class E7{static#e=null;static#t="";static get workerPort(){return this.#e}static set workerPort(t){if(!(typeof Worker<"u"&&t instanceof Worker)&&t!==null)throw new Error("Invalid `workerPort` type.");this.#e=t}static get workerSrc(){return this.#t}static set workerSrc(t){if(typeof t!="string")throw new Error("Invalid `workerSrc` type.");this.#t=t}}const I9={DATA:1,ERROR:2},ai={CANCEL:1,CANCEL_COMPLETE:2,CLOSE:3,ENQUEUE:4,ERROR:5,PULL:6,PULL_COMPLETE:7,START_COMPLETE:8};function Is(e){switch(e instanceof Error||typeof e=="object"&&e!==null||Xn('wrapReason: Expected "reason" to be a (possibly cloned) Error.'),e.name){case"AbortException":return new Lm(e.message);case"MissingPDFException":return new Am(e.message);case"PasswordException":return new aj(e.message,e.code);case"UnexpectedResponseException":return new $x(e.message,e.status);case"UnknownErrorException":return new sj(e.message,e.details);default:return new sj(e.message,e.toString())}}class I5{constructor(t,r,n){this.sourceName=t,this.targetName=r,this.comObj=n,this.callbackId=1,this.streamId=1,this.streamSinks=Object.create(null),this.streamControllers=Object.create(null),this.callbackCapabilities=Object.create(null),this.actionHandler=Object.create(null),this._onComObjOnMessage=o=>{const i=o.data;if(i.targetName!==this.sourceName)return;if(i.stream){this.#t(i);return}if(i.callback){const l=i.callbackId,d=this.callbackCapabilities[l];if(!d)throw new Error(`Cannot resolve callback ${l}`);if(delete this.callbackCapabilities[l],i.callback===I9.DATA)d.resolve(i.data);else if(i.callback===I9.ERROR)d.reject(Is(i.reason));else throw new Error("Unexpected callback case");return}const a=this.actionHandler[i.action];if(!a)throw new Error(`Unknown action from worker: ${i.action}`);if(i.callbackId){const l=this.sourceName,d=i.sourceName;new Promise(function(u){u(a(i.data))}).then(function(u){n.postMessage({sourceName:l,targetName:d,callback:I9.DATA,callbackId:i.callbackId,data:u})},function(u){n.postMessage({sourceName:l,targetName:d,callback:I9.ERROR,callbackId:i.callbackId,reason:Is(u)})});return}if(i.streamId){this.#e(i);return}a(i.data)},n.addEventListener("message",this._onComObjOnMessage)}on(t,r){const n=this.actionHandler;if(n[t])throw new Error(`There is already an actionName called "${t}"`);n[t]=r}send(t,r,n){this.comObj.postMessage({sourceName:this.sourceName,targetName:this.targetName,action:t,data:r},n)}sendWithPromise(t,r,n){const o=this.callbackId++,i=Promise.withResolvers();this.callbackCapabilities[o]=i;try{this.comObj.postMessage({sourceName:this.sourceName,targetName:this.targetName,action:t,callbackId:o,data:r},n)}catch(a){i.reject(a)}return i.promise}sendWithStream(t,r,n,o){const i=this.streamId++,a=this.sourceName,l=this.targetName,d=this.comObj;return new ReadableStream({start:u=>{const p=Promise.withResolvers();return this.streamControllers[i]={controller:u,startCall:p,pullCall:null,cancelCall:null,isClosed:!1},d.postMessage({sourceName:a,targetName:l,action:t,streamId:i,data:r,desiredSize:u.desiredSize},o),p.promise},pull:u=>{const p=Promise.withResolvers();return this.streamControllers[i].pullCall=p,d.postMessage({sourceName:a,targetName:l,stream:ai.PULL,streamId:i,desiredSize:u.desiredSize}),p.promise},cancel:u=>{Ai(u instanceof Error,"cancel must have a valid reason");const p=Promise.withResolvers();return this.streamControllers[i].cancelCall=p,this.streamControllers[i].isClosed=!0,d.postMessage({sourceName:a,targetName:l,stream:ai.CANCEL,streamId:i,reason:Is(u)}),p.promise}},n)}#e(t){const r=t.streamId,n=this.sourceName,o=t.sourceName,i=this.comObj,a=this,l=this.actionHandler[t.action],d={enqueue(u,p=1,h){if(this.isCancelled)return;const f=this.desiredSize;this.desiredSize-=p,f>0&&this.desiredSize<=0&&(this.sinkCapability=Promise.withResolvers(),this.ready=this.sinkCapability.promise),i.postMessage({sourceName:n,targetName:o,stream:ai.ENQUEUE,streamId:r,chunk:u},h)},close(){this.isCancelled||(this.isCancelled=!0,i.postMessage({sourceName:n,targetName:o,stream:ai.CLOSE,streamId:r}),delete a.streamSinks[r])},error(u){Ai(u instanceof Error,"error must have a valid reason"),!this.isCancelled&&(this.isCancelled=!0,i.postMessage({sourceName:n,targetName:o,stream:ai.ERROR,streamId:r,reason:Is(u)}))},sinkCapability:Promise.withResolvers(),onPull:null,onCancel:null,isCancelled:!1,desiredSize:t.desiredSize,ready:null};d.sinkCapability.resolve(),d.ready=d.sinkCapability.promise,this.streamSinks[r]=d,new Promise(function(u){u(l(t.data,d))}).then(function(){i.postMessage({sourceName:n,targetName:o,stream:ai.START_COMPLETE,streamId:r,success:!0})},function(u){i.postMessage({sourceName:n,targetName:o,stream:ai.START_COMPLETE,streamId:r,reason:Is(u)})})}#t(t){const r=t.streamId,n=this.sourceName,o=t.sourceName,i=this.comObj,a=this.streamControllers[r],l=this.streamSinks[r];switch(t.stream){case ai.START_COMPLETE:t.success?a.startCall.resolve():a.startCall.reject(Is(t.reason));break;case ai.PULL_COMPLETE:t.success?a.pullCall.resolve():a.pullCall.reject(Is(t.reason));break;case ai.PULL:if(!l){i.postMessage({sourceName:n,targetName:o,stream:ai.PULL_COMPLETE,streamId:r,success:!0});break}l.desiredSize<=0&&t.desiredSize>0&&l.sinkCapability.resolve(),l.desiredSize=t.desiredSize,new Promise(function(d){d(l.onPull?.())}).then(function(){i.postMessage({sourceName:n,targetName:o,stream:ai.PULL_COMPLETE,streamId:r,success:!0})},function(d){i.postMessage({sourceName:n,targetName:o,stream:ai.PULL_COMPLETE,streamId:r,reason:Is(d)})});break;case ai.ENQUEUE:if(Ai(a,"enqueue should have stream controller"),a.isClosed)break;a.controller.enqueue(t.chunk);break;case ai.CLOSE:if(Ai(a,"close should have stream controller"),a.isClosed)break;a.isClosed=!0,a.controller.close(),this.#r(a,r);break;case ai.ERROR:Ai(a,"error should have stream controller"),a.controller.error(Is(t.reason)),this.#r(a,r);break;case ai.CANCEL_COMPLETE:t.success?a.cancelCall.resolve():a.cancelCall.reject(Is(t.reason)),this.#r(a,r);break;case ai.CANCEL:if(!l)break;new Promise(function(d){d(l.onCancel?.(Is(t.reason)))}).then(function(){i.postMessage({sourceName:n,targetName:o,stream:ai.CANCEL_COMPLETE,streamId:r,success:!0})},function(d){i.postMessage({sourceName:n,targetName:o,stream:ai.CANCEL_COMPLETE,streamId:r,reason:Is(d)})}),l.sinkCapability.reject(Is(t.reason)),l.isCancelled=!0,delete this.streamSinks[r];break;default:throw new Error("Unexpected stream case")}}async#r(t,r){await Promise.allSettled([t.startCall?.promise,t.pullCall?.promise,t.cancelCall?.promise]),delete this.streamControllers[r]}destroy(){this.comObj.removeEventListener("message",this._onComObjOnMessage)}}class h0t{#e;#t;constructor({parsedData:t,rawData:r}){this.#e=t,this.#t=r}getRaw(){return this.#t}get(t){return this.#e.get(t)??null}getAll(){return UO(this.#e)}has(t){return this.#e.has(t)}}const U2=Symbol("INTERNAL");class m0t{#e=!1;#t=!1;#r=!1;#o=!0;constructor(t,{name:r,intent:n,usage:o}){this.#e=!!(t&$l.DISPLAY),this.#t=!!(t&$l.PRINT),this.name=r,this.intent=n,this.usage=o}get visible(){if(this.#r)return this.#o;if(!this.#o)return!1;const{print:t,view:r}=this.usage;return this.#e?r?.viewState!=="OFF":this.#t?t?.printState!=="OFF":!0}_setVisible(t,r,n=!1){t!==U2&&Xn("Internal method `_setVisible` called."),this.#r=n,this.#o=r}}class f0t{#e=null;#t=new Map;#r=null;#o=null;constructor(t,r=$l.DISPLAY){if(this.renderingIntent=r,this.name=null,this.creator=null,t!==null){this.name=t.name,this.creator=t.creator,this.#o=t.order;for(const n of t.groups)this.#t.set(n.id,new m0t(r,n));if(t.baseState==="OFF")for(const n of this.#t.values())n._setVisible(U2,!1);for(const n of t.on)this.#t.get(n)._setVisible(U2,!0);for(const n of t.off)this.#t.get(n)._setVisible(U2,!1);this.#r=this.getHash()}}#s(t){const r=t.length;if(r<2)return!0;const n=t[0];for(let o=1;o<r;o++){const i=t[o];let a;if(Array.isArray(i))a=this.#s(i);else if(this.#t.has(i))a=this.#t.get(i).visible;else return Jr(`Optional content group not found: ${i}`),!0;switch(n){case"And":if(!a)return!1;break;case"Or":if(a)return!0;break;case"Not":return!a;default:return!0}}return n==="And"}isVisible(t){if(this.#t.size===0)return!0;if(!t)return Cx("Optional content group not defined."),!0;if(t.type==="OCG")return this.#t.has(t.id)?this.#t.get(t.id).visible:(Jr(`Optional content group not found: ${t.id}`),!0);if(t.type==="OCMD"){if(t.expression)return this.#s(t.expression);if(!t.policy||t.policy==="AnyOn"){for(const r of t.ids){if(!this.#t.has(r))return Jr(`Optional content group not found: ${r}`),!0;if(this.#t.get(r).visible)return!0}return!1}else if(t.policy==="AllOn"){for(const r of t.ids){if(!this.#t.has(r))return Jr(`Optional content group not found: ${r}`),!0;if(!this.#t.get(r).visible)return!1}return!0}else if(t.policy==="AnyOff"){for(const r of t.ids){if(!this.#t.has(r))return Jr(`Optional content group not found: ${r}`),!0;if(!this.#t.get(r).visible)return!0}return!1}else if(t.policy==="AllOff"){for(const r of t.ids){if(!this.#t.has(r))return Jr(`Optional content group not found: ${r}`),!0;if(this.#t.get(r).visible)return!1}return!0}return Jr(`Unknown optional content policy ${t.policy}.`),!0}return Jr(`Unknown group type ${t.type}.`),!0}setVisibility(t,r=!0){const n=this.#t.get(t);if(!n){Jr(`Optional content group not found: ${t}`);return}n._setVisible(U2,!!r,!0),this.#e=null}setOCGState({state:t,preserveRB:r}){let n;for(const o of t){switch(o){case"ON":case"OFF":case"Toggle":n=o;continue}const i=this.#t.get(o);if(i)switch(n){case"ON":i._setVisible(U2,!0);break;case"OFF":i._setVisible(U2,!1);break;case"Toggle":i._setVisible(U2,!i.visible);break}}this.#e=null}get hasInitialVisibility(){return this.#r===null||this.getHash()===this.#r}getOrder(){return this.#t.size?this.#o?this.#o.slice():[...this.#t.keys()]:null}getGroups(){return this.#t.size>0?UO(this.#t):null}getGroup(t){return this.#t.get(t)||null}getHash(){if(this.#e!==null)return this.#e;const t=new Xge;for(const[r,n]of this.#t)t.update(`${r}:${n.visible}`);return this.#e=t.hexdigest()}}class g0t{constructor(t,{disableRange:r=!1,disableStream:n=!1}){Ai(t,'PDFDataTransportStream - missing required "pdfDataRangeTransport" argument.');const{length:o,initialData:i,progressiveDone:a,contentDispositionFilename:l}=t;if(this._queuedChunks=[],this._progressiveDone=a,this._contentDispositionFilename=l,i?.length>0){const d=i instanceof Uint8Array&&i.byteLength===i.buffer.byteLength?i.buffer:new Uint8Array(i).buffer;this._queuedChunks.push(d)}this._pdfDataRangeTransport=t,this._isStreamingSupported=!n,this._isRangeSupported=!r,this._contentLength=o,this._fullRequestReader=null,this._rangeReaders=[],t.addRangeListener((d,u)=>{this._onReceiveData({begin:d,chunk:u})}),t.addProgressListener((d,u)=>{this._onProgress({loaded:d,total:u})}),t.addProgressiveReadListener(d=>{this._onReceiveData({chunk:d})}),t.addProgressiveDoneListener(()=>{this._onProgressiveDone()}),t.transportReady()}_onReceiveData({begin:t,chunk:r}){const n=r instanceof Uint8Array&&r.byteLength===r.buffer.byteLength?r.buffer:new Uint8Array(r).buffer;if(t===void 0)this._fullRequestReader?this._fullRequestReader._enqueue(n):this._queuedChunks.push(n);else{const o=this._rangeReaders.some(function(i){return i._begin!==t?!1:(i._enqueue(n),!0)});Ai(o,"_onReceiveData - no `PDFDataTransportStreamRangeReader` instance found.")}}get _progressiveDataLength(){return this._fullRequestReader?._loaded??0}_onProgress(t){t.total===void 0?this._rangeReaders[0]?.onProgress?.({loaded:t.loaded}):this._fullRequestReader?.onProgress?.({loaded:t.loaded,total:t.total})}_onProgressiveDone(){this._fullRequestReader?.progressiveDone(),this._progressiveDone=!0}_removeRangeReader(t){const r=this._rangeReaders.indexOf(t);r>=0&&this._rangeReaders.splice(r,1)}getFullReader(){Ai(!this._fullRequestReader,"PDFDataTransportStream.getFullReader can only be called once.");const t=this._queuedChunks;return this._queuedChunks=null,new y0t(this,t,this._progressiveDone,this._contentDispositionFilename)}getRangeReader(t,r){if(r<=this._progressiveDataLength)return null;const n=new v0t(this,t,r);return this._pdfDataRangeTransport.requestDataRange(t,r),this._rangeReaders.push(n),n}cancelAllRequests(t){this._fullRequestReader?.cancel(t);for(const r of this._rangeReaders.slice(0))r.cancel(t);this._pdfDataRangeTransport.abort()}}class y0t{constructor(t,r,n=!1,o=null){this._stream=t,this._done=n||!1,this._filename=ZO(o)?o:null,this._queuedChunks=r||[],this._loaded=0;for(const i of this._queuedChunks)this._loaded+=i.byteLength;this._requests=[],this._headersReady=Promise.resolve(),t._fullRequestReader=this,this.onProgress=null}_enqueue(t){this._done||(this._requests.length>0?this._requests.shift().resolve({value:t,done:!1}):this._queuedChunks.push(t),this._loaded+=t.byteLength)}get headersReady(){return this._headersReady}get filename(){return this._filename}get isRangeSupported(){return this._stream._isRangeSupported}get isStreamingSupported(){return this._stream._isStreamingSupported}get contentLength(){return this._stream._contentLength}async read(){if(this._queuedChunks.length>0)return{value:this._queuedChunks.shift(),done:!1};if(this._done)return{value:void 0,done:!0};const t=Promise.withResolvers();return this._requests.push(t),t.promise}cancel(t){this._done=!0;for(const r of this._requests)r.resolve({value:void 0,done:!0});this._requests.length=0}progressiveDone(){this._done||(this._done=!0)}}class v0t{constructor(t,r,n){this._stream=t,this._begin=r,this._end=n,this._queuedChunk=null,this._requests=[],this._done=!1,this.onProgress=null}_enqueue(t){if(!this._done){if(this._requests.length===0)this._queuedChunk=t;else{this._requests.shift().resolve({value:t,done:!1});for(const n of this._requests)n.resolve({value:void 0,done:!0});this._requests.length=0}this._done=!0,this._stream._removeRangeReader(this)}}get isStreamingSupported(){return!1}async read(){if(this._queuedChunk){const r=this._queuedChunk;return this._queuedChunk=null,{value:r,done:!1}}if(this._done)return{value:void 0,done:!0};const t=Promise.withResolvers();return this._requests.push(t),t.promise}cancel(t){this._done=!0;for(const r of this._requests)r.resolve({value:void 0,done:!0});this._requests.length=0,this._stream._removeRangeReader(this)}}function b0t(e){let t=!0,r=n("filename\\*","i").exec(e);if(r){r=r[1];let p=l(r);return p=unescape(p),p=d(p),p=u(p),i(p)}if(r=a(e),r){const p=u(r);return i(p)}if(r=n("filename","i").exec(e),r){r=r[1];let p=l(r);return p=u(p),i(p)}function n(p,h){return new RegExp("(?:^|;)\\s*"+p+'\\s*=\\s*([^";\\s][^;\\s]*|"(?:[^"\\\\]|\\\\"?)+"?)',h)}function o(p,h){if(p){if(!/^[\x00-\xFF]+$/.test(h))return h;try{const f=new TextDecoder(p,{fatal:!0}),g=Sx(h);h=f.decode(g),t=!1}catch{}}return h}function i(p){return t&&/[\x80-\xff]/.test(p)&&(p=o("utf-8",p),t&&(p=o("iso-8859-1",p))),p}function a(p){const h=[];let f;const g=n("filename\\*((?!0\\d)\\d+)(\\*?)","ig");for(;(f=g.exec(p))!==null;){let[,v,w,x]=f;if(v=parseInt(v,10),v in h){if(v===0)break;continue}h[v]=[w,x]}const y=[];for(let v=0;v<h.length&&v in h;++v){let[w,x]=h[v];x=l(x),w&&(x=unescape(x),v===0&&(x=d(x))),y.push(x)}return y.join("")}function l(p){if(p.startsWith('"')){const h=p.slice(1).split('\\"');for(let f=0;f<h.length;++f){const g=h[f].indexOf('"');g!==-1&&(h[f]=h[f].slice(0,g),h.length=f+1),h[f]=h[f].replaceAll(/\\(.)/g,"$1")}p=h.join('"')}return p}function d(p){const h=p.indexOf("'");if(h===-1)return p;const f=p.slice(0,h),y=p.slice(h+1).replace(/^[^']*'/,"");return o(f,y)}function u(p){return!p.startsWith("=?")||/[\x00-\x19\x80-\xff]/.test(p)?p:p.replaceAll(/=\?([\w-]*)\?([QqBb])\?((?:[^?]|\?(?!=))*)\?=/g,function(h,f,g,y){if(g==="q"||g==="Q")return y=y.replaceAll("_"," "),y=y.replaceAll(/=([0-9a-fA-F]{2})/g,function(v,w){return String.fromCharCode(parseInt(w,16))}),o(f,y);try{y=atob(y)}catch{}return o(f,y)})}return""}function rN({getResponseHeader:e,isHttp:t,rangeChunkSize:r,disableRange:n}){const o={allowRangeRequests:!1,suggestedLength:void 0},i=parseInt(e("Content-Length"),10);return!Number.isInteger(i)||(o.suggestedLength=i,i<=2*r)||n||!t||e("Accept-Ranges")!=="bytes"||(e("Content-Encoding")||"identity")!=="identity"||(o.allowRangeRequests=!0),o}function nN(e){const t=e("Content-Disposition");if(t){let r=b0t(t);if(r.includes("%"))try{r=decodeURIComponent(r)}catch{}if(ZO(r))return r}return null}function Lx(e,t){return e===404||e===0&&t.startsWith("file:")?new Am('Missing PDF "'+t+'".'):new $x(`Unexpected server response (${e}) while retrieving PDF "${t}".`,e)}function e4e(e){return e===200||e===206}function t4e(e,t,r){return{method:"GET",headers:e,signal:r.signal,mode:"cors",credentials:t?"include":"same-origin",redirect:"follow"}}function r4e(e){const t=new Headers;for(const r in e){const n=e[r];n!==void 0&&t.append(r,n)}return t}function n4e(e){return e instanceof Uint8Array?e.buffer:e instanceof ArrayBuffer?e:(Jr(`getArrayBuffer - unexpected data format: ${e}`),new Uint8Array(e).buffer)}class oJ{constructor(t){this.source=t,this.isHttp=/^https?:/i.test(t.url),this.httpHeaders=this.isHttp&&t.httpHeaders||{},this._fullRequestReader=null,this._rangeRequestReaders=[]}get _progressiveDataLength(){return this._fullRequestReader?._loaded??0}getFullReader(){return Ai(!this._fullRequestReader,"PDFFetchStream.getFullReader can only be called once."),this._fullRequestReader=new w0t(this),this._fullRequestReader}getRangeReader(t,r){if(r<=this._progressiveDataLength)return null;const n=new x0t(this,t,r);return this._rangeRequestReaders.push(n),n}cancelAllRequests(t){this._fullRequestReader?.cancel(t);for(const r of this._rangeRequestReaders.slice(0))r.cancel(t)}}class w0t{constructor(t){this._stream=t,this._reader=null,this._loaded=0,this._filename=null;const r=t.source;this._withCredentials=r.withCredentials||!1,this._contentLength=r.length,this._headersCapability=Promise.withResolvers(),this._disableRange=r.disableRange||!1,this._rangeChunkSize=r.rangeChunkSize,!this._rangeChunkSize&&!this._disableRange&&(this._disableRange=!0),this._abortController=new AbortController,this._isStreamingSupported=!r.disableStream,this._isRangeSupported=!r.disableRange,this._headers=r4e(this._stream.httpHeaders);const n=r.url;fetch(n,t4e(this._headers,this._withCredentials,this._abortController)).then(o=>{if(!e4e(o.status))throw Lx(o.status,n);this._reader=o.body.getReader(),this._headersCapability.resolve();const i=d=>o.headers.get(d),{allowRangeRequests:a,suggestedLength:l}=rN({getResponseHeader:i,isHttp:this._stream.isHttp,rangeChunkSize:this._rangeChunkSize,disableRange:this._disableRange});this._isRangeSupported=a,this._contentLength=l||this._contentLength,this._filename=nN(i),!this._isStreamingSupported&&this._isRangeSupported&&this.cancel(new Lm("Streaming is disabled."))}).catch(this._headersCapability.reject),this.onProgress=null}get headersReady(){return this._headersCapability.promise}get filename(){return this._filename}get contentLength(){return this._contentLength}get isRangeSupported(){return this._isRangeSupported}get isStreamingSupported(){return this._isStreamingSupported}async read(){await this._headersCapability.promise;const{value:t,done:r}=await this._reader.read();return r?{value:t,done:r}:(this._loaded+=t.byteLength,this.onProgress?.({loaded:this._loaded,total:this._contentLength}),{value:n4e(t),done:!1})}cancel(t){this._reader?.cancel(t),this._abortController.abort()}}class x0t{constructor(t,r,n){this._stream=t,this._reader=null,this._loaded=0;const o=t.source;this._withCredentials=o.withCredentials||!1,this._readCapability=Promise.withResolvers(),this._isStreamingSupported=!o.disableStream,this._abortController=new AbortController,this._headers=r4e(this._stream.httpHeaders),this._headers.append("Range",`bytes=${r}-${n-1}`);const i=o.url;fetch(i,t4e(this._headers,this._withCredentials,this._abortController)).then(a=>{if(!e4e(a.status))throw Lx(a.status,i);this._readCapability.resolve(),this._reader=a.body.getReader()}).catch(this._readCapability.reject),this.onProgress=null}get isStreamingSupported(){return this._isStreamingSupported}async read(){await this._readCapability.promise;const{value:t,done:r}=await this._reader.read();return r?{value:t,done:r}:(this._loaded+=t.byteLength,this.onProgress?.({loaded:this._loaded}),{value:n4e(t),done:!1})}cancel(t){this._reader?.cancel(t),this._abortController.abort()}}const cL=200,dL=206;function C0t(e){const t=e.response;return typeof t!="string"?t:Sx(t).buffer}class $0t{constructor(t,r={}){this.url=t,this.isHttp=/^https?:/i.test(t),this.httpHeaders=this.isHttp&&r.httpHeaders||Object.create(null),this.withCredentials=r.withCredentials||!1,this.currXhrId=0,this.pendingRequests=Object.create(null)}requestRange(t,r,n){const o={begin:t,end:r};for(const i in n)o[i]=n[i];return this.request(o)}requestFull(t){return this.request(t)}request(t){const r=new XMLHttpRequest,n=this.currXhrId++,o=this.pendingRequests[n]={xhr:r};r.open("GET",this.url),r.withCredentials=this.withCredentials;for(const i in this.httpHeaders){const a=this.httpHeaders[i];a!==void 0&&r.setRequestHeader(i,a)}return this.isHttp&&"begin"in t&&"end"in t?(r.setRequestHeader("Range",`bytes=${t.begin}-${t.end-1}`),o.expectedStatus=dL):o.expectedStatus=cL,r.responseType="arraybuffer",t.onError&&(r.onerror=function(i){t.onError(r.status)}),r.onreadystatechange=this.onStateChange.bind(this,n),r.onprogress=this.onProgress.bind(this,n),o.onHeadersReceived=t.onHeadersReceived,o.onDone=t.onDone,o.onError=t.onError,o.onProgress=t.onProgress,r.send(null),n}onProgress(t,r){const n=this.pendingRequests[t];n&&n.onProgress?.(r)}onStateChange(t,r){const n=this.pendingRequests[t];if(!n)return;const o=n.xhr;if(o.readyState>=2&&n.onHeadersReceived&&(n.onHeadersReceived(),delete n.onHeadersReceived),o.readyState!==4||!(t in this.pendingRequests))return;if(delete this.pendingRequests[t],o.status===0&&this.isHttp){n.onError?.(o.status);return}const i=o.status||cL;if(!(i===cL&&n.expectedStatus===dL)&&i!==n.expectedStatus){n.onError?.(o.status);return}const l=C0t(o);if(i===dL){const d=o.getResponseHeader("Content-Range"),u=/bytes (\d+)-(\d+)\/(\d+)/.exec(d);n.onDone({begin:parseInt(u[1],10),chunk:l})}else l?n.onDone({begin:0,chunk:l}):n.onError?.(o.status)}getRequestXhr(t){return this.pendingRequests[t].xhr}isPendingRequest(t){return t in this.pendingRequests}abortRequest(t){const r=this.pendingRequests[t].xhr;delete this.pendingRequests[t],r.abort()}}class S0t{constructor(t){this._source=t,this._manager=new $0t(t.url,{httpHeaders:t.httpHeaders,withCredentials:t.withCredentials}),this._rangeChunkSize=t.rangeChunkSize,this._fullRequestReader=null,this._rangeRequestReaders=[]}_onRangeRequestReaderClosed(t){const r=this._rangeRequestReaders.indexOf(t);r>=0&&this._rangeRequestReaders.splice(r,1)}getFullReader(){return Ai(!this._fullRequestReader,"PDFNetworkStream.getFullReader can only be called once."),this._fullRequestReader=new k0t(this._manager,this._source),this._fullRequestReader}getRangeReader(t,r){const n=new E0t(this._manager,t,r);return n.onClosed=this._onRangeRequestReaderClosed.bind(this),this._rangeRequestReaders.push(n),n}cancelAllRequests(t){this._fullRequestReader?.cancel(t);for(const r of this._rangeRequestReaders.slice(0))r.cancel(t)}}class k0t{constructor(t,r){this._manager=t;const n={onHeadersReceived:this._onHeadersReceived.bind(this),onDone:this._onDone.bind(this),onError:this._onError.bind(this),onProgress:this._onProgress.bind(this)};this._url=r.url,this._fullRequestId=t.requestFull(n),this._headersReceivedCapability=Promise.withResolvers(),this._disableRange=r.disableRange||!1,this._contentLength=r.length,this._rangeChunkSize=r.rangeChunkSize,!this._rangeChunkSize&&!this._disableRange&&(this._disableRange=!0),this._isStreamingSupported=!1,this._isRangeSupported=!1,this._cachedChunks=[],this._requests=[],this._done=!1,this._storedError=void 0,this._filename=null,this.onProgress=null}_onHeadersReceived(){const t=this._fullRequestId,r=this._manager.getRequestXhr(t),n=a=>r.getResponseHeader(a),{allowRangeRequests:o,suggestedLength:i}=rN({getResponseHeader:n,isHttp:this._manager.isHttp,rangeChunkSize:this._rangeChunkSize,disableRange:this._disableRange});o&&(this._isRangeSupported=!0),this._contentLength=i||this._contentLength,this._filename=nN(n),this._isRangeSupported&&this._manager.abortRequest(t),this._headersReceivedCapability.resolve()}_onDone(t){if(t&&(this._requests.length>0?this._requests.shift().resolve({value:t.chunk,done:!1}):this._cachedChunks.push(t.chunk)),this._done=!0,!(this._cachedChunks.length>0)){for(const r of this._requests)r.resolve({value:void 0,done:!0});this._requests.length=0}}_onError(t){this._storedError=Lx(t,this._url),this._headersReceivedCapability.reject(this._storedError);for(const r of this._requests)r.reject(this._storedError);this._requests.length=0,this._cachedChunks.length=0}_onProgress(t){this.onProgress?.({loaded:t.loaded,total:t.lengthComputable?t.total:this._contentLength})}get filename(){return this._filename}get isRangeSupported(){return this._isRangeSupported}get isStreamingSupported(){return this._isStreamingSupported}get contentLength(){return this._contentLength}get headersReady(){return this._headersReceivedCapability.promise}async read(){if(this._storedError)throw this._storedError;if(this._cachedChunks.length>0)return{value:this._cachedChunks.shift(),done:!1};if(this._done)return{value:void 0,done:!0};const t=Promise.withResolvers();return this._requests.push(t),t.promise}cancel(t){this._done=!0,this._headersReceivedCapability.reject(t);for(const r of this._requests)r.resolve({value:void 0,done:!0});this._requests.length=0,this._manager.isPendingRequest(this._fullRequestId)&&this._manager.abortRequest(this._fullRequestId),this._fullRequestReader=null}}class E0t{constructor(t,r,n){this._manager=t;const o={onDone:this._onDone.bind(this),onError:this._onError.bind(this),onProgress:this._onProgress.bind(this)};this._url=t.url,this._requestId=t.requestRange(r,n,o),this._requests=[],this._queuedChunk=null,this._done=!1,this._storedError=void 0,this.onProgress=null,this.onClosed=null}_close(){this.onClosed?.(this)}_onDone(t){const r=t.chunk;this._requests.length>0?this._requests.shift().resolve({value:r,done:!1}):this._queuedChunk=r,this._done=!0;for(const n of this._requests)n.resolve({value:void 0,done:!0});this._requests.length=0,this._close()}_onError(t){this._storedError=Lx(t,this._url);for(const r of this._requests)r.reject(this._storedError);this._requests.length=0,this._queuedChunk=null}_onProgress(t){this.isStreamingSupported||this.onProgress?.({loaded:t.loaded})}get isStreamingSupported(){return!1}async read(){if(this._storedError)throw this._storedError;if(this._queuedChunk!==null){const r=this._queuedChunk;return this._queuedChunk=null,{value:r,done:!1}}if(this._done)return{value:void 0,done:!0};const t=Promise.withResolvers();return this._requests.push(t),t.promise}cancel(t){this._done=!0;for(const r of this._requests)r.resolve({value:void 0,done:!0});this._requests.length=0,this._manager.isPendingRequest(this._requestId)&&this._manager.abortRequest(this._requestId),this._close()}}const o4e=/^file:\/\/\/[a-zA-Z]:\//;function _0t(e){const t=F1.get("url"),r=t.parse(e);return r.protocol==="file:"||r.host?r:/^[a-z]:[/\\]/i.test(e)?t.parse(`file:///${e}`):(r.host||(r.protocol="file:"),r)}class T0t{constructor(t){this.source=t,this.url=_0t(t.url),this.isHttp=this.url.protocol==="http:"||this.url.protocol==="https:",this.isFsUrl=this.url.protocol==="file:",this.httpHeaders=this.isHttp&&t.httpHeaders||{},this._fullRequestReader=null,this._rangeRequestReaders=[]}get _progressiveDataLength(){return this._fullRequestReader?._loaded??0}getFullReader(){return Ai(!this._fullRequestReader,"PDFNodeStream.getFullReader can only be called once."),this._fullRequestReader=this.isFsUrl?new D0t(this):new A0t(this),this._fullRequestReader}getRangeReader(t,r){if(r<=this._progressiveDataLength)return null;const n=this.isFsUrl?new M0t(this,t,r):new L0t(this,t,r);return this._rangeRequestReaders.push(n),n}cancelAllRequests(t){this._fullRequestReader?.cancel(t);for(const r of this._rangeRequestReaders.slice(0))r.cancel(t)}}class i4e{constructor(t){this._url=t.url,this._done=!1,this._storedError=null,this.onProgress=null;const r=t.source;this._contentLength=r.length,this._loaded=0,this._filename=null,this._disableRange=r.disableRange||!1,this._rangeChunkSize=r.rangeChunkSize,!this._rangeChunkSize&&!this._disableRange&&(this._disableRange=!0),this._isStreamingSupported=!r.disableStream,this._isRangeSupported=!r.disableRange,this._readableStream=null,this._readCapability=Promise.withResolvers(),this._headersCapability=Promise.withResolvers()}get headersReady(){return this._headersCapability.promise}get filename(){return this._filename}get contentLength(){return this._contentLength}get isRangeSupported(){return this._isRangeSupported}get isStreamingSupported(){return this._isStreamingSupported}async read(){if(await this._readCapability.promise,this._done)return{value:void 0,done:!0};if(this._storedError)throw this._storedError;const t=this._readableStream.read();return t===null?(this._readCapability=Promise.withResolvers(),this.read()):(this._loaded+=t.length,this.onProgress?.({loaded:this._loaded,total:this._contentLength}),{value:new Uint8Array(t).buffer,done:!1})}cancel(t){if(!this._readableStream){this._error(t);return}this._readableStream.destroy(t)}_error(t){this._storedError=t,this._readCapability.resolve()}_setReadableStream(t){this._readableStream=t,t.on("readable",()=>{this._readCapability.resolve()}),t.on("end",()=>{t.destroy(),this._done=!0,this._readCapability.resolve()}),t.on("error",r=>{this._error(r)}),!this._isStreamingSupported&&this._isRangeSupported&&this._error(new Lm("streaming is disabled")),this._storedError&&this._readableStream.destroy(this._storedError)}}class a4e{constructor(t){this._url=t.url,this._done=!1,this._storedError=null,this.onProgress=null,this._loaded=0,this._readableStream=null,this._readCapability=Promise.withResolvers();const r=t.source;this._isStreamingSupported=!r.disableStream}get isStreamingSupported(){return this._isStreamingSupported}async read(){if(await this._readCapability.promise,this._done)return{value:void 0,done:!0};if(this._storedError)throw this._storedError;const t=this._readableStream.read();return t===null?(this._readCapability=Promise.withResolvers(),this.read()):(this._loaded+=t.length,this.onProgress?.({loaded:this._loaded}),{value:new Uint8Array(t).buffer,done:!1})}cancel(t){if(!this._readableStream){this._error(t);return}this._readableStream.destroy(t)}_error(t){this._storedError=t,this._readCapability.resolve()}_setReadableStream(t){this._readableStream=t,t.on("readable",()=>{this._readCapability.resolve()}),t.on("end",()=>{t.destroy(),this._done=!0,this._readCapability.resolve()}),t.on("error",r=>{this._error(r)}),this._storedError&&this._readableStream.destroy(this._storedError)}}function ib(e,t){return{protocol:e.protocol,auth:e.auth,host:e.hostname,port:e.port,path:e.path,method:"GET",headers:t}}class A0t extends i4e{constructor(t){super(t);const r=n=>{if(n.statusCode===404){const l=new Am(`Missing PDF "${this._url}".`);this._storedError=l,this._headersCapability.reject(l);return}this._headersCapability.resolve(),this._setReadableStream(n);const o=l=>this._readableStream.headers[l.toLowerCase()],{allowRangeRequests:i,suggestedLength:a}=rN({getResponseHeader:o,isHttp:t.isHttp,rangeChunkSize:this._rangeChunkSize,disableRange:this._disableRange});this._isRangeSupported=i,this._contentLength=a||this._contentLength,this._filename=nN(o)};if(this._request=null,this._url.protocol==="http:"){const n=F1.get("http");this._request=n.request(ib(this._url,t.httpHeaders),r)}else{const n=F1.get("https");this._request=n.request(ib(this._url,t.httpHeaders),r)}this._request.on("error",n=>{this._storedError=n,this._headersCapability.reject(n)}),this._request.end()}}class L0t extends a4e{constructor(t,r,n){super(t),this._httpHeaders={};for(const i in t.httpHeaders){const a=t.httpHeaders[i];a!==void 0&&(this._httpHeaders[i]=a)}this._httpHeaders.Range=`bytes=${r}-${n-1}`;const o=i=>{if(i.statusCode===404){const a=new Am(`Missing PDF "${this._url}".`);this._storedError=a;return}this._setReadableStream(i)};if(this._request=null,this._url.protocol==="http:"){const i=F1.get("http");this._request=i.request(ib(this._url,this._httpHeaders),o)}else{const i=F1.get("https");this._request=i.request(ib(this._url,this._httpHeaders),o)}this._request.on("error",i=>{this._storedError=i}),this._request.end()}}class D0t extends i4e{constructor(t){super(t);let r=decodeURIComponent(this._url.path);o4e.test(this._url.href)&&(r=r.replace(/^\//,""));const n=F1.get("fs");n.promises.lstat(r).then(o=>{this._contentLength=o.size,this._setReadableStream(n.createReadStream(r)),this._headersCapability.resolve()},o=>{o.code==="ENOENT"&&(o=new Am(`Missing PDF "${r}".`)),this._storedError=o,this._headersCapability.reject(o)})}}class M0t extends a4e{constructor(t,r,n){super(t);let o=decodeURIComponent(this._url.path);o4e.test(this._url.href)&&(o=o.replace(/^\//,""));const i=F1.get("fs");this._setReadableStream(i.createReadStream(o,{start:r,end:n-1}))}}const P0t=1e5,as=30,I0t=.8;let ab=class Qd{#e=Promise.withResolvers();#t=null;#r=!1;#o=!!globalThis.FontInspector?.enabled;#s=null;#n=null;#i=0;#l=0;#d=null;#u=null;#h=0;#c=0;#a=Object.create(null);#m=[];#g=null;#p=[];#v=new WeakMap;#f=null;static#b=new Map;static#x=new Map;static#$=null;static#k=new Set;constructor({textContentSource:t,container:r,viewport:n}){if(t instanceof ReadableStream)this.#g=t;else if(typeof t=="object")this.#g=new ReadableStream({start(d){d.enqueue(t),d.close()}});else throw new Error('No "textContentSource" parameter specified.');this.#t=this.#u=r,this.#c=n.scale*(globalThis.devicePixelRatio||1),this.#h=n.rotation,this.#n={prevFontSize:null,prevFontFamily:null,div:null,properties:null,ctx:null};const{pageWidth:o,pageHeight:i,pageX:a,pageY:l}=n.rawDims;this.#f=[1,0,0,-1,-a,l+i],this.#l=o,this.#i=i,Qd.#y(),cm(r,n),this.#e.promise.catch(()=>{}).then(()=>{Qd.#k.delete(this),this.#n=null,this.#a=null})}render(){const t=()=>{this.#d.read().then(({value:r,done:n})=>{if(n){this.#e.resolve();return}this.#s??=r.lang,Object.assign(this.#a,r.styles),this.#E(r.items),t()},this.#e.reject)};return this.#d=this.#g.getReader(),Qd.#k.add(this),t(),this.#e.promise}update({viewport:t,onBefore:r=null}){const n=t.scale*(globalThis.devicePixelRatio||1),o=t.rotation;if(o!==this.#h&&(r?.(),this.#h=o,cm(this.#u,{rotation:o})),n!==this.#c){r?.(),this.#c=n;const i={prevFontSize:null,prevFontFamily:null,div:null,properties:null,ctx:Qd.#w(this.#s)};for(const a of this.#p)i.properties=this.#v.get(a),i.div=a,this.#S(i)}}cancel(){const t=new Lm("TextLayer task cancelled.");this.#d?.cancel(t).catch(()=>{}),this.#d=null,this.#e.reject(t)}get textDivs(){return this.#p}get textContentItemsStr(){return this.#m}#E(t){if(this.#r)return;this.#n.ctx??=Qd.#w(this.#s);const r=this.#p,n=this.#m;for(const o of t){if(r.length>P0t){Jr("Ignoring additional textDivs for performance reasons."),this.#r=!0;return}if(o.str===void 0){if(o.type==="beginMarkedContentProps"||o.type==="beginMarkedContent"){const i=this.#t;this.#t=document.createElement("span"),this.#t.classList.add("markedContent"),o.id!==null&&this.#t.setAttribute("id",`${o.id}`),i.append(this.#t)}else o.type==="endMarkedContent"&&(this.#t=this.#t.parentNode);continue}n.push(o.str),this.#L(o)}}#L(t){const r=document.createElement("span"),n={angle:0,canvasWidth:0,hasText:t.str!=="",hasEOL:t.hasEOL,fontSize:0};this.#p.push(r);const o=lr.transform(this.#f,t.transform);let i=Math.atan2(o[1],o[0]);const a=this.#a[t.fontName];a.vertical&&(i+=Math.PI/2);const l=this.#o&&a.fontSubstitution||a.fontFamily,d=Math.hypot(o[2],o[3]),u=d*Qd.#C(l,this.#s);let p,h;i===0?(p=o[4],h=o[5]-u):(p=o[4]+u*Math.sin(i),h=o[5]-u*Math.cos(i));const f="calc(var(--scale-factor)*",g=r.style;this.#t===this.#u?(g.left=`${(100*p/this.#l).toFixed(2)}%`,g.top=`${(100*h/this.#i).toFixed(2)}%`):(g.left=`${f}${p.toFixed(2)}px)`,g.top=`${f}${h.toFixed(2)}px)`),g.fontSize=`${f}${(Qd.#$*d).toFixed(2)}px)`,g.fontFamily=l,n.fontSize=d,r.setAttribute("role","presentation"),r.textContent=t.str,r.dir=t.dir,this.#o&&(r.dataset.fontName=a.fontSubstitutionLoadedName||t.fontName),i!==0&&(n.angle=i*(180/Math.PI));let y=!1;if(t.str.length>1)y=!0;else if(t.str!==" "&&t.transform[0]!==t.transform[3]){const v=Math.abs(t.transform[0]),w=Math.abs(t.transform[3]);v!==w&&Math.max(v,w)/Math.min(v,w)>1.5&&(y=!0)}if(y&&(n.canvasWidth=a.vertical?t.height:t.width),this.#v.set(r,n),this.#n.div=r,this.#n.properties=n,this.#S(this.#n),n.hasText&&this.#t.append(r),n.hasEOL){const v=document.createElement("br");v.setAttribute("role","presentation"),this.#t.append(v)}}#S(t){const{div:r,properties:n,ctx:o,prevFontSize:i,prevFontFamily:a}=t,{style:l}=r;let d="";if(Qd.#$>1&&(d=`scale(${1/Qd.#$})`),n.canvasWidth!==0&&n.hasText){const{fontFamily:u}=l,{canvasWidth:p,fontSize:h}=n;(i!==h||a!==u)&&(o.font=`${h*this.#c}px ${u}`,t.prevFontSize=h,t.prevFontFamily=u);const{width:f}=o.measureText(r.textContent);f>0&&(d=`scaleX(${p*this.#c/f}) ${d}`)}n.angle!==0&&(d=`rotate(${n.angle}deg) ${d}`),d.length>0&&(l.transform=d)}static cleanup(){if(!(this.#k.size>0)){this.#b.clear();for(const{canvas:t}of this.#x.values())t.remove();this.#x.clear()}}static#w(t=null){let r=this.#x.get(t||="");if(!r){const n=document.createElement("canvas");n.className="hiddenCanvasElement",n.lang=t,document.body.append(n),r=n.getContext("2d",{alpha:!1,willReadFrequently:!0}),this.#x.set(t,r)}return r}static#y(){if(this.#$!==null)return;const t=document.createElement("div");t.style.opacity=0,t.style.lineHeight=1,t.style.fontSize="1px",t.textContent="X",document.body.append(t),this.#$=t.getBoundingClientRect().height,t.remove()}static#C(t,r){const n=this.#b.get(t);if(n)return n;const o=this.#w(r),i=o.font;o.canvas.width=o.canvas.height=as,o.font=`${as}px ${t}`;const a=o.measureText("");let l=a.fontBoundingBoxAscent,d=Math.abs(a.fontBoundingBoxDescent);if(l){const h=l/(l+d);return this.#b.set(t,h),o.canvas.width=o.canvas.height=0,o.font=i,h}o.strokeStyle="red",o.clearRect(0,0,as,as),o.strokeText("g",0,0);let u=o.getImageData(0,0,as,as).data;d=0;for(let h=u.length-1-3;h>=0;h-=4)if(u[h]>0){d=Math.ceil(h/4/as);break}o.clearRect(0,0,as,as),o.strokeText("A",0,as),u=o.getImageData(0,0,as,as).data,l=0;for(let h=0,f=u.length;h<f;h+=4)if(u[h]>0){l=as-Math.floor(h/4/as);break}o.canvas.width=o.canvas.height=0,o.font=i;const p=l?l/(l+d):I0t;return this.#b.set(t,p),p}};function j0t(){Zge("`renderTextLayer`, please use `TextLayer` instead.");const{textContentSource:e,container:t,viewport:r,...n}=arguments[0],o=Object.keys(n);o.length>0&&Jr("Ignoring `renderTextLayer` parameters: "+o.join(", "));const i=new ab({textContentSource:e,container:t,viewport:r}),{textDivs:a,textContentItemsStr:l}=i;return{promise:i.render(),textDivs:a,textContentItemsStr:l}}function R0t(){Zge("`updateTextLayer`, please use `TextLayer` instead.")}class _7{static textContent(t){const r=[],n={items:r,styles:Object.create(null)};function o(i){if(!i)return;let a=null;const l=i.name;if(l==="#text")a=i.value;else if(_7.shouldBuildText(l))i?.attributes?.textContent?a=i.attributes.textContent:i.value&&(a=i.value);else return;if(a!==null&&r.push({str:a}),!!i.children)for(const d of i.children)o(d)}return o(t),n}static shouldBuildText(t){return!(t==="textarea"||t==="input"||t==="option"||t==="select")}}const F0t=65536,O0t=100,N0t=5e3,z0t=ka?X2t:O2t,B0t=ka?Q2t:Gge,H0t=ka?K2t:F2t,V0t=ka?J2t:qge;function U0t(e={}){typeof e=="string"||e instanceof URL?e={url:e}:(e instanceof ArrayBuffer||ArrayBuffer.isView(e))&&(e={data:e});const t=new oN,{docId:r}=t,n=e.url?W0t(e.url):null,o=e.data?Y0t(e.data):null,i=e.httpHeaders||null,a=e.withCredentials===!0,l=e.password??null,d=e.range instanceof s4e?e.range:null,u=Number.isInteger(e.rangeChunkSize)&&e.rangeChunkSize>0?e.rangeChunkSize:F0t;let p=e.worker instanceof kl?e.worker:null;const h=e.verbosity,f=typeof e.docBaseUrl=="string"&&!qO(e.docBaseUrl)?e.docBaseUrl:null,g=typeof e.cMapUrl=="string"?e.cMapUrl:null,y=e.cMapPacked!==!1,v=e.CMapReaderFactory||B0t,w=typeof e.standardFontDataUrl=="string"?e.standardFontDataUrl:null,x=e.StandardFontDataFactory||V0t,$=e.stopAtErrors!==!0,S=Number.isInteger(e.maxImageSize)&&e.maxImageSize>-1?e.maxImageSize:-1,k=e.isEvalSupported!==!1,T=typeof e.isOffscreenCanvasSupported=="boolean"?e.isOffscreenCanvasSupported:!ka,E=Number.isInteger(e.canvasMaxAreaInBytes)?e.canvasMaxAreaInBytes:-1,A=typeof e.disableFontFace=="boolean"?e.disableFontFace:ka,D=e.fontExtraProperties===!0,P=e.enableXfa===!0,j=e.ownerDocument||globalThis.document,B=e.disableRange===!0,O=e.disableStream===!0,q=e.disableAutoFetch===!0,W=e.pdfBug===!0,F=e.enableHWA===!0,V=d?d.length:e.length??NaN,I=typeof e.useSystemFonts=="boolean"?e.useSystemFonts:!ka&&!A,L=typeof e.useWorkerFetch=="boolean"?e.useWorkerFetch:v===Gge&&x===qge&&g&&w&&P5(g,document.baseURI)&&P5(w,document.baseURI),z=e.canvasFactory||new z0t({ownerDocument:j,enableHWA:F}),H=e.filterFactory||new H0t({docId:r,ownerDocument:j}),ee=null;E2t(h);const Z={canvasFactory:z,filterFactory:H};if(L||(Z.cMapReaderFactory=new v({baseUrl:g,isCompressed:y}),Z.standardFontDataFactory=new x({baseUrl:w})),!p){const Q={verbosity:h,port:E7.workerPort};p=Q.port?kl.fromPort(Q):new kl(Q),t._worker=p}const U={docId:r,apiVersion:"4.4.168",data:o,password:l,disableAutoFetch:q,rangeChunkSize:u,length:V,docBaseUrl:f,enableXfa:P,evaluatorOptions:{maxImageSize:S,disableFontFace:A,ignoreErrors:$,isEvalSupported:k,isOffscreenCanvasSupported:T,canvasMaxAreaInBytes:E,fontExtraProperties:D,useSystemFonts:I,cMapUrl:L?g:null,standardFontDataUrl:L?w:null}},X={disableFontFace:A,fontExtraProperties:D,ownerDocument:j,pdfBug:W,styleElement:ee,loadingParams:{disableAutoFetch:q,enableXfa:P}};return p.promise.then(function(){if(t.destroyed)throw new Error("Loading aborted");if(p.destroyed)throw new Error("Worker was destroyed");const Q=p.messageHandler.sendWithPromise("GetDocRequest",U,o?[o.buffer]:null);let oe;if(d)oe=new g0t(d,{disableRange:B,disableStream:O});else if(!o){if(!n)throw new Error("getDocument - no `url` parameter provided.");oe=(le=>ka?function(){return typeof fetch<"u"&&typeof Response<"u"&&"body"in Response.prototype}()&&P5(le.url)?new oJ(le):new T0t(le):P5(le.url)?new oJ(le):new S0t(le))({url:n,length:V,httpHeaders:i,withCredentials:a,rangeChunkSize:u,disableRange:B,disableStream:O})}return Q.then(ge=>{if(t.destroyed)throw new Error("Loading aborted");if(p.destroyed)throw new Error("Worker was destroyed");const le=new I5(r,ge,p.port),se=new K0t(le,t,oe,X,Z);t._transport=se,le.send("Ready",null)})}).catch(t._capability.reject),t}function W0t(e){if(e instanceof URL)return e.href;try{return new URL(e,window.location).href}catch{if(ka&&typeof e=="string")return e}throw new Error("Invalid PDF url data: either string or URL-object is expected in the url property.")}function Y0t(e){if(ka&&typeof ev<"u"&&e instanceof ev)throw new Error("Please provide binary data as `Uint8Array`, rather than `Buffer`.");if(e instanceof Uint8Array&&e.byteLength===e.buffer.byteLength)return e;if(typeof e=="string")return Sx(e);if(e instanceof ArrayBuffer||ArrayBuffer.isView(e)||typeof e=="object"&&!isNaN(e?.length))return new Uint8Array(e);throw new Error("Invalid PDF binary data: either TypedArray, string, or array-like object is expected in the data property.")}function iJ(e){return typeof e=="object"&&Number.isInteger(e?.num)&&e.num>=0&&Number.isInteger(e?.gen)&&e.gen>=0}class oN{static#e=0;constructor(){this._capability=Promise.withResolvers(),this._transport=null,this._worker=null,this.docId=`d${oN.#e++}`,this.destroyed=!1,this.onPassword=null,this.onProgress=null}get promise(){return this._capability.promise}async destroy(){this.destroyed=!0;try{this._worker?.port&&(this._worker._pendingDestroy=!0),await this._transport?.destroy()}catch(t){throw this._worker?.port&&delete this._worker._pendingDestroy,t}this._transport=null,this._worker&&(this._worker.destroy(),this._worker=null)}}let s4e=class{constructor(t,r,n=!1,o=null){this.length=t,this.initialData=r,this.progressiveDone=n,this.contentDispositionFilename=o,this._rangeListeners=[],this._progressListeners=[],this._progressiveReadListeners=[],this._progressiveDoneListeners=[],this._readyCapability=Promise.withResolvers()}addRangeListener(t){this._rangeListeners.push(t)}addProgressListener(t){this._progressListeners.push(t)}addProgressiveReadListener(t){this._progressiveReadListeners.push(t)}addProgressiveDoneListener(t){this._progressiveDoneListeners.push(t)}onDataRange(t,r){for(const n of this._rangeListeners)n(t,r)}onDataProgress(t,r){this._readyCapability.promise.then(()=>{for(const n of this._progressListeners)n(t,r)})}onDataProgressiveRead(t){this._readyCapability.promise.then(()=>{for(const r of this._progressiveReadListeners)r(t)})}onDataProgressiveDone(){this._readyCapability.promise.then(()=>{for(const t of this._progressiveDoneListeners)t()})}transportReady(){this._readyCapability.resolve()}requestDataRange(t,r){Xn("Abstract method PDFDataRangeTransport.requestDataRange")}abort(){}};class G0t{constructor(t,r){this._pdfInfo=t,this._transport=r}get annotationStorage(){return this._transport.annotationStorage}get filterFactory(){return this._transport.filterFactory}get numPages(){return this._pdfInfo.numPages}get fingerprints(){return this._pdfInfo.fingerprints}get isPureXfa(){return vn(this,"isPureXfa",!!this._transport._htmlForXfa)}get allXfaHtml(){return this._transport._htmlForXfa}getPage(t){return this._transport.getPage(t)}getPageIndex(t){return this._transport.getPageIndex(t)}getDestinations(){return this._transport.getDestinations()}getDestination(t){return this._transport.getDestination(t)}getPageLabels(){return this._transport.getPageLabels()}getPageLayout(){return this._transport.getPageLayout()}getPageMode(){return this._transport.getPageMode()}getViewerPreferences(){return this._transport.getViewerPreferences()}getOpenAction(){return this._transport.getOpenAction()}getAttachments(){return this._transport.getAttachments()}getJSActions(){return this._transport.getDocJSActions()}getOutline(){return this._transport.getOutline()}getOptionalContentConfig({intent:t="display"}={}){const{renderingIntent:r}=this._transport.getRenderingIntent(t);return this._transport.getOptionalContentConfig(r)}getPermissions(){return this._transport.getPermissions()}getMetadata(){return this._transport.getMetadata()}getMarkInfo(){return this._transport.getMarkInfo()}getData(){return this._transport.getData()}saveDocument(){return this._transport.saveDocument()}getDownloadInfo(){return this._transport.downloadInfoCapability.promise}cleanup(t=!1){return this._transport.startCleanup(t||this.isPureXfa)}destroy(){return this.loadingTask.destroy()}cachedPageNumber(t){return this._transport.cachedPageNumber(t)}get loadingParams(){return this._transport.loadingParams}get loadingTask(){return this._transport.loadingTask}getFieldObjects(){return this._transport.getFieldObjects()}hasJSActions(){return this._transport.hasJSActions()}getCalculationOrderIds(){return this._transport.getCalculationOrderIds()}}class q0t{#e=null;#t=!1;constructor(t,r,n,o=!1){this._pageIndex=t,this._pageInfo=r,this._transport=n,this._stats=o?new WQ:null,this._pdfBug=o,this.commonObjs=n.commonObjs,this.objs=new l4e,this._maybeCleanupAfterRender=!1,this._intentStates=new Map,this.destroyed=!1}get pageNumber(){return this._pageIndex+1}get rotate(){return this._pageInfo.rotate}get ref(){return this._pageInfo.ref}get userUnit(){return this._pageInfo.userUnit}get view(){return this._pageInfo.view}getViewport({scale:t,rotation:r=this.rotate,offsetX:n=0,offsetY:o=0,dontFlip:i=!1}={}){return new u6({viewBox:this.view,scale:t,rotation:r,offsetX:n,offsetY:o,dontFlip:i})}getAnnotations({intent:t="display"}={}){const{renderingIntent:r}=this._transport.getRenderingIntent(t);return this._transport.getAnnotations(this._pageIndex,r)}getJSActions(){return this._transport.getPageJSActions(this._pageIndex)}get filterFactory(){return this._transport.filterFactory}get isPureXfa(){return vn(this,"isPureXfa",!!this._transport._htmlForXfa)}async getXfa(){return this._transport._htmlForXfa?.children[this._pageIndex]||null}render({canvasContext:t,viewport:r,intent:n="display",annotationMode:o=X2.ENABLE,transform:i=null,background:a=null,optionalContentConfigPromise:l=null,annotationCanvasMap:d=null,pageColors:u=null,printAnnotationStorage:p=null}){this._stats?.time("Overall");const h=this._transport.getRenderingIntent(n,o,p),{renderingIntent:f,cacheKey:g}=h;this.#t=!1,this.#o(),l||=this._transport.getOptionalContentConfig(f);let y=this._intentStates.get(g);y||(y=Object.create(null),this._intentStates.set(g,y)),y.streamReaderCancelTimeout&&(clearTimeout(y.streamReaderCancelTimeout),y.streamReaderCancelTimeout=null);const v=!!(f&$l.PRINT);y.displayReadyCapability||(y.displayReadyCapability=Promise.withResolvers(),y.operatorList={fnArray:[],argsArray:[],lastChunk:!1,separateAnnots:null},this._stats?.time("Page Request"),this._pumpOperatorList(h));const w=S=>{y.renderTasks.delete(x),(this._maybeCleanupAfterRender||v)&&(this.#t=!0),this.#r(!v),S?(x.capability.reject(S),this._abortOperatorList({intentState:y,reason:S instanceof Error?S:new Error(S)})):x.capability.resolve(),this._stats&&(this._stats.timeEnd("Rendering"),this._stats.timeEnd("Overall"),globalThis.Stats?.enabled&&globalThis.Stats.add(this.pageNumber,this._stats))},x=new hf({callback:w,params:{canvasContext:t,viewport:r,transform:i,background:a},objs:this.objs,commonObjs:this.commonObjs,annotationCanvasMap:d,operatorList:y.operatorList,pageIndex:this._pageIndex,canvasFactory:this._transport.canvasFactory,filterFactory:this._transport.filterFactory,useRequestAnimationFrame:!v,pdfBug:this._pdfBug,pageColors:u});(y.renderTasks||=new Set).add(x);const $=x.task;return Promise.all([y.displayReadyCapability.promise,l]).then(([S,k])=>{if(this.destroyed){w();return}if(this._stats?.time("Rendering"),!(k.renderingIntent&f))throw new Error("Must use the same `intent`-argument when calling the `PDFPageProxy.render` and `PDFDocumentProxy.getOptionalContentConfig` methods.");x.initializeGraphics({transparency:S,optionalContentConfig:k}),x.operatorListChanged()}).catch(w),$}getOperatorList({intent:t="display",annotationMode:r=X2.ENABLE,printAnnotationStorage:n=null}={}){function o(){a.operatorList.lastChunk&&(a.opListReadCapability.resolve(a.operatorList),a.renderTasks.delete(l))}const i=this._transport.getRenderingIntent(t,r,n,!0);let a=this._intentStates.get(i.cacheKey);a||(a=Object.create(null),this._intentStates.set(i.cacheKey,a));let l;return a.opListReadCapability||(l=Object.create(null),l.operatorListChanged=o,a.opListReadCapability=Promise.withResolvers(),(a.renderTasks||=new Set).add(l),a.operatorList={fnArray:[],argsArray:[],lastChunk:!1,separateAnnots:null},this._stats?.time("Page Request"),this._pumpOperatorList(i)),a.opListReadCapability.promise}streamTextContent({includeMarkedContent:t=!1,disableNormalization:r=!1}={}){return this._transport.messageHandler.sendWithStream("GetTextContent",{pageIndex:this._pageIndex,includeMarkedContent:t===!0,disableNormalization:r===!0},{highWaterMark:100,size(o){return o.items.length}})}getTextContent(t={}){if(this._transport._htmlForXfa)return this.getXfa().then(n=>_7.textContent(n));const r=this.streamTextContent(t);return new Promise(function(n,o){function i(){a.read().then(function({value:d,done:u}){if(u){n(l);return}l.lang??=d.lang,Object.assign(l.styles,d.styles),l.items.push(...d.items),i()},o)}const a=r.getReader(),l={items:[],styles:Object.create(null),lang:null};i()})}getStructTree(){return this._transport.getStructTree(this._pageIndex)}_destroy(){this.destroyed=!0;const t=[];for(const r of this._intentStates.values())if(this._abortOperatorList({intentState:r,reason:new Error("Page was destroyed."),force:!0}),!r.opListReadCapability)for(const n of r.renderTasks)t.push(n.completed),n.cancel();return this.objs.clear(),this.#t=!1,this.#o(),Promise.all(t)}cleanup(t=!1){this.#t=!0;const r=this.#r(!1);return t&&r&&(this._stats&&=new WQ),r}#r(t=!1){if(this.#o(),!this.#t||this.destroyed)return!1;if(t)return this.#e=setTimeout(()=>{this.#e=null,this.#r(!1)},N0t),!1;for(const{renderTasks:r,operatorList:n}of this._intentStates.values())if(r.size>0||!n.lastChunk)return!1;return this._intentStates.clear(),this.objs.clear(),this.#t=!1,!0}#o(){this.#e&&(clearTimeout(this.#e),this.#e=null)}_startRenderPage(t,r){const n=this._intentStates.get(r);n&&(this._stats?.timeEnd("Page Request"),n.displayReadyCapability?.resolve(t))}_renderPageChunk(t,r){for(let n=0,o=t.length;n<o;n++)r.operatorList.fnArray.push(t.fnArray[n]),r.operatorList.argsArray.push(t.argsArray[n]);r.operatorList.lastChunk=t.lastChunk,r.operatorList.separateAnnots=t.separateAnnots;for(const n of r.renderTasks)n.operatorListChanged();t.lastChunk&&this.#r(!0)}_pumpOperatorList({renderingIntent:t,cacheKey:r,annotationStorageSerializable:n}){const{map:o,transfer:i}=n,l=this._transport.messageHandler.sendWithStream("GetOperatorList",{pageIndex:this._pageIndex,intent:t,cacheKey:r,annotationStorage:o},i).getReader(),d=this._intentStates.get(r);d.streamReader=l;const u=()=>{l.read().then(({value:p,done:h})=>{if(h){d.streamReader=null;return}this._transport.destroyed||(this._renderPageChunk(p,d),u())},p=>{if(d.streamReader=null,!this._transport.destroyed){if(d.operatorList){d.operatorList.lastChunk=!0;for(const h of d.renderTasks)h.operatorListChanged();this.#r(!0)}if(d.displayReadyCapability)d.displayReadyCapability.reject(p);else if(d.opListReadCapability)d.opListReadCapability.reject(p);else throw p}})};u()}_abortOperatorList({intentState:t,reason:r,force:n=!1}){if(t.streamReader){if(t.streamReaderCancelTimeout&&(clearTimeout(t.streamReaderCancelTimeout),t.streamReaderCancelTimeout=null),!n){if(t.renderTasks.size>0)return;if(r instanceof GO){let o=O0t;r.extraDelay>0&&r.extraDelay<1e3&&(o+=r.extraDelay),t.streamReaderCancelTimeout=setTimeout(()=>{t.streamReaderCancelTimeout=null,this._abortOperatorList({intentState:t,reason:r,force:!0})},o);return}}if(t.streamReader.cancel(new Lm(r.message)).catch(()=>{}),t.streamReader=null,!this._transport.destroyed){for(const[o,i]of this._intentStates)if(i===t){this._intentStates.delete(o);break}this.cleanup()}}}get stats(){return this._stats}}class Z0t{#e=new Set;#t=Promise.resolve();postMessage(t,r){const n={data:structuredClone(t,r?{transfer:r}:null)};this.#t.then(()=>{for(const o of this.#e)o.call(this,n)})}addEventListener(t,r){this.#e.add(r)}removeEventListener(t,r){this.#e.delete(r)}terminate(){this.#e.clear()}}const Pu={isWorkerDisabled:!1,fakeWorkerId:0};ka&&(Pu.isWorkerDisabled=!0,E7.workerSrc||="./pdf.worker.mjs"),Pu.isSameOrigin=function(e,t){let r;try{if(r=new URL(e),!r.origin||r.origin==="null")return!1}catch{return!1}const n=new URL(t,r);return r.origin===n.origin},Pu.createCDNWrapper=function(e){const t=`await import("${e}");`;return URL.createObjectURL(new Blob([t],{type:"text/javascript"}))};class kl{static#e;constructor({name:t=null,port:r=null,verbosity:n=_2t()}={}){if(this.name=t,this.destroyed=!1,this.verbosity=n,this._readyCapability=Promise.withResolvers(),this._port=null,this._webWorker=null,this._messageHandler=null,r){if(kl.#e?.has(r))throw new Error("Cannot use more than one PDFWorker per port.");(kl.#e||=new WeakMap).set(r,this),this._initializeFromPort(r);return}this._initialize()}get promise(){return ka?Promise.all([F1.promise,this._readyCapability.promise]):this._readyCapability.promise}#t(){this._readyCapability.resolve(),this._messageHandler.send("configure",{verbosity:this.verbosity})}get port(){return this._port}get messageHandler(){return this._messageHandler}_initializeFromPort(t){this._port=t,this._messageHandler=new I5("main","worker",t),this._messageHandler.on("ready",function(){}),this.#t()}_initialize(){if(Pu.isWorkerDisabled||kl.#r){this._setupFakeWorker();return}let{workerSrc:t}=kl;try{Pu.isSameOrigin(window.location.href,t)||(t=Pu.createCDNWrapper(new URL(t,window.location).href));const r=new Worker(t,{type:"module"}),n=new I5("main","worker",r),o=()=>{i.abort(),n.destroy(),r.terminate(),this.destroyed?this._readyCapability.reject(new Error("Worker was destroyed")):this._setupFakeWorker()},i=new AbortController;r.addEventListener("error",()=>{this._webWorker||o()},{signal:i.signal}),n.on("test",l=>{if(i.abort(),this.destroyed||!l){o();return}this._messageHandler=n,this._port=r,this._webWorker=r,this.#t()}),n.on("ready",l=>{if(i.abort(),this.destroyed){o();return}try{a()}catch{this._setupFakeWorker()}});const a=()=>{const l=new Uint8Array;n.send("test",l,[l.buffer])};a();return}catch{Cx("The worker has been disabled.")}this._setupFakeWorker()}_setupFakeWorker(){Pu.isWorkerDisabled||(Jr("Setting up fake worker."),Pu.isWorkerDisabled=!0),kl._setupFakeWorkerGlobal.then(t=>{if(this.destroyed){this._readyCapability.reject(new Error("Worker was destroyed"));return}const r=new Z0t;this._port=r;const n=`fake${Pu.fakeWorkerId++}`,o=new I5(n+"_worker",n,r);t.setup(o,r),this._messageHandler=new I5(n,n+"_worker",r),this.#t()}).catch(t=>{this._readyCapability.reject(new Error(`Setting up fake worker failed: "${t.message}".`))})}destroy(){this.destroyed=!0,this._webWorker&&(this._webWorker.terminate(),this._webWorker=null),kl.#e?.delete(this._port),this._port=null,this._messageHandler&&(this._messageHandler.destroy(),this._messageHandler=null)}static fromPort(t){if(!t?.port)throw new Error("PDFWorker.fromPort - invalid method signature.");const r=this.#e?.get(t.port);if(r){if(r._pendingDestroy)throw new Error("PDFWorker.fromPort - the worker is being destroyed.\nPlease remember to await `PDFDocumentLoadingTask.destroy()`-calls.");return r}return new kl(t)}static get workerSrc(){if(E7.workerSrc)return E7.workerSrc;throw new Error('No "GlobalWorkerOptions.workerSrc" specified.')}static get#r(){try{return globalThis.pdfjsWorker?.WorkerMessageHandler||null}catch{return null}}static get _setupFakeWorkerGlobal(){return vn(this,"_setupFakeWorkerGlobal",(async()=>this.#r?this.#r:(await import(this.workerSrc)).WorkerMessageHandler)())}}class K0t{#e=new Map;#t=new Map;#r=new Map;#o=new Map;#s=null;constructor(t,r,n,o,i){this.messageHandler=t,this.loadingTask=r,this.commonObjs=new l4e,this.fontLoader=new q2t({ownerDocument:o.ownerDocument,styleElement:o.styleElement}),this.loadingParams=o.loadingParams,this._params=o,this.canvasFactory=i.canvasFactory,this.filterFactory=i.filterFactory,this.cMapReaderFactory=i.cMapReaderFactory,this.standardFontDataFactory=i.standardFontDataFactory,this.destroyed=!1,this.destroyCapability=null,this._networkStream=n,this._fullReader=null,this._lastProgress=null,this.downloadInfoCapability=Promise.withResolvers(),this.setupMessageHandler()}#n(t,r=null){const n=this.#e.get(t);if(n)return n;const o=this.messageHandler.sendWithPromise(t,r);return this.#e.set(t,o),o}get annotationStorage(){return vn(this,"annotationStorage",new eN)}getRenderingIntent(t,r=X2.ENABLE,n=null,o=!1){let i=$l.DISPLAY,a=lj;switch(t){case"any":i=$l.ANY;break;case"display":break;case"print":i=$l.PRINT;break;default:Jr(`getRenderingIntent - invalid intent: ${t}`)}switch(r){case X2.DISABLE:i+=$l.ANNOTATIONS_DISABLE;break;case X2.ENABLE:break;case X2.ENABLE_FORMS:i+=$l.ANNOTATIONS_FORMS;break;case X2.ENABLE_STORAGE:i+=$l.ANNOTATIONS_STORAGE,a=(i&$l.PRINT&&n instanceof Qge?n:this.annotationStorage).serializable;break;default:Jr(`getRenderingIntent - invalid annotationMode: ${r}`)}return o&&(i+=$l.OPLIST),{renderingIntent:i,cacheKey:`${i}_${a.hash}`,annotationStorageSerializable:a}}destroy(){if(this.destroyCapability)return this.destroyCapability.promise;this.destroyed=!0,this.destroyCapability=Promise.withResolvers(),this.#s?.reject(new Error("Worker was destroyed during onPassword callback"));const t=[];for(const n of this.#t.values())t.push(n._destroy());this.#t.clear(),this.#r.clear(),this.#o.clear(),this.hasOwnProperty("annotationStorage")&&this.annotationStorage.resetModified();const r=this.messageHandler.sendWithPromise("Terminate",null);return t.push(r),Promise.all(t).then(()=>{this.commonObjs.clear(),this.fontLoader.clear(),this.#e.clear(),this.filterFactory.destroy(),ab.cleanup(),this._networkStream?.cancelAllRequests(new Lm("Worker was terminated.")),this.messageHandler&&(this.messageHandler.destroy(),this.messageHandler=null),this.destroyCapability.resolve()},this.destroyCapability.reject),this.destroyCapability.promise}setupMessageHandler(){const{messageHandler:t,loadingTask:r}=this;t.on("GetReader",(n,o)=>{Ai(this._networkStream,"GetReader - no `IPDFStream` instance available."),this._fullReader=this._networkStream.getFullReader(),this._fullReader.onProgress=i=>{this._lastProgress={loaded:i.loaded,total:i.total}},o.onPull=()=>{this._fullReader.read().then(function({value:i,done:a}){if(a){o.close();return}Ai(i instanceof ArrayBuffer,"GetReader - expected an ArrayBuffer."),o.enqueue(new Uint8Array(i),1,[i])}).catch(i=>{o.error(i)})},o.onCancel=i=>{this._fullReader.cancel(i),o.ready.catch(a=>{if(!this.destroyed)throw a})}}),t.on("ReaderHeadersReady",n=>{const o=Promise.withResolvers(),i=this._fullReader;return i.headersReady.then(()=>{(!i.isStreamingSupported||!i.isRangeSupported)&&(this._lastProgress&&r.onProgress?.(this._lastProgress),i.onProgress=a=>{r.onProgress?.({loaded:a.loaded,total:a.total})}),o.resolve({isStreamingSupported:i.isStreamingSupported,isRangeSupported:i.isRangeSupported,contentLength:i.contentLength})},o.reject),o.promise}),t.on("GetRangeReader",(n,o)=>{Ai(this._networkStream,"GetRangeReader - no `IPDFStream` instance available.");const i=this._networkStream.getRangeReader(n.begin,n.end);if(!i){o.close();return}o.onPull=()=>{i.read().then(function({value:a,done:l}){if(l){o.close();return}Ai(a instanceof ArrayBuffer,"GetRangeReader - expected an ArrayBuffer."),o.enqueue(new Uint8Array(a),1,[a])}).catch(a=>{o.error(a)})},o.onCancel=a=>{i.cancel(a),o.ready.catch(l=>{if(!this.destroyed)throw l})}}),t.on("GetDoc",({pdfInfo:n})=>{this._numPages=n.numPages,this._htmlForXfa=n.htmlForXfa,delete n.htmlForXfa,r._capability.resolve(new G0t(n,this))}),t.on("DocException",function(n){let o;switch(n.name){case"PasswordException":o=new aj(n.message,n.code);break;case"InvalidPDFException":o=new Uge(n.message);break;case"MissingPDFException":o=new Am(n.message);break;case"UnexpectedResponseException":o=new $x(n.message,n.status);break;case"UnknownErrorException":o=new sj(n.message,n.details);break;default:Xn("DocException - expected a valid Error.")}r._capability.reject(o)}),t.on("PasswordRequest",n=>{if(this.#s=Promise.withResolvers(),r.onPassword){const o=i=>{i instanceof Error?this.#s.reject(i):this.#s.resolve({password:i})};try{r.onPassword(o,n.code)}catch(i){this.#s.reject(i)}}else this.#s.reject(new aj(n.message,n.code));return this.#s.promise}),t.on("DataLoaded",n=>{r.onProgress?.({loaded:n.length,total:n.length}),this.downloadInfoCapability.resolve(n)}),t.on("StartRenderPage",n=>{if(this.destroyed)return;this.#t.get(n.pageIndex)._startRenderPage(n.transparency,n.cacheKey)}),t.on("commonobj",([n,o,i])=>{if(this.destroyed||this.commonObjs.has(n))return null;switch(o){case"Font":const{disableFontFace:a,fontExtraProperties:l,pdfBug:d}=this._params;if("error"in i){const f=i.error;Jr(`Error during font loading: ${f}`),this.commonObjs.resolve(n,f);break}const u=d&&globalThis.FontInspector?.enabled?(f,g)=>globalThis.FontInspector.fontAdded(f,g):null,p=new Z2t(i,{disableFontFace:a,inspectFont:u});this.fontLoader.bind(p).catch(()=>t.sendWithPromise("FontFallback",{id:n})).finally(()=>{!l&&p.data&&(p.data=null),this.commonObjs.resolve(n,p)});break;case"CopyLocalImage":const{imageRef:h}=i;Ai(h,"The imageRef must be defined.");for(const f of this.#t.values())for(const[,g]of f.objs)if(g?.ref===h)return g.dataLen?(this.commonObjs.resolve(n,structuredClone(g)),g.dataLen):null;break;case"FontPath":case"Image":case"Pattern":this.commonObjs.resolve(n,i);break;default:throw new Error(`Got unknown common object type ${o}`)}return null}),t.on("obj",([n,o,i,a])=>{if(this.destroyed)return;const l=this.#t.get(o);if(!l.objs.has(n)){if(l._intentStates.size===0){a?.bitmap?.close();return}switch(i){case"Image":l.objs.resolve(n,a),a?.dataLen>C2t&&(l._maybeCleanupAfterRender=!0);break;case"Pattern":l.objs.resolve(n,a);break;default:throw new Error(`Got unknown object type ${i}`)}}}),t.on("DocProgress",n=>{this.destroyed||r.onProgress?.({loaded:n.loaded,total:n.total})}),t.on("FetchBuiltInCMap",n=>this.destroyed?Promise.reject(new Error("Worker was destroyed.")):this.cMapReaderFactory?this.cMapReaderFactory.fetch(n):Promise.reject(new Error("CMapReaderFactory not initialized, see the `useWorkerFetch` parameter."))),t.on("FetchStandardFontData",n=>this.destroyed?Promise.reject(new Error("Worker was destroyed.")):this.standardFontDataFactory?this.standardFontDataFactory.fetch(n):Promise.reject(new Error("StandardFontDataFactory not initialized, see the `useWorkerFetch` parameter.")))}getData(){return this.messageHandler.sendWithPromise("GetData",null)}saveDocument(){this.annotationStorage.size<=0&&Jr("saveDocument called while `annotationStorage` is empty, please use the getData-method instead.");const{map:t,transfer:r}=this.annotationStorage.serializable;return this.messageHandler.sendWithPromise("SaveDocument",{isPureXfa:!!this._htmlForXfa,numPages:this._numPages,annotationStorage:t,filename:this._fullReader?.filename??null},r).finally(()=>{this.annotationStorage.resetModified()})}getPage(t){if(!Number.isInteger(t)||t<=0||t>this._numPages)return Promise.reject(new Error("Invalid page request."));const r=t-1,n=this.#r.get(r);if(n)return n;const o=this.messageHandler.sendWithPromise("GetPage",{pageIndex:r}).then(i=>{if(this.destroyed)throw new Error("Transport destroyed");i.refStr&&this.#o.set(i.refStr,t);const a=new q0t(r,i,this,this._params.pdfBug);return this.#t.set(r,a),a});return this.#r.set(r,o),o}getPageIndex(t){return iJ(t)?this.messageHandler.sendWithPromise("GetPageIndex",{num:t.num,gen:t.gen}):Promise.reject(new Error("Invalid pageIndex request."))}getAnnotations(t,r){return this.messageHandler.sendWithPromise("GetAnnotations",{pageIndex:t,intent:r})}getFieldObjects(){return this.#n("GetFieldObjects")}hasJSActions(){return this.#n("HasJSActions")}getCalculationOrderIds(){return this.messageHandler.sendWithPromise("GetCalculationOrderIds",null)}getDestinations(){return this.messageHandler.sendWithPromise("GetDestinations",null)}getDestination(t){return typeof t!="string"?Promise.reject(new Error("Invalid destination request.")):this.messageHandler.sendWithPromise("GetDestination",{id:t})}getPageLabels(){return this.messageHandler.sendWithPromise("GetPageLabels",null)}getPageLayout(){return this.messageHandler.sendWithPromise("GetPageLayout",null)}getPageMode(){return this.messageHandler.sendWithPromise("GetPageMode",null)}getViewerPreferences(){return this.messageHandler.sendWithPromise("GetViewerPreferences",null)}getOpenAction(){return this.messageHandler.sendWithPromise("GetOpenAction",null)}getAttachments(){return this.messageHandler.sendWithPromise("GetAttachments",null)}getDocJSActions(){return this.#n("GetDocJSActions")}getPageJSActions(t){return this.messageHandler.sendWithPromise("GetPageJSActions",{pageIndex:t})}getStructTree(t){return this.messageHandler.sendWithPromise("GetStructTree",{pageIndex:t})}getOutline(){return this.messageHandler.sendWithPromise("GetOutline",null)}getOptionalContentConfig(t){return this.#n("GetOptionalContentConfig").then(r=>new f0t(r,t))}getPermissions(){return this.messageHandler.sendWithPromise("GetPermissions",null)}getMetadata(){const t="GetMetadata",r=this.#e.get(t);if(r)return r;const n=this.messageHandler.sendWithPromise(t,null).then(o=>({info:o[0],metadata:o[1]?new h0t(o[1]):null,contentDispositionFilename:this._fullReader?.filename??null,contentLength:this._fullReader?.contentLength??null}));return this.#e.set(t,n),n}getMarkInfo(){return this.messageHandler.sendWithPromise("GetMarkInfo",null)}async startCleanup(t=!1){if(!this.destroyed){await this.messageHandler.sendWithPromise("Cleanup",null);for(const r of this.#t.values())if(!r.cleanup())throw new Error(`startCleanup: Page ${r.pageNumber} is currently rendering.`);this.commonObjs.clear(),t||this.fontLoader.clear(),this.#e.clear(),this.filterFactory.destroy(!0),ab.cleanup()}}cachedPageNumber(t){if(!iJ(t))return null;const r=t.gen===0?`${t.num}R`:`${t.num}R${t.gen}`;return this.#o.get(r)??null}}const j9=Symbol("INITIAL_DATA");class l4e{#e=Object.create(null);#t(t){return this.#e[t]||={...Promise.withResolvers(),data:j9}}get(t,r=null){if(r){const o=this.#t(t);return o.promise.then(()=>r(o.data)),null}const n=this.#e[t];if(!n||n.data===j9)throw new Error(`Requesting object that isn't resolved yet ${t}.`);return n.data}has(t){const r=this.#e[t];return!!r&&r.data!==j9}resolve(t,r=null){const n=this.#t(t);n.data=r,n.resolve()}clear(){for(const t in this.#e){const{data:r}=this.#e[t];r?.bitmap?.close()}this.#e=Object.create(null)}*[Symbol.iterator](){for(const t in this.#e){const{data:r}=this.#e[t];r!==j9&&(yield[t,r])}}}class X0t{#e=null;constructor(t){this.#e=t,this.onContinue=null}get promise(){return this.#e.capability.promise}cancel(t=0){this.#e.cancel(null,t)}get separateAnnots(){const{separateAnnots:t}=this.#e.operatorList;if(!t)return!1;const{annotationCanvasMap:r}=this.#e;return t.form||t.canvas&&r?.size>0}}class hf{#e=null;static#t=new WeakSet;constructor({callback:t,params:r,objs:n,commonObjs:o,annotationCanvasMap:i,operatorList:a,pageIndex:l,canvasFactory:d,filterFactory:u,useRequestAnimationFrame:p=!1,pdfBug:h=!1,pageColors:f=null}){this.callback=t,this.params=r,this.objs=n,this.commonObjs=o,this.annotationCanvasMap=i,this.operatorListIdx=null,this.operatorList=a,this._pageIndex=l,this.canvasFactory=d,this.filterFactory=u,this._pdfBug=h,this.pageColors=f,this.running=!1,this.graphicsReadyCallback=null,this.graphicsReady=!1,this._useRequestAnimationFrame=p===!0&&typeof window<"u",this.cancelled=!1,this.capability=Promise.withResolvers(),this.task=new X0t(this),this._cancelBound=this.cancel.bind(this),this._continueBound=this._continue.bind(this),this._scheduleNextBound=this._scheduleNext.bind(this),this._nextBound=this._next.bind(this),this._canvas=r.canvasContext.canvas}get completed(){return this.capability.promise.catch(function(){})}initializeGraphics({transparency:t=!1,optionalContentConfig:r}){if(this.cancelled)return;if(this._canvas){if(hf.#t.has(this._canvas))throw new Error("Cannot use the same canvas during multiple render() operations. Use different canvas or ensure previous operations were cancelled or completed.");hf.#t.add(this._canvas)}this._pdfBug&&globalThis.StepperManager?.enabled&&(this.stepper=globalThis.StepperManager.create(this._pageIndex),this.stepper.init(this.operatorList),this.stepper.nextBreakPoint=this.stepper.getNextBreakPoint());const{canvasContext:n,viewport:o,transform:i,background:a}=this.params;this.gfx=new Ef(n,this.commonObjs,this.objs,this.canvasFactory,this.filterFactory,{optionalContentConfig:r},this.annotationCanvasMap,this.pageColors),this.gfx.beginDrawing({transform:i,viewport:o,transparency:t,background:a}),this.operatorListIdx=0,this.graphicsReady=!0,this.graphicsReadyCallback?.()}cancel(t=null,r=0){this.running=!1,this.cancelled=!0,this.gfx?.endDrawing(),this.#e&&(window.cancelAnimationFrame(this.#e),this.#e=null),hf.#t.delete(this._canvas),this.callback(t||new GO(`Rendering cancelled, page ${this._pageIndex+1}`,r))}operatorListChanged(){if(!this.graphicsReady){this.graphicsReadyCallback||=this._continueBound;return}this.stepper?.updateOperatorList(this.operatorList),!this.running&&this._continue()}_continue(){this.running=!0,!this.cancelled&&(this.task.onContinue?this.task.onContinue(this._scheduleNextBound):this._scheduleNext())}_scheduleNext(){this._useRequestAnimationFrame?this.#e=window.requestAnimationFrame(()=>{this.#e=null,this._nextBound().catch(this._cancelBound)}):Promise.resolve().then(this._nextBound).catch(this._cancelBound)}async _next(){this.cancelled||(this.operatorListIdx=this.gfx.executeOperatorList(this.operatorList,this.operatorListIdx,this._continueBound,this.stepper),this.operatorListIdx===this.operatorList.argsArray.length&&(this.running=!1,this.operatorList.lastChunk&&(this.gfx.endDrawing(),hf.#t.delete(this._canvas),this.callback())))}}const Q0t="4.4.168",J0t="19fbc8998";function aJ(e){return Math.floor(Math.max(0,Math.min(1,e))*255).toString(16).padStart(2,"0")}function V4(e){return Math.max(0,Math.min(255,255*e))}class sJ{static CMYK_G([t,r,n,o]){return["G",1-Math.min(1,.3*t+.59*n+.11*r+o)]}static G_CMYK([t]){return["CMYK",0,0,0,1-t]}static G_RGB([t]){return["RGB",t,t,t]}static G_rgb([t]){return t=V4(t),[t,t,t]}static G_HTML([t]){const r=aJ(t);return`#${r}${r}${r}`}static RGB_G([t,r,n]){return["G",.3*t+.59*r+.11*n]}static RGB_rgb(t){return t.map(V4)}static RGB_HTML(t){return`#${t.map(aJ).join("")}`}static T_HTML(){return"#00000000"}static T_rgb(){return[null]}static CMYK_RGB([t,r,n,o]){return["RGB",1-Math.min(1,t+o),1-Math.min(1,n+o),1-Math.min(1,r+o)]}static CMYK_rgb([t,r,n,o]){return[V4(1-Math.min(1,t+o)),V4(1-Math.min(1,n+o)),V4(1-Math.min(1,r+o))]}static CMYK_HTML(t){const r=this.CMYK_RGB(t).slice(1);return this.RGB_HTML(r)}static RGB_CMYK([t,r,n]){const o=1-t,i=1-r,a=1-n,l=Math.min(o,i,a);return["CMYK",o,i,a,l]}}class c4e{static setupStorage(t,r,n,o,i){const a=o.getValue(r,{value:null});switch(n.name){case"textarea":if(a.value!==null&&(t.textContent=a.value),i==="print")break;t.addEventListener("input",l=>{o.setValue(r,{value:l.target.value})});break;case"input":if(n.attributes.type==="radio"||n.attributes.type==="checkbox"){if(a.value===n.attributes.xfaOn?t.setAttribute("checked",!0):a.value===n.attributes.xfaOff&&t.removeAttribute("checked"),i==="print")break;t.addEventListener("change",l=>{o.setValue(r,{value:l.target.checked?l.target.getAttribute("xfaOn"):l.target.getAttribute("xfaOff")})})}else{if(a.value!==null&&t.setAttribute("value",a.value),i==="print")break;t.addEventListener("input",l=>{o.setValue(r,{value:l.target.value})})}break;case"select":if(a.value!==null){t.setAttribute("value",a.value);for(const l of n.children)l.attributes.value===a.value?l.attributes.selected=!0:l.attributes.hasOwnProperty("selected")&&delete l.attributes.selected}t.addEventListener("input",l=>{const d=l.target.options,u=d.selectedIndex===-1?"":d[d.selectedIndex].value;o.setValue(r,{value:u})});break}}static setAttributes({html:t,element:r,storage:n=null,intent:o,linkService:i}){const{attributes:a}=r,l=t instanceof HTMLAnchorElement;a.type==="radio"&&(a.name=`${a.name}-${o}`);for(const[d,u]of Object.entries(a))if(u!=null)switch(d){case"class":u.length&&t.setAttribute(d,u.join(" "));break;case"dataId":break;case"id":t.setAttribute("data-element-id",u);break;case"style":Object.assign(t.style,u);break;case"textContent":t.textContent=u;break;default:(!l||d!=="href"&&d!=="newWindow")&&t.setAttribute(d,u)}l&&i.addLinkAttributes(t,a.href,a.newWindow),n&&a.dataId&&this.setupStorage(t,a.dataId,r,n)}static render(t){const r=t.annotationStorage,n=t.linkService,o=t.xfaHtml,i=t.intent||"display",a=document.createElement(o.name);o.attributes&&this.setAttributes({html:a,element:o,intent:i,linkService:n});const l=i!=="richText",d=t.div;if(d.append(a),t.viewport){const h=`matrix(${t.viewport.transform.join(",")})`;d.style.transform=h}l&&d.setAttribute("class","xfaLayer xfaFont");const u=[];if(o.children.length===0){if(o.value){const h=document.createTextNode(o.value);a.append(h),l&&_7.shouldBuildText(o.name)&&u.push(h)}return{textDivs:u}}const p=[[o,-1,a]];for(;p.length>0;){const[h,f,g]=p.at(-1);if(f+1===h.children.length){p.pop();continue}const y=h.children[++p.at(-1)[1]];if(y===null)continue;const{name:v}=y;if(v==="#text"){const x=document.createTextNode(y.value);u.push(x),g.append(x);continue}const w=y?.attributes?.xmlns?document.createElementNS(y.attributes.xmlns,v):document.createElement(v);if(g.append(w),y.attributes&&this.setAttributes({html:w,element:y,storage:r,intent:i,linkService:n}),y.children?.length>0)p.push([y,-1,w]);else if(y.value){const x=document.createTextNode(y.value);l&&_7.shouldBuildText(v)&&u.push(x),w.append(x)}}for(const h of d.querySelectorAll(".xfaNonInteractive input, .xfaNonInteractive textarea"))h.setAttribute("readOnly",!0);return{textDivs:u}}static update(t){const r=`matrix(${t.viewport.transform.join(",")})`;t.div.style.transform=r,t.div.hidden=!1}}const m6=1e3,ept=9,dm=new WeakSet;function e2(e){return{width:e[2]-e[0],height:e[3]-e[1]}}class tpt{static create(t){switch(t.data.annotationType){case Si.LINK:return new d4e(t);case Si.TEXT:return new rpt(t);case Si.WIDGET:switch(t.data.fieldType){case"Tx":return new npt(t);case"Btn":return t.data.radioButton?new u4e(t):t.data.checkBox?new ipt(t):new apt(t);case"Ch":return new spt(t);case"Sig":return new opt(t)}return new Dm(t);case Si.POPUP:return new pj(t);case Si.FREETEXT:return new p4e(t);case Si.LINE:return new cpt(t);case Si.SQUARE:return new dpt(t);case Si.CIRCLE:return new upt(t);case Si.POLYLINE:return new h4e(t);case Si.CARET:return new hpt(t);case Si.INK:return new m4e(t);case Si.POLYGON:return new ppt(t);case Si.HIGHLIGHT:return new mpt(t);case Si.UNDERLINE:return new fpt(t);case Si.SQUIGGLY:return new gpt(t);case Si.STRIKEOUT:return new ypt(t);case Si.STAMP:return new f4e(t);case Si.FILEATTACHMENT:return new vpt(t);default:return new ti(t)}}}class ti{#e=null;#t=!1;#r=null;constructor(t,{isRenderable:r=!1,ignoreBorder:n=!1,createQuadrilaterals:o=!1}={}){this.isRenderable=r,this.data=t.data,this.layer=t.layer,this.linkService=t.linkService,this.downloadManager=t.downloadManager,this.imageResourcesPath=t.imageResourcesPath,this.renderForms=t.renderForms,this.svgFactory=t.svgFactory,this.annotationStorage=t.annotationStorage,this.enableScripting=t.enableScripting,this.hasJSActions=t.hasJSActions,this._fieldObjects=t.fieldObjects,this.parent=t.parent,r&&(this.container=this._createContainer(n)),o&&this._createQuadrilaterals()}static _hasPopupData({titleObj:t,contentsObj:r,richText:n}){return!!(t?.str||r?.str||n?.str)}get hasPopupData(){return ti._hasPopupData(this.data)}updateEdited(t){if(!this.container)return;this.#e||={rect:this.data.rect.slice(0)};const{rect:r}=t;r&&this.#o(r),this.#r?.popup.updateEdited(t)}resetEdited(){this.#e&&(this.#o(this.#e.rect),this.#r?.popup.resetEdited(),this.#e=null)}#o(t){const{container:{style:r},data:{rect:n,rotation:o},parent:{viewport:{rawDims:{pageWidth:i,pageHeight:a,pageX:l,pageY:d}}}}=this;n?.splice(0,4,...t);const{width:u,height:p}=e2(t);r.left=`${100*(t[0]-l)/i}%`,r.top=`${100*(a-t[3]+d)/a}%`,o===0?(r.width=`${100*u/i}%`,r.height=`${100*p/a}%`):this.setRotation(o)}_createContainer(t){const{data:r,parent:{page:n,viewport:o}}=this,i=document.createElement("section");i.setAttribute("data-annotation-id",r.id),this instanceof Dm||(i.tabIndex=m6);const{style:a}=i;if(a.zIndex=this.parent.zIndex++,r.popupRef&&i.setAttribute("aria-haspopup","dialog"),r.alternativeText&&(i.title=r.alternativeText),r.noRotate&&i.classList.add("norotate"),!r.rect||this instanceof pj){const{rotation:v}=r;return!r.hasOwnCanvas&&v!==0&&this.setRotation(v,i),i}const{width:l,height:d}=e2(r.rect);if(!t&&r.borderStyle.width>0){a.borderWidth=`${r.borderStyle.width}px`;const v=r.borderStyle.horizontalCornerRadius,w=r.borderStyle.verticalCornerRadius;if(v>0||w>0){const $=`calc(${v}px * var(--scale-factor)) / calc(${w}px * var(--scale-factor))`;a.borderRadius=$}else if(this instanceof u4e){const $=`calc(${l}px * var(--scale-factor)) / calc(${d}px * var(--scale-factor))`;a.borderRadius=$}switch(r.borderStyle.style){case B4.SOLID:a.borderStyle="solid";break;case B4.DASHED:a.borderStyle="dashed";break;case B4.BEVELED:Jr("Unimplemented border style: beveled");break;case B4.INSET:Jr("Unimplemented border style: inset");break;case B4.UNDERLINE:a.borderBottomStyle="solid";break}const x=r.borderColor||null;x?(this.#t=!0,a.borderColor=lr.makeHexColor(x[0]|0,x[1]|0,x[2]|0)):a.borderWidth=0}const u=lr.normalizeRect([r.rect[0],n.view[3]-r.rect[1]+n.view[1],r.rect[2],n.view[3]-r.rect[3]+n.view[1]]),{pageWidth:p,pageHeight:h,pageX:f,pageY:g}=o.rawDims;a.left=`${100*(u[0]-f)/p}%`,a.top=`${100*(u[1]-g)/h}%`;const{rotation:y}=r;return r.hasOwnCanvas||y===0?(a.width=`${100*l/p}%`,a.height=`${100*d/h}%`):this.setRotation(y,i),i}setRotation(t,r=this.container){if(!this.data.rect)return;const{pageWidth:n,pageHeight:o}=this.parent.viewport.rawDims,{width:i,height:a}=e2(this.data.rect);let l,d;t%180===0?(l=100*i/n,d=100*a/o):(l=100*a/n,d=100*i/o),r.style.width=`${l}%`,r.style.height=`${d}%`,r.setAttribute("data-main-rotation",(360-t)%360)}get _commonActions(){const t=(r,n,o)=>{const i=o.detail[r],a=i[0],l=i.slice(1);o.target.style[n]=sJ[`${a}_HTML`](l),this.annotationStorage.setValue(this.data.id,{[n]:sJ[`${a}_rgb`](l)})};return vn(this,"_commonActions",{display:r=>{const{display:n}=r.detail,o=n%2===1;this.container.style.visibility=o?"hidden":"visible",this.annotationStorage.setValue(this.data.id,{noView:o,noPrint:n===1||n===2})},print:r=>{this.annotationStorage.setValue(this.data.id,{noPrint:!r.detail.print})},hidden:r=>{const{hidden:n}=r.detail;this.container.style.visibility=n?"hidden":"visible",this.annotationStorage.setValue(this.data.id,{noPrint:n,noView:n})},focus:r=>{setTimeout(()=>r.target.focus({preventScroll:!1}),0)},userName:r=>{r.target.title=r.detail.userName},readonly:r=>{r.target.disabled=r.detail.readonly},required:r=>{this._setRequired(r.target,r.detail.required)},bgColor:r=>{t("bgColor","backgroundColor",r)},fillColor:r=>{t("fillColor","backgroundColor",r)},fgColor:r=>{t("fgColor","color",r)},textColor:r=>{t("textColor","color",r)},borderColor:r=>{t("borderColor","borderColor",r)},strokeColor:r=>{t("strokeColor","borderColor",r)},rotation:r=>{const n=r.detail.rotation;this.setRotation(n),this.annotationStorage.setValue(this.data.id,{rotation:n})}})}_dispatchEventFromSandbox(t,r){const n=this._commonActions;for(const o of Object.keys(r.detail))(t[o]||n[o])?.(r)}_setDefaultPropertiesFromJS(t){if(!this.enableScripting)return;const r=this.annotationStorage.getRawValue(this.data.id);if(!r)return;const n=this._commonActions;for(const[o,i]of Object.entries(r)){const a=n[o];if(a){const l={detail:{[o]:i},target:t};a(l),delete r[o]}}}_createQuadrilaterals(){if(!this.container)return;const{quadPoints:t}=this.data;if(!t)return;const[r,n,o,i]=this.data.rect.map(v=>Math.fround(v));if(t.length===8){const[v,w,x,$]=t.subarray(2,6);if(o===v&&i===w&&r===x&&n===$)return}const{style:a}=this.container;let l;if(this.#t){const{borderColor:v,borderWidth:w}=a;a.borderWidth=0,l=["url('data:image/svg+xml;utf8,",'<svg xmlns="http://www.w3.org/2000/svg"',' preserveAspectRatio="none" viewBox="0 0 1 1">',`<g fill="transparent" stroke="${v}" stroke-width="${w}">`],this.container.classList.add("hasBorder")}const d=o-r,u=i-n,{svgFactory:p}=this,h=p.createElement("svg");h.classList.add("quadrilateralsContainer"),h.setAttribute("width",0),h.setAttribute("height",0);const f=p.createElement("defs");h.append(f);const g=p.createElement("clipPath"),y=`clippath_${this.data.id}`;g.setAttribute("id",y),g.setAttribute("clipPathUnits","objectBoundingBox"),f.append(g);for(let v=2,w=t.length;v<w;v+=8){const x=t[v],$=t[v+1],S=t[v+2],k=t[v+3],T=p.createElement("rect"),E=(S-r)/d,A=(i-$)/u,D=(x-S)/d,P=($-k)/u;T.setAttribute("x",E),T.setAttribute("y",A),T.setAttribute("width",D),T.setAttribute("height",P),g.append(T),l?.push(`<rect vector-effect="non-scaling-stroke" x="${E}" y="${A}" width="${D}" height="${P}"/>`)}this.#t&&(l.push("</g></svg>')"),a.backgroundImage=l.join("")),this.container.append(h),this.container.style.clipPath=`url(#${y})`}_createPopup(){const{container:t,data:r}=this;t.setAttribute("aria-haspopup","dialog");const n=this.#r=new pj({data:{color:r.color,titleObj:r.titleObj,modificationDate:r.modificationDate,contentsObj:r.contentsObj,richText:r.richText,parentRect:r.rect,borderStyle:0,id:`popup_${r.id}`,rotation:r.rotation},parent:this.parent,elements:[this]});this.parent.div.append(n.render())}render(){Xn("Abstract method `AnnotationElement.render` called")}_getElementsByName(t,r=null){const n=[];if(this._fieldObjects){const o=this._fieldObjects[t];if(o)for(const{page:i,id:a,exportValues:l}of o){if(i===-1||a===r)continue;const d=typeof l=="string"?l:null,u=document.querySelector(`[data-element-id="${a}"]`);if(u&&!dm.has(u)){Jr(`_getElementsByName - element not allowed: ${a}`);continue}n.push({id:a,exportValue:d,domElement:u})}return n}for(const o of document.getElementsByName(t)){const{exportValue:i}=o,a=o.getAttribute("data-element-id");a!==r&&dm.has(o)&&n.push({id:a,exportValue:i,domElement:o})}return n}show(){this.container&&(this.container.hidden=!1),this.popup?.maybeShow()}hide(){this.container&&(this.container.hidden=!0),this.popup?.forceHide()}getElementsToTriggerPopup(){return this.container}addHighlightArea(){const t=this.getElementsToTriggerPopup();if(Array.isArray(t))for(const r of t)r.classList.add("highlightArea");else t.classList.add("highlightArea")}get _isEditable(){return!1}_editOnDoubleClick(){if(!this._isEditable)return;const{annotationEditorType:t,data:{id:r}}=this;this.container.addEventListener("dblclick",()=>{this.linkService.eventBus?.dispatch("switchannotationeditormode",{source:this,mode:t,editId:r})})}}class d4e extends ti{constructor(t,r=null){super(t,{isRenderable:!0,ignoreBorder:!!r?.ignoreBorder,createQuadrilaterals:!0}),this.isTooltipOnly=t.data.isTooltipOnly}render(){const{data:t,linkService:r}=this,n=document.createElement("a");n.setAttribute("data-element-id",t.id);let o=!1;return t.url?(r.addLinkAttributes(n,t.url,t.newWindow),o=!0):t.action?(this._bindNamedAction(n,t.action),o=!0):t.attachment?(this.#t(n,t.attachment,t.attachmentDest),o=!0):t.setOCGState?(this.#r(n,t.setOCGState),o=!0):t.dest?(this._bindLink(n,t.dest),o=!0):(t.actions&&(t.actions.Action||t.actions["Mouse Up"]||t.actions["Mouse Down"])&&this.enableScripting&&this.hasJSActions&&(this._bindJSAction(n,t),o=!0),t.resetForm?(this._bindResetFormAction(n,t.resetForm),o=!0):this.isTooltipOnly&&!o&&(this._bindLink(n,""),o=!0)),this.container.classList.add("linkAnnotation"),o&&this.container.append(n),this.container}#e(){this.container.setAttribute("data-internal-link","")}_bindLink(t,r){t.href=this.linkService.getDestinationHash(r),t.onclick=()=>(r&&this.linkService.goToDestination(r),!1),(r||r==="")&&this.#e()}_bindNamedAction(t,r){t.href=this.linkService.getAnchorUrl(""),t.onclick=()=>(this.linkService.executeNamedAction(r),!1),this.#e()}#t(t,r,n=null){t.href=this.linkService.getAnchorUrl(""),r.description&&(t.title=r.description),t.onclick=()=>(this.downloadManager?.openOrDownloadData(r.content,r.filename,n),!1),this.#e()}#r(t,r){t.href=this.linkService.getAnchorUrl(""),t.onclick=()=>(this.linkService.executeSetOCGState(r),!1),this.#e()}_bindJSAction(t,r){t.href=this.linkService.getAnchorUrl("");const n=new Map([["Action","onclick"],["Mouse Up","onmouseup"],["Mouse Down","onmousedown"]]);for(const o of Object.keys(r.actions)){const i=n.get(o);i&&(t[i]=()=>(this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:r.id,name:o}}),!1))}t.onclick||(t.onclick=()=>!1),this.#e()}_bindResetFormAction(t,r){const n=t.onclick;if(n||(t.href=this.linkService.getAnchorUrl("")),this.#e(),!this._fieldObjects){Jr('_bindResetFormAction - "resetForm" action not supported, ensure that the `fieldObjects` parameter is provided.'),n||(t.onclick=()=>!1);return}t.onclick=()=>{n?.();const{fields:o,refs:i,include:a}=r,l=[];if(o.length!==0||i.length!==0){const p=new Set(i);for(const h of o){const f=this._fieldObjects[h]||[];for(const{id:g}of f)p.add(g)}for(const h of Object.values(this._fieldObjects))for(const f of h)p.has(f.id)===a&&l.push(f)}else for(const p of Object.values(this._fieldObjects))l.push(...p);const d=this.annotationStorage,u=[];for(const p of l){const{id:h}=p;switch(u.push(h),p.type){case"text":{const g=p.defaultValue||"";d.setValue(h,{value:g});break}case"checkbox":case"radiobutton":{const g=p.defaultValue===p.exportValues;d.setValue(h,{value:g});break}case"combobox":case"listbox":{const g=p.defaultValue||"";d.setValue(h,{value:g});break}default:continue}const f=document.querySelector(`[data-element-id="${h}"]`);if(f){if(!dm.has(f)){Jr(`_bindResetFormAction - element not allowed: ${h}`);continue}}else continue;f.dispatchEvent(new Event("resetform"))}return this.enableScripting&&this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:"app",ids:u,name:"ResetForm"}}),!1}}}class rpt extends ti{constructor(t){super(t,{isRenderable:!0})}render(){this.container.classList.add("textAnnotation");const t=document.createElement("img");return t.src=this.imageResourcesPath+"annotation-"+this.data.name.toLowerCase()+".svg",t.setAttribute("data-l10n-id","pdfjs-text-annotation-type"),t.setAttribute("data-l10n-args",JSON.stringify({type:this.data.name})),!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container.append(t),this.container}}class Dm extends ti{render(){return this.container}showElementAndHideCanvas(t){this.data.hasOwnCanvas&&(t.previousSibling?.nodeName==="CANVAS"&&(t.previousSibling.hidden=!0),t.hidden=!1)}_getKeyModifier(t){return bs.platform.isMac?t.metaKey:t.ctrlKey}_setEventListener(t,r,n,o,i){n.includes("mouse")?t.addEventListener(n,a=>{this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:this.data.id,name:o,value:i(a),shift:a.shiftKey,modifier:this._getKeyModifier(a)}})}):t.addEventListener(n,a=>{if(n==="blur"){if(!r.focused||!a.relatedTarget)return;r.focused=!1}else if(n==="focus"){if(r.focused)return;r.focused=!0}i&&this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:this.data.id,name:o,value:i(a)}})})}_setEventListeners(t,r,n,o){for(const[i,a]of n)(a==="Action"||this.data.actions?.[a])&&((a==="Focus"||a==="Blur")&&(r||={focused:!1}),this._setEventListener(t,r,i,a,o),a==="Focus"&&!this.data.actions?.Blur?this._setEventListener(t,r,"blur","Blur",null):a==="Blur"&&!this.data.actions?.Focus&&this._setEventListener(t,r,"focus","Focus",null))}_setBackgroundColor(t){const r=this.data.backgroundColor||null;t.style.backgroundColor=r===null?"transparent":lr.makeHexColor(r[0],r[1],r[2])}_setTextStyle(t){const r=["left","center","right"],{fontColor:n}=this.data.defaultAppearanceData,o=this.data.defaultAppearanceData.fontSize||ept,i=t.style;let a;const l=2,d=u=>Math.round(10*u)/10;if(this.data.multiLine){const u=Math.abs(this.data.rect[3]-this.data.rect[1]-l),p=Math.round(u/(iL*o))||1,h=u/p;a=Math.min(o,d(h/iL))}else{const u=Math.abs(this.data.rect[3]-this.data.rect[1]-l);a=Math.min(o,d(u/iL))}i.fontSize=`calc(${a}px * var(--scale-factor))`,i.color=lr.makeHexColor(n[0],n[1],n[2]),this.data.textAlignment!==null&&(i.textAlign=r[this.data.textAlignment])}_setRequired(t,r){r?t.setAttribute("required",!0):t.removeAttribute("required"),t.setAttribute("aria-required",r)}}class npt extends Dm{constructor(t){const r=t.renderForms||t.data.hasOwnCanvas||!t.data.hasAppearance&&!!t.data.fieldValue;super(t,{isRenderable:r})}setPropertyOnSiblings(t,r,n,o){const i=this.annotationStorage;for(const a of this._getElementsByName(t.name,t.id))a.domElement&&(a.domElement[r]=n),i.setValue(a.id,{[o]:n})}render(){const t=this.annotationStorage,r=this.data.id;this.container.classList.add("textWidgetAnnotation");let n=null;if(this.renderForms){const o=t.getValue(r,{value:this.data.fieldValue});let i=o.value||"";const a=t.getValue(r,{charLimit:this.data.maxLen}).charLimit;a&&i.length>a&&(i=i.slice(0,a));let l=o.formattedValue||this.data.textContent?.join(`
290
290
  `)||null;l&&this.data.comb&&(l=l.replaceAll(/\s+/g,""));const d={userValue:i,formattedValue:l,lastCommittedValue:null,commitKey:1,focused:!1};this.data.multiLine?(n=document.createElement("textarea"),n.textContent=l??i,this.data.doNotScroll&&(n.style.overflowY="hidden")):(n=document.createElement("input"),n.type="text",n.setAttribute("value",l??i),this.data.doNotScroll&&(n.style.overflowX="hidden")),this.data.hasOwnCanvas&&(n.hidden=!0),dm.add(n),n.setAttribute("data-element-id",r),n.disabled=this.data.readOnly,n.name=this.data.fieldName,n.tabIndex=m6,this._setRequired(n,this.data.required),a&&(n.maxLength=a),n.addEventListener("input",p=>{t.setValue(r,{value:p.target.value}),this.setPropertyOnSiblings(n,"value",p.target.value,"value"),d.formattedValue=null}),n.addEventListener("resetform",p=>{const h=this.data.defaultFieldValue??"";n.value=d.userValue=h,d.formattedValue=null});let u=p=>{const{formattedValue:h}=d;h!=null&&(p.target.value=h),p.target.scrollLeft=0};if(this.enableScripting&&this.hasJSActions){n.addEventListener("focus",h=>{if(d.focused)return;const{target:f}=h;d.userValue&&(f.value=d.userValue),d.lastCommittedValue=f.value,d.commitKey=1,this.data.actions?.Focus||(d.focused=!0)}),n.addEventListener("updatefromsandbox",h=>{this.showElementAndHideCanvas(h.target);const f={value(g){d.userValue=g.detail.value??"",t.setValue(r,{value:d.userValue.toString()}),g.target.value=d.userValue},formattedValue(g){const{formattedValue:y}=g.detail;d.formattedValue=y,y!=null&&g.target!==document.activeElement&&(g.target.value=y),t.setValue(r,{formattedValue:y})},selRange(g){g.target.setSelectionRange(...g.detail.selRange)},charLimit:g=>{const{charLimit:y}=g.detail,{target:v}=g;if(y===0){v.removeAttribute("maxLength");return}v.setAttribute("maxLength",y);let w=d.userValue;!w||w.length<=y||(w=w.slice(0,y),v.value=d.userValue=w,t.setValue(r,{value:w}),this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:r,name:"Keystroke",value:w,willCommit:!0,commitKey:1,selStart:v.selectionStart,selEnd:v.selectionEnd}}))}};this._dispatchEventFromSandbox(f,h)}),n.addEventListener("keydown",h=>{d.commitKey=1;let f=-1;if(h.key==="Escape"?f=0:h.key==="Enter"&&!this.data.multiLine?f=2:h.key==="Tab"&&(d.commitKey=3),f===-1)return;const{value:g}=h.target;d.lastCommittedValue!==g&&(d.lastCommittedValue=g,d.userValue=g,this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:r,name:"Keystroke",value:g,willCommit:!0,commitKey:f,selStart:h.target.selectionStart,selEnd:h.target.selectionEnd}}))});const p=u;u=null,n.addEventListener("blur",h=>{if(!d.focused||!h.relatedTarget)return;this.data.actions?.Blur||(d.focused=!1);const{value:f}=h.target;d.userValue=f,d.lastCommittedValue!==f&&this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:r,name:"Keystroke",value:f,willCommit:!0,commitKey:d.commitKey,selStart:h.target.selectionStart,selEnd:h.target.selectionEnd}}),p(h)}),this.data.actions?.Keystroke&&n.addEventListener("beforeinput",h=>{d.lastCommittedValue=null;const{data:f,target:g}=h,{value:y,selectionStart:v,selectionEnd:w}=g;let x=v,$=w;switch(h.inputType){case"deleteWordBackward":{const S=y.substring(0,v).match(/\w*[^\w]*$/);S&&(x-=S[0].length);break}case"deleteWordForward":{const S=y.substring(v).match(/^[^\w]*\w*/);S&&($+=S[0].length);break}case"deleteContentBackward":v===w&&(x-=1);break;case"deleteContentForward":v===w&&($+=1);break}h.preventDefault(),this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:r,name:"Keystroke",value:y,change:f||"",willCommit:!1,selStart:x,selEnd:$}})}),this._setEventListeners(n,d,[["focus","Focus"],["blur","Blur"],["mousedown","Mouse Down"],["mouseenter","Mouse Enter"],["mouseleave","Mouse Exit"],["mouseup","Mouse Up"]],h=>h.target.value)}if(u&&n.addEventListener("blur",u),this.data.comb){const h=(this.data.rect[2]-this.data.rect[0])/a;n.classList.add("comb"),n.style.letterSpacing=`calc(${h}px * var(--scale-factor) - 1ch)`}}else n=document.createElement("div"),n.textContent=this.data.fieldValue,n.style.verticalAlign="middle",n.style.display="table-cell",this.data.hasOwnCanvas&&(n.hidden=!0);return this._setTextStyle(n),this._setBackgroundColor(n),this._setDefaultPropertiesFromJS(n),this.container.append(n),this.container}}class opt extends Dm{constructor(t){super(t,{isRenderable:!!t.data.hasOwnCanvas})}}class ipt extends Dm{constructor(t){super(t,{isRenderable:t.renderForms})}render(){const t=this.annotationStorage,r=this.data,n=r.id;let o=t.getValue(n,{value:r.exportValue===r.fieldValue}).value;typeof o=="string"&&(o=o!=="Off",t.setValue(n,{value:o})),this.container.classList.add("buttonWidgetAnnotation","checkBox");const i=document.createElement("input");return dm.add(i),i.setAttribute("data-element-id",n),i.disabled=r.readOnly,this._setRequired(i,this.data.required),i.type="checkbox",i.name=r.fieldName,o&&i.setAttribute("checked",!0),i.setAttribute("exportValue",r.exportValue),i.tabIndex=m6,i.addEventListener("change",a=>{const{name:l,checked:d}=a.target;for(const u of this._getElementsByName(l,n)){const p=d&&u.exportValue===r.exportValue;u.domElement&&(u.domElement.checked=p),t.setValue(u.id,{value:p})}t.setValue(n,{value:d})}),i.addEventListener("resetform",a=>{const l=r.defaultFieldValue||"Off";a.target.checked=l===r.exportValue}),this.enableScripting&&this.hasJSActions&&(i.addEventListener("updatefromsandbox",a=>{const l={value(d){d.target.checked=d.detail.value!=="Off",t.setValue(n,{value:d.target.checked})}};this._dispatchEventFromSandbox(l,a)}),this._setEventListeners(i,null,[["change","Validate"],["change","Action"],["focus","Focus"],["blur","Blur"],["mousedown","Mouse Down"],["mouseenter","Mouse Enter"],["mouseleave","Mouse Exit"],["mouseup","Mouse Up"]],a=>a.target.checked)),this._setBackgroundColor(i),this._setDefaultPropertiesFromJS(i),this.container.append(i),this.container}}class u4e extends Dm{constructor(t){super(t,{isRenderable:t.renderForms})}render(){this.container.classList.add("buttonWidgetAnnotation","radioButton");const t=this.annotationStorage,r=this.data,n=r.id;let o=t.getValue(n,{value:r.fieldValue===r.buttonValue}).value;if(typeof o=="string"&&(o=o!==r.buttonValue,t.setValue(n,{value:o})),o)for(const a of this._getElementsByName(r.fieldName,n))t.setValue(a.id,{value:!1});const i=document.createElement("input");if(dm.add(i),i.setAttribute("data-element-id",n),i.disabled=r.readOnly,this._setRequired(i,this.data.required),i.type="radio",i.name=r.fieldName,o&&i.setAttribute("checked",!0),i.tabIndex=m6,i.addEventListener("change",a=>{const{name:l,checked:d}=a.target;for(const u of this._getElementsByName(l,n))t.setValue(u.id,{value:!1});t.setValue(n,{value:d})}),i.addEventListener("resetform",a=>{const l=r.defaultFieldValue;a.target.checked=l!=null&&l===r.buttonValue}),this.enableScripting&&this.hasJSActions){const a=r.buttonValue;i.addEventListener("updatefromsandbox",l=>{const d={value:u=>{const p=a===u.detail.value;for(const h of this._getElementsByName(u.target.name)){const f=p&&h.id===n;h.domElement&&(h.domElement.checked=f),t.setValue(h.id,{value:f})}}};this._dispatchEventFromSandbox(d,l)}),this._setEventListeners(i,null,[["change","Validate"],["change","Action"],["focus","Focus"],["blur","Blur"],["mousedown","Mouse Down"],["mouseenter","Mouse Enter"],["mouseleave","Mouse Exit"],["mouseup","Mouse Up"]],l=>l.target.checked)}return this._setBackgroundColor(i),this._setDefaultPropertiesFromJS(i),this.container.append(i),this.container}}class apt extends d4e{constructor(t){super(t,{ignoreBorder:t.data.hasAppearance})}render(){const t=super.render();t.classList.add("buttonWidgetAnnotation","pushButton");const r=t.lastChild;return this.enableScripting&&this.hasJSActions&&r&&(this._setDefaultPropertiesFromJS(r),r.addEventListener("updatefromsandbox",n=>{this._dispatchEventFromSandbox({},n)})),t}}class spt extends Dm{constructor(t){super(t,{isRenderable:t.renderForms})}render(){this.container.classList.add("choiceWidgetAnnotation");const t=this.annotationStorage,r=this.data.id,n=t.getValue(r,{value:this.data.fieldValue}),o=document.createElement("select");dm.add(o),o.setAttribute("data-element-id",r),o.disabled=this.data.readOnly,this._setRequired(o,this.data.required),o.name=this.data.fieldName,o.tabIndex=m6;let i=this.data.combo&&this.data.options.length>0;this.data.combo||(o.size=this.data.options.length,this.data.multiSelect&&(o.multiple=!0)),o.addEventListener("resetform",p=>{const h=this.data.defaultFieldValue;for(const f of o.options)f.selected=f.value===h});for(const p of this.data.options){const h=document.createElement("option");h.textContent=p.displayValue,h.value=p.exportValue,n.value.includes(p.exportValue)&&(h.setAttribute("selected",!0),i=!1),o.append(h)}let a=null;if(i){const p=document.createElement("option");p.value=" ",p.setAttribute("hidden",!0),p.setAttribute("selected",!0),o.prepend(p),a=()=>{p.remove(),o.removeEventListener("input",a),a=null},o.addEventListener("input",a)}const l=p=>{const h=p?"value":"textContent",{options:f,multiple:g}=o;return g?Array.prototype.filter.call(f,y=>y.selected).map(y=>y[h]):f.selectedIndex===-1?null:f[f.selectedIndex][h]};let d=l(!1);const u=p=>{const h=p.target.options;return Array.prototype.map.call(h,f=>({displayValue:f.textContent,exportValue:f.value}))};return this.enableScripting&&this.hasJSActions?(o.addEventListener("updatefromsandbox",p=>{const h={value(f){a?.();const g=f.detail.value,y=new Set(Array.isArray(g)?g:[g]);for(const v of o.options)v.selected=y.has(v.value);t.setValue(r,{value:l(!0)}),d=l(!1)},multipleSelection(f){o.multiple=!0},remove(f){const g=o.options,y=f.detail.remove;g[y].selected=!1,o.remove(y),g.length>0&&Array.prototype.findIndex.call(g,w=>w.selected)===-1&&(g[0].selected=!0),t.setValue(r,{value:l(!0),items:u(f)}),d=l(!1)},clear(f){for(;o.length!==0;)o.remove(0);t.setValue(r,{value:null,items:[]}),d=l(!1)},insert(f){const{index:g,displayValue:y,exportValue:v}=f.detail.insert,w=o.children[g],x=document.createElement("option");x.textContent=y,x.value=v,w?w.before(x):o.append(x),t.setValue(r,{value:l(!0),items:u(f)}),d=l(!1)},items(f){const{items:g}=f.detail;for(;o.length!==0;)o.remove(0);for(const y of g){const{displayValue:v,exportValue:w}=y,x=document.createElement("option");x.textContent=v,x.value=w,o.append(x)}o.options.length>0&&(o.options[0].selected=!0),t.setValue(r,{value:l(!0),items:u(f)}),d=l(!1)},indices(f){const g=new Set(f.detail.indices);for(const y of f.target.options)y.selected=g.has(y.index);t.setValue(r,{value:l(!0)}),d=l(!1)},editable(f){f.target.disabled=!f.detail.editable}};this._dispatchEventFromSandbox(h,p)}),o.addEventListener("input",p=>{const h=l(!0),f=l(!1);t.setValue(r,{value:h}),p.preventDefault(),this.linkService.eventBus?.dispatch("dispatcheventinsandbox",{source:this,detail:{id:r,name:"Keystroke",value:d,change:f,changeEx:h,willCommit:!1,commitKey:1,keyDown:!1}})}),this._setEventListeners(o,null,[["focus","Focus"],["blur","Blur"],["mousedown","Mouse Down"],["mouseenter","Mouse Enter"],["mouseleave","Mouse Exit"],["mouseup","Mouse Up"],["input","Action"],["input","Validate"]],p=>p.target.value)):o.addEventListener("input",function(p){t.setValue(r,{value:l(!0)})}),this.data.combo&&this._setTextStyle(o),this._setBackgroundColor(o),this._setDefaultPropertiesFromJS(o),this.container.append(o),this.container}}class pj extends ti{constructor(t){const{data:r,elements:n}=t;super(t,{isRenderable:ti._hasPopupData(r)}),this.elements=n,this.popup=null}render(){this.container.classList.add("popupAnnotation");const t=this.popup=new lpt({container:this.container,color:this.data.color,titleObj:this.data.titleObj,modificationDate:this.data.modificationDate,contentsObj:this.data.contentsObj,richText:this.data.richText,rect:this.data.rect,parentRect:this.data.parentRect||null,parent:this.parent,elements:this.elements,open:this.data.open}),r=[];for(const n of this.elements)n.popup=t,r.push(n.data.id),n.addHighlightArea();return this.container.setAttribute("aria-controls",r.map(n=>`${Yge}${n}`).join(",")),this.container}}class lpt{#e=this.#L.bind(this);#t=this.#C.bind(this);#r=this.#y.bind(this);#o=this.#w.bind(this);#s=null;#n=null;#i=null;#l=null;#d=null;#u=null;#h=null;#c=!1;#a=null;#m=null;#g=null;#p=null;#v=null;#f=null;#b=!1;constructor({container:t,color:r,elements:n,titleObj:o,modificationDate:i,contentsObj:a,richText:l,parent:d,rect:u,parentRect:p,open:h}){this.#n=t,this.#v=o,this.#i=a,this.#p=l,this.#u=d,this.#s=r,this.#g=u,this.#h=p,this.#d=n,this.#l=Kge.toDateObject(i),this.trigger=n.flatMap(f=>f.getElementsToTriggerPopup());for(const f of this.trigger)f.addEventListener("click",this.#o),f.addEventListener("mouseenter",this.#r),f.addEventListener("mouseleave",this.#t),f.classList.add("popupTriggerArea");for(const f of n)f.container?.addEventListener("keydown",this.#e);this.#n.hidden=!0,h&&this.#w()}render(){if(this.#a)return;const t=this.#a=document.createElement("div");if(t.className="popup",this.#s){const i=t.style.outlineColor=lr.makeHexColor(...this.#s);CSS.supports("background-color","color-mix(in srgb, red 30%, white)")?t.style.backgroundColor=`color-mix(in srgb, ${i} 30%, white)`:t.style.backgroundColor=lr.makeHexColor(...this.#s.map(l=>Math.floor(.7*(255-l)+l)))}const r=document.createElement("span");r.className="header";const n=document.createElement("h1");if(r.append(n),{dir:n.dir,str:n.textContent}=this.#v,t.append(r),this.#l){const i=document.createElement("span");i.classList.add("popupDate"),i.setAttribute("data-l10n-id","pdfjs-annotation-date-string"),i.setAttribute("data-l10n-args",JSON.stringify({date:this.#l.toLocaleDateString(),time:this.#l.toLocaleTimeString()})),r.append(i)}const o=this.#x;if(o)c4e.render({xfaHtml:o,intent:"richText",div:t}),t.lastChild.classList.add("richText","popupContent");else{const i=this._formatContents(this.#i);t.append(i)}this.#n.append(t)}get#x(){const t=this.#p,r=this.#i;return t?.str&&(!r?.str||r.str===t.str)&&this.#p.html||null}get#$(){return this.#x?.attributes?.style?.fontSize||0}get#k(){return this.#x?.attributes?.style?.color||null}#E(t){const r=[],n={str:t,html:{name:"div",attributes:{dir:"auto"},children:[{name:"p",children:r}]}},o={style:{color:this.#k,fontSize:this.#$?`calc(${this.#$}px * var(--scale-factor))`:""}};for(const i of t.split(`
291
291
  `))r.push({name:"span",value:i,attributes:o});return n}_formatContents({str:t,dir:r}){const n=document.createElement("p");n.classList.add("popupContent"),n.dir=r;const o=t.split(/(?:\r\n?|\n)/);for(let i=0,a=o.length;i<a;++i){const l=o[i];n.append(document.createTextNode(l)),i<a-1&&n.append(document.createElement("br"))}return n}#L(t){t.altKey||t.shiftKey||t.ctrlKey||t.metaKey||(t.key==="Enter"||t.key==="Escape"&&this.#c)&&this.#w()}updateEdited({rect:t,popupContent:r}){this.#f||={contentsObj:this.#i,richText:this.#p},t&&(this.#m=null),r&&(this.#p=this.#E(r),this.#i=null),this.#a?.remove(),this.#a=null}resetEdited(){this.#f&&({contentsObj:this.#i,richText:this.#p}=this.#f,this.#f=null,this.#a?.remove(),this.#a=null,this.#m=null)}#S(){if(this.#m!==null)return;const{page:{view:t},viewport:{rawDims:{pageWidth:r,pageHeight:n,pageX:o,pageY:i}}}=this.#u;let a=!!this.#h,l=a?this.#h:this.#g;for(const y of this.#d)if(!l||lr.intersect(y.data.rect,l)!==null){l=y.data.rect,a=!0;break}const d=lr.normalizeRect([l[0],t[3]-l[1]+t[1],l[2],t[3]-l[3]+t[1]]),p=a?l[2]-l[0]+5:0,h=d[0]+p,f=d[1];this.#m=[100*(h-o)/r,100*(f-i)/n];const{style:g}=this.#n;g.left=`${this.#m[0]}%`,g.top=`${this.#m[1]}%`}#w(){this.#c=!this.#c,this.#c?(this.#y(),this.#n.addEventListener("click",this.#o),this.#n.addEventListener("keydown",this.#e)):(this.#C(),this.#n.removeEventListener("click",this.#o),this.#n.removeEventListener("keydown",this.#e))}#y(){this.#a||this.render(),this.isVisible?this.#c&&this.#n.classList.add("focused"):(this.#S(),this.#n.hidden=!1,this.#n.style.zIndex=parseInt(this.#n.style.zIndex)+1e3)}#C(){this.#n.classList.remove("focused"),!(this.#c||!this.isVisible)&&(this.#n.hidden=!0,this.#n.style.zIndex=parseInt(this.#n.style.zIndex)-1e3)}forceHide(){this.#b=this.isVisible,this.#b&&(this.#n.hidden=!0)}maybeShow(){this.#b&&(this.#a||this.#y(),this.#b=!1,this.#n.hidden=!1)}get isVisible(){return this.#n.hidden===!1}}class p4e extends ti{constructor(t){super(t,{isRenderable:!0,ignoreBorder:!0}),this.textContent=t.data.textContent,this.textPosition=t.data.textPosition,this.annotationEditorType=hn.FREETEXT}render(){if(this.container.classList.add("freeTextAnnotation"),this.textContent){const t=document.createElement("div");t.classList.add("annotationTextContent"),t.setAttribute("role","comment");for(const r of this.textContent){const n=document.createElement("span");n.textContent=r,t.append(n)}this.container.append(t)}return!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this._editOnDoubleClick(),this.container}get _isEditable(){return this.data.hasOwnCanvas}}class cpt extends ti{#e=null;constructor(t){super(t,{isRenderable:!0,ignoreBorder:!0})}render(){this.container.classList.add("lineAnnotation");const t=this.data,{width:r,height:n}=e2(t.rect),o=this.svgFactory.create(r,n,!0),i=this.#e=this.svgFactory.createElement("svg:line");return i.setAttribute("x1",t.rect[2]-t.lineCoordinates[0]),i.setAttribute("y1",t.rect[3]-t.lineCoordinates[1]),i.setAttribute("x2",t.rect[2]-t.lineCoordinates[2]),i.setAttribute("y2",t.rect[3]-t.lineCoordinates[3]),i.setAttribute("stroke-width",t.borderStyle.width||1),i.setAttribute("stroke","transparent"),i.setAttribute("fill","transparent"),o.append(i),this.container.append(o),!t.popupRef&&this.hasPopupData&&this._createPopup(),this.container}getElementsToTriggerPopup(){return this.#e}addHighlightArea(){this.container.classList.add("highlightArea")}}class dpt extends ti{#e=null;constructor(t){super(t,{isRenderable:!0,ignoreBorder:!0})}render(){this.container.classList.add("squareAnnotation");const t=this.data,{width:r,height:n}=e2(t.rect),o=this.svgFactory.create(r,n,!0),i=t.borderStyle.width,a=this.#e=this.svgFactory.createElement("svg:rect");return a.setAttribute("x",i/2),a.setAttribute("y",i/2),a.setAttribute("width",r-i),a.setAttribute("height",n-i),a.setAttribute("stroke-width",i||1),a.setAttribute("stroke","transparent"),a.setAttribute("fill","transparent"),o.append(a),this.container.append(o),!t.popupRef&&this.hasPopupData&&this._createPopup(),this.container}getElementsToTriggerPopup(){return this.#e}addHighlightArea(){this.container.classList.add("highlightArea")}}class upt extends ti{#e=null;constructor(t){super(t,{isRenderable:!0,ignoreBorder:!0})}render(){this.container.classList.add("circleAnnotation");const t=this.data,{width:r,height:n}=e2(t.rect),o=this.svgFactory.create(r,n,!0),i=t.borderStyle.width,a=this.#e=this.svgFactory.createElement("svg:ellipse");return a.setAttribute("cx",r/2),a.setAttribute("cy",n/2),a.setAttribute("rx",r/2-i/2),a.setAttribute("ry",n/2-i/2),a.setAttribute("stroke-width",i||1),a.setAttribute("stroke","transparent"),a.setAttribute("fill","transparent"),o.append(a),this.container.append(o),!t.popupRef&&this.hasPopupData&&this._createPopup(),this.container}getElementsToTriggerPopup(){return this.#e}addHighlightArea(){this.container.classList.add("highlightArea")}}class h4e extends ti{#e=null;constructor(t){super(t,{isRenderable:!0,ignoreBorder:!0}),this.containerClassName="polylineAnnotation",this.svgElementName="svg:polyline"}render(){this.container.classList.add(this.containerClassName);const{data:{rect:t,vertices:r,borderStyle:n,popupRef:o}}=this;if(!r)return this.container;const{width:i,height:a}=e2(t),l=this.svgFactory.create(i,a,!0);let d=[];for(let p=0,h=r.length;p<h;p+=2){const f=r[p]-t[0],g=t[3]-r[p+1];d.push(`${f},${g}`)}d=d.join(" ");const u=this.#e=this.svgFactory.createElement(this.svgElementName);return u.setAttribute("points",d),u.setAttribute("stroke-width",n.width||1),u.setAttribute("stroke","transparent"),u.setAttribute("fill","transparent"),l.append(u),this.container.append(l),!o&&this.hasPopupData&&this._createPopup(),this.container}getElementsToTriggerPopup(){return this.#e}addHighlightArea(){this.container.classList.add("highlightArea")}}class ppt extends h4e{constructor(t){super(t),this.containerClassName="polygonAnnotation",this.svgElementName="svg:polygon"}}class hpt extends ti{constructor(t){super(t,{isRenderable:!0,ignoreBorder:!0})}render(){return this.container.classList.add("caretAnnotation"),!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container}}class m4e extends ti{#e=[];constructor(t){super(t,{isRenderable:!0,ignoreBorder:!0}),this.containerClassName="inkAnnotation",this.svgElementName="svg:polyline",this.annotationEditorType=hn.INK}render(){this.container.classList.add(this.containerClassName);const{data:{rect:t,inkLists:r,borderStyle:n,popupRef:o}}=this,{width:i,height:a}=e2(t),l=this.svgFactory.create(i,a,!0);for(const d of r){let u=[];for(let h=0,f=d.length;h<f;h+=2){const g=d[h]-t[0],y=t[3]-d[h+1];u.push(`${g},${y}`)}u=u.join(" ");const p=this.svgFactory.createElement(this.svgElementName);this.#e.push(p),p.setAttribute("points",u),p.setAttribute("stroke-width",n.width||1),p.setAttribute("stroke","transparent"),p.setAttribute("fill","transparent"),!o&&this.hasPopupData&&this._createPopup(),l.append(p)}return this.container.append(l),this.container}getElementsToTriggerPopup(){return this.#e}addHighlightArea(){this.container.classList.add("highlightArea")}}class mpt extends ti{constructor(t){super(t,{isRenderable:!0,ignoreBorder:!0,createQuadrilaterals:!0})}render(){return!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container.classList.add("highlightAnnotation"),this.container}}class fpt extends ti{constructor(t){super(t,{isRenderable:!0,ignoreBorder:!0,createQuadrilaterals:!0})}render(){return!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container.classList.add("underlineAnnotation"),this.container}}class gpt extends ti{constructor(t){super(t,{isRenderable:!0,ignoreBorder:!0,createQuadrilaterals:!0})}render(){return!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container.classList.add("squigglyAnnotation"),this.container}}class ypt extends ti{constructor(t){super(t,{isRenderable:!0,ignoreBorder:!0,createQuadrilaterals:!0})}render(){return!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container.classList.add("strikeoutAnnotation"),this.container}}class f4e extends ti{constructor(t){super(t,{isRenderable:!0,ignoreBorder:!0})}render(){return this.container.classList.add("stampAnnotation"),!this.data.popupRef&&this.hasPopupData&&this._createPopup(),this.container}}class vpt extends ti{#e=null;constructor(t){super(t,{isRenderable:!0});const{file:r}=this.data;this.filename=r.filename,this.content=r.content,this.linkService.eventBus?.dispatch("fileattachmentannotation",{source:this,...r})}render(){this.container.classList.add("fileAttachmentAnnotation");const{container:t,data:r}=this;let n;r.hasAppearance||r.fillAlpha===0?n=document.createElement("div"):(n=document.createElement("img"),n.src=`${this.imageResourcesPath}annotation-${/paperclip/i.test(r.name)?"paperclip":"pushpin"}.svg`,r.fillAlpha&&r.fillAlpha<1&&(n.style=`filter: opacity(${Math.round(r.fillAlpha*100)}%);`)),n.addEventListener("dblclick",this.#t.bind(this)),this.#e=n;const{isMac:o}=bs.platform;return t.addEventListener("keydown",i=>{i.key==="Enter"&&(o?i.metaKey:i.ctrlKey)&&this.#t()}),!r.popupRef&&this.hasPopupData?this._createPopup():n.classList.add("popupTriggerArea"),t.append(n),t}getElementsToTriggerPopup(){return this.#e}addHighlightArea(){this.container.classList.add("highlightArea")}#t(){this.downloadManager?.openOrDownloadData(this.content,this.filename)}}let bpt=class{#e=null;#t=null;#r=new Map;constructor({div:t,accessibilityManager:r,annotationCanvasMap:n,annotationEditorUIManager:o,page:i,viewport:a}){this.div=t,this.#e=r,this.#t=n,this.page=i,this.viewport=a,this.zIndex=0,this._annotationEditorUIManager=o}#o(t,r){const n=t.firstChild||t;n.id=`${Yge}${r}`,this.div.append(t),this.#e?.moveElementInDOM(this.div,t,n,!1)}async render(t){const{annotations:r}=t,n=this.div;cm(n,this.viewport);const o=new Map,i={data:null,layer:n,linkService:t.linkService,downloadManager:t.downloadManager,imageResourcesPath:t.imageResourcesPath||"",renderForms:t.renderForms!==!1,svgFactory:new YO,annotationStorage:t.annotationStorage||new eN,enableScripting:t.enableScripting===!0,hasJSActions:t.hasJSActions,fieldObjects:t.fieldObjects,parent:this,elements:null};for(const a of r){if(a.noHTML)continue;const l=a.annotationType===Si.POPUP;if(l){const p=o.get(a.id);if(!p)continue;i.elements=p}else{const{width:p,height:h}=e2(a.rect);if(p<=0||h<=0)continue}i.data=a;const d=tpt.create(i);if(!d.isRenderable)continue;if(!l&&a.popupRef){const p=o.get(a.popupRef);p?p.push(d):o.set(a.popupRef,[d])}const u=d.render();a.hidden&&(u.style.visibility="hidden"),this.#o(u,a.id),d.annotationEditorType>0&&(this.#r.set(d.data.id,d),this._annotationEditorUIManager?.renderAnnotationElement(d))}this.#s()}update({viewport:t}){const r=this.div;this.viewport=t,cm(r,{rotation:t.rotation}),this.#s(),r.hidden=!1}#s(){if(!this.#t)return;const t=this.div;for(const[r,n]of this.#t){const o=t.querySelector(`[data-annotation-id="${r}"]`);if(!o)continue;n.className="annotationContent";const{firstChild:i}=o;i?i.nodeName==="CANVAS"?i.replaceWith(n):i.classList.contains("annotationContent")?i.after(n):i.before(n):o.append(n)}this.#t.clear()}getEditableAnnotations(){return Array.from(this.#r.values())}getEditableAnnotation(t){return this.#r.get(t)}};const R9=/\r\n?|\n/g;class Ei extends Tr{#e=this.editorDivBlur.bind(this);#t=this.editorDivFocus.bind(this);#r=this.editorDivInput.bind(this);#o=this.editorDivKeydown.bind(this);#s=this.editorDivPaste.bind(this);#n;#i="";#l=`${this.id}-editor`;#d;#u=null;static _freeTextDefaultContent="";static _internalPadding=0;static _defaultColor=null;static _defaultFontSize=10;static get _keyboardManager(){const t=Ei.prototype,r=i=>i.isEmpty(),n=I0.TRANSLATE_SMALL,o=I0.TRANSLATE_BIG;return vn(this,"_keyboardManager",new p6([[["ctrl+s","mac+meta+s","ctrl+p","mac+meta+p"],t.commitOrRemove,{bubbles:!0}],[["ctrl+Enter","mac+meta+Enter","Escape","mac+Escape"],t.commitOrRemove],[["ArrowLeft","mac+ArrowLeft"],t._translateEmpty,{args:[-n,0],checker:r}],[["ctrl+ArrowLeft","mac+shift+ArrowLeft"],t._translateEmpty,{args:[-o,0],checker:r}],[["ArrowRight","mac+ArrowRight"],t._translateEmpty,{args:[n,0],checker:r}],[["ctrl+ArrowRight","mac+shift+ArrowRight"],t._translateEmpty,{args:[o,0],checker:r}],[["ArrowUp","mac+ArrowUp"],t._translateEmpty,{args:[0,-n],checker:r}],[["ctrl+ArrowUp","mac+shift+ArrowUp"],t._translateEmpty,{args:[0,-o],checker:r}],[["ArrowDown","mac+ArrowDown"],t._translateEmpty,{args:[0,n],checker:r}],[["ctrl+ArrowDown","mac+shift+ArrowDown"],t._translateEmpty,{args:[0,o],checker:r}]]))}static _type="freetext";static _editorType=hn.FREETEXT;constructor(t){super({...t,name:"freeTextEditor"}),this.#n=t.color||Ei._defaultColor||Tr._defaultLineColor,this.#d=t.fontSize||Ei._defaultFontSize}static initialize(t,r){Tr.initialize(t,r,{strings:["pdfjs-free-text-default-content"]});const n=getComputedStyle(document.documentElement);this._internalPadding=parseFloat(n.getPropertyValue("--freetext-padding"))}static updateDefaultParams(t,r){switch(t){case Lr.FREETEXT_SIZE:Ei._defaultFontSize=r;break;case Lr.FREETEXT_COLOR:Ei._defaultColor=r;break}}updateParams(t,r){switch(t){case Lr.FREETEXT_SIZE:this.#h(r);break;case Lr.FREETEXT_COLOR:this.#c(r);break}}static get defaultPropertiesToUpdate(){return[[Lr.FREETEXT_SIZE,Ei._defaultFontSize],[Lr.FREETEXT_COLOR,Ei._defaultColor||Tr._defaultLineColor]]}get propertiesToUpdate(){return[[Lr.FREETEXT_SIZE,this.#d],[Lr.FREETEXT_COLOR,this.#n]]}#h(t){const r=o=>{this.editorDiv.style.fontSize=`calc(${o}px * var(--scale-factor))`,this.translate(0,-(o-this.#d)*this.parentScale),this.#d=o,this.#m()},n=this.#d;this.addCommands({cmd:r.bind(this,t),undo:r.bind(this,n),post:this._uiManager.updateUI.bind(this._uiManager,this),mustExec:!0,type:Lr.FREETEXT_SIZE,overwriteIfSameType:!0,keepUndo:!0})}#c(t){const r=o=>{this.#n=this.editorDiv.style.color=o},n=this.#n;this.addCommands({cmd:r.bind(this,t),undo:r.bind(this,n),post:this._uiManager.updateUI.bind(this._uiManager,this),mustExec:!0,type:Lr.FREETEXT_COLOR,overwriteIfSameType:!0,keepUndo:!0})}_translateEmpty(t,r){this._uiManager.translateSelectedEditors(t,r,!0)}getInitialTranslation(){const t=this.parentScale;return[-Ei._internalPadding*t,-(Ei._internalPadding+this.#d)*t]}rebuild(){this.parent&&(super.rebuild(),this.div!==null&&(this.isAttachedToDOM||this.parent.add(this)))}enableEditMode(){if(this.isInEditMode())return;this.parent.setEditingState(!1),this.parent.updateToolbar(hn.FREETEXT),super.enableEditMode(),this.overlayDiv.classList.remove("enabled"),this.editorDiv.contentEditable=!0,this._isDraggable=!1,this.div.removeAttribute("aria-activedescendant");const t=this._uiManager._signal;this.editorDiv.addEventListener("keydown",this.#o,{signal:t}),this.editorDiv.addEventListener("focus",this.#t,{signal:t}),this.editorDiv.addEventListener("blur",this.#e,{signal:t}),this.editorDiv.addEventListener("input",this.#r,{signal:t}),this.editorDiv.addEventListener("paste",this.#s,{signal:t})}disableEditMode(){this.isInEditMode()&&(this.parent.setEditingState(!0),super.disableEditMode(),this.overlayDiv.classList.add("enabled"),this.editorDiv.contentEditable=!1,this.div.setAttribute("aria-activedescendant",this.#l),this._isDraggable=!0,this.editorDiv.removeEventListener("keydown",this.#o),this.editorDiv.removeEventListener("focus",this.#t),this.editorDiv.removeEventListener("blur",this.#e),this.editorDiv.removeEventListener("input",this.#r),this.editorDiv.removeEventListener("paste",this.#s),this.div.focus({preventScroll:!0}),this.isEditing=!1,this.parent.div.classList.add("freetextEditing"))}focusin(t){this._focusEventsAllowed&&(super.focusin(t),t.target!==this.editorDiv&&this.editorDiv.focus())}onceAdded(){this.width||(this.enableEditMode(),this.editorDiv.focus(),this._initialOptions?.isCentered&&this.center(),this._initialOptions=null)}isEmpty(){return!this.editorDiv||this.editorDiv.innerText.trim()===""}remove(){this.isEditing=!1,this.parent&&(this.parent.setEditingState(!0),this.parent.div.classList.add("freetextEditing")),super.remove()}#a(){const t=[];this.editorDiv.normalize();for(const r of this.editorDiv.childNodes)t.push(Ei.#g(r));return t.join(`
292
292
  `)}#m(){const[t,r]=this.parentDimensions;let n;if(this.isAttachedToDOM)n=this.div.getBoundingClientRect();else{const{currentLayer:o,div:i}=this,a=i.style.display,l=i.classList.contains("hidden");i.classList.remove("hidden"),i.style.display="hidden",o.div.append(this.div),n=i.getBoundingClientRect(),i.remove(),i.style.display=a,i.classList.toggle("hidden",l)}this.rotation%180===this.parentRotation%180?(this.width=n.width/t,this.height=n.height/r):(this.width=n.height/t,this.height=n.width/r),this.fixAndSetPosition()}commit(){if(!this.isInEditMode())return;super.commit(),this.disableEditMode();const t=this.#i,r=this.#i=this.#a().trimEnd();if(t===r)return;const n=o=>{if(this.#i=o,!o){this.remove();return}this.#p(),this._uiManager.rebuild(this),this.#m()};this.addCommands({cmd:()=>{n(r)},undo:()=>{n(t)},mustExec:!1}),this.#m()}shouldGetKeyboardEvents(){return this.isInEditMode()}enterInEditMode(){this.enableEditMode(),this.editorDiv.focus()}dblclick(t){this.enterInEditMode()}keydown(t){t.target===this.div&&t.key==="Enter"&&(this.enterInEditMode(),t.preventDefault())}editorDivKeydown(t){Ei._keyboardManager.exec(this,t)}editorDivFocus(t){this.isEditing=!0}editorDivBlur(t){this.isEditing=!1}editorDivInput(t){this.parent.div.classList.toggle("freetextEditing",this.isEmpty())}disableEditing(){this.editorDiv.setAttribute("role","comment"),this.editorDiv.removeAttribute("aria-multiline")}enableEditing(){this.editorDiv.setAttribute("role","textbox"),this.editorDiv.setAttribute("aria-multiline",!0)}render(){if(this.div)return this.div;let t,r;this.width&&(t=this.x,r=this.y),super.render(),this.editorDiv=document.createElement("div"),this.editorDiv.className="internal",this.editorDiv.setAttribute("id",this.#l),this.editorDiv.setAttribute("data-l10n-id","pdfjs-free-text"),this.enableEditing(),Tr._l10nPromise.get("pdfjs-free-text-default-content").then(o=>this.editorDiv?.setAttribute("default-content",o)),this.editorDiv.contentEditable=!0;const{style:n}=this.editorDiv;if(n.fontSize=`calc(${this.#d}px * var(--scale-factor))`,n.color=this.#n,this.div.append(this.editorDiv),this.overlayDiv=document.createElement("div"),this.overlayDiv.classList.add("overlay","enabled"),this.div.append(this.overlayDiv),ob(this,this.div,["dblclick","keydown"]),this.width){const[o,i]=this.parentDimensions;if(this.annotationElementId){const{position:a}=this.#u;let[l,d]=this.getInitialTranslation();[l,d]=this.pageTranslationToScreen(l,d);const[u,p]=this.pageDimensions,[h,f]=this.pageTranslation;let g,y;switch(this.rotation){case 0:g=t+(a[0]-h)/u,y=r+this.height-(a[1]-f)/p;break;case 90:g=t+(a[0]-h)/u,y=r-(a[1]-f)/p,[l,d]=[d,-l];break;case 180:g=t-this.width+(a[0]-h)/u,y=r-(a[1]-f)/p,[l,d]=[-l,-d];break;case 270:g=t+(a[0]-h-this.height*p)/u,y=r+(a[1]-f-this.width*u)/p,[l,d]=[-d,l];break}this.setAt(g*o,y*i,l,d)}else this.setAt(t*o,r*i,this.width*o,this.height*i);this.#p(),this._isDraggable=!0,this.editorDiv.contentEditable=!1}else this._isDraggable=!1,this.editorDiv.contentEditable=!0;return this.div}static#g(t){return(t.nodeType===Node.TEXT_NODE?t.nodeValue:t.innerText).replaceAll(R9,"")}editorDivPaste(t){const r=t.clipboardData||window.clipboardData,{types:n}=r;if(n.length===1&&n[0]==="text/plain")return;t.preventDefault();const o=Ei.#f(r.getData("text")||"").replaceAll(R9,`
@@ -326,7 +326,7 @@ _failed_count_ Transaction failed.`},transactionsUpdated_transactionsFailed:{suc
326
326
  _updated_count_ Transaction updated.
327
327
  _failed_count_ Transactions failed.`},transactionCategorized_transactionUpdated_transactionFailed:{success:"",failed:"",notification:`_categorized_count_ Transaction categorized.
328
328
  _updated_count_ Transaction updated.
329
- _failed_count_ Transaction failed.`},people_invite_people:{success:"Invitation sent",failed:"",notification:""},people_invite_multiple_people:{success:"Users invited",failed:"",notification:""},people_update_person:{success:"User info changed",failed:"",notification:""},people_delete_person:{success:"User deleted",failed:"",notification:""},reimbursement_updated:{success:"Reimbursement saved",failed:"_api-error_.",notification:""},reimbursement_approved:{success:"Reimbursement approved",failed:"_api-error_.",notification:""},reimbursement_rejected:{success:"Reimbursement rejected",failed:"_api-error_.",notification:""},reimbursement_sent_for_approval:{success:"Reimbursement sent for approval",failed:"_api-error_.",notification:""},reimbursement_deleted:{success:"Reimbursement deleted",failed:"_api-error_.",notification:""},reimbursement_cancelled:{success:"Reimbursement canceled",failed:"_api-error_.",notification:""},reimbursement_cancelled_deleted:{success:"Reimbursement canceled and deleted",failed:"_api-error_.",notification:""},reimbursement_bulk_submit:{success:"_count_ _report_ will be _action_. You'll be notified once it's done.",failed:"_api-error_.",notification:""},reimbursement_bulk_processed:{success:"_report_ _has_ been _action_. The page will refresh now to reflect updates.",failed:"_api-error_.",notification:""},save_reconcile_for_later:{success:"Reconciliation saved",failed:"Reconciliation not saved. Please try again!",notification:""},reconcile:{success:"_reconcile_account_ reconciliation in progress.",failed:"Reconciliation failed for _reconcile_account_",notification:""},exclude_transaction:{success:"Transaction excluded",failed:"Transaction exclusion failed",notification:""},account_added:{success:"Account added successfully",failed:"",notification:""},issue_charge_card:{success:"New _card_ issued for _user-name_",failed:"",notification:""},issue_charge_cards:{success:"New cards issued",failed:"",notification:""},charge_card_auto_pay_enable:{success:"Early payment enabled",failed:"",notification:""},charge_card_auto_pay_disable:{success:"Early payment disabled",failed:"",notification:""},business_verification_save:{success:"Business Verification Details saved successfully.",failed:"Couldn't save Business Verification Details. Please try again.",notification:""},business_verification_submit:{success:"Business Verification Details submitted successfully.",failed:"Couldn't submit Business Verification Details. Please try again.",notification:""},business_verification_from_bills_submit:{success:"Verified successfully.",failed:"Couldn't submit Business Verification Details. Please try again.",notification:""},plaid_connection:{success:"",failed:"Something went wrong! Please try again.",notification:""},bill_pay_setup:{success:"",failed:"Failed to load Bill Pay Setup Details! Please try again.",notification:""},zeni_accounts_setup:{success:"",failed:"Failed to load Zeni Accounts Setup Details! Please try again.",notification:""},bill_pay_approval_create:{success:"Approval Rule created successfully.",failed:"Couldn't create Approval Rule! Please try again.",notification:""},bill_pay_duplicate_approval_create:{success:"Approval Rule created successfully.",failed:"_api-error_",notification:""},bill_pay_approval_update:{success:"Approval Rule updated successfully.",failed:"Couldn't update Approval Rule! Please try again.",notification:""},update_zeni_account_nickname:{success:"Zeni Account nickname updated successfully",failed:"_api-error_.",notification:""},create_checking_account:{success:"New Business Account Added",failed:"_api-error_.",notification:""},deposit_check:{success:"Check Deposit Successful",failed:"_api-error_.",notification:""},bill_pay_duplicate_approval_update:{success:"Approval Rule updated successfully.",failed:"_api-error_",notification:""},bill_pay_approval_delete:{success:"Approval Rule deleted successfully.",failed:"Couldn't delete Approval Rule! Please try again.",notification:""},reimbursement_setup:{success:"",failed:"Failed to load Reimbursements Setup Details! Please try again.",notification:""},reimbursement_approval_create:{success:"Approval Rule created successfully.",failed:"Couldn't create Approval Rule! Please try again.",notification:""},reimbursement_duplicate_approval_create:{success:"Approval Rule created successfully.",failed:"_api-error_",notification:""},reimbursement_approval_update:{success:"Approval Rule updated successfully.",failed:"Couldn't update Approval Rule! Please try again.",notification:""},reimbursement_duplicate_approval_update:{success:"Approval Rule updated successfully.",failed:"_api-error_",notification:""},reimbursement_approval_delete:{success:"Approval Rule deleted successfully.",failed:"Couldn't delete Approval Rule! Please try again.",notification:""},reimbursement_create_mileage:{success:"Mileage rate added successfully.",failed:"_api-error_.",notification:""},reimbursement_update_mileage:{success:"Mileage rate updated successfully.",failed:"_api-error_.",notification:""},reimbursement_accept_term:{success:"",failed:"_api-error_.",notification:""},reimbursement_accept_employee_term:{success:"",failed:"_api-error_.",notification:""},cockpit_month_end_email_sent:{success:"Zeni Insights sent successfully for _company-name_.",failed:"",notification:""},cockpit_month_end_email_save:{success:"Zeni Insights saved successfully for _company-name_.",failed:"",notification:""},cockpit_month_end_email_attachment_upload:{success:"",failed:"Sorry, the file you uploaded is too large. Maximum file size allowed is 700KB",notification:""},audit_score_updated:{success:"Audit Score updated",failed:"",notification:""},create_bank_account_ach:{success:"ACH account added successfully.",failed:"",notification:""},unlink_deposit_account:{success:"",failed:"_api-error_.",notification:""},create_bank_account_wire:{success:"_wire-type_ wire account added successfully.",failed:"",notification:""},create_bank_account_international:{success:"_wire-type_ wire account added successfully.",failed:"",notification:""},bill_pay_updated:{success:"Bill saved",failed:"_api-error_.",notification:""},bill_pay_deleted:{success:"Bill deleted",failed:"_api-error_.",notification:""},bill_pay_bulk_submit:{success:"_count_ _bill_ will be _action_. You'll be notified once it's done.",failed:"_api-error_.",notification:""},bill_pay_bulk_processed:{success:"_bill_ _has_ been _action_. The page will refresh now to reflect updates.",failed:"_api-error_.",notification:""},bill_pay_cancelled_deleted:{success:"Bill canceled and deleted",failed:"_api-error_.",notification:""},bill_pay_cancelled:{success:"Bill canceled",failed:"_api-error_.",notification:""},bill_pay_approved:{success:"Bill approved",failed:"_api-error_.",notification:""},bill_pay_rejected:{success:"Bill rejected",failed:"_api-error_.",notification:""},bill_pay_sent_for_approval:{success:"Bill sent for approval",failed:"_api-error_.",notification:""},bill_pay_accept_term:{success:"",failed:"_api-error_.",notification:""},bill_pay_refund:{success:"Refund process initiated",failed:"_api-error_.",notification:""},bill_pay_retry:{success:"Payment retried",failed:"_api-error_.",notification:""},bill_pay_marked_as_paid:{success:"Bill marked as paid",failed:"_api-error_.",notification:""},update_vendor:{success:"Vendor updated successfully.",failed:"_api-error_.",notification:""},data_refresh_update:{success:"Data refreshed",failed:"_api-error_.",notification:""},delete_bank_account:{success:"Bank account deleted successfully.",failed:"_api-error_.",notification:""},update_debit_card_pin_attempt:{success:"PIN changed successfully",failed:"_api-error_.",notification:""},set_debit_card_pin:{success:"PIN set successfully",failed:"_api-error_.",notification:""},create_bank_account:{success:"",failed:"_api-error_.",notification:""},send_email_magic_link_to_user:{success:"",failed:"_api-error_.",notification:""},complete_profile_done:{success:"Profile details saved.",failed:"_api-error_.",notification:""},zeni_account_accept_term:{success:"",failed:"_api-error_.",notification:""},transfer_money:{success:"",failed:"_api-error_.",notification:""},create_vendor:{success:"Vendor created successfully.",failed:"_api-error_.",notification:""},onboarding_customer_view:{success:"Onboarding Business Details fetched successfully.",failed:"Couldn't fetch Onboarding Business Details. Please try again.",notification:""},onboarding_customer_view_complete:{success:"Onboarding status updated successfully.",failed:"Couldn't update Onboarding status. Please try again.",notification:""},onboarding_customer_identity_verification_save:{success:"Onboarding Identity Details saved successfully.",failed:"Couldn't save Onboarding Identity Details. Please try again.",notification:""},onboarding_customer_identity_verification_submit:{success:"Onboarding Identity Details submitted successfully.",failed:"Couldn't submit Onboarding Identity Details. Please try again.",notification:""},onboarding_customer_business_verification_save:{success:"Onboarding Business Details saved successfully.",failed:"Couldn't save Onboarding Business Details. Please try again.",notification:""},onboarding_customer_business_verification_submit:{success:"Onboarding Business Details submitted successfully.",failed:"Couldn't submit Onboarding Business Details. Please try again.",notification:""},retry_bank_account_connection:{success:"Bank account connection completed successfully.",failed:"Bank account connection failed.",notification:""},dashboard_invite_sent:{success:"Dashboard invite sent to _user-name_ for _company-name_ successfully.",failed:"Dashboard invite failed",notification:""},onboarding_info_saved:{success:"Saved successfully",failed:"Save failed",notification:""},approve_original_merchant:{success:'Review request for "_merchant_name_" is approved successfully.',failed:"_api-error_.",notification:""},approve_global_merchant:{success:'Review request for "_original_merchant_name_" to "_approved_merchant_name_" is approved successfully.',failed:"_api-error_.",notification:""},reject_global_merchant:{success:'Vendor "_merchant_name_" review rejected',failed:"_api-error_.",notification:""},create_global_merchant:{success:'Vendor "_global_merchant_name_" successfully added to global list.',failed:"_api-error_.",notification:""},fetch_global_merchant_no_recommendation:{success:'There are no recommendations for the name "_global_merchant_name_".',failed:"_api-error_.",notification:""},save_vendor_sent_for_review:{success:'Vendor "_vendor_name_" sent for the review.',failed:"_api-error_.",notification:""},save_vendor_renamed:{success:'Vendor "_old_vendor_name_" renamed to "_updated_vendor_name_."',failed:"_api-error_.",notification:""},save_vendor_marked_as_employee:{success:"Marked as employee",failed:"_api-error_.",notification:""},save_vendor_marked_as_local_contractor:{success:"Marked as local contractor",failed:"_api-error_.",notification:""},charge_card_setup:{success:"",failed:"Failed to load Cards Setup Details! Please try again.",notification:""},charge_card_receipt_upload:{success:"Card receipt uploaded",failed:"_api-error_.",notification:""},charge_card_resend_invite:{success:"Card invite resent",failed:"_api-error_.",notification:""},charge_card_revoke_invite:{success:"Card invite revoked",failed:"_api-error_.",notification:""},charge_card_update_limit:{success:"Card limit updated to _amount_",failed:"Limit updation failed with _api-error_.",notification:""},charge_cards_update_limit:{success:"Limit updated for _number_of_cards_",failed:"Limit updation failed with _api-error_.",notification:""},update_charge_card_name:{success:'Card _masked_card_number_ renamed to "_new_card_name_"',failed:"Card name updation failed with _api-error_.",notification:""},update_charge_card_name_card_user:{success:'Card renamed to "_new_card_name_"',failed:"Card name updation failed with _api-error_.",notification:""},lock_charge_card:{success:"Card _masked_card_number_ locked",failed:"Card lock failed with _api-error_.",notification:""},lock_charge_card_card_user:{success:"Card locked",failed:"Card lock failed with _api-error_.",notification:""},unlock_charge_card:{success:"Card _masked_card_number_ unlocked",failed:"Card unlock failed with _api-error_.",notification:""},unlock_charge_card_card_user:{success:"Card unlocked",failed:"Card unlock failed with _api-error_.",notification:""},close_charge_card:{success:"Card _masked_card_number_ closed",failed:"Card close failed with _api-error_.",notification:""},unlock_charge_cards:{success:"_number_of_cards_ unlocked",failed:"Cards unlock failed with _api-error_.",notification:""},lock_charge_cards:{success:"_number_of_cards_ locked",failed:"Cards lock failed with _api-error_.",notification:""},close_charge_cards:{success:"_number_of_cards_ closed",failed:"Cards close failed with _api-error_.",notification:""},revoke_invite_charge_cards:{success:"Invite revoked for _number_of_cards_",failed:"Invite revoke failed with _api-error_.",notification:""},create_schedule:{success:'Schedule created for "_vendor_name_"',failed:"Schedule creation failed with _api-error_.",notification:""},save_schedule:{success:'Schedule saved for "_vendor_name_"',failed:"Save schedule failed with _api-error_.",notification:""},je_posted:{success:"JE Posted",failed:"JE Posting failed with _api-error_.",notification:""},ignore_schedule:{success:"Schedule Ignored",failed:"Schedule Ignore failed with _api-error_.",notification:""},delete_schedule:{success:'Schedule deleted for "_vendor_name_"',failed:"Delete schedule failed with _api-error_.",notification:""},mark_as_complete_schedule:{success:'Schedule marked as completed for "_vendor_name_"',failed:"Mark as complete schedule failed with _api-error_.",notification:""},cancel_journal_entry:{success:"Accrual Canceled",failed:"Accrual Cancel failed with _api-error_.",notification:""},charge_card_accept_term:{success:"",failed:"_api-error_.",notification:""},charge_card_express_interest:{success:"Interest expressed successfully",failed:"_api-error_.",notification:""},save_task_detail:{success:"",failed:"_api-error_.",notification:""},fetch_task_detail:{success:"Task details fetched successfully.",failed:"_api-error_.",notification:""},delete_task:{success:"",failed:"_api-error_.",notification:""},archive_task:{success:"",failed:"_api-error_.",notification:""},update_charge_card:{success:"",failed:"_api-error_.",notification:""},notification_settings_saved:{success:"Notification Settings Saved",failed:"_api-error_.",notification:""},referral_invite_sent:{success:"Referral Invite Sent",failed:"_api-error_.",notification:""},notification_mark_as_read:{success:"Notifications marked as read successfully.",failed:"Something went wrong! Please try again.",notification:""},settings_accounting_accounts_updated:{success:"Accounts saved",failed:"",notification:""},task_group_creation_success:{success:"Task group created successfully",failed:"Task group creation failed",notification:""},task_group_deletion_success:{success:"Task group deleted successfully",failed:"Task group deletion failed",notification:""},task_group_update_success:{success:"Task group updated successfully",failed:"Task group update failed",notification:""},primary_funding_account_updated:{success:"Bank account updated for _productType_.",failed:"",notification:""},task_time_spent_validation:{success:"",failed:"Time can't exceed 99h 59m",notification:""},missing_receipts_attachment:{success:"",failed:"Failed to upload attachment__message__ please try again!",notification:""},flux_analysis_reviewed:{success:"_vendors_count_ _vendor_ reviewed",failed:"_api-error_.",notification:""},flux_analysis_unreviewed:{success:"_vendors_count_ _vendor_ unreviewed",failed:"_api-error_.",notification:""},express_pay_submit:{success:"Payment scheduled",failed:"_api-error_.",notification:""},recon_transaction_categorize:{success:"Transaction categorized",failed:"_api-error_.",notification:""},recon_transaction_match:{success:"Transaction matched",failed:"_api-error_.",notification:""},ai_cfo_create_session_and_submit:{success:"",failed:"Something went wrong, please try again!",notification:""},treasury_setup:{success:"",failed:"Failed to load Treasury Setup Details! Please try again.",notification:""},treasury_accept_term:{success:"Treasury Terms accepted successfully.",failed:"Failed to accept terms. Please try again.",notification:""},treasury_transfer_money:{success:"Transfer initiated.",failed:"Transfer failed. Please try again.",notification:""},treasury_transfer_money_failed:{success:"",failed:"Transfer failed. Please try again.",notification:""},treasury_update_portfolio_allocation:{success:"Portfolio allocation updated.",failed:"Portfolio allocation update failed. Please try again!",notification:""},reports_resync:{success:"",failed:"Something went wrong. Please try again.",notification:"No new data available."},invalid_phone_number:{success:"",failed:"Invalid phone number",notification:""}},currency:{currencyCode:"USD",currencySymbol:"$",currency:"United States Dollar",countryCode:"US"},format:{ssnFormat:"###-##-####",tinFormat:"##-#######"},status:{pending:"Pending"},cancel:"Cancel",confirm:"Confirm",continue:"Continue",proceed:"Proceed",next:"Next",noText:"--",privacy:"Zeni Privacy Policy",terms:"Terms and Conditions",privacyPolicyUrl:"https://www.zeni.ai/legal/privacy-policy",termsUrl:"https://www.zeni.ai/legal/terms-of-service",footer:{save:"Save",submit:"Submit",cancel:"Cancel",approve:"Approve",reject:"Reject",send:"Send",resubmit:"Resubmit",add:"Add",continueAnyway:"Continue Anyway",resolve:"Resolve",inReview:"In Review",sentForReview:"Sent for Review",linkCard:"Link Card",next:"Next",back:"Back",markAsUnReviewed:"Mark as Unreviewed",markAsReviewed:"Mark as Reviewed",saveForLater:"Save for Later",reconcile:"Reconcile",edit:"Edit",noThanks:"No, Thanks",letsGetStarted:"Let's Get Started"},completeText:"Complete",incompleteText:"Incomplete",notInitiatedText:"Not Initiated",pendingReviewText:"Pending Review",pendingVerificationText:"Pending Verification",retry:"Retry",verified:"Verified",validation:{emailAddressRequired:"Email address required",invalidEmailAddress:"Invalid email address",invalidUrlAddress:"Invalid URL"},needHelp:{text:"Need Help",hoverPrefix:"Experiencing issues?",hoverSuffix:" Schedule a call"},confirmationPopup:{discardTitle:"Discard unsaved changes?",discardDescription:"Changes are not automatically saved. Your changes will be lost if you continue.",discard:"Discard",cancel:"Cancel"},via:"via",cockpit:"cockpit",analytics:"Analytics",filters:{noOptions:"No Options",noMatchesFound:"No Matches Found",userProfileAltText:"Failed to load",startDate:"Start Date",endDate:"End Date"},updated:"Updated",hoursAgo:"hours ago",minutesAgo:"a few minutes ago",noMatches:"Nothing matched your search. Please try again!",noReport:"No _item-name_ to display yet!",reloadPage:{label:"Something went wrong, please try again!"},settings:{title:{accounting:"Accounting Setup",approvalRules:"Approval Rules",bankConnections:"Bank Connections",integrations:"Integrations",myProfile:"My Profile",myBankConnections:"My Bank Connections",notifications:"Notifications"},common:{update:"Update",cancel:"Cancel",productTypeString:"My Profile"},subtitle:{myProfile:"Profile Details",myBankConnections:"Reimbursements"},label:{primary:"Primary",billPay:"Bill Pay",reimbursements:"Reimbursements",bankAccount:"Bank Account",noManager:"No Manager",myProfile:"My Profile"},infoText:{accounting:"Quick access to manage the company's accounting-related settings",approvalRules:"Quick access to manage the multi-level approval rules for bills & reimbursements to make Zeni work better for you",bankConnections:"Manage primary bank account connections for Zeni Bill Payments, Reimbursements, Business Checking, and Business Cards.",businessVerification:"Financial regulations require Zeni to collect both identity & company details to verify your business",companyDetails:"Quick access to manage the company's detailed information",integrations:"Quick access to manage the company's third-party connected services",myProfile:"Quick access to manage your personal details",myBankConnections:"Manage your linked personal bank details used to receive reimbursements"},bankConnectionHeader:{productType:"Products",primaryAccount:"Primary Account",linkAccount:"QBO Linked Account",status:"Status",balance:"Balance"},bankConnectionListHeader:{primary:"Primary",other:"Other Connections",otherToolTip:"These bank connections aren't linked to any product. Select from the dropdown above to connect."},productNameByType:{bill_pay:"Bill Pay",reimbursement:"Reimbursements",zeni_accounts:"Checking",zeni_treasury:"Treasury",charge_cards:"Cards"},otherAccount:{title:"Product",subTitle:"Not assigned",subTitleSmall:"not assigned",remove:"Remove Connection"},notifications:{sectionTitle:{reminders:"Reminders",monthEndInsights:"Month-end Insights"},frequency:{biWeekly:"Bi-Weekly"},mode:{email:"Email",dashboard:"Dashboard"},reminders:{missingReceiptNotification:"Missing Receipts:",uncategorizedTransactionNotification:"Uncategorized Transactions:",pendingBillApprovalNotification:"Bill Approvals:",pendingReimbursementApprovalNotification:"Reimbursement Approvals:"},monthEndInsights:{labels:{notifyMe:"Notify Me:",notifyOthers:"Notify Others:"},userFieldPlaceholder:"Who should receive this email?",stopReceivingEmailsText:"To stop receiving this email, reach out to",stopReceivingMonthEndInsightsSubject:"Stop Month End Insights"},reminderFrequencyOptions:[{label:"Daily",value:"daily"},{label:"Weekly",value:"weekly"},{label:"Bi-weekly",value:"bi-weekly"},{label:"Monthly",value:"monthly"}]}},copyToClipBoard:{copy:"Copy",copied:"Copied"},monthsByIndex:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},download:{errorMessages:{unsupportedFileType:"Unsupported Filetype",fileDownloadError:"Download __feature__ Failed with"},defaultFileName:"Report.xlsx"},balanceCard:{cashBalanceSectionTitle:"Total Cash Balance",cardBalanceSectionTitle:"Total Card Balance",comparedTo:"compared to",noBalanceText:"No balance data to display yet!"},insightsCard:{vs:"vs",title:"Insights",no_data:{label:"Cash, Opex, Revenue, COS, and Cash In Cash Out Insights, will appear once you have sufficient financial activity. Stay tuned! 💸"}},timeframe:{day:"Days",month:"Months",quarter:"Quarters",year:"Years",week:"Weeks",free_range:"Time period",this_week_to_date:"This Week",last_week:"Last Week",this_month_to_date:"This Month",last_month:"Last Month",last_3_months:"Last 3 Months",last_6_months:"Last 6 Months",last_12_months:"Last 12 Months",this_year_to_date:"This Year",last_year:"Last Year"},quarterPrefix:"Q",compareSwitchLabel:"Compare",compareMode:{off:"Off",compare_mode_percent:"Percentage",compare_mode_amount:"Amount",changePercent:"Change %",changePrefix:"Change"},chartCard:{total:"Total",activity:"Activity",no_data_available:"No data available!",no_data_available_for:"No data available for",tooltip:{actual:"Actual",forecast:"Forecast",change:"Change",change_percent:"Change %"},forecast_dropdown:{forecast_source:"Via Quickbooks",forecast_invalid_issue:"This period is not in the time frame of the actuals. Please view it via the Forecast tab."},netBurnOrIncome:{grossBurn:"Gross Burn",netBurnOrIncome:"Net Income / Burn",gross_burn:"Gross Burn",cogs:"COS",net_burn_or_income:"Net Income / Burn",income:"Revenue",expenses:"OPEX",net_burn:"Net Burn",net_income:"Net Income",no_data_available:"A minimum of one-month data is required!",cogs_forecast:"Forecast",net_burn_or_income_forecast:"Forecast",income_forecast:"Forecast",expenses_forecast:"Forecast"},netBurnOrIncomeCalculator:{title:"Burn Rate Calculator",accounting_method:{label:"Configure Burn Rate, Runway, and Cash Zero date based on below options:",cash:"Cash Flow from Operating Activities",ebitda:"EBITDA",net_income:"Net Income"},time_span_id_for_average:{label:"Further configure Burn Rate, Runway, and Cash Zero date based on below options:",last_month:"Last month",last_completed_month:"Last completed month",average_of_last_2_months:"Average of last 2 completed months",average_of_last_3_months:"Average of last 3 completed months",under_review_last_month_label:"(Including Under Review)"}},revenue:{income:"Revenue",cogs:"COS",gross_margin:"Gross Margin",grossMargin:"Gross Margin",income_forecast:"Forecast",cogs_forecast:"Forecast",gross_margin_forecast:"Forecast",grossMargin_forecast:"Forecast"},cashInCashOut:{cash_in:"Cash In",cash_out:"Cash Out",net_cash_flow:"Net Cash Flow"},no_data:{revenue:"No revenues to display yet, but thrift is a great revenue. Fight On!🤘",cash_in_cash_out:"No cash in cash out to display yet!",cash_position:"No cash position to display yet!",net_burn_or_income:"No net burn to display yet!",operating_expenses:"No operating expenses to display yet!",top_expenses:{this_week_to_date:"No expenses this week 🤷",last_week:"No expenses last week 🤷",this_month_to_date:"No expenses this month 🤷",last_month:"No expenses last month 🤷",last_3_months:"No expenses last 3 months 🤷",last_6_months:"No expenses last 6 months 🤷",last_12_months:"No expenses last 12 months 🤷",this_year_to_date:"No expenses this year 🤷",last_year:"No expenses last year 🤷"},aging_report:"No data to display yet!"}},drawerMenus:{dashboard:"Dashboard",cockpit:"Cockpit",reports:"Reports",people:"People",forecast:"Forecast",cards:"Cards",bills:"Bills",ai_automation:"AI Bookkeeping",storybooks:"Storybooks",settings:"Settings",logout:"Logout",reimbursements:"Reimbursements",checking:"Checking",vendors:"Vendors",rewards:"Rewards",accounting:"Accounting",approval_rules:"Approval Rules",billing:"Billing",bank_connections:"Bank Connections",business_verification:"Business Verification",company_details:"Company Details",integrations:"Integrations",my_profile:"My Profile",my_bank_connections:"My Bank Connections",notifications:"Notifications",performance:"Performance",ai_accountant:"AI Accountant",ai_cfo:"AI CFO",new_chat:"New Chat",explore:"Explore",treasury:"Treasury"},drawerMenuSubtitles:{rewards:"Earn __reward-amount__ per referral"},drawerGroups:{finance:"Finance",cash:"Cash",spend_management:"Spend Management",banking:"Banking",company:"Company",company_settings:"Company Settings",personal_settings:"Personal Settings",ai_bookkeeping:"AI Bookkeeping",ai_cfo:"",ai_agents:"AI Agents",ai_accountant:"AI Accountant"},drawerTags:{new:"NEW"},dashboardDropDownList:{menuOption:{logout:{label:"Logout",value:"logout"},settings:{label:"Settings",value:"settings"},cockpit:{label:"Cockpit",value:"cockpit"}}},transactionItem:{date:"Date",account:"Account"},transactionType:{invoice:"Invoice",creditMemo:"Credit Memo",salesReceipt:"Sales Receipt",refund:"Refund",expense:"Expense",check:"Check",bill:"Bill",billPayment:"Bill Payment",transfer:"Transfer",vendorCredit:"Vendor Credit",creditCardCredit:"Credit Card Credit",deposit:"Deposit",creditCardPayment:"Credit Card Payment",journalEntry:"Journal Entry",payment:"Payment"},signIn:{heading:"Welcome to Zeni",confirmationLinkSent:"Confirmation link sent",message:"Your financial dashboard is just one step away. Get started.",signInSecurelyMessage:"Choose an account to sign in securely",signInGoogleButton:"Sign In With Google",signInMicrosoftButton:"Sign In With Microsoft",termsPrivacyFinePrintPart:"By creating an account on Zeni, you confirm that you ",agreeWith:"agree with our ",termsOfService:"terms of service",and:"and",privacyPolicy:"privacy policy",termsUrl:"https://www.zeni.ai/terms",privacyPolicyUrl:"https://www.zeni.ai/privacy-policy",signInError:`Couldn’t sign-in to your account.
329
+ _failed_count_ Transaction failed.`},people_invite_people:{success:"Invitation sent",failed:"",notification:""},people_invite_multiple_people:{success:"Users invited",failed:"",notification:""},people_update_person:{success:"User info changed",failed:"",notification:""},people_delete_person:{success:"User deleted",failed:"",notification:""},reimbursement_updated:{success:"Reimbursement saved",failed:"_api-error_.",notification:""},reimbursement_approved:{success:"Reimbursement approved",failed:"_api-error_.",notification:""},reimbursement_rejected:{success:"Reimbursement rejected",failed:"_api-error_.",notification:""},reimbursement_sent_for_approval:{success:"Reimbursement sent for approval",failed:"_api-error_.",notification:""},reimbursement_deleted:{success:"Reimbursement deleted",failed:"_api-error_.",notification:""},reimbursement_cancelled:{success:"Reimbursement canceled",failed:"_api-error_.",notification:""},reimbursement_cancelled_deleted:{success:"Reimbursement canceled and deleted",failed:"_api-error_.",notification:""},reimbursement_bulk_submit:{success:"_count_ _report_ will be _action_. You'll be notified once it's done.",failed:"_api-error_.",notification:""},reimbursement_bulk_processed:{success:"_report_ _has_ been _action_. The page will refresh now to reflect updates.",failed:"_api-error_.",notification:""},save_reconcile_for_later:{success:"Reconciliation saved",failed:"Reconciliation not saved. Please try again!",notification:""},reconcile:{success:"_reconcile_account_ reconciliation in progress.",failed:"Reconciliation failed for _reconcile_account_",notification:""},exclude_transaction:{success:"Transaction excluded",failed:"Transaction exclusion failed",notification:""},account_added:{success:"Account added successfully",failed:"",notification:""},issue_charge_card:{success:"New _card_ issued for _user-name_",failed:"",notification:""},issue_charge_cards:{success:"New cards issued",failed:"",notification:""},charge_card_auto_pay_enable:{success:"Early payment enabled",failed:"",notification:""},charge_card_auto_pay_disable:{success:"Early payment disabled",failed:"",notification:""},business_verification_save:{success:"Business Verification Details saved successfully.",failed:"Couldn't save Business Verification Details. Please try again.",notification:""},business_verification_submit:{success:"Business Verification Details submitted successfully.",failed:"Couldn't submit Business Verification Details. Please try again.",notification:""},business_verification_from_bills_submit:{success:"Verified successfully.",failed:"Couldn't submit Business Verification Details. Please try again.",notification:""},plaid_connection:{success:"",failed:"Something went wrong! Please try again.",notification:""},bill_pay_setup:{success:"",failed:"Failed to load Bill Pay Setup Details! Please try again.",notification:""},zeni_accounts_setup:{success:"",failed:"Failed to load Zeni Accounts Setup Details! Please try again.",notification:""},bill_pay_approval_create:{success:"Approval Rule created successfully.",failed:"Couldn't create Approval Rule! Please try again.",notification:""},bill_pay_duplicate_approval_create:{success:"Approval Rule created successfully.",failed:"_api-error_",notification:""},bill_pay_approval_update:{success:"Approval Rule updated successfully.",failed:"Couldn't update Approval Rule! Please try again.",notification:""},update_zeni_account_nickname:{success:"Zeni Account nickname updated successfully",failed:"_api-error_.",notification:""},create_checking_account:{success:"New Business Account Added",failed:"_api-error_.",notification:""},deposit_check:{success:"Check Deposit Successful",failed:"_api-error_.",notification:""},bill_pay_duplicate_approval_update:{success:"Approval Rule updated successfully.",failed:"_api-error_",notification:""},bill_pay_approval_delete:{success:"Approval Rule deleted successfully.",failed:"Couldn't delete Approval Rule! Please try again.",notification:""},reimbursement_setup:{success:"",failed:"Failed to load Reimbursements Setup Details! Please try again.",notification:""},reimbursement_approval_create:{success:"Approval Rule created successfully.",failed:"Couldn't create Approval Rule! Please try again.",notification:""},reimbursement_duplicate_approval_create:{success:"Approval Rule created successfully.",failed:"_api-error_",notification:""},reimbursement_approval_update:{success:"Approval Rule updated successfully.",failed:"Couldn't update Approval Rule! Please try again.",notification:""},reimbursement_duplicate_approval_update:{success:"Approval Rule updated successfully.",failed:"_api-error_",notification:""},reimbursement_approval_delete:{success:"Approval Rule deleted successfully.",failed:"Couldn't delete Approval Rule! Please try again.",notification:""},reimbursement_create_mileage:{success:"Mileage rate added successfully.",failed:"_api-error_.",notification:""},reimbursement_update_mileage:{success:"Mileage rate updated successfully.",failed:"_api-error_.",notification:""},reimbursement_accept_term:{success:"",failed:"_api-error_.",notification:""},reimbursement_accept_employee_term:{success:"",failed:"_api-error_.",notification:""},cockpit_month_end_email_sent:{success:"Zeni Insights sent successfully for _company-name_.",failed:"",notification:""},cockpit_month_end_email_save:{success:"Zeni Insights saved successfully for _company-name_.",failed:"",notification:""},cockpit_month_end_email_attachment_upload:{success:"",failed:"Sorry, the file you uploaded is too large. Maximum file size allowed is 700KB",notification:""},audit_score_updated:{success:"Audit Score updated",failed:"",notification:""},create_bank_account_ach:{success:"ACH account added successfully.",failed:"",notification:""},unlink_deposit_account:{success:"",failed:"_api-error_.",notification:""},create_bank_account_wire:{success:"_wire-type_ wire account added successfully.",failed:"",notification:""},create_bank_account_international:{success:"_wire-type_ wire account added successfully.",failed:"",notification:""},bill_pay_updated:{success:"Bill saved",failed:"_api-error_.",notification:""},bill_pay_deleted:{success:"Bill deleted",failed:"_api-error_.",notification:""},bill_pay_bulk_submit:{success:"_count_ _bill_ will be _action_. You'll be notified once it's done.",failed:"_api-error_.",notification:""},bill_pay_bulk_processed:{success:"_bill_ _has_ been _action_. The page will refresh now to reflect updates.",failed:"_api-error_.",notification:""},bill_pay_cancelled_deleted:{success:"Bill canceled and deleted",failed:"_api-error_.",notification:""},bill_pay_cancelled:{success:"Bill canceled",failed:"_api-error_.",notification:""},bill_pay_approved:{success:"Bill approved",failed:"_api-error_.",notification:""},bill_pay_rejected:{success:"Bill rejected",failed:"_api-error_.",notification:""},bill_pay_sent_for_approval:{success:"Bill sent for approval",failed:"_api-error_.",notification:""},bill_pay_accept_term:{success:"",failed:"_api-error_.",notification:""},bill_pay_refund:{success:"Refund process initiated",failed:"_api-error_.",notification:""},bill_pay_retry:{success:"Payment retried",failed:"_api-error_.",notification:""},bill_pay_marked_as_paid:{success:"Bill marked as paid",failed:"_api-error_.",notification:""},update_vendor:{success:"Vendor updated successfully.",failed:"_api-error_.",notification:""},data_refresh_update:{success:"Data refreshed",failed:"_api-error_.",notification:""},delete_bank_account:{success:"Bank account deleted successfully.",failed:"_api-error_.",notification:""},update_debit_card_pin_attempt:{success:"PIN changed successfully",failed:"_api-error_.",notification:""},set_debit_card_pin:{success:"PIN set successfully",failed:"_api-error_.",notification:""},create_bank_account:{success:"",failed:"_api-error_.",notification:""},send_email_magic_link_to_user:{success:"",failed:"_api-error_.",notification:""},complete_profile_done:{success:"Profile details saved.",failed:"_api-error_.",notification:""},zeni_account_accept_term:{success:"",failed:"_api-error_.",notification:""},transfer_money:{success:"",failed:"_api-error_.",notification:""},create_vendor:{success:"Vendor created successfully.",failed:"_api-error_.",notification:""},onboarding_customer_view:{success:"Onboarding Business Details fetched successfully.",failed:"Couldn't fetch Onboarding Business Details. Please try again.",notification:""},onboarding_customer_view_complete:{success:"Onboarding status updated successfully.",failed:"Couldn't update Onboarding status. Please try again.",notification:""},onboarding_customer_identity_verification_save:{success:"Onboarding Identity Details saved successfully.",failed:"Couldn't save Onboarding Identity Details. Please try again.",notification:""},onboarding_customer_identity_verification_submit:{success:"Onboarding Identity Details submitted successfully.",failed:"Couldn't submit Onboarding Identity Details. Please try again.",notification:""},onboarding_customer_business_verification_save:{success:"Onboarding Business Details saved successfully.",failed:"Couldn't save Onboarding Business Details. Please try again.",notification:""},onboarding_customer_business_verification_submit:{success:"Onboarding Business Details submitted successfully.",failed:"Couldn't submit Onboarding Business Details. Please try again.",notification:""},retry_bank_account_connection:{success:"Bank account connection completed successfully.",failed:"Bank account connection failed.",notification:""},dashboard_invite_sent:{success:"Dashboard invite sent to _user-name_ for _company-name_ successfully.",failed:"Dashboard invite failed",notification:""},onboarding_info_saved:{success:"Saved successfully",failed:"Save failed",notification:""},approve_original_merchant:{success:'Review request for "_merchant_name_" is approved successfully.',failed:"_api-error_.",notification:""},approve_global_merchant:{success:'Review request for "_original_merchant_name_" to "_approved_merchant_name_" is approved successfully.',failed:"_api-error_.",notification:""},reject_global_merchant:{success:'Vendor "_merchant_name_" review rejected',failed:"_api-error_.",notification:""},create_global_merchant:{success:'Vendor "_global_merchant_name_" successfully added to global list.',failed:"_api-error_.",notification:""},fetch_global_merchant_no_recommendation:{success:'There are no recommendations for the name "_global_merchant_name_".',failed:"_api-error_.",notification:""},save_vendor_sent_for_review:{success:'Vendor "_vendor_name_" sent for the review.',failed:"_api-error_.",notification:""},save_vendor_renamed:{success:'Vendor "_old_vendor_name_" renamed to "_updated_vendor_name_."',failed:"_api-error_.",notification:""},save_vendor_marked_as_employee:{success:"Marked as employee",failed:"_api-error_.",notification:""},save_vendor_marked_as_local_contractor:{success:"Marked as local contractor",failed:"_api-error_.",notification:""},charge_card_setup:{success:"",failed:"Failed to load Cards Setup Details! Please try again.",notification:""},charge_card_receipt_upload:{success:"Card receipt uploaded",failed:"_api-error_.",notification:""},charge_card_resend_invite:{success:"Card invite resent",failed:"_api-error_.",notification:""},charge_card_revoke_invite:{success:"Card invite revoked",failed:"_api-error_.",notification:""},charge_card_update_limit:{success:"Card limit updated to _amount_",failed:"Limit updation failed with _api-error_.",notification:""},charge_cards_update_limit:{success:"Limit updated for _number_of_cards_",failed:"Limit updation failed with _api-error_.",notification:""},update_charge_card_name:{success:'Card _masked_card_number_ renamed to "_new_card_name_"',failed:"Card name updation failed with _api-error_.",notification:""},update_charge_card_name_card_user:{success:'Card renamed to "_new_card_name_"',failed:"Card name updation failed with _api-error_.",notification:""},lock_charge_card:{success:"Card _masked_card_number_ locked",failed:"Card lock failed with _api-error_.",notification:""},lock_charge_card_card_user:{success:"Card locked",failed:"Card lock failed with _api-error_.",notification:""},unlock_charge_card:{success:"Card _masked_card_number_ unlocked",failed:"Card unlock failed with _api-error_.",notification:""},unlock_charge_card_card_user:{success:"Card unlocked",failed:"Card unlock failed with _api-error_.",notification:""},close_charge_card:{success:"Card _masked_card_number_ closed",failed:"Card close failed with _api-error_.",notification:""},unlock_charge_cards:{success:"_number_of_cards_ unlocked",failed:"Cards unlock failed with _api-error_.",notification:""},lock_charge_cards:{success:"_number_of_cards_ locked",failed:"Cards lock failed with _api-error_.",notification:""},close_charge_cards:{success:"_number_of_cards_ closed",failed:"Cards close failed with _api-error_.",notification:""},revoke_invite_charge_cards:{success:"Invite revoked for _number_of_cards_",failed:"Invite revoke failed with _api-error_.",notification:""},create_schedule:{success:'Schedule created for "_vendor_name_"',failed:"Schedule creation failed with _api-error_.",notification:""},save_schedule:{success:'Schedule saved for "_vendor_name_"',failed:"Save schedule failed with _api-error_.",notification:""},je_posted:{success:"JE Posted",failed:"JE Posting failed with _api-error_.",notification:""},ignore_schedule:{success:"Schedule Ignored",failed:"Schedule Ignore failed with _api-error_.",notification:""},delete_schedule:{success:'Schedule deleted for "_vendor_name_"',failed:"Delete schedule failed with _api-error_.",notification:""},mark_as_complete_schedule:{success:'Schedule marked as completed for "_vendor_name_"',failed:"Mark as complete schedule failed with _api-error_.",notification:""},cancel_journal_entry:{success:"Accrual Canceled",failed:"Accrual Cancel failed with _api-error_.",notification:""},charge_card_accept_term:{success:"",failed:"_api-error_.",notification:""},charge_card_express_interest:{success:"Interest expressed successfully",failed:"_api-error_.",notification:""},save_task_detail:{success:"",failed:"_api-error_.",notification:""},fetch_task_detail:{success:"Task details fetched successfully.",failed:"_api-error_.",notification:""},delete_task:{success:"",failed:"_api-error_.",notification:""},archive_task:{success:"",failed:"_api-error_.",notification:""},update_charge_card:{success:"",failed:"_api-error_.",notification:""},notification_settings_saved:{success:"Notification Settings Saved",failed:"_api-error_.",notification:""},referral_invite_sent:{success:"Referral Invite Sent",failed:"_api-error_.",notification:""},notification_mark_as_read:{success:"Notifications marked as read successfully.",failed:"Something went wrong! Please try again.",notification:""},settings_accounting_accounts_updated:{success:"Accounts saved",failed:"",notification:""},task_group_creation_success:{success:"Task group created successfully",failed:"Task group creation failed",notification:""},task_group_deletion_success:{success:"Task group deleted successfully",failed:"Task group deletion failed",notification:""},task_group_update_success:{success:"Task group updated successfully",failed:"Task group update failed",notification:""},primary_funding_account_updated:{success:"Bank account updated for _productType_.",failed:"",notification:""},task_time_spent_validation:{success:"",failed:"Time can't exceed 99h 59m",notification:""},missing_receipts_attachment:{success:"",failed:"Failed to upload attachment__message__ please try again!",notification:""},flux_analysis_reviewed:{success:"_vendors_count_ _vendor_ reviewed",failed:"_api-error_.",notification:""},flux_analysis_unreviewed:{success:"_vendors_count_ _vendor_ unreviewed",failed:"_api-error_.",notification:""},express_pay_submit:{success:"Payment scheduled",failed:"_api-error_.",notification:""},recon_transaction_categorize:{success:"Transaction reviewed",failed:"_api-error_.",notification:""},recon_transaction_match:{success:"Transaction matched",failed:"_api-error_.",notification:""},ai_cfo_create_session_and_submit:{success:"",failed:"Something went wrong, please try again!",notification:""},treasury_setup:{success:"",failed:"Failed to load Treasury Setup Details! Please try again.",notification:""},treasury_accept_term:{success:"Treasury Terms accepted successfully.",failed:"Failed to accept terms. Please try again.",notification:""},treasury_transfer_money:{success:"Transfer initiated.",failed:"Transfer failed. Please try again.",notification:""},treasury_transfer_money_failed:{success:"",failed:"Transfer failed. Please try again.",notification:""},treasury_update_portfolio_allocation:{success:"Portfolio allocation updated.",failed:"Portfolio allocation update failed. Please try again!",notification:""},reports_resync:{success:"",failed:"Something went wrong. Please try again.",notification:"No new data available."},invalid_phone_number:{success:"",failed:"Invalid phone number",notification:""}},currency:{currencyCode:"USD",currencySymbol:"$",currency:"United States Dollar",countryCode:"US"},format:{ssnFormat:"###-##-####",tinFormat:"##-#######"},status:{pending:"Pending"},cancel:"Cancel",confirm:"Confirm",continue:"Continue",proceed:"Proceed",next:"Next",noText:"--",privacy:"Zeni Privacy Policy",terms:"Terms and Conditions",privacyPolicyUrl:"https://www.zeni.ai/legal/privacy-policy",termsUrl:"https://www.zeni.ai/legal/terms-of-service",footer:{save:"Save",submit:"Submit",cancel:"Cancel",approve:"Approve",reject:"Reject",send:"Send",resubmit:"Resubmit",add:"Add",continueAnyway:"Continue Anyway",resolve:"Resolve",inReview:"In Review",sentForReview:"Sent for Review",linkCard:"Link Card",next:"Next",back:"Back",markAsUnReviewed:"Mark as Unreviewed",markAsReviewed:"Mark as Reviewed",saveForLater:"Save for Later",reconcile:"Reconcile",edit:"Edit",noThanks:"No, Thanks",letsGetStarted:"Let's Get Started"},completeText:"Complete",incompleteText:"Incomplete",notInitiatedText:"Not Initiated",pendingReviewText:"Pending Review",pendingVerificationText:"Pending Verification",retry:"Retry",verified:"Verified",validation:{emailAddressRequired:"Email address required",invalidEmailAddress:"Invalid email address",invalidUrlAddress:"Invalid URL"},needHelp:{text:"Need Help",hoverPrefix:"Experiencing issues?",hoverSuffix:" Schedule a call"},confirmationPopup:{discardTitle:"Discard unsaved changes?",discardDescription:"Changes are not automatically saved. Your changes will be lost if you continue.",discard:"Discard",cancel:"Cancel"},via:"via",cockpit:"cockpit",analytics:"Analytics",filters:{noOptions:"No Options",noMatchesFound:"No Matches Found",userProfileAltText:"Failed to load",startDate:"Start Date",endDate:"End Date"},updated:"Updated",hoursAgo:"hours ago",minutesAgo:"a few minutes ago",noMatches:"Nothing matched your search. Please try again!",noReport:"No _item-name_ to display yet!",reloadPage:{label:"Something went wrong, please try again!"},settings:{title:{accounting:"Accounting Setup",approvalRules:"Approval Rules",bankConnections:"Bank Connections",integrations:"Integrations",myProfile:"My Profile",myBankConnections:"My Bank Connections",notifications:"Notifications"},common:{update:"Update",cancel:"Cancel",productTypeString:"My Profile"},subtitle:{myProfile:"Profile Details",myBankConnections:"Reimbursements"},label:{primary:"Primary",billPay:"Bill Pay",reimbursements:"Reimbursements",bankAccount:"Bank Account",noManager:"No Manager",myProfile:"My Profile"},infoText:{accounting:"Quick access to manage the company's accounting-related settings",approvalRules:"Quick access to manage the multi-level approval rules for bills & reimbursements to make Zeni work better for you",bankConnections:"Manage primary bank account connections for Zeni Bill Payments, Reimbursements, Business Checking, and Business Cards.",businessVerification:"Financial regulations require Zeni to collect both identity & company details to verify your business",companyDetails:"Quick access to manage the company's detailed information",integrations:"Quick access to manage the company's third-party connected services",myProfile:"Quick access to manage your personal details",myBankConnections:"Manage your linked personal bank details used to receive reimbursements"},bankConnectionHeader:{productType:"Products",primaryAccount:"Primary Account",linkAccount:"QBO Linked Account",status:"Status",balance:"Balance"},bankConnectionListHeader:{primary:"Primary",other:"Other Connections",otherToolTip:"These bank connections aren't linked to any product. Select from the dropdown above to connect."},productNameByType:{bill_pay:"Bill Pay",reimbursement:"Reimbursements",zeni_accounts:"Checking",zeni_treasury:"Treasury",charge_cards:"Cards"},otherAccount:{title:"Product",subTitle:"Not assigned",subTitleSmall:"not assigned",remove:"Remove Connection"},notifications:{sectionTitle:{reminders:"Reminders",monthEndInsights:"Month-end Insights"},frequency:{biWeekly:"Bi-Weekly"},mode:{email:"Email",dashboard:"Dashboard"},reminders:{missingReceiptNotification:"Missing Receipts:",uncategorizedTransactionNotification:"Uncategorized Transactions:",pendingBillApprovalNotification:"Bill Approvals:",pendingReimbursementApprovalNotification:"Reimbursement Approvals:"},monthEndInsights:{labels:{notifyMe:"Notify Me:",notifyOthers:"Notify Others:"},userFieldPlaceholder:"Who should receive this email?",stopReceivingEmailsText:"To stop receiving this email, reach out to",stopReceivingMonthEndInsightsSubject:"Stop Month End Insights"},reminderFrequencyOptions:[{label:"Daily",value:"daily"},{label:"Weekly",value:"weekly"},{label:"Bi-weekly",value:"bi-weekly"},{label:"Monthly",value:"monthly"}]}},copyToClipBoard:{copy:"Copy",copied:"Copied"},monthsByIndex:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},download:{errorMessages:{unsupportedFileType:"Unsupported Filetype",fileDownloadError:"Download __feature__ Failed with"},defaultFileName:"Report.xlsx"},balanceCard:{cashBalanceSectionTitle:"Total Cash Balance",cardBalanceSectionTitle:"Total Card Balance",comparedTo:"compared to",noBalanceText:"No balance data to display yet!"},insightsCard:{vs:"vs",title:"Insights",no_data:{label:"Cash, Opex, Revenue, COS, and Cash In Cash Out Insights, will appear once you have sufficient financial activity. Stay tuned! 💸"}},timeframe:{day:"Days",month:"Months",quarter:"Quarters",year:"Years",week:"Weeks",free_range:"Time period",this_week_to_date:"This Week",last_week:"Last Week",this_month_to_date:"This Month",last_month:"Last Month",last_3_months:"Last 3 Months",last_6_months:"Last 6 Months",last_12_months:"Last 12 Months",this_year_to_date:"This Year",last_year:"Last Year"},quarterPrefix:"Q",compareSwitchLabel:"Compare",compareMode:{off:"Off",compare_mode_percent:"Percentage",compare_mode_amount:"Amount",changePercent:"Change %",changePrefix:"Change"},chartCard:{total:"Total",activity:"Activity",no_data_available:"No data available!",no_data_available_for:"No data available for",tooltip:{actual:"Actual",forecast:"Forecast",change:"Change",change_percent:"Change %"},forecast_dropdown:{forecast_source:"Via Quickbooks",forecast_invalid_issue:"This period is not in the time frame of the actuals. Please view it via the Forecast tab."},netBurnOrIncome:{grossBurn:"Gross Burn",netBurnOrIncome:"Net Income / Burn",gross_burn:"Gross Burn",cogs:"COS",net_burn_or_income:"Net Income / Burn",income:"Revenue",expenses:"OPEX",net_burn:"Net Burn",net_income:"Net Income",no_data_available:"A minimum of one-month data is required!",cogs_forecast:"Forecast",net_burn_or_income_forecast:"Forecast",income_forecast:"Forecast",expenses_forecast:"Forecast"},netBurnOrIncomeCalculator:{title:"Burn Rate Calculator",accounting_method:{label:"Configure Burn Rate, Runway, and Cash Zero date based on below options:",cash:"Cash Flow from Operating Activities",ebitda:"EBITDA",net_income:"Net Income"},time_span_id_for_average:{label:"Further configure Burn Rate, Runway, and Cash Zero date based on below options:",last_month:"Last month",last_completed_month:"Last completed month",average_of_last_2_months:"Average of last 2 completed months",average_of_last_3_months:"Average of last 3 completed months",under_review_last_month_label:"(Including Under Review)"}},revenue:{income:"Revenue",cogs:"COS",gross_margin:"Gross Margin",grossMargin:"Gross Margin",income_forecast:"Forecast",cogs_forecast:"Forecast",gross_margin_forecast:"Forecast",grossMargin_forecast:"Forecast"},cashInCashOut:{cash_in:"Cash In",cash_out:"Cash Out",net_cash_flow:"Net Cash Flow"},no_data:{revenue:"No revenues to display yet, but thrift is a great revenue. Fight On!🤘",cash_in_cash_out:"No cash in cash out to display yet!",cash_position:"No cash position to display yet!",net_burn_or_income:"No net burn to display yet!",operating_expenses:"No operating expenses to display yet!",top_expenses:{this_week_to_date:"No expenses this week 🤷",last_week:"No expenses last week 🤷",this_month_to_date:"No expenses this month 🤷",last_month:"No expenses last month 🤷",last_3_months:"No expenses last 3 months 🤷",last_6_months:"No expenses last 6 months 🤷",last_12_months:"No expenses last 12 months 🤷",this_year_to_date:"No expenses this year 🤷",last_year:"No expenses last year 🤷"},aging_report:"No data to display yet!"}},drawerMenus:{dashboard:"Dashboard",cockpit:"Cockpit",reports:"Reports",people:"People",forecast:"Forecast",cards:"Cards",bills:"Bills",ai_automation:"AI Bookkeeping",storybooks:"Storybooks",settings:"Settings",logout:"Logout",reimbursements:"Reimbursements",checking:"Checking",vendors:"Vendors",rewards:"Rewards",accounting:"Accounting",approval_rules:"Approval Rules",billing:"Billing",bank_connections:"Bank Connections",business_verification:"Business Verification",company_details:"Company Details",integrations:"Integrations",my_profile:"My Profile",my_bank_connections:"My Bank Connections",notifications:"Notifications",performance:"Performance",ai_accountant:"AI Accountant",ai_cfo:"AI CFO",new_chat:"New Chat",explore:"Explore",treasury:"Treasury"},drawerMenuSubtitles:{rewards:"Earn __reward-amount__ per referral"},drawerGroups:{finance:"Finance",cash:"Cash",spend_management:"Spend Management",banking:"Banking",company:"Company",company_settings:"Company Settings",personal_settings:"Personal Settings",ai_bookkeeping:"AI Bookkeeping",ai_cfo:"",ai_agents:"AI Agents",ai_accountant:"AI Accountant"},drawerTags:{new:"NEW"},dashboardDropDownList:{menuOption:{logout:{label:"Logout",value:"logout"},settings:{label:"Settings",value:"settings"},cockpit:{label:"Cockpit",value:"cockpit"}}},transactionItem:{date:"Date",account:"Account"},transactionType:{invoice:"Invoice",creditMemo:"Credit Memo",salesReceipt:"Sales Receipt",refund:"Refund",expense:"Expense",check:"Check",bill:"Bill",billPayment:"Bill Payment",transfer:"Transfer",vendorCredit:"Vendor Credit",creditCardCredit:"Credit Card Credit",deposit:"Deposit",creditCardPayment:"Credit Card Payment",journalEntry:"Journal Entry",payment:"Payment"},signIn:{heading:"Welcome to Zeni",confirmationLinkSent:"Confirmation link sent",message:"Your financial dashboard is just one step away. Get started.",signInSecurelyMessage:"Choose an account to sign in securely",signInGoogleButton:"Sign In With Google",signInMicrosoftButton:"Sign In With Microsoft",termsPrivacyFinePrintPart:"By creating an account on Zeni, you confirm that you ",agreeWith:"agree with our ",termsOfService:"terms of service",and:"and",privacyPolicy:"privacy policy",termsUrl:"https://www.zeni.ai/terms",privacyPolicyUrl:"https://www.zeni.ai/privacy-policy",signInError:`Couldn’t sign-in to your account.
330
330
  Please try again.`,signInAuthError:`Authorization failed, and sign-in is restricted.
331
331
  Please try and authorize again.`,emailNotFoundPopup:{title:"We couldn't find the email ID",confirmEmail:"Please ensure that you are logging in with the same email ID that you shared with Zeni.",checkAccess:"Make sure you have access to your company's Zeni dashboard. If not, reach out to your Zeni admin.",contactZeni:"Please contact Zeni's sales executive if you are in the process of onboarding with Zeni."},magicLinkSent:{primaryMessage:"A secure sign in link has been sent to __email__ to access the dashboard.",secondaryMessage:"If you can't see the email, check your spam/junk folder.",resendLinkCountdown:"Resend Link in __seconds__s",resendLink:"Resend Link"},workEmailExample:"name@workemail.com",signInButton:"Sign In",invalidEmailMessage:"Invalid email address",magicLinkExpired:"Your sign-in link has expired. Please try again.",magicLinkExpiredHeading:"This sign-in link has expired",requestNewLink:"Request a new link",workEmailLink:"Sign in using email",workEmailSubText:"For users without Google/Microsoft access.",googleOrMicrosoftLink:"Sign in using Google or Microsoft",continueAs:"Continue as"},billPayPromoCard:{title:"Bill Pay",aipoweredInvoice:{prefix:"AI-powered invoice processing helps create bills in seconds."},multiLevelApproval:{prefix:"Multi-level approval flows allows you to stay in control of payments."},financeTeam:{prefix:"Fully managed by your expert Zeni Finance Team."},fastestWay:{prefix:"Fastest way to pay your vendors and contractors, 100% free"},btn:"Learn More",signUp:"Sign Up for FREE"},reimbursementPromoCard:{title:"Reimbursements",aiPowered:{prefix:"AI powered receipts processing helps you create reports in seconds."},multiLevel:{prefix:"Multi-level approval flows allow you to stay in control of payments."},reimburse:{prefix:"Reimburse employees at lightning speed, absolutely free"},signUp:"Sign Up for FREE",btn:"Learn More"},treasuryPromoCard:{title:"Treasury",introducing:"Introducing",btn:"Get Started",watchVideo:{prefix:"Watch how Zeni Treasury helps you earn more."},highYield:{title:"Earn yields upto",prefix:`Put your idle cash to work and earn
332
332
  more than a standard checking account.`},sipcInsured:{title:"SIPC coverage upto",amount:"$500K",prefix:`SIPC protection ensures your assets
@@ -416,7 +416,7 @@ _failed_count_ Transaction failed.`},transactionsUpdated_transactionsFailed:{suc
416
416
  _updated_count_ Transaction updated.
417
417
  _failed_count_ Transactions failed.`},transactionCategorized_transactionUpdated_transactionFailed:{success:"",failed:"",notification:`_categorized_count_ Transaction categorized.
418
418
  _updated_count_ Transaction updated.
419
- _failed_count_ Transaction failed.`},people_invite_people:{success:"Invitation sent",failed:"",notification:""},people_invite_multiple_people:{success:"Users invited",failed:"",notification:""},people_update_person:{success:"User info changed",failed:"",notification:""},people_delete_person:{success:"User deleted",failed:"",notification:""},reimbursement_updated:{success:"Reimbursement saved",failed:"_api-error_.",notification:""},reimbursement_approved:{success:"Reimbursement approved",failed:"_api-error_.",notification:""},reimbursement_rejected:{success:"Reimbursement rejected",failed:"_api-error_.",notification:""},reimbursement_sent_for_approval:{success:"Reimbursement sent for approval",failed:"_api-error_.",notification:""},reimbursement_deleted:{success:"Reimbursement deleted",failed:"_api-error_.",notification:""},reimbursement_cancelled:{success:"Reimbursement canceled",failed:"_api-error_.",notification:""},reimbursement_cancelled_deleted:{success:"Reimbursement canceled and deleted",failed:"_api-error_.",notification:""},reimbursement_bulk_submit:{success:"_count_ _report_ will be _action_. You'll be notified once it's done.",failed:"_api-error_.",notification:""},reimbursement_bulk_processed:{success:"_report_ _has_ been _action_. The page will refresh now to reflect updates.",failed:"_api-error_.",notification:""},save_reconcile_for_later:{success:"Reconciliation saved",failed:"Reconciliation not saved. Please try again!",notification:""},reconcile:{success:"_reconcile_account_ reconciliation in progress.",failed:"Reconciliation failed for _reconcile_account_",notification:""},exclude_transaction:{success:"Transaction excluded",failed:"Transaction exclusion failed",notification:""},account_added:{success:"Account added successfully",failed:"",notification:""},issue_charge_card:{success:"New _card_ issued for _user-name_",failed:"",notification:""},issue_charge_cards:{success:"New cards issued",failed:"",notification:""},charge_card_auto_pay_enable:{success:"Early payment enabled",failed:"",notification:""},charge_card_auto_pay_disable:{success:"Early payment disabled",failed:"",notification:""},business_verification_save:{success:"Business Verification Details saved successfully.",failed:"Couldn't save Business Verification Details. Please try again.",notification:""},business_verification_submit:{success:"Business Verification Details submitted successfully.",failed:"Couldn't submit Business Verification Details. Please try again.",notification:""},business_verification_from_bills_submit:{success:"Verified successfully.",failed:"Couldn't submit Business Verification Details. Please try again.",notification:""},plaid_connection:{success:"",failed:"Something went wrong! Please try again.",notification:""},bill_pay_setup:{success:"",failed:"Failed to load Bill Pay Setup Details! Please try again.",notification:""},zeni_accounts_setup:{success:"",failed:"Failed to load Zeni Accounts Setup Details! Please try again.",notification:""},bill_pay_approval_create:{success:"Approval Rule created successfully.",failed:"Couldn't create Approval Rule! Please try again.",notification:""},bill_pay_duplicate_approval_create:{success:"Approval Rule created successfully.",failed:"_api-error_",notification:""},bill_pay_approval_update:{success:"Approval Rule updated successfully.",failed:"Couldn't update Approval Rule! Please try again.",notification:""},update_zeni_account_nickname:{success:"Zeni Account nickname updated successfully",failed:"_api-error_.",notification:""},create_checking_account:{success:"New Business Account Added",failed:"_api-error_.",notification:""},deposit_check:{success:"Check Deposit Successful",failed:"_api-error_.",notification:""},bill_pay_duplicate_approval_update:{success:"Approval Rule updated successfully.",failed:"_api-error_",notification:""},bill_pay_approval_delete:{success:"Approval Rule deleted successfully.",failed:"Couldn't delete Approval Rule! Please try again.",notification:""},reimbursement_setup:{success:"",failed:"Failed to load Reimbursements Setup Details! Please try again.",notification:""},reimbursement_approval_create:{success:"Approval Rule created successfully.",failed:"Couldn't create Approval Rule! Please try again.",notification:""},reimbursement_duplicate_approval_create:{success:"Approval Rule created successfully.",failed:"_api-error_",notification:""},reimbursement_approval_update:{success:"Approval Rule updated successfully.",failed:"Couldn't update Approval Rule! Please try again.",notification:""},reimbursement_duplicate_approval_update:{success:"Approval Rule updated successfully.",failed:"_api-error_",notification:""},reimbursement_approval_delete:{success:"Approval Rule deleted successfully.",failed:"Couldn't delete Approval Rule! Please try again.",notification:""},reimbursement_create_mileage:{success:"Mileage rate added successfully.",failed:"_api-error_.",notification:""},reimbursement_update_mileage:{success:"Mileage rate updated successfully.",failed:"_api-error_.",notification:""},reimbursement_accept_term:{success:"",failed:"_api-error_.",notification:""},reimbursement_accept_employee_term:{success:"",failed:"_api-error_.",notification:""},cockpit_month_end_email_sent:{success:"Zeni Insights sent successfully for _company-name_.",failed:"",notification:""},cockpit_month_end_email_save:{success:"Zeni Insights saved successfully for _company-name_.",failed:"",notification:""},cockpit_month_end_email_attachment_upload:{success:"",failed:"Sorry, the file you uploaded is too large. Maximum file size allowed is 700KB",notification:""},audit_score_updated:{success:"Audit Score updated",failed:"",notification:""},create_bank_account_ach:{success:"ACH account added successfully.",failed:"",notification:""},unlink_deposit_account:{success:"",failed:"_api-error_.",notification:""},create_bank_account_wire:{success:"_wire-type_ wire account added successfully.",failed:"",notification:""},create_bank_account_international:{success:"_wire-type_ wire account added successfully.",failed:"",notification:""},bill_pay_updated:{success:"Bill saved",failed:"_api-error_.",notification:""},bill_pay_deleted:{success:"Bill deleted",failed:"_api-error_.",notification:""},bill_pay_bulk_submit:{success:"_count_ _bill_ will be _action_. You'll be notified once it's done.",failed:"_api-error_.",notification:""},bill_pay_bulk_processed:{success:"_bill_ _has_ been _action_. The page will refresh now to reflect updates.",failed:"_api-error_.",notification:""},bill_pay_cancelled_deleted:{success:"Bill canceled and deleted",failed:"_api-error_.",notification:""},bill_pay_cancelled:{success:"Bill canceled",failed:"_api-error_.",notification:""},bill_pay_approved:{success:"Bill approved",failed:"_api-error_.",notification:""},bill_pay_rejected:{success:"Bill rejected",failed:"_api-error_.",notification:""},bill_pay_sent_for_approval:{success:"Bill sent for approval",failed:"_api-error_.",notification:""},bill_pay_accept_term:{success:"",failed:"_api-error_.",notification:""},bill_pay_refund:{success:"Refund process initiated",failed:"_api-error_.",notification:""},bill_pay_retry:{success:"Payment retried",failed:"_api-error_.",notification:""},bill_pay_marked_as_paid:{success:"Bill marked as paid",failed:"_api-error_.",notification:""},update_vendor:{success:"Vendor updated successfully.",failed:"_api-error_.",notification:""},data_refresh_update:{success:"Data refreshed",failed:"_api-error_.",notification:""},delete_bank_account:{success:"Bank account deleted successfully.",failed:"_api-error_.",notification:""},update_debit_card_pin_attempt:{success:"PIN changed successfully",failed:"_api-error_.",notification:""},set_debit_card_pin:{success:"PIN set successfully",failed:"_api-error_.",notification:""},create_bank_account:{success:"",failed:"_api-error_.",notification:""},send_email_magic_link_to_user:{success:"",failed:"_api-error_.",notification:""},complete_profile_done:{success:"Profile details saved.",failed:"_api-error_.",notification:""},zeni_account_accept_term:{success:"",failed:"_api-error_.",notification:""},transfer_money:{success:"",failed:"_api-error_.",notification:""},create_vendor:{success:"Vendor created successfully.",failed:"_api-error_.",notification:""},onboarding_customer_view:{success:"Onboarding Business Details fetched successfully.",failed:"Couldn't fetch Onboarding Business Details. Please try again.",notification:""},onboarding_customer_view_complete:{success:"Onboarding status updated successfully.",failed:"Couldn't update Onboarding status. Please try again.",notification:""},onboarding_customer_identity_verification_save:{success:"Onboarding Identity Details saved successfully.",failed:"Couldn't save Onboarding Identity Details. Please try again.",notification:""},onboarding_customer_identity_verification_submit:{success:"Onboarding Identity Details submitted successfully.",failed:"Couldn't submit Onboarding Identity Details. Please try again.",notification:""},onboarding_customer_business_verification_save:{success:"Onboarding Business Details saved successfully.",failed:"Couldn't save Onboarding Business Details. Please try again.",notification:""},onboarding_customer_business_verification_submit:{success:"Onboarding Business Details submitted successfully.",failed:"Couldn't submit Onboarding Business Details. Please try again.",notification:""},retry_bank_account_connection:{success:"Bank account connection completed successfully.",failed:"Bank account connection failed.",notification:""},dashboard_invite_sent:{success:"Dashboard invite sent to _user-name_ for _company-name_ successfully.",failed:"Dashboard invite failed",notification:""},onboarding_info_saved:{success:"Saved successfully",failed:"Save failed",notification:""},approve_original_merchant:{success:'Review request for "_merchant_name_" is approved successfully.',failed:"_api-error_.",notification:""},approve_global_merchant:{success:'Review request for "_original_merchant_name_" to "_approved_merchant_name_" is approved successfully.',failed:"_api-error_.",notification:""},reject_global_merchant:{success:'Vendor "_merchant_name_" review rejected',failed:"_api-error_.",notification:""},create_global_merchant:{success:'Vendor "_global_merchant_name_" successfully added to global list.',failed:"_api-error_.",notification:""},fetch_global_merchant_no_recommendation:{success:'There are no recommendations for the name "_global_merchant_name_".',failed:"_api-error_.",notification:""},save_vendor_sent_for_review:{success:'Vendor "_vendor_name_" sent for the review.',failed:"_api-error_.",notification:""},save_vendor_renamed:{success:'Vendor "_old_vendor_name_" renamed to "_updated_vendor_name_."',failed:"_api-error_.",notification:""},save_vendor_marked_as_employee:{success:"Marked as employee",failed:"_api-error_.",notification:""},save_vendor_marked_as_local_contractor:{success:"Marked as local contractor",failed:"_api-error_.",notification:""},charge_card_setup:{success:"",failed:"Failed to load Cards Setup Details! Please try again.",notification:""},charge_card_receipt_upload:{success:"Card receipt uploaded",failed:"_api-error_.",notification:""},charge_card_resend_invite:{success:"Card invite resent",failed:"_api-error_.",notification:""},charge_card_revoke_invite:{success:"Card invite revoked",failed:"_api-error_.",notification:""},charge_card_update_limit:{success:"Card limit updated to _amount_",failed:"Limit updation failed with _api-error_.",notification:""},charge_cards_update_limit:{success:"Limit updated for _number_of_cards_",failed:"Limit updation failed with _api-error_.",notification:""},update_charge_card_name:{success:'Card _masked_card_number_ renamed to "_new_card_name_"',failed:"Card name updation failed with _api-error_.",notification:""},update_charge_card_name_card_user:{success:'Card renamed to "_new_card_name_"',failed:"Card name updation failed with _api-error_.",notification:""},lock_charge_card:{success:"Card _masked_card_number_ locked",failed:"Card lock failed with _api-error_.",notification:""},lock_charge_card_card_user:{success:"Card locked",failed:"Card lock failed with _api-error_.",notification:""},unlock_charge_card:{success:"Card _masked_card_number_ unlocked",failed:"Card unlock failed with _api-error_.",notification:""},unlock_charge_card_card_user:{success:"Card unlocked",failed:"Card unlock failed with _api-error_.",notification:""},close_charge_card:{success:"Card _masked_card_number_ closed",failed:"Card close failed with _api-error_.",notification:""},unlock_charge_cards:{success:"_number_of_cards_ unlocked",failed:"Cards unlock failed with _api-error_.",notification:""},lock_charge_cards:{success:"_number_of_cards_ locked",failed:"Cards lock failed with _api-error_.",notification:""},close_charge_cards:{success:"_number_of_cards_ closed",failed:"Cards close failed with _api-error_.",notification:""},revoke_invite_charge_cards:{success:"Invite revoked for _number_of_cards_",failed:"Invite revoke failed with _api-error_.",notification:""},create_schedule:{success:'Schedule created for "_vendor_name_"',failed:"Schedule creation failed with _api-error_.",notification:""},save_schedule:{success:'Schedule saved for "_vendor_name_"',failed:"Save schedule failed with _api-error_.",notification:""},je_posted:{success:"JE Posted",failed:"JE Posting failed with _api-error_.",notification:""},ignore_schedule:{success:"Schedule ignored",failed:"Schedule ignore failed with _api-error_.",notification:""},delete_schedule:{success:'Schedule deleted for "_vendor_name_"',failed:"Delete schedule failed with _api-error_.",notification:""},mark_as_complete_schedule:{success:'Schedule marked as completed for "_vendor_name_"',failed:"Mark as complete schedule failed with _api-error_.",notification:""},cancel_journal_entry:{success:"Accrual Canceled",failed:"Accrual Cancel failed with _api-error_.",notification:""},charge_card_accept_term:{success:"",failed:"_api-error_.",notification:""},charge_card_express_interest:{success:"Interest expressed successfully",failed:"_api-error_.",notification:""},save_task_detail:{success:"",failed:"_api-error_.",notification:""},fetch_task_detail:{success:"Task details fetched successfully.",failed:"_api-error_.",notification:""},delete_task:{success:"",failed:"_api-error_.",notification:""},archive_task:{success:"",failed:"_api-error_.",notification:""},update_charge_card:{success:"",failed:"_api-error_.",notification:""},notification_settings_saved:{success:"Notification Settings Saved",failed:"_api-error_.",notification:""},referral_invite_sent:{success:"Referral Invite Sent",failed:"_api-error_.",notification:""},notification_mark_as_read:{success:"Notifications marked as read successfully.",failed:"Something went wrong! Please try again.",notification:""},settings_accounting_accounts_updated:{success:"Accounts saved",failed:"",notification:""},task_group_creation_success:{success:"Task group created successfully",failed:"Task group creation failed",notification:""},task_group_deletion_success:{success:"Task group deleted successfully",failed:"Task group deletion failed",notification:""},task_group_update_success:{success:"Task group updated successfully",failed:"Task group update failed",notification:""},primary_funding_account_updated:{success:"Bank account updated for _productType_.",failed:"",notification:""},task_time_spent_validation:{success:"",failed:"Time can't exceed 99h 59m",notification:""},missing_receipts_attachment:{success:"",failed:"Failed to upload attachment__message__ please try again!",notification:""},flux_analysis_reviewed:{success:"_vendors_count_ _vendor_ reviewed",failed:"_api-error_.",notification:""},flux_analysis_unreviewed:{success:"_vendors_count_ _vendor_ unreviewed",failed:"_api-error_.",notification:""},express_pay_submit:{success:"Payment scheduled",failed:"_api-error_.",notification:""},recon_transaction_categorize:{success:"Transaction categorized",failed:"_api-error_.",notification:""},recon_transaction_match:{success:"Transaction matched",failed:"_api-error_.",notification:""},ai_cfo_create_session_and_submit:{success:"",failed:"Something went wrong, please try again!",notification:""},treasury_setup:{success:"",failed:"Failed to load Treasury Setup Details! Please try again.",notification:""},treasury_accept_term:{success:"Treasury Terms accepted successfully.",failed:"Failed to accept terms. Please try again.",notification:""},treasury_transfer_money:{success:"Transfer initiated.",failed:"Transfer failed. Please try again.",notification:""},treasury_transfer_money_failed:{success:"",failed:"Transfer failed. Please try again.",notification:""},treasury_update_portfolio_allocation:{success:"Portfolio allocation updated.",failed:"Portfolio allocation update failed. Please try again!",notification:""},reports_resync:{success:"",failed:"Something went wrong. Please try again.",notification:"No new data available."},invalid_phone_number:{success:"",failed:"Invalid phone number",notification:""}},currency:{currencyCode:"INR",currencySymbol:"₹",currency:"Indian Rupee",countryCode:"IN"},format:{ssnFormat:"###-##-####",tinFormat:"##-#######"},status:{pending:"Pending"},cancel:"Cancel",confirm:"Confirm",continue:"Continue",proceed:"Proceed",next:"Next",noText:"--",privacy:"Zeni Privacy Policy",terms:"Terms and Conditions",privacyPolicyUrl:"https://www.zeni.ai/legal/privacy-policy",termsUrl:"https://www.zeni.ai/legal/terms-of-service",footer:{save:"Save",submit:"Submit",cancel:"Cancel",approve:"Approve",reject:"Reject",send:"Send",resubmit:"Resubmit",add:"Add",continueAnyway:"Continue Anyway",resolve:"Resolve",inReview:"In Review",sentForReview:"Sent for Review",linkCard:"Link Card",next:"Next",back:"Back",markAsUnReviewed:"Mark as Unreviewed",markAsReviewed:"Mark as Reviewed",saveForLater:"Save for Later",reconcile:"Reconcile",edit:"Edit",noThanks:"No, Thanks",letsGetStarted:"Let's Get Started"},completeText:"Complete",incompleteText:"Incomplete",notInitiatedText:"Not Initiated",pendingReviewText:"Pending Review",pendingVerificationText:"Pending Verification",retry:"Retry",verified:"Verified",validation:{emailAddressRequired:"Email address required",invalidEmailAddress:"Invalid email address",invalidUrlAddress:"Invalid URL"},needHelp:{text:"Need Help",hoverPrefix:"Experiencing issues?",hoverSuffix:" Schedule a call"},confirmationPopup:{discardTitle:"Discard unsaved changes?",discardDescription:"Changes are not automatically saved. Your changes will be lost if you continue.",discard:"Discard",cancel:"Cancel"},via:"via",cockpit:"cockpit",analytics:"Analytics",filters:{noOptions:"No Options",noMatchesFound:"No Matches Found",userProfileAltText:"Failed to load",startDate:"Start Date",endDate:"End Date"},updated:"Updated",hoursAgo:"hours ago",minutesAgo:"a few minutes ago",noMatches:"Nothing matched your search. Please try again!",noReport:"No _item-name_ to display yet!",reloadPage:{label:"Something went wrong, please try again!"},settings:{title:{accounting:"Accounting Setup",approvalRules:"Approval Rules",bankConnections:"Bank Connections",integrations:"Integrations",myProfile:"My Profile",myBankConnections:"My Bank Connections",notifications:"Notifications"},common:{update:"Update",cancel:"Cancel",productTypeString:"My Profile"},subtitle:{myProfile:"Profile Details",myBankConnections:"Reimbursements"},label:{primary:"Primary",billPay:"Bill Pay",reimbursements:"Reimbursements",bankAccount:"Bank Account",noManager:"No Manager",myProfile:"My Profile"},infoText:{accounting:"Quick access to manage the company's accounting-related settings",approvalRules:"Quick access to manage the multi-level approval rules for bills & reimbursements to make Zeni work better for you",bankConnections:"Manage primary bank account connections for Zeni Bill Payments, Reimbursements, Business Checking, and Business Cards.",businessVerification:"Financial regulations require Zeni to collect both identity & company details to verify your business",companyDetails:"Quick access to manage the company's detailed information",integrations:"Quick access to manage the company's third-party connected services",myProfile:"Quick access to manage your personal details",myBankConnections:"Manage your linked personal bank details used to receive reimbursements"},bankConnectionHeader:{productType:"Products",primaryAccount:"Primary Account",linkAccount:"QBO Linked Account",status:"Status",balance:"Balance"},bankConnectionListHeader:{primary:"Primary",other:"Other Connections",otherToolTip:"These bank connections aren't linked to any product. Select from the dropdown above to connect."},productNameByType:{bill_pay:"Bill Pay",reimbursement:"Reimbursements",zeni_accounts:"Checking",zeni_treasury:"Treasury",charge_cards:"Cards"},otherAccount:{title:"Product",subTitle:"Not assigned",subTitleSmall:"not assigned",remove:"Remove Connection"},notifications:{sectionTitle:{reminders:"Reminders",monthEndInsights:"Month-end Insights"},frequency:{biWeekly:"Bi-Weekly"},mode:{email:"Email",dashboard:"Dashboard"},reminders:{missingReceiptNotification:"Missing Receipts:",uncategorizedTransactionNotification:"Uncategorized Transactions:",pendingBillApprovalNotification:"Bill Approvals:",pendingReimbursementApprovalNotification:"Reimbursement Approvals:"},monthEndInsights:{labels:{notifyMe:"Notify Me:",notifyOthers:"Notify Others:"},userFieldPlaceholder:"Who should receive this email?",stopReceivingEmailsText:"To stop receiving this email, reach out to",stopReceivingMonthEndInsightsSubject:"Stop Month End Insights"},reminderFrequencyOptions:[{label:"Daily",value:"daily"},{label:"Weekly",value:"weekly"},{label:"Bi-weekly",value:"bi-weekly"},{label:"Monthly",value:"monthly"}]}},copyToClipBoard:{copy:"Copy",copied:"Copied"},monthsByIndex:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},download:{errorMessages:{unsupportedFileType:"Unsupported Filetype",fileDownloadError:"Download __feature__ Failed with"},defaultFileName:"Report.xlsx"},balanceCard:{cashBalanceSectionTitle:"Total Cash Balance",cardBalanceSectionTitle:"Total Card Balance",comparedTo:"compared to",noBalanceText:"No balance data to display yet!"},insightsCard:{vs:"vs",title:"Insights",no_data:{label:"Cash, Opex, Revenue, COS, and Cash In Cash Out Insights, will appear once you have sufficient financial activity. Stay tuned! 💸"}},timeframe:{day:"Days",month:"Months",quarter:"Quarters",year:"Years",week:"Weeks",free_range:"Time period",this_week_to_date:"This Week",last_week:"Last Week",this_month_to_date:"This Month",last_month:"Last Month",last_3_months:"Last 3 Months",last_6_months:"Last 6 Months",last_12_months:"Last 12 Months",this_year_to_date:"This Year",last_year:"Last Year"},quarterPrefix:"Q",compareSwitchLabel:"Compare",compareMode:{off:"Off",compare_mode_percent:"Percentage",compare_mode_amount:"Amount",changePercent:"Change %",changePrefix:"Change"},chartCard:{total:"Total",activity:"Activity",no_data_available:"No data available!",no_data_available_for:"No data available for",tooltip:{actual:"Actual",forecast:"Forecast",change:"Change",change_percent:"Change %"},forecast_dropdown:{forecast_source:"Via Quickbooks",forecast_invalid_issue:"This period is not in the time frame of the actuals. Please view it via the Forecast tab."},netBurnOrIncome:{grossBurn:"Gross Burn",netBurnOrIncome:"Net Income / Burn",gross_burn:"Gross Burn",cogs:"COS",net_burn_or_income:"Net Income / Burn",income:"Revenue",expenses:"OPEX",net_burn:"Net Burn",net_income:"Net Income",no_data_available:"A minimum of one-month data is required!",cogs_forecast:"Forecast",net_burn_or_income_forecast:"Forecast",income_forecast:"Forecast",expenses_forecast:"Forecast"},netBurnOrIncomeCalculator:{title:"Burn Rate Calculator",accounting_method:{label:"Configure Burn Rate, Runway, and Cash Zero date based on below options:",cash:"Cash Flow from Operating Activities",ebitda:"EBITDA",net_income:"Net Income"},time_span_id_for_average:{label:"Further configure Burn Rate, Runway, and Cash Zero date based on below options:",last_month:"Last month",last_completed_month:"Last completed month",average_of_last_2_months:"Average of last 2 completed months",average_of_last_3_months:"Average of last 3 completed months",under_review_last_month_label:"(Including Under Review)"}},revenue:{income:"Revenue",cogs:"COS",gross_margin:"Gross Margin",grossMargin:"Gross Margin",income_forecast:"Forecast",cogs_forecast:"Forecast",gross_margin_forecast:"Forecast",grossMargin_forecast:"Forecast"},cashInCashOut:{cash_in:"Cash In",cash_out:"Cash Out",net_cash_flow:"Net Cash Flow"},no_data:{revenue:"No revenues to display yet, but thrift is a great revenue. Fight On!🤘",cash_in_cash_out:"No cash in cash out to display yet!",cash_position:"No cash position to display yet!",net_burn_or_income:"No net burn to display yet!",operating_expenses:"No operating expenses to display yet!",top_expenses:{this_week_to_date:"No expenses this week 🤷",last_week:"No expenses last week 🤷",this_month_to_date:"No expenses this month 🤷",last_month:"No expenses last month 🤷",last_3_months:"No expenses last 3 months 🤷",last_6_months:"No expenses last 6 months 🤷",last_12_months:"No expenses last 12 months 🤷",this_year_to_date:"No expenses this year 🤷",last_year:"No expenses last year 🤷"},aging_report:"No data to display yet!"}},drawerMenus:{dashboard:"Dashboard",cockpit:"Cockpit",reports:"Reports",people:"People",forecast:"Forecast",ai_automation:"AI Bookkeeping",cards:"Cards",bills:"Bills",storybooks:"Storybooks",settings:"Settings",logout:"Logout",reimbursements:"Reimbursements",checking:"Checking",vendors:"Vendors",rewards:"Rewards",accounting:"Accounting",approval_rules:"Approval Rules",billing:"Billing",bank_connections:"Bank Connections",business_verification:"Business Verification",company_details:"Company Details",integrations:"Integrations",my_profile:"My Profile",my_bank_connections:"My Bank Connections",notifications:"Notifications",performance:"Performance",ai_accountant:"AI Accountant",ai_cfo:"AI CFO",new_chat:"New Chat",explore:"Explore",treasury:"Treasury"},drawerMenuSubtitles:{rewards:"Earn __reward-amount__ per referral"},drawerGroups:{finance:"Finance",cash:"Cash",spend_management:"Spend Management",banking:"Banking",company:"Company",company_settings:"Company Settings",personal_settings:"Personal Settings",ai_bookkeeping:"AI Bookkeeping",ai_cfo:"",ai_agents:"AI Agents",ai_accountant:"AI Accountant"},drawerTags:{new:"NEW"},dashboardDropDownList:{menuOption:{logout:{label:"Logout",value:"logout"},settings:{label:"Settings",value:"settings"},cockpit:{label:"Cockpit",value:"cockpit"}}},transactionItem:{date:"Date",account:"Account"},transactionType:{invoice:"Invoice",creditMemo:"Credit Memo",salesReceipt:"Sales Receipt",refund:"Refund",expense:"Expense",check:"Check",bill:"Bill",billPayment:"Bill Payment",transfer:"Transfer",vendorCredit:"Vendor Credit",creditCardCredit:"Credit Card Credit",deposit:"Deposit",creditCardPayment:"Credit Card Payment",journalEntry:"Journal Entry",payment:"Payment"},signIn:{heading:"Welcome to Zeni",confirmationLinkSent:"Confirmation link sent",message:"Your financial dashboard is just one step away. Get started.",signInSecurelyMessage:"Choose an account to sign in securely",signInGoogleButton:"Sign In With Google",signInMicrosoftButton:"Sign In With Microsoft",termsPrivacyFinePrintPart:"By creating an account on Zeni, you confirm that you ",agreeWith:"agree with our ",termsOfService:"terms of service",and:"and",privacyPolicy:"privacy policy",termsUrl:"https://www.zeni.ai/terms",privacyPolicyUrl:"https://www.zeni.ai/privacy-policy",signInError:`Couldn’t sign-in to your account.
419
+ _failed_count_ Transaction failed.`},people_invite_people:{success:"Invitation sent",failed:"",notification:""},people_invite_multiple_people:{success:"Users invited",failed:"",notification:""},people_update_person:{success:"User info changed",failed:"",notification:""},people_delete_person:{success:"User deleted",failed:"",notification:""},reimbursement_updated:{success:"Reimbursement saved",failed:"_api-error_.",notification:""},reimbursement_approved:{success:"Reimbursement approved",failed:"_api-error_.",notification:""},reimbursement_rejected:{success:"Reimbursement rejected",failed:"_api-error_.",notification:""},reimbursement_sent_for_approval:{success:"Reimbursement sent for approval",failed:"_api-error_.",notification:""},reimbursement_deleted:{success:"Reimbursement deleted",failed:"_api-error_.",notification:""},reimbursement_cancelled:{success:"Reimbursement canceled",failed:"_api-error_.",notification:""},reimbursement_cancelled_deleted:{success:"Reimbursement canceled and deleted",failed:"_api-error_.",notification:""},reimbursement_bulk_submit:{success:"_count_ _report_ will be _action_. You'll be notified once it's done.",failed:"_api-error_.",notification:""},reimbursement_bulk_processed:{success:"_report_ _has_ been _action_. The page will refresh now to reflect updates.",failed:"_api-error_.",notification:""},save_reconcile_for_later:{success:"Reconciliation saved",failed:"Reconciliation not saved. Please try again!",notification:""},reconcile:{success:"_reconcile_account_ reconciliation in progress.",failed:"Reconciliation failed for _reconcile_account_",notification:""},exclude_transaction:{success:"Transaction excluded",failed:"Transaction exclusion failed",notification:""},account_added:{success:"Account added successfully",failed:"",notification:""},issue_charge_card:{success:"New _card_ issued for _user-name_",failed:"",notification:""},issue_charge_cards:{success:"New cards issued",failed:"",notification:""},charge_card_auto_pay_enable:{success:"Early payment enabled",failed:"",notification:""},charge_card_auto_pay_disable:{success:"Early payment disabled",failed:"",notification:""},business_verification_save:{success:"Business Verification Details saved successfully.",failed:"Couldn't save Business Verification Details. Please try again.",notification:""},business_verification_submit:{success:"Business Verification Details submitted successfully.",failed:"Couldn't submit Business Verification Details. Please try again.",notification:""},business_verification_from_bills_submit:{success:"Verified successfully.",failed:"Couldn't submit Business Verification Details. Please try again.",notification:""},plaid_connection:{success:"",failed:"Something went wrong! Please try again.",notification:""},bill_pay_setup:{success:"",failed:"Failed to load Bill Pay Setup Details! Please try again.",notification:""},zeni_accounts_setup:{success:"",failed:"Failed to load Zeni Accounts Setup Details! Please try again.",notification:""},bill_pay_approval_create:{success:"Approval Rule created successfully.",failed:"Couldn't create Approval Rule! Please try again.",notification:""},bill_pay_duplicate_approval_create:{success:"Approval Rule created successfully.",failed:"_api-error_",notification:""},bill_pay_approval_update:{success:"Approval Rule updated successfully.",failed:"Couldn't update Approval Rule! Please try again.",notification:""},update_zeni_account_nickname:{success:"Zeni Account nickname updated successfully",failed:"_api-error_.",notification:""},create_checking_account:{success:"New Business Account Added",failed:"_api-error_.",notification:""},deposit_check:{success:"Check Deposit Successful",failed:"_api-error_.",notification:""},bill_pay_duplicate_approval_update:{success:"Approval Rule updated successfully.",failed:"_api-error_",notification:""},bill_pay_approval_delete:{success:"Approval Rule deleted successfully.",failed:"Couldn't delete Approval Rule! Please try again.",notification:""},reimbursement_setup:{success:"",failed:"Failed to load Reimbursements Setup Details! Please try again.",notification:""},reimbursement_approval_create:{success:"Approval Rule created successfully.",failed:"Couldn't create Approval Rule! Please try again.",notification:""},reimbursement_duplicate_approval_create:{success:"Approval Rule created successfully.",failed:"_api-error_",notification:""},reimbursement_approval_update:{success:"Approval Rule updated successfully.",failed:"Couldn't update Approval Rule! Please try again.",notification:""},reimbursement_duplicate_approval_update:{success:"Approval Rule updated successfully.",failed:"_api-error_",notification:""},reimbursement_approval_delete:{success:"Approval Rule deleted successfully.",failed:"Couldn't delete Approval Rule! Please try again.",notification:""},reimbursement_create_mileage:{success:"Mileage rate added successfully.",failed:"_api-error_.",notification:""},reimbursement_update_mileage:{success:"Mileage rate updated successfully.",failed:"_api-error_.",notification:""},reimbursement_accept_term:{success:"",failed:"_api-error_.",notification:""},reimbursement_accept_employee_term:{success:"",failed:"_api-error_.",notification:""},cockpit_month_end_email_sent:{success:"Zeni Insights sent successfully for _company-name_.",failed:"",notification:""},cockpit_month_end_email_save:{success:"Zeni Insights saved successfully for _company-name_.",failed:"",notification:""},cockpit_month_end_email_attachment_upload:{success:"",failed:"Sorry, the file you uploaded is too large. Maximum file size allowed is 700KB",notification:""},audit_score_updated:{success:"Audit Score updated",failed:"",notification:""},create_bank_account_ach:{success:"ACH account added successfully.",failed:"",notification:""},unlink_deposit_account:{success:"",failed:"_api-error_.",notification:""},create_bank_account_wire:{success:"_wire-type_ wire account added successfully.",failed:"",notification:""},create_bank_account_international:{success:"_wire-type_ wire account added successfully.",failed:"",notification:""},bill_pay_updated:{success:"Bill saved",failed:"_api-error_.",notification:""},bill_pay_deleted:{success:"Bill deleted",failed:"_api-error_.",notification:""},bill_pay_bulk_submit:{success:"_count_ _bill_ will be _action_. You'll be notified once it's done.",failed:"_api-error_.",notification:""},bill_pay_bulk_processed:{success:"_bill_ _has_ been _action_. The page will refresh now to reflect updates.",failed:"_api-error_.",notification:""},bill_pay_cancelled_deleted:{success:"Bill canceled and deleted",failed:"_api-error_.",notification:""},bill_pay_cancelled:{success:"Bill canceled",failed:"_api-error_.",notification:""},bill_pay_approved:{success:"Bill approved",failed:"_api-error_.",notification:""},bill_pay_rejected:{success:"Bill rejected",failed:"_api-error_.",notification:""},bill_pay_sent_for_approval:{success:"Bill sent for approval",failed:"_api-error_.",notification:""},bill_pay_accept_term:{success:"",failed:"_api-error_.",notification:""},bill_pay_refund:{success:"Refund process initiated",failed:"_api-error_.",notification:""},bill_pay_retry:{success:"Payment retried",failed:"_api-error_.",notification:""},bill_pay_marked_as_paid:{success:"Bill marked as paid",failed:"_api-error_.",notification:""},update_vendor:{success:"Vendor updated successfully.",failed:"_api-error_.",notification:""},data_refresh_update:{success:"Data refreshed",failed:"_api-error_.",notification:""},delete_bank_account:{success:"Bank account deleted successfully.",failed:"_api-error_.",notification:""},update_debit_card_pin_attempt:{success:"PIN changed successfully",failed:"_api-error_.",notification:""},set_debit_card_pin:{success:"PIN set successfully",failed:"_api-error_.",notification:""},create_bank_account:{success:"",failed:"_api-error_.",notification:""},send_email_magic_link_to_user:{success:"",failed:"_api-error_.",notification:""},complete_profile_done:{success:"Profile details saved.",failed:"_api-error_.",notification:""},zeni_account_accept_term:{success:"",failed:"_api-error_.",notification:""},transfer_money:{success:"",failed:"_api-error_.",notification:""},create_vendor:{success:"Vendor created successfully.",failed:"_api-error_.",notification:""},onboarding_customer_view:{success:"Onboarding Business Details fetched successfully.",failed:"Couldn't fetch Onboarding Business Details. Please try again.",notification:""},onboarding_customer_view_complete:{success:"Onboarding status updated successfully.",failed:"Couldn't update Onboarding status. Please try again.",notification:""},onboarding_customer_identity_verification_save:{success:"Onboarding Identity Details saved successfully.",failed:"Couldn't save Onboarding Identity Details. Please try again.",notification:""},onboarding_customer_identity_verification_submit:{success:"Onboarding Identity Details submitted successfully.",failed:"Couldn't submit Onboarding Identity Details. Please try again.",notification:""},onboarding_customer_business_verification_save:{success:"Onboarding Business Details saved successfully.",failed:"Couldn't save Onboarding Business Details. Please try again.",notification:""},onboarding_customer_business_verification_submit:{success:"Onboarding Business Details submitted successfully.",failed:"Couldn't submit Onboarding Business Details. Please try again.",notification:""},retry_bank_account_connection:{success:"Bank account connection completed successfully.",failed:"Bank account connection failed.",notification:""},dashboard_invite_sent:{success:"Dashboard invite sent to _user-name_ for _company-name_ successfully.",failed:"Dashboard invite failed",notification:""},onboarding_info_saved:{success:"Saved successfully",failed:"Save failed",notification:""},approve_original_merchant:{success:'Review request for "_merchant_name_" is approved successfully.',failed:"_api-error_.",notification:""},approve_global_merchant:{success:'Review request for "_original_merchant_name_" to "_approved_merchant_name_" is approved successfully.',failed:"_api-error_.",notification:""},reject_global_merchant:{success:'Vendor "_merchant_name_" review rejected',failed:"_api-error_.",notification:""},create_global_merchant:{success:'Vendor "_global_merchant_name_" successfully added to global list.',failed:"_api-error_.",notification:""},fetch_global_merchant_no_recommendation:{success:'There are no recommendations for the name "_global_merchant_name_".',failed:"_api-error_.",notification:""},save_vendor_sent_for_review:{success:'Vendor "_vendor_name_" sent for the review.',failed:"_api-error_.",notification:""},save_vendor_renamed:{success:'Vendor "_old_vendor_name_" renamed to "_updated_vendor_name_."',failed:"_api-error_.",notification:""},save_vendor_marked_as_employee:{success:"Marked as employee",failed:"_api-error_.",notification:""},save_vendor_marked_as_local_contractor:{success:"Marked as local contractor",failed:"_api-error_.",notification:""},charge_card_setup:{success:"",failed:"Failed to load Cards Setup Details! Please try again.",notification:""},charge_card_receipt_upload:{success:"Card receipt uploaded",failed:"_api-error_.",notification:""},charge_card_resend_invite:{success:"Card invite resent",failed:"_api-error_.",notification:""},charge_card_revoke_invite:{success:"Card invite revoked",failed:"_api-error_.",notification:""},charge_card_update_limit:{success:"Card limit updated to _amount_",failed:"Limit updation failed with _api-error_.",notification:""},charge_cards_update_limit:{success:"Limit updated for _number_of_cards_",failed:"Limit updation failed with _api-error_.",notification:""},update_charge_card_name:{success:'Card _masked_card_number_ renamed to "_new_card_name_"',failed:"Card name updation failed with _api-error_.",notification:""},update_charge_card_name_card_user:{success:'Card renamed to "_new_card_name_"',failed:"Card name updation failed with _api-error_.",notification:""},lock_charge_card:{success:"Card _masked_card_number_ locked",failed:"Card lock failed with _api-error_.",notification:""},lock_charge_card_card_user:{success:"Card locked",failed:"Card lock failed with _api-error_.",notification:""},unlock_charge_card:{success:"Card _masked_card_number_ unlocked",failed:"Card unlock failed with _api-error_.",notification:""},unlock_charge_card_card_user:{success:"Card unlocked",failed:"Card unlock failed with _api-error_.",notification:""},close_charge_card:{success:"Card _masked_card_number_ closed",failed:"Card close failed with _api-error_.",notification:""},unlock_charge_cards:{success:"_number_of_cards_ unlocked",failed:"Cards unlock failed with _api-error_.",notification:""},lock_charge_cards:{success:"_number_of_cards_ locked",failed:"Cards lock failed with _api-error_.",notification:""},close_charge_cards:{success:"_number_of_cards_ closed",failed:"Cards close failed with _api-error_.",notification:""},revoke_invite_charge_cards:{success:"Invite revoked for _number_of_cards_",failed:"Invite revoke failed with _api-error_.",notification:""},create_schedule:{success:'Schedule created for "_vendor_name_"',failed:"Schedule creation failed with _api-error_.",notification:""},save_schedule:{success:'Schedule saved for "_vendor_name_"',failed:"Save schedule failed with _api-error_.",notification:""},je_posted:{success:"JE Posted",failed:"JE Posting failed with _api-error_.",notification:""},ignore_schedule:{success:"Schedule ignored",failed:"Schedule ignore failed with _api-error_.",notification:""},delete_schedule:{success:'Schedule deleted for "_vendor_name_"',failed:"Delete schedule failed with _api-error_.",notification:""},mark_as_complete_schedule:{success:'Schedule marked as completed for "_vendor_name_"',failed:"Mark as complete schedule failed with _api-error_.",notification:""},cancel_journal_entry:{success:"Accrual Canceled",failed:"Accrual Cancel failed with _api-error_.",notification:""},charge_card_accept_term:{success:"",failed:"_api-error_.",notification:""},charge_card_express_interest:{success:"Interest expressed successfully",failed:"_api-error_.",notification:""},save_task_detail:{success:"",failed:"_api-error_.",notification:""},fetch_task_detail:{success:"Task details fetched successfully.",failed:"_api-error_.",notification:""},delete_task:{success:"",failed:"_api-error_.",notification:""},archive_task:{success:"",failed:"_api-error_.",notification:""},update_charge_card:{success:"",failed:"_api-error_.",notification:""},notification_settings_saved:{success:"Notification Settings Saved",failed:"_api-error_.",notification:""},referral_invite_sent:{success:"Referral Invite Sent",failed:"_api-error_.",notification:""},notification_mark_as_read:{success:"Notifications marked as read successfully.",failed:"Something went wrong! Please try again.",notification:""},settings_accounting_accounts_updated:{success:"Accounts saved",failed:"",notification:""},task_group_creation_success:{success:"Task group created successfully",failed:"Task group creation failed",notification:""},task_group_deletion_success:{success:"Task group deleted successfully",failed:"Task group deletion failed",notification:""},task_group_update_success:{success:"Task group updated successfully",failed:"Task group update failed",notification:""},primary_funding_account_updated:{success:"Bank account updated for _productType_.",failed:"",notification:""},task_time_spent_validation:{success:"",failed:"Time can't exceed 99h 59m",notification:""},missing_receipts_attachment:{success:"",failed:"Failed to upload attachment__message__ please try again!",notification:""},flux_analysis_reviewed:{success:"_vendors_count_ _vendor_ reviewed",failed:"_api-error_.",notification:""},flux_analysis_unreviewed:{success:"_vendors_count_ _vendor_ unreviewed",failed:"_api-error_.",notification:""},express_pay_submit:{success:"Payment scheduled",failed:"_api-error_.",notification:""},recon_transaction_categorize:{success:"Transaction reviewed",failed:"_api-error_.",notification:""},recon_transaction_match:{success:"Transaction matched",failed:"_api-error_.",notification:""},ai_cfo_create_session_and_submit:{success:"",failed:"Something went wrong, please try again!",notification:""},treasury_setup:{success:"",failed:"Failed to load Treasury Setup Details! Please try again.",notification:""},treasury_accept_term:{success:"Treasury Terms accepted successfully.",failed:"Failed to accept terms. Please try again.",notification:""},treasury_transfer_money:{success:"Transfer initiated.",failed:"Transfer failed. Please try again.",notification:""},treasury_transfer_money_failed:{success:"",failed:"Transfer failed. Please try again.",notification:""},treasury_update_portfolio_allocation:{success:"Portfolio allocation updated.",failed:"Portfolio allocation update failed. Please try again!",notification:""},reports_resync:{success:"",failed:"Something went wrong. Please try again.",notification:"No new data available."},invalid_phone_number:{success:"",failed:"Invalid phone number",notification:""}},currency:{currencyCode:"INR",currencySymbol:"₹",currency:"Indian Rupee",countryCode:"IN"},format:{ssnFormat:"###-##-####",tinFormat:"##-#######"},status:{pending:"Pending"},cancel:"Cancel",confirm:"Confirm",continue:"Continue",proceed:"Proceed",next:"Next",noText:"--",privacy:"Zeni Privacy Policy",terms:"Terms and Conditions",privacyPolicyUrl:"https://www.zeni.ai/legal/privacy-policy",termsUrl:"https://www.zeni.ai/legal/terms-of-service",footer:{save:"Save",submit:"Submit",cancel:"Cancel",approve:"Approve",reject:"Reject",send:"Send",resubmit:"Resubmit",add:"Add",continueAnyway:"Continue Anyway",resolve:"Resolve",inReview:"In Review",sentForReview:"Sent for Review",linkCard:"Link Card",next:"Next",back:"Back",markAsUnReviewed:"Mark as Unreviewed",markAsReviewed:"Mark as Reviewed",saveForLater:"Save for Later",reconcile:"Reconcile",edit:"Edit",noThanks:"No, Thanks",letsGetStarted:"Let's Get Started"},completeText:"Complete",incompleteText:"Incomplete",notInitiatedText:"Not Initiated",pendingReviewText:"Pending Review",pendingVerificationText:"Pending Verification",retry:"Retry",verified:"Verified",validation:{emailAddressRequired:"Email address required",invalidEmailAddress:"Invalid email address",invalidUrlAddress:"Invalid URL"},needHelp:{text:"Need Help",hoverPrefix:"Experiencing issues?",hoverSuffix:" Schedule a call"},confirmationPopup:{discardTitle:"Discard unsaved changes?",discardDescription:"Changes are not automatically saved. Your changes will be lost if you continue.",discard:"Discard",cancel:"Cancel"},via:"via",cockpit:"cockpit",analytics:"Analytics",filters:{noOptions:"No Options",noMatchesFound:"No Matches Found",userProfileAltText:"Failed to load",startDate:"Start Date",endDate:"End Date"},updated:"Updated",hoursAgo:"hours ago",minutesAgo:"a few minutes ago",noMatches:"Nothing matched your search. Please try again!",noReport:"No _item-name_ to display yet!",reloadPage:{label:"Something went wrong, please try again!"},settings:{title:{accounting:"Accounting Setup",approvalRules:"Approval Rules",bankConnections:"Bank Connections",integrations:"Integrations",myProfile:"My Profile",myBankConnections:"My Bank Connections",notifications:"Notifications"},common:{update:"Update",cancel:"Cancel",productTypeString:"My Profile"},subtitle:{myProfile:"Profile Details",myBankConnections:"Reimbursements"},label:{primary:"Primary",billPay:"Bill Pay",reimbursements:"Reimbursements",bankAccount:"Bank Account",noManager:"No Manager",myProfile:"My Profile"},infoText:{accounting:"Quick access to manage the company's accounting-related settings",approvalRules:"Quick access to manage the multi-level approval rules for bills & reimbursements to make Zeni work better for you",bankConnections:"Manage primary bank account connections for Zeni Bill Payments, Reimbursements, Business Checking, and Business Cards.",businessVerification:"Financial regulations require Zeni to collect both identity & company details to verify your business",companyDetails:"Quick access to manage the company's detailed information",integrations:"Quick access to manage the company's third-party connected services",myProfile:"Quick access to manage your personal details",myBankConnections:"Manage your linked personal bank details used to receive reimbursements"},bankConnectionHeader:{productType:"Products",primaryAccount:"Primary Account",linkAccount:"QBO Linked Account",status:"Status",balance:"Balance"},bankConnectionListHeader:{primary:"Primary",other:"Other Connections",otherToolTip:"These bank connections aren't linked to any product. Select from the dropdown above to connect."},productNameByType:{bill_pay:"Bill Pay",reimbursement:"Reimbursements",zeni_accounts:"Checking",zeni_treasury:"Treasury",charge_cards:"Cards"},otherAccount:{title:"Product",subTitle:"Not assigned",subTitleSmall:"not assigned",remove:"Remove Connection"},notifications:{sectionTitle:{reminders:"Reminders",monthEndInsights:"Month-end Insights"},frequency:{biWeekly:"Bi-Weekly"},mode:{email:"Email",dashboard:"Dashboard"},reminders:{missingReceiptNotification:"Missing Receipts:",uncategorizedTransactionNotification:"Uncategorized Transactions:",pendingBillApprovalNotification:"Bill Approvals:",pendingReimbursementApprovalNotification:"Reimbursement Approvals:"},monthEndInsights:{labels:{notifyMe:"Notify Me:",notifyOthers:"Notify Others:"},userFieldPlaceholder:"Who should receive this email?",stopReceivingEmailsText:"To stop receiving this email, reach out to",stopReceivingMonthEndInsightsSubject:"Stop Month End Insights"},reminderFrequencyOptions:[{label:"Daily",value:"daily"},{label:"Weekly",value:"weekly"},{label:"Bi-weekly",value:"bi-weekly"},{label:"Monthly",value:"monthly"}]}},copyToClipBoard:{copy:"Copy",copied:"Copied"},monthsByIndex:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},download:{errorMessages:{unsupportedFileType:"Unsupported Filetype",fileDownloadError:"Download __feature__ Failed with"},defaultFileName:"Report.xlsx"},balanceCard:{cashBalanceSectionTitle:"Total Cash Balance",cardBalanceSectionTitle:"Total Card Balance",comparedTo:"compared to",noBalanceText:"No balance data to display yet!"},insightsCard:{vs:"vs",title:"Insights",no_data:{label:"Cash, Opex, Revenue, COS, and Cash In Cash Out Insights, will appear once you have sufficient financial activity. Stay tuned! 💸"}},timeframe:{day:"Days",month:"Months",quarter:"Quarters",year:"Years",week:"Weeks",free_range:"Time period",this_week_to_date:"This Week",last_week:"Last Week",this_month_to_date:"This Month",last_month:"Last Month",last_3_months:"Last 3 Months",last_6_months:"Last 6 Months",last_12_months:"Last 12 Months",this_year_to_date:"This Year",last_year:"Last Year"},quarterPrefix:"Q",compareSwitchLabel:"Compare",compareMode:{off:"Off",compare_mode_percent:"Percentage",compare_mode_amount:"Amount",changePercent:"Change %",changePrefix:"Change"},chartCard:{total:"Total",activity:"Activity",no_data_available:"No data available!",no_data_available_for:"No data available for",tooltip:{actual:"Actual",forecast:"Forecast",change:"Change",change_percent:"Change %"},forecast_dropdown:{forecast_source:"Via Quickbooks",forecast_invalid_issue:"This period is not in the time frame of the actuals. Please view it via the Forecast tab."},netBurnOrIncome:{grossBurn:"Gross Burn",netBurnOrIncome:"Net Income / Burn",gross_burn:"Gross Burn",cogs:"COS",net_burn_or_income:"Net Income / Burn",income:"Revenue",expenses:"OPEX",net_burn:"Net Burn",net_income:"Net Income",no_data_available:"A minimum of one-month data is required!",cogs_forecast:"Forecast",net_burn_or_income_forecast:"Forecast",income_forecast:"Forecast",expenses_forecast:"Forecast"},netBurnOrIncomeCalculator:{title:"Burn Rate Calculator",accounting_method:{label:"Configure Burn Rate, Runway, and Cash Zero date based on below options:",cash:"Cash Flow from Operating Activities",ebitda:"EBITDA",net_income:"Net Income"},time_span_id_for_average:{label:"Further configure Burn Rate, Runway, and Cash Zero date based on below options:",last_month:"Last month",last_completed_month:"Last completed month",average_of_last_2_months:"Average of last 2 completed months",average_of_last_3_months:"Average of last 3 completed months",under_review_last_month_label:"(Including Under Review)"}},revenue:{income:"Revenue",cogs:"COS",gross_margin:"Gross Margin",grossMargin:"Gross Margin",income_forecast:"Forecast",cogs_forecast:"Forecast",gross_margin_forecast:"Forecast",grossMargin_forecast:"Forecast"},cashInCashOut:{cash_in:"Cash In",cash_out:"Cash Out",net_cash_flow:"Net Cash Flow"},no_data:{revenue:"No revenues to display yet, but thrift is a great revenue. Fight On!🤘",cash_in_cash_out:"No cash in cash out to display yet!",cash_position:"No cash position to display yet!",net_burn_or_income:"No net burn to display yet!",operating_expenses:"No operating expenses to display yet!",top_expenses:{this_week_to_date:"No expenses this week 🤷",last_week:"No expenses last week 🤷",this_month_to_date:"No expenses this month 🤷",last_month:"No expenses last month 🤷",last_3_months:"No expenses last 3 months 🤷",last_6_months:"No expenses last 6 months 🤷",last_12_months:"No expenses last 12 months 🤷",this_year_to_date:"No expenses this year 🤷",last_year:"No expenses last year 🤷"},aging_report:"No data to display yet!"}},drawerMenus:{dashboard:"Dashboard",cockpit:"Cockpit",reports:"Reports",people:"People",forecast:"Forecast",ai_automation:"AI Bookkeeping",cards:"Cards",bills:"Bills",storybooks:"Storybooks",settings:"Settings",logout:"Logout",reimbursements:"Reimbursements",checking:"Checking",vendors:"Vendors",rewards:"Rewards",accounting:"Accounting",approval_rules:"Approval Rules",billing:"Billing",bank_connections:"Bank Connections",business_verification:"Business Verification",company_details:"Company Details",integrations:"Integrations",my_profile:"My Profile",my_bank_connections:"My Bank Connections",notifications:"Notifications",performance:"Performance",ai_accountant:"AI Accountant",ai_cfo:"AI CFO",new_chat:"New Chat",explore:"Explore",treasury:"Treasury"},drawerMenuSubtitles:{rewards:"Earn __reward-amount__ per referral"},drawerGroups:{finance:"Finance",cash:"Cash",spend_management:"Spend Management",banking:"Banking",company:"Company",company_settings:"Company Settings",personal_settings:"Personal Settings",ai_bookkeeping:"AI Bookkeeping",ai_cfo:"",ai_agents:"AI Agents",ai_accountant:"AI Accountant"},drawerTags:{new:"NEW"},dashboardDropDownList:{menuOption:{logout:{label:"Logout",value:"logout"},settings:{label:"Settings",value:"settings"},cockpit:{label:"Cockpit",value:"cockpit"}}},transactionItem:{date:"Date",account:"Account"},transactionType:{invoice:"Invoice",creditMemo:"Credit Memo",salesReceipt:"Sales Receipt",refund:"Refund",expense:"Expense",check:"Check",bill:"Bill",billPayment:"Bill Payment",transfer:"Transfer",vendorCredit:"Vendor Credit",creditCardCredit:"Credit Card Credit",deposit:"Deposit",creditCardPayment:"Credit Card Payment",journalEntry:"Journal Entry",payment:"Payment"},signIn:{heading:"Welcome to Zeni",confirmationLinkSent:"Confirmation link sent",message:"Your financial dashboard is just one step away. Get started.",signInSecurelyMessage:"Choose an account to sign in securely",signInGoogleButton:"Sign In With Google",signInMicrosoftButton:"Sign In With Microsoft",termsPrivacyFinePrintPart:"By creating an account on Zeni, you confirm that you ",agreeWith:"agree with our ",termsOfService:"terms of service",and:"and",privacyPolicy:"privacy policy",termsUrl:"https://www.zeni.ai/terms",privacyPolicyUrl:"https://www.zeni.ai/privacy-policy",signInError:`Couldn’t sign-in to your account.
420
420
  Please try again.`,signInAuthError:`Authorization failed, and sign-in is restricted.
421
421
  Please try and authorize again.`,emailNotFoundPopup:{title:"We couldn't find the email ID",confirmEmail:"Please ensure that you are logging in with the same email ID that you shared with Zeni.",checkAccess:"Make sure you have access to your company's Zeni dashboard. If not, reach out to your Zeni admin.",contactZeni:"Please contact Zeni's sales executive if you are in the process of onboarding with Zeni."},magicLinkSent:{primaryMessage:"A secure sign in link has been sent to __email__ to access the dashboard.",secondaryMessage:"If you can't see the email, check your spam/junk folder.",resendLinkCountdown:"Resend Link in __seconds__s",resendLink:"Resend Link"},workEmailExample:"name@workemail.com",signInButton:"Sign In",invalidEmailMessage:"Invalid email address",magicLinkExpired:"Your sign-in link has expired. Please try again.",magicLinkExpiredHeading:"This sign-in link has expired",requestNewLink:"Request a new link",workEmailLink:"Sign in using email",workEmailSubText:"For users without Google/Microsoft access.",googleOrMicrosoftLink:"Sign in using Google or Microsoft",continueAs:"Continue as"},billPayPromoCard:{title:"Bill Pay",aipoweredInvoice:{prefix:"AI-powered invoice processing helps create bills in seconds."},multiLevelApproval:{prefix:"Multi-level approval flows allows you to stay in control of payments."},financeTeam:{prefix:"Fully managed by your expert Zeni Finance Team."},fastestWay:{prefix:"Fastest way to pay your vendors and contractors, 100% free"},btn:"Learn More",signUp:"Sign Up for FREE"},reimbursementPromoCard:{title:"Reimbursements",aiPowered:{prefix:"AI powered receipts processing helps you create reports in seconds."},multiLevel:{prefix:"Multi-level approval flows allow you to stay in control of payments."},reimburse:{prefix:"Reimburse employees at lightning speed, absolutely free"},signUp:"Sign Up for FREE",btn:"Learn More"},treasuryPromoCard:{title:"Treasury",introducing:"Introducing",btn:"Get Started",watchVideo:{prefix:"Watch how Zeni Treasury helps you earn more."},highYield:{title:"Earn yields upto",prefix:`Put your idle cash to work and earn
422
422
  more than a standard checking account.`},sipcInsured:{title:"SIPC coverage upto",amount:"$500K",prefix:`SIPC protection ensures your assets
@@ -5393,7 +5393,7 @@ Initiate your first transfer to start earning yield.`,insuredFundsTooltip:"Secur
5393
5393
  padding-top: ${e=>ks.ButtonContainerPaddingTop.valuePx(e.windowSize)};
5394
5394
  `,HHt=m.div``,VHt=m($Ht)`
5395
5395
  transform: scale(1, 0.9);
5396
- `,UHt=m(Ka)``,WHt=14e5,v7e=1e7,YHt=32e6,GHt=["application/postscript","application/pdf","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet","application/vnd.ms-excel","application/msword","application/vnd.openxmlformats-officedocument.wordprocessingml.document","application/vnd.oasis.opendocument.text","application/vnd.oasis.opendocument.spreadsheet","application/rtf","text/plain","text/html","text/csv","text/xml","image/jpg","image/jpeg","image/png","image/svg+xml","image/webp","image/gif","image/heic","image/heif","application/x-excel","image/tiff","image/tif","application/xml"],qHt=e=>B0(e,GHt),D7=({fileType:e="file",value:t,isSizeLimitForEachFile:r=!1,fileRef:n,multiple:o=!0,name:i,acceptableTypes:a,sizeLimit:l,isDisabled:d=!1,onFileSizeError:u,onFileChange:p})=>{const h=["application/postscript","application/pdf","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet","application/vnd.ms-excel","application/msword","application/vnd.openxmlformats-officedocument.wordprocessingml.document","application/vnd.oasis.opendocument.text","application/vnd.oasis.opendocument.spreadsheet","application/rtf","text/plain","text/html","text/csv","text/xml","image/jpeg","image/png","image/svg+xml","image/webp","image/gif","image/heic","image/heif"];return s.jsx("input",{type:e,ref:n,value:t,name:i,size:1e3,disabled:d,"data-testid":ke("file-input",i),onChange:f=>{let g=0;if(l!=null&&f.target.files!=null&&f.target.files.length>0){if(r&&f.target.files.length===1&&f.target.files[0].size>l){u?.(!0,!0),f.target.value="";return}for(let y=0;y<f.target.files.length;y++){if(r&&f.target.files[y].size>l){u?.(!0,!1),f.target.value="";return}g=g+f.target.files[y].size}g>l?(u?.(!0),f.target.value=""):(u?.(!1),p(f),f.target.value="")}else u?.(!1),p(f),f.target.value=""},style:{display:"none"},accept:(a??h).toString(),multiple:o})},b7e="application/pdf",w7e=["image/jpg","image/jpeg","image/png","image/webp","image/bmp"],ZHt={useWebWorker:!0,maxWidthOrHeight:1920,initialQuality:.92,maxSizeMB:2},KHt=async(e,t)=>{if(w7e.includes(e.type)===!1)return e;const r=await ta(e,{useWebWorker:!0,maxWidthOrHeight:900,initialQuality:1,maxSizeMB:1.4}),n=r.lastModified,o=r.type.split("/")[1];let i=`image_${n}.${o}`;return t!=null&&(i=`${t}.${o}`),new File([r],i,{lastModified:n,type:r.type})},XHt=async(e,t)=>{if(w7e.includes(e.type)===!1)return e;const r=await ta(e,ZHt),n=r.type.split("/")[1],o=`${t.replace(/\.[^.]+$/,"")||"image"}.${n}`;return new File([r],o,{lastModified:e.lastModified,type:r.type})},QHt=1.5,JHt=.7;function eVt(e,t){return new Promise((r,n)=>{e.toBlob(o=>{if(o==null){n(new Error("canvas.toBlob returned null"));return}r(o)},"image/jpeg",t)})}async function tVt(e,t,r){const n=e.getViewport({scale:t}),o=document.createElement("canvas");o.width=Math.floor(n.width),o.height=Math.floor(n.height);const i=o.getContext("2d");if(i==null)throw new Error("Could not get canvas 2d context");return await e.render({canvasContext:i,viewport:n}).promise,(await eVt(o,r)).arrayBuffer()}async function rVt(e,t){const[{PDFDocument:r},n]=await Promise.all([bt(()=>import("./index-DRnHG-3E.js"),__vite__mapDeps([13,5,1,6,14])),bt(()=>Promise.resolve().then(()=>nmt),void 0).then(p=>p.pdfjs)]),o=await e.arrayBuffer(),i=await n.getDocument({data:new Uint8Array(o)}).promise,a=i.numPages,l=await r.create();for(let p=1;p<=a;p++){const h=await i.getPage(p),f=await tVt(h,QHt,JHt),g=await l.embedJpg(new Uint8Array(f)),y=g.scale(1);l.addPage([y.width,y.height]).drawImage(g,{x:0,y:0,width:y.width,height:y.height})}const d=await l.save(),u=t.toLowerCase().endsWith(".pdf")?t:`${t}.pdf`;return new File([d],u,{type:b7e,lastModified:e.lastModified})}async function nVt(e,t){const r=e instanceof File?e:new File([e],t,{type:e.type});if(e.type===b7e){const o=await rVt(r,t);return o.size<r.size?{blob:o,name:o.name}:{blob:e,name:t}}const n=await XHt(r,t);return{blob:n,name:n.name}}async function TZr(e,t){const r=await Promise.all(e.map((n,o)=>{const i=t[o]??`file_${o}`;return nVt(n,i).catch(a=>(console.warn("[compressReceiptFiles] compression failed, using original:",a instanceof Error?a.message:a),{blob:n,name:i}))}));return{blobs:r.map(n=>n.blob),names:r.map(n=>n.name)}}const oVt=({fileType:e="file",fileRef:t,name:r,value:n="",multiple:o=!1,acceptableTypes:i,onFileSizeError:a,onImageChange:l})=>s.jsx("input",{type:e,ref:t,name:r,value:n,size:1e3,"data-testid":ke("input-file-element-mobile",r),onChange:async d=>{const u=d.target.files?.[0],p=u?.size;u!=null&&p!=null?(a?.(!1),l(u),d.target.value=""):(a?.(!0),d.target.value="")},style:{display:"none"},accept:`${(i??"image/jpg, image/jpeg").toString()}`,multiple:o,capture:!0}),x7e=({shouldDisplay:e,width:t=30,height:r=30,styles:n,animationInLoop:o=!1})=>{const[,i]=o5e(i5e),[a]=Mc("MoneyTransferSuccess");return C.useEffect(()=>{e&&i(!0)},[e,i]),e&&a!=null?s.jsx(I1,{style:{width:t,height:r,...n},play:!0,animationData:a,loop:o,rendererSettings:{preserveAspectRatio:"xMidYMid slice"}}):null},iVt=e=>rn`
5396
+ `,UHt=m(Ka)``,WHt=14e5,v7e=1e7,YHt=32e6,GHt=["application/postscript","application/pdf","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet","application/vnd.ms-excel","application/msword","application/vnd.openxmlformats-officedocument.wordprocessingml.document","application/vnd.oasis.opendocument.text","application/vnd.oasis.opendocument.spreadsheet","application/rtf","text/plain","text/html","text/csv","text/xml","image/jpg","image/jpeg","image/png","image/svg+xml","image/webp","image/gif","image/heic","image/heif","application/x-excel","image/tiff","image/tif","application/xml"],qHt=e=>B0(e,GHt),D7=({fileType:e="file",value:t,isSizeLimitForEachFile:r=!1,fileRef:n,multiple:o=!0,name:i,acceptableTypes:a,sizeLimit:l,isDisabled:d=!1,onFileSizeError:u,onFileChange:p})=>{const h=["application/postscript","application/pdf","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet","application/vnd.ms-excel","application/msword","application/vnd.openxmlformats-officedocument.wordprocessingml.document","application/vnd.oasis.opendocument.text","application/vnd.oasis.opendocument.spreadsheet","application/rtf","text/plain","text/html","text/csv","text/xml","image/jpeg","image/png","image/svg+xml","image/webp","image/gif","image/heic","image/heif"];return s.jsx("input",{type:e,ref:n,value:t,name:i,size:1e3,disabled:d,"data-testid":ke("file-input",i),onChange:f=>{let g=0;if(l!=null&&f.target.files!=null&&f.target.files.length>0){if(r&&f.target.files.length===1&&f.target.files[0].size>l){u?.(!0,!0),f.target.value="";return}for(let y=0;y<f.target.files.length;y++){if(r&&f.target.files[y].size>l){u?.(!0,!1),f.target.value="";return}g=g+f.target.files[y].size}g>l?(u?.(!0),f.target.value=""):(u?.(!1),p(f),f.target.value="")}else u?.(!1),p(f),f.target.value=""},style:{display:"none"},accept:(a??h).toString(),multiple:o})},b7e="application/pdf",w7e=["image/jpg","image/jpeg","image/png","image/webp","image/bmp"],ZHt={useWebWorker:!0,maxWidthOrHeight:1920,initialQuality:.92,maxSizeMB:2},KHt=async(e,t)=>{if(w7e.includes(e.type)===!1)return e;const r=await ta(e,{useWebWorker:!0,maxWidthOrHeight:900,initialQuality:1,maxSizeMB:1.4}),n=r.lastModified,o=r.type.split("/")[1];let i=`image_${n}.${o}`;return t!=null&&(i=`${t}.${o}`),new File([r],i,{lastModified:n,type:r.type})},XHt=async(e,t)=>{if(w7e.includes(e.type)===!1)return e;const r=await ta(e,ZHt),n=r.type.split("/")[1],o=`${t.replace(/\.[^.]+$/,"")||"image"}.${n}`;return new File([r],o,{lastModified:e.lastModified,type:r.type})},QHt=1.5,JHt=.7;function eVt(e,t){return new Promise((r,n)=>{e.toBlob(o=>{if(o==null){n(new Error("canvas.toBlob returned null"));return}r(o)},"image/jpeg",t)})}async function tVt(e,t,r){const n=e.getViewport({scale:t}),o=document.createElement("canvas");o.width=Math.floor(n.width),o.height=Math.floor(n.height);const i=o.getContext("2d");if(i==null)throw new Error("Could not get canvas 2d context");return await e.render({canvasContext:i,viewport:n}).promise,(await eVt(o,r)).arrayBuffer()}async function rVt(e,t){const[{PDFDocument:r},n]=await Promise.all([bt(()=>import("./index-BWdq4kfG.js"),__vite__mapDeps([13,5,1,6,14])),bt(()=>Promise.resolve().then(()=>nmt),void 0).then(p=>p.pdfjs)]),o=await e.arrayBuffer(),i=await n.getDocument({data:new Uint8Array(o)}).promise,a=i.numPages,l=await r.create();for(let p=1;p<=a;p++){const h=await i.getPage(p),f=await tVt(h,QHt,JHt),g=await l.embedJpg(new Uint8Array(f)),y=g.scale(1);l.addPage([y.width,y.height]).drawImage(g,{x:0,y:0,width:y.width,height:y.height})}const d=await l.save(),u=t.toLowerCase().endsWith(".pdf")?t:`${t}.pdf`;return new File([d],u,{type:b7e,lastModified:e.lastModified})}async function nVt(e,t){const r=e instanceof File?e:new File([e],t,{type:e.type});if(e.type===b7e){const o=await rVt(r,t);return o.size<r.size?{blob:o,name:o.name}:{blob:e,name:t}}const n=await XHt(r,t);return{blob:n,name:n.name}}async function TZr(e,t){const r=await Promise.all(e.map((n,o)=>{const i=t[o]??`file_${o}`;return nVt(n,i).catch(a=>(console.warn("[compressReceiptFiles] compression failed, using original:",a instanceof Error?a.message:a),{blob:n,name:i}))}));return{blobs:r.map(n=>n.blob),names:r.map(n=>n.name)}}const oVt=({fileType:e="file",fileRef:t,name:r,value:n="",multiple:o=!1,acceptableTypes:i,onFileSizeError:a,onImageChange:l})=>s.jsx("input",{type:e,ref:t,name:r,value:n,size:1e3,"data-testid":ke("input-file-element-mobile",r),onChange:async d=>{const u=d.target.files?.[0],p=u?.size;u!=null&&p!=null?(a?.(!1),l(u),d.target.value=""):(a?.(!0),d.target.value="")},style:{display:"none"},accept:`${(i??"image/jpg, image/jpeg").toString()}`,multiple:o,capture:!0}),x7e=({shouldDisplay:e,width:t=30,height:r=30,styles:n,animationInLoop:o=!1})=>{const[,i]=o5e(i5e),[a]=Mc("MoneyTransferSuccess");return C.useEffect(()=>{e&&i(!0)},[e,i]),e&&a!=null?s.jsx(I1,{style:{width:t,height:r,...n},play:!0,animationData:a,loop:o,rendererSettings:{preserveAspectRatio:"xMidYMid slice"}}):null},iVt=e=>rn`
5397
5397
  0% {
5398
5398
  width: 0%;
5399
5399
  }
@@ -21484,7 +21484,7 @@ to {
21484
21484
  display: flex;
21485
21485
  flex-direction: column;
21486
21486
  row-gap: ${e=>El.sectionRowGap.valuePx(e.windowSize)};
21487
- `,k9e=e=>`${e}_form`,u8r=Object.freeze(Object.defineProperty({__proto__:null,default:i8r,trackTreasuryTransferAnalytics:Wy,uniqueName:k9e},Symbol.toStringTag,{value:"Module"}));vt(()=>Promise.resolve().then(()=>AIt));const tQr=vt(()=>bt(()=>import("./OverlayContainerPage-Daz3A7cI-DCcii6jR.js"),__vite__mapDeps([15,16,1,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./ConfettiBurst-Cygb8bhF-CpMHcY5K.js"),__vite__mapDeps([21,1,17,6,8,5,16,18,19,20,7])));vt(()=>Promise.resolve().then(()=>dUt));const rQr=vt(()=>bt(()=>import("./SignIn-BZXzRb1K-B_z9rDGz.js"),__vite__mapDeps([22,1,16,17,6,8,5,23,24,25,18,19,20,7])));vt(()=>bt(()=>import("./Dashboard-CJSMYKO7-S41CzF6L.js"),__vite__mapDeps([26,1,16,17,6,8,5,27,28,29,30,31,32,33,34,35,36,37,38,39,40,18,19,20,7,41,42,43,44,45,46,47,21])));vt(()=>bt(()=>import("./AppDrawerContent-Df0b3OK2-CKxXRIrV.js"),__vite__mapDeps([48,1,16,17,6,8,5,27,18,19,20,7])));vt(()=>bt(()=>import("./TransactionListBig-dUBjAacV-DC5_6EqD.js"),__vite__mapDeps([49,1,16,17,6,8,5,41,37,30,38,39,18,19,20,7])));vt(()=>bt(()=>import("./TransactionListPage-x0r04hx4-ByjUdu-s.js"),__vite__mapDeps([50,1,16,17,6,8,5,51,52,53,54,18,19,20,7])));vt(()=>bt(()=>import("./DashboardReportPage-CcY-7-W_-DdmW4wbH.js"),__vite__mapDeps([55,1,16,17,6,8,5,56,57,58,59,60,39,61,33,29,34,35,62,63,64,65,66,67,32,68,69,18,19,20,7])));vt(()=>bt(()=>import("./ReportsPage-D-4SKTVF-DBO0HPPe.js"),__vite__mapDeps([70,1,16,17,6,8,5,56,57,58,59,64,71,65,72,54,18,19,20,7,66,73,68,69])));vt(()=>bt(()=>import("./TopExDetailPage-B8-Zzr1B-CRfyljYM.js"),__vite__mapDeps([74,16,1,17,6,8,5,31,30,32,65,67,18,19,20,7])));vt(()=>bt(()=>import("./TransactionDetailPage-D8v3KPrb-BrPGsz8W.js"),__vite__mapDeps([75,1,16,17,6,8,5,76,77,78,29,34,35,18,19,20,7,62,60,39,51,52,53,79,80])));vt(()=>bt(()=>import("./QBOConnectionDialog-CFgV4ltt-DFaL9t9h.js"),__vite__mapDeps([81,16,1,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./VerifyDevice-c6uTgDIl-CbEOfzzD.js"),__vite__mapDeps([82,1,16,17,6,8,5,83,25,18,19,20,7])));vt(()=>bt(()=>import("./AccountLockedInfoModal-BqLkGmTA-Bi36nE_K.js"),__vite__mapDeps([83,16,1,17,6,8,5,25,18,19,20,7])).then(e=>e.a));vt(()=>bt(()=>import("./InsightsCardStack-BSigEuRs-DrhT2GS8.js"),__vite__mapDeps([36,1,37,30,16,17,6,8,5,38,39,40,18,19,20,7])));vt(()=>bt(()=>import("./InformationCardStack-DEj81xCg-BlO4gF2p.js"),__vite__mapDeps([44,1,37,30,16,17,6,8,5,38,39,18,19,20,7])));vt(()=>bt(()=>import("./DownloadOverlay-gRH0FIa6-e2777Hoq.js"),__vite__mapDeps([72,1,16,17,6,8,5,56,57,58,59,54,18,19,20,7])));vt(()=>bt(()=>import("./PeoplePage-Di9LbUPG-Da8rtaKy.js"),__vite__mapDeps([84,1,16,17,6,8,5,85,86,18,19,20,7])));vt(()=>bt(()=>import("./PandLWithForecastPage-BzeV5E9J-BCbR55BC.js"),__vite__mapDeps([87,1,16,17,6,8,5,88,56,71,65,58,59,89,66,73,18,19,20,7])));vt(()=>bt(()=>import("./TrendChart-C7DgNHh6-CJUZv0E3.js"),__vite__mapDeps([78,1,5,6,29,16,17,8,34,35,18,19,20,7])));vt(()=>bt(()=>import("./EntityDetailPage-dZ-H_-kO-B3yxSec8.js"),__vite__mapDeps([90,16,1,17,6,8,5,77,78,29,34,35,18,19,20,7,62,60,39,51,52,53])));const nQr=vt(()=>bt(()=>import("./NotFoundPage-Y4UqiUrL-Dl07MVyQ.js"),__vite__mapDeps([91,16,1,17,6,8,5,23,18,19,20,7]))),oQr=vt(()=>Promise.resolve().then(()=>zYt));vt(()=>bt(()=>import("./CompanyPassportCard-Bv6Aws7i-dO40WjmK.js"),__vite__mapDeps([42,16,1,17,6,8,5,37,30,18,19,20,7])));vt(()=>bt(()=>import("./CompanyPassportPage-DRhnOgdd-BOnCftvv.js"),__vite__mapDeps([92,1,16,17,6,8,5,93,94,95,18,19,20,7])));vt(()=>bt(()=>import("./CreateOrEditVendorPage-_jZBL7C2-BT5eOx4Y.js"),__vite__mapDeps([96,1,16,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./VendorACHDetailsPage-ChZp1Db0-Cse3K9q8.js"),__vite__mapDeps([97,1,98,16,17,6,8,5,99,100,101,18,19,20,7])));vt(()=>bt(()=>import("./VendorDomesticWireDetailsPage-Dfawpwuo-BLDa-BWv.js"),__vite__mapDeps([102,1,103,16,17,6,8,5,101,100,99,104,105,18,19,20,7])));vt(()=>bt(()=>import("./VendorInternationalWireDetailsPage-CT75sZ0O-CdoJJkNf.js"),__vite__mapDeps([106,1,16,17,6,8,5,99,104,105,107,18,19,20,7])));vt(()=>bt(()=>import("./ReviewDetailsPage-Df882foz-DSNm6Tvp.js"),__vite__mapDeps([108,1,16,17,6,8,5,109,110,18,19,20,7])));vt(()=>bt(()=>import("./BillPayPromoPage-M3bRYehy-Bpwpx-W-.js"),__vite__mapDeps([111,1,16,17,6,8,5,112,47,89,18,19,20,7])));vt(()=>bt(()=>import("./BillPaySetUpPage-CJyPhrld-BW-k6Cq5.js"),__vite__mapDeps([113,1,16,17,6,8,5,114,18,19,20,7])));vt(()=>bt(()=>import("./ApprovalRulesSettingsPage-ChI1Wnf--DELVy5mB.js"),__vite__mapDeps([115,16,1,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./BankConnectionsSettingsPage-CCEKqkfW-CxNmb7UL.js"),__vite__mapDeps([116,1,16,17,6,8,5,117,18,19,20,7])));vt(()=>bt(()=>import("./MyBankConnectionsSettingsPage-B67G0-7Z-n6eVqpf_.js"),__vite__mapDeps([118,1,16,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./MyProfileSettingsPage-TqtGXk0G-LTkAmfNQ.js"),__vite__mapDeps([119,1,16,17,6,8,5,105,120,86,121,18,19,20,7])));vt(()=>bt(()=>import("./NotificationSettingsPage-Ct1wYM98-cHt-xjmV.js"),__vite__mapDeps([122,1,16,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./BusinessVerificationPage-D7btikKT-BPUDQBNI.js"),__vite__mapDeps([123,1,16,17,6,8,5,124,105,93,94,18,19,20,7])));vt(()=>bt(()=>import("./ReimbursementPromoPage-BxBAhFM1-BF6hJaxb.js"),__vite__mapDeps([125,1,16,17,6,8,5,112,47,89,18,19,20,7])));vt(()=>bt(()=>import("./ReimbursementSetUpPage-CP8WtKvQ-CigASL8Y.js"),__vite__mapDeps([126,1,16,17,6,8,5,114,18,19,20,7])));vt(()=>Promise.resolve().then(()=>Jsr));vt(()=>bt(()=>import("./BillDetailPage-DA1djKtd-CT6NN5ei.js"),__vite__mapDeps([127,1,16,17,6,8,5,109,18,19,20,7])));vt(()=>bt(()=>import("./InvoiceUploadSection-COIpUGEB-wLZvdMHG.js"),__vite__mapDeps([128,1,16,17,6,8,5,129,18,19,20,7,130])));vt(()=>bt(()=>import("./BillPayApprovalRulesPage-CZnYZ8cn-D3dv90TB.js"),__vite__mapDeps([131,16,1,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./BillPayApprovalRuleDetailPage-CLkMLaIk-DBi0iP3G.js"),__vite__mapDeps([132,1,16,17,6,8,5,133,18,19,20,7])));vt(()=>bt(()=>import("./ReimbursementApprovalRulesPage-CUQt2z6s-CacQtgTe.js"),__vite__mapDeps([134,16,1,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./ReimbursementApprovalRuleDetailPage-gUzCi41q-KVZqQggT.js"),__vite__mapDeps([135,1,16,17,6,8,5,133,18,19,20,7])));const iQr=vt(()=>Promise.resolve().then(()=>gFt));vt(()=>bt(()=>import("./EditReimbursementDetailPage-CC4JbXua-Dip_aVtM.js"),__vite__mapDeps([136,1,16,17,6,8,5,128,129,18,19,20,7,130,137,93,107,101,99,80])));vt(()=>bt(()=>import("./ReimbursementDetailPage-CgwRpLnh-BB4SRwDm.js"),__vite__mapDeps([138,1,16,17,6,8,5,128,129,18,19,20,7,130,137])));vt(()=>bt(()=>import("./InvitePeoplePage-DLPupvdi-DD0j_YWt.js"),__vite__mapDeps([139,1,16,17,6,8,5,140,120,86,121,18,19,20,7])));vt(()=>bt(()=>import("./CompleteProfile-CdVQdaB0-CLoHBDqw.js"),__vite__mapDeps([141,1,16,17,6,8,5,95,18,19,20,7])));vt(()=>bt(()=>import("./EditPeoplePage-D3GenIke-s4IX6oMr.js"),__vite__mapDeps([142,1,16,17,6,8,5,140,120,86,121,18,19,20,7])));const p8r=vt(()=>bt(()=>import("./AppBasePage-BBolfeYB-CAoueBdK.js"),__vite__mapDeps([143,16,1,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./SpendManagementListViewPage-jdvSYQ4J-C-TI7b_0.js"),__vite__mapDeps([144,5,1,6,16,17,8,145,146,18,19,20,7])));vt(()=>bt(()=>import("./VendorDetailPage-CG0SxxIa-DRDl0JtE.js"),__vite__mapDeps([147,1,16,17,6,8,5,148,51,52,53,77,78,29,34,35,18,19,20,7,62,60,39,40,105,149])));vt(()=>bt(()=>import("./VendorFiling1099EditablePage-DQs8RP_2-BUbnv_T9.js"),__vite__mapDeps([150,1,16,17,6,8,5,149,18,19,20,7])));vt(()=>bt(()=>import("./ZeniAccountListViewPage-BVGsjSB2-BZPNsiNG.js"),__vite__mapDeps([151,1,16,17,6,8,5,152,153,154,155,18,19,20,7])));vt(()=>bt(()=>import("./ZeniAccountDetailPage-CSVQF6vO-BffDIt1S.js"),__vite__mapDeps([156,1,16,17,6,8,5,52,53,157,158,154,18,19,20,7])));vt(()=>bt(()=>import("./AccountInfoPage-CDn5K_o2-641sWKgU.js"),__vite__mapDeps([159,1,16,17,6,8,5,146,160,157,53,18,19,20,7])));vt(()=>bt(()=>import("./TransferDrawerPage-LppLtT6A-9tQ3RVxi.js"),__vite__mapDeps([161,1,16,17,6,8,5,155,160,157,53,18,19,20,7])));vt(()=>bt(()=>import("./CreditCardPaymentDrawerPage-CWF47Q9G-lJ5s9KFG.js"),__vite__mapDeps([162,16,1,17,6,8,5,76,18,19,20,7])));vt(()=>bt(()=>import("./CheckDepositDrawerPage-Cy0NVgKc-D8fpunhe.js"),__vite__mapDeps([163,1,16,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./ZeniAccountPromoPage-s-QGT-pZ-4BJMfYD4.js"),__vite__mapDeps([164,1,16,17,6,8,5,89,18,19,20,7])));vt(()=>bt(()=>import("./ZeniAccountSetupPage-CqXokSq4-D67zlWge.js"),__vite__mapDeps([165,1,16,17,6,8,5,114,18,19,20,7])));vt(()=>bt(()=>import("./DepositAccTransactionListPage-C1EuUbFg-CI8oEH7-.js"),__vite__mapDeps([166,1,16,17,6,8,5,52,53,158,18,19,20,7])));vt(()=>bt(()=>import("./StatementsPage-Cw6GRd81-ChCacJhz.js"),__vite__mapDeps([167,1,16,17,6,8,5,52,53,168,157,18,19,20,7])));vt(()=>bt(()=>import("./TransactionVendorDetailPage-BqjeDf6Q-Dzq8RIOd.js"),__vite__mapDeps([169,1,16,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./CustomerOnboardingPage-DWmMR5Ke-C-0daaby.js"),__vite__mapDeps([170,1,16,17,6,8,5,171,117,172,124,105,93,94,173,81,18,19,20,7])));vt(()=>bt(()=>import("./CustomerOnboardingContainerPage-qmrLtjkH-BEltfCv2.js"),__vite__mapDeps([174,175,16,1,17,6,8,5,171,117,172,18,19,20,7,170,124,105,93,94,173,81])));vt(()=>bt(()=>import("./CustomerOnboardingNoStepsPage-CWvaI2vY-BkjuYe-o.js"),__vite__mapDeps([175,16,1,17,6,8,5,171,117,172,18,19,20,7])));vt(()=>bt(()=>import("./CustomerOnboardingProductSuitePage-CEOJEMdY-ntP-LOfn.js"),__vite__mapDeps([176,1,16,17,6,8,5,21,18,19,20,7,24])));vt(()=>bt(()=>import("./CustomerOnboardingActivationPage-DbaC9Uy1-BzvBGrNi.js"),__vite__mapDeps([177,1,16,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./BillingSettingsPage-CQngU3lq-DrWAQyUl.js"),__vite__mapDeps([178,1,16,17,6,8,5,171,117,18,19,20,7])));vt(()=>bt(()=>import("./UncategorizedAccountsMappingPage-f9xrtur3-C6VmI6RW.js"),__vite__mapDeps([179,1,16,17,6,8,5,180,18,19,20,7])));vt(()=>bt(()=>import("./IntegrationsSettingsPage-BEBtsJ8z-BJ7jcJB8.js"),__vite__mapDeps([181,16,1,17,6,8,5,173,81,18,19,20,7])));vt(()=>bt(()=>import("./UnitIntegrationPage-SiS8CA0g-CWR3OzFU.js"),__vite__mapDeps([182,1,16,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./MagicLinkACHDetailsPage-DtxKOlmX-C3DvZH5g.js"),__vite__mapDeps([183,98,1,16,17,6,8,5,99,100,101,18,19,20,7])));vt(()=>bt(()=>import("./MagicLinkDomesticWireDetailsPage-C7DsI3GD-DonhhvUC.js"),__vite__mapDeps([184,103,1,16,17,6,8,5,101,100,99,104,105,18,19,20,7])));vt(()=>bt(()=>import("./MagicLinkInternationalWireDetailsPage-BQtq93Cv-Cdv7ebZp.js"),__vite__mapDeps([185,186,1,16,17,6,8,5,99,104,105,100,18,19,20,7])));vt(()=>bt(()=>import("./AttachmentView-mC246Bpw-CT1OWA3c.js"),__vite__mapDeps([129,1,16,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./MagicLinkSuccessPage-BU8oXuny-C8cR1VFE.js"),__vite__mapDeps([187,16,1,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./Vendor2FAPopup-CYwD3yQ8-C90N1LpP.js"),__vite__mapDeps([188,1,17,6,8,5,16,18,19,20,7])));vt(()=>bt(()=>import("./AgingReportsPage-Cam_Ox67-DaZT71t6.js"),__vite__mapDeps([189,1,16,17,6,8,5,63,28,29,62,58,59,67,32,190,191,18,19,20,7])));vt(()=>bt(()=>import("./ApAgingDetailPage-uy2AK45a-JhYM22T9.js"),__vite__mapDeps([192,1,16,17,6,8,5,193,191,18,19,20,7])));vt(()=>bt(()=>import("./ArAgingDetailPage-DpdUPb6--BJoxfTPP.js"),__vite__mapDeps([194,1,16,17,6,8,5,193,191,18,19,20,7])));vt(()=>bt(()=>import("./OpExByVendorPage-B5dz3g_I-CwduKJys.js"),__vite__mapDeps([195,1,16,17,6,8,5,29,35,56,64,58,59,71,65,62,67,32,61,63,196,69,190,18,19,20,7])));vt(()=>bt(()=>import("./VendorInternationalWireSwiftDetailsPage-CBKqnkvK-Bir8wvug.js"),__vite__mapDeps([197,1,186,16,17,6,8,5,99,104,105,100,18,19,20,7])));vt(()=>bt(()=>import("./VendorFirstReviewPage-XaE6ddOQ-rVweCi-_.js"),__vite__mapDeps([198,1,16,17,6,8,5,85,18,19,20,7])));const aQr=vt(()=>bt(()=>import("./NewGlobalMerchantPage-BXM36kwh-Cd4H2AF3.js"),__vite__mapDeps([199,1,16,17,6,8,5,18,19,20,7]))),sQr=vt(()=>bt(()=>import("./GlobalReviewListPage-Ou4B6O28-Cj-vrRvJ.js"),__vite__mapDeps([200,1,16,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./ScheduleDetailsPage-Dcl5GREY-Ct_YcYBo.js"),__vite__mapDeps([201,1,16,17,6,8,5,202,18,19,20,7])));vt(()=>bt(()=>import("./ScheduleDetailsFixedAssetsPage-cVGyXDC1-BNedCqMx.js"),__vite__mapDeps([203,1,16,17,6,8,5,202,18,19,20,7])));vt(()=>bt(()=>import("./LinkJETransactionPage-NXVaaeQn-Dc1IDF_5.js"),__vite__mapDeps([204,1,16,17,6,8,5,75,76,77,78,29,34,35,18,19,20,7,62,60,39,51,52,53,79,80])));vt(()=>bt(()=>import("./ChargeCardPromoPage-xhEvT_sU-D7VUd9Kw.js"),__vite__mapDeps([205,1,16,17,6,8,5,39,46,89,18,19,20,7])));vt(()=>bt(()=>import("./ChargeCardSetupPage-Be89R3A7-BvY-IfNf.js"),__vite__mapDeps([206,1,16,17,6,8,5,76,114,18,19,20,7])));vt(()=>bt(()=>import("./ChargeCardListPage-CTG6bNbA-DN4yg5h2.js"),__vite__mapDeps([207,1,16,17,6,8,5,145,208,85,86,209,205,39,46,89,18,19,20,7,210,45,40])));vt(()=>bt(()=>import("./MyPendingActivationChargeCardListPage-Cbap6Vpr-CSFLEHXK.js"),__vite__mapDeps([211,16,1,17,6,8,5,208,85,86,209,18,19,20,7])));vt(()=>bt(()=>import("./ChargeCardDetailPage-BYNjlLQX-smovJQ3p.js"),__vite__mapDeps([212,1,16,17,6,8,5,39,213,18,209,130,210,86,19,20,7])));vt(()=>bt(()=>import("./CashbackDetailPage-ToN5ueBt-BpzeYowT.js"),__vite__mapDeps([214,16,1,17,6,8,5,60,39,18,19,20,7])));vt(()=>bt(()=>import("./ChargeCardStatementsPage-CFNCOiLr-DDhNhCxi.js"),__vite__mapDeps([215,16,1,17,6,8,5,52,53,157,18,19,20,7])));vt(()=>bt(()=>import("./IssueChargeCardPage-6LWMwuaq-BfBIAKq3.js"),__vite__mapDeps([216,1,16,17,6,8,5,120,86,18,19,20,7])));vt(()=>bt(()=>import("./AddToWalletPage-Bc0GY8mw-CwBrjgnk.js"),__vite__mapDeps([217,1,16,17,6,8,5,213,18,19,20,7])));vt(()=>bt(()=>import("./AddAddressForCardDrawer-CZ9kZK-_-7zBs11LO.js"),__vite__mapDeps([218,1,16,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./TaskManagementPage-C3M_HCXR-DTuYPwo5.js"),__vite__mapDeps([219,1,16,17,6,8,5,145,220,144,146,18,19,20,7])));vt(()=>bt(()=>Promise.resolve().then(()=>jwr),void 0).then(e=>e.m));vt(()=>bt(()=>import("./InvitePageListView-B0aN2fz0-C_ebzQNV.js"),__vite__mapDeps([221,1,16,17,6,8,5,43,18,19,20,7])));vt(()=>bt(()=>import("./InviteFormPage-CHZVhrof-Ctwgv0tR.js"),__vite__mapDeps([222,1,16,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./DrawerPage-gsfboWa--D8_bnW1E.js"),__vite__mapDeps([223,16,1,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./NotificationsPage-C8PlG40Q-CVuSfSFc.js"),__vite__mapDeps([224,1,16,17,6,8,5,148,225,220,18,19,20,7])));vt(()=>bt(()=>import("./FeaturePreviewPage-Us5W5Wo9-CTfS268U.js"),__vite__mapDeps([226,16,1,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./BillsBulkReviewDrawerPage-DlAOz-SY-hKyZsi63.js"),__vite__mapDeps([227,1,5,6,228,16,17,8,18,19,20,7])));vt(()=>bt(()=>import("./ReimbursementsBulkReviewDrawerPage-Ir7LV3Qg-Dnq7FHvk.js"),__vite__mapDeps([229,1,5,6,228,16,17,8,18,19,20,7])));vt(()=>bt(()=>import("./ExpenseAutomationOverviewPage-CtBVIXza-8HVAkTgZ.js"),__vite__mapDeps([230,1,16,17,6,8,5,231,18,19,20,7])));vt(()=>bt(()=>import("./AIPerformancePage-9OxanlvK-Bk_qTUs7.js"),__vite__mapDeps([232,1,16,17,6,8,5,88,18,19,20,7])));vt(()=>bt(()=>import("./ExpenseAutomationPage-BByZfMUo-Bp9htN-p.js"),__vite__mapDeps([233,1,16,17,6,8,5,58,59,196,69,180,79,18,19,20,7])));vt(()=>bt(()=>import("./AccountReconDetailsDrawerPage-CyQ13mJl-CAv47_Mb.js"),__vite__mapDeps([234,1,16,17,6,8,5,59,18,19,20,7])));vt(()=>bt(()=>import("./InternationalWireVerificationPage-CGLyTJOX-CNAH8NOm.js"),__vite__mapDeps([235,1,16,17,6,8,5,94,18,19,20,7])));vt(()=>bt(()=>import("./ExpressPayPage-Dx4Cc9w2-5nFukiXm.js"),__vite__mapDeps([236,1,16,17,6,8,5,94,110,18,19,20,7])));vt(()=>bt(()=>import("./TreasuryPromoPage--MgysW-J-BnZiQCLe.js"),__vite__mapDeps([237,1,16,17,6,8,5,47,152,153,18,19,20,7])));vt(()=>Promise.resolve().then(()=>u8r));vt(()=>Promise.resolve().then(()=>J9r));vt(()=>Promise.resolve().then(()=>o6r));vt(()=>bt(()=>import("./TreasuryOverviewPage-DNoQLXPn-DtJgqzkX.js"),__vite__mapDeps([238,1,16,17,6,8,5,53,52,231,153,18,19,20,7])));vt(()=>bt(()=>import("./TreasuryStatementsPage-DRPB8HzF-D1pupcJw.js"),__vite__mapDeps([239,1,16,17,6,8,5,52,53,168,157,18,19,20,7])));vt(()=>bt(()=>import("./TreasuryTaxLetterPage-BeeNFRtm-BSH1fBvD.js"),__vite__mapDeps([240,1,16,17,6,8,5,52,53,168,157,18,19,20,7])));const h8r=e=>b.createElement("svg",{viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},b.createElement("rect",{x:3.16187,y:4.9248,width:16,height:16,rx:2,stroke:"currentColor",strokeWidth:1.5}),b.createElement("path",{d:"M9.75 1.9248H18.1619C20.371 1.9248 22.1619 3.71567 22.1619 5.9248V15",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round"}),b.createElement("path",{d:"M15.4644 10.7257L10.4607 15.494C10.3977 15.5542 10.3231 15.6009 10.2415 15.6314C10.1598 15.6619 10.0728 15.6754 9.98577 15.6712C9.8999 15.6671 9.81573 15.6459 9.73823 15.6087C9.66073 15.5715 9.59148 15.5191 9.53459 15.4546L7.2569 12.8672",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"})),m8r=e=>b.createElement("svg",{viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},b.createElement("path",{d:"M1.40002 7H22.5756",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),b.createElement("path",{d:"M8.065 17.29H15.9105",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),b.createElement("path",{d:"M4.26514 12.1444H19.7104",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"})),f8r=_R(new Date().getFullYear(),0),g8r=[...Array(12)].map((e,t)=>f8r.add(t,"month").format(ce.getLocalizedStrings().dateFormat.visual.MMMMFormat)),E9e=()=>Ft().subtract(1,"quarter").endOf("quarter"),_9e=()=>Ft().subtract(1,"month").endOf("month"),lQr=({options:e,selectedDate:t})=>{const r=ce.getLocalizedStrings().dateFormat.analytics.MMSlashDDSlashYYYYFormat;return e.find(n=>n.value==="month"?t.format(r)===_9e().format(r):n.value==="quarter"?t.format(r)===E9e().format(r):!1)?.value},y8r=e=>e==="month"?_9e():E9e(),T9e=e=>g8r.findIndex(t=>t===e)+1,v8r=m(q4e)`
21487
+ `,k9e=e=>`${e}_form`,u8r=Object.freeze(Object.defineProperty({__proto__:null,default:i8r,trackTreasuryTransferAnalytics:Wy,uniqueName:k9e},Symbol.toStringTag,{value:"Module"}));vt(()=>Promise.resolve().then(()=>AIt));const tQr=vt(()=>bt(()=>import("./OverlayContainerPage-Daz3A7cI-BG61qzjJ.js"),__vite__mapDeps([15,16,1,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./ConfettiBurst-1rYKpbAj-DHWZb_DF.js"),__vite__mapDeps([21,1,17,6,8,5,16,18,19,20,7])));vt(()=>Promise.resolve().then(()=>dUt));const rQr=vt(()=>bt(()=>import("./SignIn-DQBJB5ad-yHNBe1dm.js"),__vite__mapDeps([22,1,16,17,6,8,5,23,24,25,18,19,20,7])));vt(()=>bt(()=>import("./Dashboard-_o0Ftdv8-B4FMEqu7.js"),__vite__mapDeps([26,1,16,17,6,8,5,27,28,29,30,31,32,33,34,35,36,37,38,39,40,18,19,20,7,41,42,43,44,45,46,47,21])));vt(()=>bt(()=>import("./AppDrawerContent-DM1t0oLS-DX8gDdRy.js"),__vite__mapDeps([48,1,16,17,6,8,5,27,18,19,20,7])));vt(()=>bt(()=>import("./TransactionListBig-D_Jw9Ip2-Bz8jw08Q.js"),__vite__mapDeps([49,1,16,17,6,8,5,41,37,30,38,39,18,19,20,7])));vt(()=>bt(()=>import("./TransactionListPage-B2yWm7eA-DCySOEer.js"),__vite__mapDeps([50,1,16,17,6,8,5,51,52,53,54,18,19,20,7])));vt(()=>bt(()=>import("./DashboardReportPage-Cu5wqWkj-BjOABFkU.js"),__vite__mapDeps([55,1,16,17,6,8,5,56,57,58,59,60,39,61,33,29,34,35,62,63,64,65,66,67,32,68,69,18,19,20,7])));vt(()=>bt(()=>import("./ReportsPage-h2DAaQfK-Dj7aDDw4.js"),__vite__mapDeps([70,1,16,17,6,8,5,56,57,58,59,64,71,65,72,54,18,19,20,7,66,73,68,69])));vt(()=>bt(()=>import("./TopExDetailPage-BsCwwwDi-CdmjqJ_1.js"),__vite__mapDeps([74,16,1,17,6,8,5,31,30,32,65,67,18,19,20,7])));vt(()=>bt(()=>import("./TransactionDetailPage-rpCG65yC-CLh205i5.js"),__vite__mapDeps([75,1,16,17,6,8,5,76,77,78,29,34,35,18,19,20,7,62,60,39,51,52,53,79,80])));vt(()=>bt(()=>import("./QBOConnectionDialog-BFy0lMZd-D5AhMSo8.js"),__vite__mapDeps([81,16,1,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./VerifyDevice-BHocExfO-CXvB8GAp.js"),__vite__mapDeps([82,1,16,17,6,8,5,83,25,18,19,20,7])));vt(()=>bt(()=>import("./AccountLockedInfoModal-CEk5d9hq-BU7zCzNG.js"),__vite__mapDeps([83,16,1,17,6,8,5,25,18,19,20,7])).then(e=>e.a));vt(()=>bt(()=>import("./InsightsCardStack-BBczCYEz-CM9k6Dqk.js"),__vite__mapDeps([36,1,37,30,16,17,6,8,5,38,39,40,18,19,20,7])));vt(()=>bt(()=>import("./InformationCardStack-DnB7TmOk-BJQfDBIj.js"),__vite__mapDeps([44,1,37,30,16,17,6,8,5,38,39,18,19,20,7])));vt(()=>bt(()=>import("./DownloadOverlay-c57lEf_V-BH-A5hnp.js"),__vite__mapDeps([72,1,16,17,6,8,5,56,57,58,59,54,18,19,20,7])));vt(()=>bt(()=>import("./PeoplePage-DN5VtG7Q-CKG_6p7l.js"),__vite__mapDeps([84,1,16,17,6,8,5,85,86,18,19,20,7])));vt(()=>bt(()=>import("./PandLWithForecastPage-Bu49FbWD-DV8somvz.js"),__vite__mapDeps([87,1,16,17,6,8,5,88,56,71,65,58,59,89,66,73,18,19,20,7])));vt(()=>bt(()=>import("./TrendChart-BI4Tz813-BMzjSOb0.js"),__vite__mapDeps([78,1,5,6,29,16,17,8,34,35,18,19,20,7])));vt(()=>bt(()=>import("./EntityDetailPage-DbTiF9Hs-DOWN_WQU.js"),__vite__mapDeps([90,16,1,17,6,8,5,77,78,29,34,35,18,19,20,7,62,60,39,51,52,53])));const nQr=vt(()=>bt(()=>import("./NotFoundPage-BEya4LS2-BrCuBa4j.js"),__vite__mapDeps([91,16,1,17,6,8,5,23,18,19,20,7]))),oQr=vt(()=>Promise.resolve().then(()=>zYt));vt(()=>bt(()=>import("./CompanyPassportCard-BOxM716U-DxvRrHgL.js"),__vite__mapDeps([42,16,1,17,6,8,5,37,30,18,19,20,7])));vt(()=>bt(()=>import("./CompanyPassportPage-DzE7sm8S-ZZY5euQN.js"),__vite__mapDeps([92,1,16,17,6,8,5,93,94,95,18,19,20,7])));vt(()=>bt(()=>import("./CreateOrEditVendorPage-WQeDCj-E-ZLNX3FBX.js"),__vite__mapDeps([96,1,16,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./VendorACHDetailsPage-DMMoCytX-D-f3jOPl.js"),__vite__mapDeps([97,1,98,16,17,6,8,5,99,100,101,18,19,20,7])));vt(()=>bt(()=>import("./VendorDomesticWireDetailsPage-WxmpwlTS-CXFWxa5o.js"),__vite__mapDeps([102,1,103,16,17,6,8,5,101,100,99,104,105,18,19,20,7])));vt(()=>bt(()=>import("./VendorInternationalWireDetailsPage-CzPRK4E2-DP27a23P.js"),__vite__mapDeps([106,1,16,17,6,8,5,99,104,105,107,18,19,20,7])));vt(()=>bt(()=>import("./ReviewDetailsPage-BiYxRnvA-cVXSS1nN.js"),__vite__mapDeps([108,1,16,17,6,8,5,109,110,18,19,20,7])));vt(()=>bt(()=>import("./BillPayPromoPage-aGKOv8Ur-59DxEGOU.js"),__vite__mapDeps([111,1,16,17,6,8,5,112,47,89,18,19,20,7])));vt(()=>bt(()=>import("./BillPaySetUpPage-DRCjyEfB-CkG4ce3e.js"),__vite__mapDeps([113,1,16,17,6,8,5,114,18,19,20,7])));vt(()=>bt(()=>import("./ApprovalRulesSettingsPage-GZCo6_i2-ClrA48La.js"),__vite__mapDeps([115,16,1,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./BankConnectionsSettingsPage-BpwKq93l-yFMdYswL.js"),__vite__mapDeps([116,1,16,17,6,8,5,117,18,19,20,7])));vt(()=>bt(()=>import("./MyBankConnectionsSettingsPage-Dn9AT8p1-BbviCBBU.js"),__vite__mapDeps([118,1,16,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./MyProfileSettingsPage-CBvjEd7r-B3f0C00b.js"),__vite__mapDeps([119,1,16,17,6,8,5,105,120,86,121,18,19,20,7])));vt(()=>bt(()=>import("./NotificationSettingsPage-C9SjRKCu-Du1Cf4y_.js"),__vite__mapDeps([122,1,16,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./BusinessVerificationPage-CbqJIVpz-BiQu25FO.js"),__vite__mapDeps([123,1,16,17,6,8,5,124,105,93,94,18,19,20,7])));vt(()=>bt(()=>import("./ReimbursementPromoPage-MweW-4DO-BO5Os0EF.js"),__vite__mapDeps([125,1,16,17,6,8,5,112,47,89,18,19,20,7])));vt(()=>bt(()=>import("./ReimbursementSetUpPage-BD2LWlbW-YI084Mlh.js"),__vite__mapDeps([126,1,16,17,6,8,5,114,18,19,20,7])));vt(()=>Promise.resolve().then(()=>Jsr));vt(()=>bt(()=>import("./BillDetailPage-BG7FhHEq-CI73yv-V.js"),__vite__mapDeps([127,1,16,17,6,8,5,109,18,19,20,7])));vt(()=>bt(()=>import("./InvoiceUploadSection-DPd4VmqZ-BLpPijn4.js"),__vite__mapDeps([128,1,16,17,6,8,5,129,18,19,20,7,130])));vt(()=>bt(()=>import("./BillPayApprovalRulesPage-DiCNUU-G-CN0GV9DL.js"),__vite__mapDeps([131,16,1,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./BillPayApprovalRuleDetailPage-BAK1Gfko-DXu3RSd8.js"),__vite__mapDeps([132,1,16,17,6,8,5,133,18,19,20,7])));vt(()=>bt(()=>import("./ReimbursementApprovalRulesPage-D5ZMrrmO-CIYzhtUg.js"),__vite__mapDeps([134,16,1,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./ReimbursementApprovalRuleDetailPage-0o5lDuM2-Cr0TZK-s.js"),__vite__mapDeps([135,1,16,17,6,8,5,133,18,19,20,7])));const iQr=vt(()=>Promise.resolve().then(()=>gFt));vt(()=>bt(()=>import("./EditReimbursementDetailPage-Bt7XKq5h-BcSPiJVn.js"),__vite__mapDeps([136,1,16,17,6,8,5,128,129,18,19,20,7,130,137,93,107,101,99,80])));vt(()=>bt(()=>import("./ReimbursementDetailPage-DatcF8rt-B5PSoIBr.js"),__vite__mapDeps([138,1,16,17,6,8,5,128,129,18,19,20,7,130,137])));vt(()=>bt(()=>import("./InvitePeoplePage-DrBtwpMH-D70ug1bL.js"),__vite__mapDeps([139,1,16,17,6,8,5,140,120,86,121,18,19,20,7])));vt(()=>bt(()=>import("./CompleteProfile-BjGSPASa-Bfp0I59Q.js"),__vite__mapDeps([141,1,16,17,6,8,5,95,18,19,20,7])));vt(()=>bt(()=>import("./EditPeoplePage-DJthuIP4-Ccr8TbIs.js"),__vite__mapDeps([142,1,16,17,6,8,5,140,120,86,121,18,19,20,7])));const p8r=vt(()=>bt(()=>import("./AppBasePage-DoCF494Z-BPFvSn_P.js"),__vite__mapDeps([143,16,1,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./SpendManagementListViewPage-Ac-9u-X2-ConJ7IhF.js"),__vite__mapDeps([144,5,1,6,16,17,8,145,146,18,19,20,7])));vt(()=>bt(()=>import("./VendorDetailPage-CLFKkF8I-DlccPRJ1.js"),__vite__mapDeps([147,1,16,17,6,8,5,148,51,52,53,77,78,29,34,35,18,19,20,7,62,60,39,40,105,149])));vt(()=>bt(()=>import("./VendorFiling1099EditablePage-CrWrhHZl-MLHVoFXe.js"),__vite__mapDeps([150,1,16,17,6,8,5,149,18,19,20,7])));vt(()=>bt(()=>import("./ZeniAccountListViewPage-Cxid0mfh-Bo45T4Gx.js"),__vite__mapDeps([151,1,16,17,6,8,5,152,153,154,155,18,19,20,7])));vt(()=>bt(()=>import("./ZeniAccountDetailPage-ZZ3Ra-Jf-_49Q_UUx.js"),__vite__mapDeps([156,1,16,17,6,8,5,52,53,157,158,154,18,19,20,7])));vt(()=>bt(()=>import("./AccountInfoPage-Ca_vKG58-pmVk2hiY.js"),__vite__mapDeps([159,1,16,17,6,8,5,146,160,157,53,18,19,20,7])));vt(()=>bt(()=>import("./TransferDrawerPage-BnEVH7Mc-C6QWMjAo.js"),__vite__mapDeps([161,1,16,17,6,8,5,155,160,157,53,18,19,20,7])));vt(()=>bt(()=>import("./CreditCardPaymentDrawerPage-Q12y6HMX-CRUPlZFr.js"),__vite__mapDeps([162,16,1,17,6,8,5,76,18,19,20,7])));vt(()=>bt(()=>import("./CheckDepositDrawerPage-ClxKj2js-BOLtAKO1.js"),__vite__mapDeps([163,1,16,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./ZeniAccountPromoPage-YIYFkPIB-YhnencbA.js"),__vite__mapDeps([164,1,16,17,6,8,5,89,18,19,20,7])));vt(()=>bt(()=>import("./ZeniAccountSetupPage-BJ9UJ0dP-yNigxq0M.js"),__vite__mapDeps([165,1,16,17,6,8,5,114,18,19,20,7])));vt(()=>bt(()=>import("./DepositAccTransactionListPage-oj9tntbI-CMORNmGB.js"),__vite__mapDeps([166,1,16,17,6,8,5,52,53,158,18,19,20,7])));vt(()=>bt(()=>import("./StatementsPage-DVR5LhTi-ldyTOd7O.js"),__vite__mapDeps([167,1,16,17,6,8,5,52,53,168,157,18,19,20,7])));vt(()=>bt(()=>import("./TransactionVendorDetailPage-Dr5C4-7q-BPGPWJM6.js"),__vite__mapDeps([169,1,16,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./CustomerOnboardingPage-CvN9Jrdy-BbxW7een.js"),__vite__mapDeps([170,1,16,17,6,8,5,171,117,172,124,105,93,94,173,81,18,19,20,7])));vt(()=>bt(()=>import("./CustomerOnboardingContainerPage-C9radmIS-D7esgWyy.js"),__vite__mapDeps([174,175,16,1,17,6,8,5,171,117,172,18,19,20,7,170,124,105,93,94,173,81])));vt(()=>bt(()=>import("./CustomerOnboardingNoStepsPage-CNni6chX-DEHNST6I.js"),__vite__mapDeps([175,16,1,17,6,8,5,171,117,172,18,19,20,7])));vt(()=>bt(()=>import("./CustomerOnboardingProductSuitePage-CZkX9ur7-CVf3ueoc.js"),__vite__mapDeps([176,1,16,17,6,8,5,21,18,19,20,7,24])));vt(()=>bt(()=>import("./CustomerOnboardingActivationPage-BJhw-PvI-DfxjHeaa.js"),__vite__mapDeps([177,1,16,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./BillingSettingsPage-CdYb74V7-D26O7kQD.js"),__vite__mapDeps([178,1,16,17,6,8,5,171,117,18,19,20,7])));vt(()=>bt(()=>import("./UncategorizedAccountsMappingPage-sbn4Sdr2-CCtQxv0E.js"),__vite__mapDeps([179,1,16,17,6,8,5,180,18,19,20,7])));vt(()=>bt(()=>import("./IntegrationsSettingsPage-CByj2tO4-zF-3f5Vb.js"),__vite__mapDeps([181,16,1,17,6,8,5,173,81,18,19,20,7])));vt(()=>bt(()=>import("./UnitIntegrationPage-CZUyjeh5-DYAwrSQY.js"),__vite__mapDeps([182,1,16,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./MagicLinkACHDetailsPage-Cpde2XoD-JoGWlKNi.js"),__vite__mapDeps([183,98,1,16,17,6,8,5,99,100,101,18,19,20,7])));vt(()=>bt(()=>import("./MagicLinkDomesticWireDetailsPage-DQYH52_8-Clx_7zaI.js"),__vite__mapDeps([184,103,1,16,17,6,8,5,101,100,99,104,105,18,19,20,7])));vt(()=>bt(()=>import("./MagicLinkInternationalWireDetailsPage-DwBUSxwe-x_28I9nn.js"),__vite__mapDeps([185,186,1,16,17,6,8,5,99,104,105,100,18,19,20,7])));vt(()=>bt(()=>import("./AttachmentView-B0d42oAf-CFenLcCO.js"),__vite__mapDeps([129,1,16,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./MagicLinkSuccessPage-DbhdGmhh-DNYzgAJU.js"),__vite__mapDeps([187,16,1,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./Vendor2FAPopup-C_PmEAQ7-BaU4ZlJ1.js"),__vite__mapDeps([188,1,17,6,8,5,16,18,19,20,7])));vt(()=>bt(()=>import("./AgingReportsPage-n-UKn3Ei-CfeYGvlE.js"),__vite__mapDeps([189,1,16,17,6,8,5,63,28,29,62,58,59,67,32,190,191,18,19,20,7])));vt(()=>bt(()=>import("./ApAgingDetailPage-Duu2uAEr-CuSndO2U.js"),__vite__mapDeps([192,1,16,17,6,8,5,193,191,18,19,20,7])));vt(()=>bt(()=>import("./ArAgingDetailPage-CaOr6vAU-Dju9MqE9.js"),__vite__mapDeps([194,1,16,17,6,8,5,193,191,18,19,20,7])));vt(()=>bt(()=>import("./OpExByVendorPage-Dxk68R6U-TSpF0BZT.js"),__vite__mapDeps([195,1,16,17,6,8,5,29,35,56,64,58,59,71,65,62,67,32,61,63,196,69,190,18,19,20,7])));vt(()=>bt(()=>import("./VendorInternationalWireSwiftDetailsPage-BBYmlLxN-CGwvkONg.js"),__vite__mapDeps([197,1,186,16,17,6,8,5,99,104,105,100,18,19,20,7])));vt(()=>bt(()=>import("./VendorFirstReviewPage-C6MnbIan-CvuNZRdM.js"),__vite__mapDeps([198,1,16,17,6,8,5,85,18,19,20,7])));const aQr=vt(()=>bt(()=>import("./NewGlobalMerchantPage-B_019EtP-Cnin4QvT.js"),__vite__mapDeps([199,1,16,17,6,8,5,18,19,20,7]))),sQr=vt(()=>bt(()=>import("./GlobalReviewListPage-9V-xoqvs-O56nx8QU.js"),__vite__mapDeps([200,1,16,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./ScheduleDetailsPage-DebosLND-CytjKLyD.js"),__vite__mapDeps([201,1,16,17,6,8,5,202,18,19,20,7])));vt(()=>bt(()=>import("./ScheduleDetailsFixedAssetsPage-DlXqz1QQ-CI8b87nD.js"),__vite__mapDeps([203,1,16,17,6,8,5,202,18,19,20,7])));vt(()=>bt(()=>import("./LinkJETransactionPage-C0onrP5t-DohOtG77.js"),__vite__mapDeps([204,1,16,17,6,8,5,75,76,77,78,29,34,35,18,19,20,7,62,60,39,51,52,53,79,80])));vt(()=>bt(()=>import("./ChargeCardPromoPage-BwqrXrY--B5or9kQv.js"),__vite__mapDeps([205,1,16,17,6,8,5,39,46,89,18,19,20,7])));vt(()=>bt(()=>import("./ChargeCardSetupPage-DRzB7Rt4-SAR76aeK.js"),__vite__mapDeps([206,1,16,17,6,8,5,76,114,18,19,20,7])));vt(()=>bt(()=>import("./ChargeCardListPage-130ILwkr-xWvWRUI-.js"),__vite__mapDeps([207,1,16,17,6,8,5,145,208,85,86,209,205,39,46,89,18,19,20,7,210,45,40])));vt(()=>bt(()=>import("./MyPendingActivationChargeCardListPage-DrQu6s7j-DI8j4Roq.js"),__vite__mapDeps([211,16,1,17,6,8,5,208,85,86,209,18,19,20,7])));vt(()=>bt(()=>import("./ChargeCardDetailPage-BQnJsfn5-D6Qm3_DY.js"),__vite__mapDeps([212,1,16,17,6,8,5,39,213,18,209,130,210,86,19,20,7])));vt(()=>bt(()=>import("./CashbackDetailPage-D-kXy6LW-DDN4yxLo.js"),__vite__mapDeps([214,16,1,17,6,8,5,60,39,18,19,20,7])));vt(()=>bt(()=>import("./ChargeCardStatementsPage-C3NxKjmB-Bqdh-I41.js"),__vite__mapDeps([215,16,1,17,6,8,5,52,53,157,18,19,20,7])));vt(()=>bt(()=>import("./IssueChargeCardPage-xbfFhV0O-D87TKikm.js"),__vite__mapDeps([216,1,16,17,6,8,5,120,86,18,19,20,7])));vt(()=>bt(()=>import("./AddToWalletPage-OJBvAKUj-CKSRCSe6.js"),__vite__mapDeps([217,1,16,17,6,8,5,213,18,19,20,7])));vt(()=>bt(()=>import("./AddAddressForCardDrawer-DfOyebHX-BnGN6mbi.js"),__vite__mapDeps([218,1,16,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./TaskManagementPage-CVXMOPf2-q63kh_yR.js"),__vite__mapDeps([219,1,16,17,6,8,5,145,220,144,146,18,19,20,7])));vt(()=>bt(()=>Promise.resolve().then(()=>jwr),void 0).then(e=>e.m));vt(()=>bt(()=>import("./InvitePageListView-HfsehyxK-ADhebkRn.js"),__vite__mapDeps([221,1,16,17,6,8,5,43,18,19,20,7])));vt(()=>bt(()=>import("./InviteFormPage-XsnZcAvb-F0roB33R.js"),__vite__mapDeps([222,1,16,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./DrawerPage-inbhWwND-BaLC0Hdr.js"),__vite__mapDeps([223,16,1,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./NotificationsPage-FJHx_WBG-TAfeF35H.js"),__vite__mapDeps([224,1,16,17,6,8,5,148,225,220,18,19,20,7])));vt(()=>bt(()=>import("./FeaturePreviewPage-qsUO3mUu-CQPzEAZz.js"),__vite__mapDeps([226,16,1,17,6,8,5,18,19,20,7])));vt(()=>bt(()=>import("./BillsBulkReviewDrawerPage-D8EGfY5P-BpW4NDmq.js"),__vite__mapDeps([227,1,5,6,228,16,17,8,18,19,20,7])));vt(()=>bt(()=>import("./ReimbursementsBulkReviewDrawerPage-DV_PLm_g-CdjeW3Za.js"),__vite__mapDeps([229,1,5,6,228,16,17,8,18,19,20,7])));vt(()=>bt(()=>import("./ExpenseAutomationOverviewPage-QZT_UFXf-Q6Yezq8W.js"),__vite__mapDeps([230,1,16,17,6,8,5,231,18,19,20,7])));vt(()=>bt(()=>import("./AIPerformancePage-4v4Fkm9f-BqYLGo1s.js"),__vite__mapDeps([232,1,16,17,6,8,5,88,18,19,20,7])));vt(()=>bt(()=>import("./ExpenseAutomationPage-Y7V_Z8rd-Nz-tHH0P.js"),__vite__mapDeps([233,1,16,17,6,8,5,58,59,196,69,180,79,18,19,20,7])));vt(()=>bt(()=>import("./AccountReconDetailsDrawerPage-DYKjrPwN-BReGAKzb.js"),__vite__mapDeps([234,1,16,17,6,8,5,59,18,19,20,7])));vt(()=>bt(()=>import("./InternationalWireVerificationPage-kIajgPZt-Cim3HMUE.js"),__vite__mapDeps([235,1,16,17,6,8,5,94,18,19,20,7])));vt(()=>bt(()=>import("./ExpressPayPage-CIp_R6ZQ-SvQXytoV.js"),__vite__mapDeps([236,1,16,17,6,8,5,94,110,18,19,20,7])));vt(()=>bt(()=>import("./TreasuryPromoPage-C6D3bF2f-xmypxDfH.js"),__vite__mapDeps([237,1,16,17,6,8,5,47,152,153,18,19,20,7])));vt(()=>Promise.resolve().then(()=>u8r));vt(()=>Promise.resolve().then(()=>J9r));vt(()=>Promise.resolve().then(()=>o6r));vt(()=>bt(()=>import("./TreasuryOverviewPage-C927Rdkg-PWkTzy8N.js"),__vite__mapDeps([238,1,16,17,6,8,5,53,52,231,153,18,19,20,7])));vt(()=>bt(()=>import("./TreasuryStatementsPage-BE54gWl6-BusQnftI.js"),__vite__mapDeps([239,1,16,17,6,8,5,52,53,168,157,18,19,20,7])));vt(()=>bt(()=>import("./TreasuryTaxLetterPage-BaHut8Wc-DaO1lvfz.js"),__vite__mapDeps([240,1,16,17,6,8,5,52,53,168,157,18,19,20,7])));const h8r=e=>b.createElement("svg",{viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},b.createElement("rect",{x:3.16187,y:4.9248,width:16,height:16,rx:2,stroke:"currentColor",strokeWidth:1.5}),b.createElement("path",{d:"M9.75 1.9248H18.1619C20.371 1.9248 22.1619 3.71567 22.1619 5.9248V15",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round"}),b.createElement("path",{d:"M15.4644 10.7257L10.4607 15.494C10.3977 15.5542 10.3231 15.6009 10.2415 15.6314C10.1598 15.6619 10.0728 15.6754 9.98577 15.6712C9.8999 15.6671 9.81573 15.6459 9.73823 15.6087C9.66073 15.5715 9.59148 15.5191 9.53459 15.4546L7.2569 12.8672",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"})),m8r=e=>b.createElement("svg",{viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},b.createElement("path",{d:"M1.40002 7H22.5756",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),b.createElement("path",{d:"M8.065 17.29H15.9105",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),b.createElement("path",{d:"M4.26514 12.1444H19.7104",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"})),f8r=_R(new Date().getFullYear(),0),g8r=[...Array(12)].map((e,t)=>f8r.add(t,"month").format(ce.getLocalizedStrings().dateFormat.visual.MMMMFormat)),E9e=()=>Ft().subtract(1,"quarter").endOf("quarter"),_9e=()=>Ft().subtract(1,"month").endOf("month"),lQr=({options:e,selectedDate:t})=>{const r=ce.getLocalizedStrings().dateFormat.analytics.MMSlashDDSlashYYYYFormat;return e.find(n=>n.value==="month"?t.format(r)===_9e().format(r):n.value==="quarter"?t.format(r)===E9e().format(r):!1)?.value},y8r=e=>e==="month"?_9e():E9e(),T9e=e=>g8r.findIndex(t=>t===e)+1,v8r=m(q4e)`
21488
21488
  border: none;
21489
21489
  background-color: ${e=>e.theme.colors.grey5};
21490
21490
  width: 105px;
@@ -29375,7 +29375,7 @@ ${e}`,WAr=e=>b.createElement("svg",{width:38,height:39,viewBox:"0 0 38 39",fill:
29375
29375
  &:hover {
29376
29376
  color: ${e=>e.theme.colors.primary};
29377
29377
  }
29378
- `,LQr=vt(()=>bt(()=>import("./WarningsDrawerPage-BS-TFvBs-DNJve9qV.js"),__vite__mapDeps([241,16,1,17,6,8,5,18,19,20,7])));var XUr=Lbe();const c7=aw(XUr);class QUr{getSignedInUser(){const t=window.localStorage.getItem(this.ZENI_SESSION_ID),r=window.localStorage.getItem(this.ZENI_SIGNED_IN_USER);if(r!=null&&t!=null)return JSON.parse(this.decrypt(r,t))}getShowNegativeAmountInParenthesis(){const t=window.localStorage.getItem(this.ZENI_SHOW_NEGATIVE_AMOUNT_IN_PARENTHESIS),r=window.localStorage.getItem(this.ZENI_SESSION_ID);return t!=null&&r!=null?JSON.parse(this.decrypt(t,r)):!1}getShowNegativeAmountInParenthesisPDF(){const t=window.localStorage.getItem(this.ZENI_SHOW_NEGATIVE_AMOUNT_IN_PARENTHESIS_PDF),r=window.localStorage.getItem(this.ZENI_SESSION_ID);return t!=null&&r!=null?JSON.parse(this.decrypt(t,r)):!0}getSignedInUserTenant(t){const r=window.localStorage.getItem(this.ZENI_SIGNED_IN_USER_TENANTS),n=window.localStorage.getItem(this.ZENI_SESSION_ID);if(r!=null&&n!=null)return JSON.parse(this.decrypt(r,n)).find(i=>i.tenantEmailDomain===t)}getSignedInUserTenantWithId(t){const r=window.localStorage.getItem(this.ZENI_SIGNED_IN_USER_TENANTS),n=window.localStorage.getItem(this.ZENI_SESSION_ID);if(r!=null&&n!=null)return JSON.parse(this.decrypt(r,n)).find(i=>i.tenantId===t)}getForceRefreshedComponents(){const t=window.localStorage.getItem(this.ZENI_SESSION_ID),r=window.localStorage.getItem(this.ZENI_FORCE_REFRESHED_COMPONENTS);if(r&&t!=null){const n=this.decrypt(r,t);return n?JSON.parse(n):[]}return[]}saveForceRefreshedComponents(t){const r=window.localStorage.getItem(this.ZENI_SESSION_ID);r!=null?window.localStorage.setItem(this.ZENI_FORCE_REFRESHED_COMPONENTS,this.encrypt(JSON.stringify(t),r)):console.warn("Can't update the force refreshed components when the user is logged out!")}saveSignedInUserWithSession(t,r){if(t==null||r==null)throw new Error("Can't accept nil for user or session Id");window.localStorage.setItem(this.ZENI_SESSION_ID,r),window.localStorage.setItem(this.ZENI_SIGNED_IN_USER,this.encrypt(JSON.stringify(t),r))}saveSignedInUserTenants(t,r){const n=r??window.localStorage.getItem(this.ZENI_SESSION_ID);n!=null?window.localStorage.setItem(this.ZENI_SIGNED_IN_USER_TENANTS,this.encrypt(JSON.stringify(t),n)):console.warn("Can't update the setting when the user is logged out!")}saveShowNegativeAmountInParenthesis(t){const r=window.localStorage.getItem(this.ZENI_SESSION_ID);if(r!=null)window.localStorage.setItem(this.ZENI_SHOW_NEGATIVE_AMOUNT_IN_PARENTHESIS,this.encrypt(JSON.stringify(t),r));else throw new Error("Can't update the setting when the user is logged out!")}saveShowNegativeAmountInParenthesisPDF(t){const r=window.localStorage.getItem(this.ZENI_SESSION_ID);if(r!=null)window.localStorage.setItem(this.ZENI_SHOW_NEGATIVE_AMOUNT_IN_PARENTHESIS_PDF,this.encrypt(JSON.stringify(t),r));else throw new Error("Can't update the setting when the user is logged out!")}isSignedIn(){return[this.ZENI_SESSION_ID,this.ZENI_SIGNED_IN_USER].map(r=>window.localStorage.getItem(r)!=null).reduce((r,n)=>r&&n)}clearAll(){this.ALL_IDs.forEach(t=>window.localStorage.removeItem(t))}setTheme(t){const r=window.localStorage.getItem(this.ZENI_SESSION_ID);r!=null&&window.localStorage.setItem(this.ZENI_THEME,this.encrypt(t,r))}getTheme(){const t=window.localStorage.getItem(this.ZENI_THEME),r=window.localStorage.getItem(this.ZENI_SESSION_ID);if(t!=null&&r!==null)return this.decrypt(t,r)}encrypt(t,r){return c7.AES.encrypt(t,r).toString()}decrypt(t,r){return c7.AES.decrypt(t,r).toString(c7.enc.Utf8)}ZENI_SESSION_ID="ZENI_SESSION_ID";ZENI_SIGNED_IN_USER="ZENI_SIGNED_IN_USER";ZENI_SIGNED_IN_USER_TENANTS="ZENI_SIGNED_IN_USER_TENANTS";ZENI_SHOW_NEGATIVE_AMOUNT_IN_PARENTHESIS="ZENI_SHOW_NEGATIVE_AMOUNT_IN_PARENTHESIS";ZENI_SHOW_NEGATIVE_AMOUNT_IN_PARENTHESIS_PDF="ZENI_SHOW_NEGATIVE_AMOUNT_IN_PARENTHESIS_PDF";ZENI_THEME="ZENI_THEME";ZENI_FORCE_REFRESHED_COMPONENTS="ZENI_FORCE_REFRESHED_COMPONENTS";ALL_IDs=[this.ZENI_SESSION_ID,this.ZENI_SIGNED_IN_USER,this.ZENI_SHOW_NEGATIVE_AMOUNT_IN_PARENTHESIS,this.ZENI_SHOW_NEGATIVE_AMOUNT_IN_PARENTHESIS_PDF,this.ZENI_SIGNED_IN_USER_TENANTS,this.ZENI_THEME,this.ZENI_FORCE_REFRESHED_COMPONENTS]}const ca=new QUr,JUr=({children:e})=>{const t=_be("(prefers-color-scheme: dark)"),[r,n]=C.useState({dark:t});b.useEffect(()=>{const a=ca.getTheme()==null?t:ca.getTheme()==="dark";r.dark!==a&&n({dark:a})},[r,t]);const o=()=>{const a=!r.dark;ca.setTheme(a?"dark":"light"),n({...r,dark:a})},i=r.dark?gur():fur();return Wt.jsx(cur,{dark:r.dark,webAppTheme:i,toggle:o,children:e})},eWr=["sandbox","production"],tWr=e=>B0(e,eWr),rWr=e=>{switch(e){case"DEV":case"QA":case"PUNE":case"SUNNYVALE":case"DELHI":case"MOHALI":return"sandbox";case"PROD":case"NEXT":return"production";default:return"sandbox"}},nWr=["development","staging","production"],oWr=e=>B0(e,nWr),iWr=e=>{switch(e){case"QA":case"PUNE":case"SUNNYVALE":case"DELHI":case"MOHALI":return"staging";case"PROD":case"NEXT":return"production";case"DEV":default:return"development"}},aWr=["DEV","QA","PUNE","SUNNYVALE","DELHI","MOHALI","PROD","NEXT"],sWr=e=>B0(e,aWr),d1=sWr("PROD"),SR=()=>d1==="DEV"||d1==="QA"||d1==="PUNE"||d1==="SUNNYVALE"||d1==="DELHI"||d1==="MOHALI",gz="https://zeni-webapp.uc.r.appspot.com",lWr="a9cfa638c9c62aa82fb38cd66d7f717e",DQr=tWr(rWr(d1)),cWr=oWr(iWr(d1));function dWr(e,t){return c7.AES.decrypt(e,t).toString(c7.enc.Utf8)}const uWr="ZENI-WEB-APP-",vye=.9,di={sentryDsn:"",sentryTraceSamplingRate:1,googleClientId:"",googleMapsAPIKey:"",microsoftClientId:"",mixpanelToken:"",pusherClientSecret:"",pusherCluster:"",quickbooksKey:"",appUrl:"",featureClientSecret:"",featureClientSecretCockpit:"",cardVaultId:"",stripeKey:"",qboRedirectionUrl:"",mixpanelUrl:"",mixpanelHMUrl:""};let bm,yz;function pWr(e){di.sentryDsn=e.keys.SENTRY_DSN,di.sentryTraceSamplingRate=e.keys.SENTRY_TRACE_SAMPLE_RATES!=null?parseInt(e.keys.SENTRY_TRACE_SAMPLE_RATES):vye,di.googleClientId=e.keys.GOOGLE_CLIENT_ID,di.googleMapsAPIKey=e.keys.GOOGLE_MAP_KEY,di.microsoftClientId=e.keys.MICROSOFT_CLIENT_ID,di.mixpanelToken=e.keys.MIXPANEL_TOKEN,di.pusherClientSecret=e.keys.PUSHER_CLIENT_SECRET,di.pusherCluster=e.keys.PUSHER_CLUSTER,di.quickbooksKey=e.keys.QUICKBOOK_TOKEN,di.appUrl=e.keys.WEB_ENDPOINT,di.featureClientSecret=e.keys.STATSIG_CLIENT_SECRET,di.featureClientSecretCockpit=e.keys.STATSIG_CLIENT_SECRET_COCKPIT,di.cardVaultId=e.keys.UNIT_VAULT_ID,di.stripeKey=e.keys.STRIPE_KEY,di.qboRedirectionUrl=e.keys.QBO_URL,di.mixpanelUrl=e.keys.MIXPANEL_URL,di.mixpanelHMUrl=e.keys.MIXPANEL_HM_URL,yz=e.externalEndPoints,bm=e.apiEndPoints,hWr()}function hWr(){try{const e=new Set;if(bm!=null){for(const t of Object.values(bm))if(typeof t=="string"&&t.startsWith("http"))try{e.add(new URL(t).origin)}catch{}}for(const t of e){const r=document.createElement("link");r.rel="preconnect",r.href=t,r.crossOrigin="anonymous",document.head.appendChild(r)}}catch{}}async function mWr(){const t=encodeURIComponent(JSON.stringify({environment:d1}));try{const r=await fetch(`${gz}/api/keys?query=${t}`);if(!r.ok)throw new Error(`HTTP error! status: ${r.status}`);return await r.json()}catch(r){return console.error("Error fetching details:",r),null}}let lce=!1;function dy(){lce||(yh.init(lWr,{api_host:yz.mixpanelBaseUrl,ignore_dnt:!0}),lce=!0)}class Ph{identify(t,r){if(dy(),this.#r=t,t!=null&&r!=null&&(Ph.#t==null||hbe({userId:t,traits:r},Ph.#t)!==!0)){const{$email:n,...o}={...r};yh.identify(t),n&&n!=null&&yh.people.set_once({$email:n}),yh.people.set(o),Ph.#t={userId:t,traits:r},SR()&&console.log(`*** Called people set with userId ${t} traits ${JSON.stringify(r)} `)}}identifyUserAndCompany(t,r,n,o,i){throw Error("Use identify in the web-app!!")}track(t,r){if(dy(),this.#r!=null){const n={distinct_id:this.#r,...r};yh.track(t,n)}else console.error("user is not identified :(, so can not fire event");SR()&&console.log(`*** firing ${t} with props ${JSON.stringify(r)}`)}alias(t,r){dy(),yh.alias(t,r)}reset(){dy(),yh.identify(void 0),this.#r=void 0,Ph.#t=void 0}static get analytics(){return this.#e}static#e=new $n.Analytics(new Ph);static#t;#r}const F$=Ph.analytics,fWr=()=>{const e=sw(),t=b1(r=>r.companyState);if(e.pathname.includes("/management/parent/")){const r=e.pathname.split("/")[3],n=t.companiesById[r];if(n!=null)return`${n.companyInfo.name} ${ce.getLocalizedStrings().cockpit.cockpitHeaderSubsidiaryText}`}if(e.pathname.includes("management/month-end-report/company/")){const r=e.pathname.split("/")[4],n=t.companiesById[r];if(n!=null)return n.companyInfo.name}},cce=e=>{switch(e){case"healthMonitor":return"health-monitor";case"taskManager":return"task-manager";default:return e}},MQr=e=>{switch(e){case"healthMonitor":return"health monitor";case"taskManager":return"task manager";default:return e}};function gWr(e,t){return{updateDownloadStateHandler:r=>{e(mbe(r))},onZeniLogoClick:()=>{t.themeState.toggle()},onLogOutClick:()=>{e(jce()),e(Rce(!1)),ca.clearAll();const r=t.locationHook.state?.origin??"/";t.navigate(r,{replace:!0})},onNewCustomerClick:()=>{t.navigate("/onboarding/new"),F$?.trackOnboardingNewCustomerStarted()},onThreadClick:(r,n,o)=>{const i=r.entityType.split(".");if(i.length===2){const a=Dse(i[0]);if(a!=null){const l=cce(a);t.navigate(`/${l}`),o(r,n)}else console.warn(`Invalid navigation target in thread: ${i[0]}`)}},onNotificationClick:(r,n,o)=>{const i=r.entityType.split(".");if(r.isGlobalComment&&i.length===2){const a=Dse(i[0]);if(a!=null){const l=cce(a);t.navigate(`/${l}`),o(r,n)}else console.warn(`Invalid navigation target in notification: ${i[0]}`)}}}}function yWr(e,t){const{signedInUser:r,cockpitHeader:n}=t,o=e.tenantState.currentTenantId,a=dw(e)?.companyName??"",l={userId:r?.userId??"",sessionId:r?.zeniSessionId??"",tenantId:o??""};return{signedInUser:r,cockpitHeader:n,downloadState:e.companyViewState.downloadState,downloadParams:{currentTenantCompanyName:a,cockpitEndPoint:`${gz}/cockpitTabs`,authParams:l}}}const vWr=lve(yWr,gWr)(J_r);function bWr(){const e=lur(),t=ca.getSignedInUser(),r=ER(),n=sw(),o=fWr(),i=b1(d=>fbe(d)),a={tabsFileType:"excel",tabs:["management","subscription","portfolio","onboarding","healthMonitor"],filterByTabs:i.filterByTabs,timezone:gbe()},l=n.pathname.split("/")[1];return Wt.jsx(vWr,{locationHook:n,themeState:e,signedInUser:t,cockpitHeader:o,allTabsViews:i,defaultOptions:a,analytics:F$,currentTab:l,navigate:r})}const wWr=["/management/*","/subscription/*","/onboarding/*","/portfolio/*","/audit/*","/health-monitor/*","/task-manager/*"];function xWr({appContent:e}){const t=wWr.filter(r=>cve(r)).length===0;return Wt.jsxs(Wt.Fragment,{children:[t?null:Wt.jsx(bWr,{}),Wt.jsx(Wt.Fragment,{children:e})]})}const CWr="cockpit",bye="init-enter";function $Wr({location:e,visitedUrl:t}){const{pathname:r}=e;return b.useLayoutEffect(()=>{const n=t.get(r||bye);dce(n!==void 0?n:0)}),null}const SWr=b.memo($Wr,(e,t)=>{const{location:r,visitedUrl:n}=e,{location:o}=t,i=r.pathname||bye,a=kWr();return n.set(i,a),!((o.pathname!==r.pathname||o.search!==r.search)&&o.hash==="")}),dce=(e=0)=>window.requestAnimationFrame(()=>{window.scrollTo(0,e)}),kWr=()=>{let e=0;return document!=null&&document.documentElement!==null&&(e=document.documentElement.scrollTop),window.pageYOffset||e},wye=e=>b.lazy(async()=>{const t=e.toString(),r=ca.getForceRefreshedComponents(),n=new Set(r),o=n.has(t);try{const i=await e();return n.delete(t),ca.saveForceRefreshedComponents(Array.from(n)),i}catch(i){throw o||(n.add(t),ca.saveForceRefreshedComponents(Array.from(n)),location.reload()),i}}),EWr=wye(()=>bt(()=>import("./ScreenRoutes-B-IHS-7V.js"),__vite__mapDeps([242,5,1,6,17,8,243,16,7,2,14,4,9,11,18,19,20]))),_Wr=wye(()=>bt(()=>import("./SignInScreen-aZSIS5dr.js"),__vite__mapDeps([244,17,1,6,8,5,243,16,18,19,20,7])));function TWr(){const e=b.useRef();e.current==null&&(e.current=new Map);const t=ER(),r=sw(),n=new URLSearchParams(r.search),o=n?.get("utm_source"),i=n?.get("utm_medium");return b.useEffect(()=>{const a="signin/auth";ca.isSignedIn()===!1&&!r.pathname.includes(a)&&t(a,{replace:!0,state:{...r.state,message:"...",origin:r.pathname,queryParams:{utmSource:o,utmMedium:i}}})}),Wt.jsxs(DWr,{children:[Wt.jsx(SWr,{visitedUrl:e.current,location:r}),Wt.jsx(AWr,{})]})}const AWr=()=>{const e=ca.isSignedIn(),t=ca.getSignedInUser(),r=e&&TR(t),n=b1(d=>dw(d)),o={userId:t?.userId??"",sessionId:t?.zeniSessionId??"",tenantId:n.tenantId??""},i=b1(d=>ybe(d)),l=b1(d=>vbe(d)).map(d=>({companyId:d.companyId,tenantId:d.tenantId,companyName:d.name}));return Wt.jsx(ffr,{roomId:CWr,authParams:o,users:i,companies:l,authUrlEndPoint:`${bm.tenantMicroServiceBaseUrl}/1.0/commenting/auth`,fetchZeniUsers:!1,commentingUsersUrlEndPoint:`${bm.tenantMicroServiceBaseUrl}/1.0/users/zeni-users`,autoConnect:r,withRoomProvider:!1,loggedInUser:t,withThreadsProvider:!0,filter:{application:"cockpit"},children:Wt.jsx(LWr,{})})},LWr=()=>Wt.jsx(b.Suspense,{fallback:Wt.jsx(MWr,{children:Wt.jsx(vr,{size:"Large",start:!0})}),children:Wt.jsxs(dve,{children:[Wt.jsx(Y$,{path:"/",element:Wt.jsx(uve,{to:"management",replace:!0})}),Wt.jsx(Y$,{path:"/signin/auth",element:Wt.jsx(_Wr,{})}),Wt.jsx(Y$,{path:"*",element:Wt.jsx(xWr,{appContent:Wt.jsx(EWr,{})})})]})}),DWr=qt("div")``,MWr=qt("div")`
29378
+ `,LQr=vt(()=>bt(()=>import("./WarningsDrawerPage-CzufXgaN-BVjYF7DU.js"),__vite__mapDeps([241,16,1,17,6,8,5,18,19,20,7])));var XUr=Lbe();const c7=aw(XUr);class QUr{getSignedInUser(){const t=window.localStorage.getItem(this.ZENI_SESSION_ID),r=window.localStorage.getItem(this.ZENI_SIGNED_IN_USER);if(r!=null&&t!=null)return JSON.parse(this.decrypt(r,t))}getShowNegativeAmountInParenthesis(){const t=window.localStorage.getItem(this.ZENI_SHOW_NEGATIVE_AMOUNT_IN_PARENTHESIS),r=window.localStorage.getItem(this.ZENI_SESSION_ID);return t!=null&&r!=null?JSON.parse(this.decrypt(t,r)):!1}getShowNegativeAmountInParenthesisPDF(){const t=window.localStorage.getItem(this.ZENI_SHOW_NEGATIVE_AMOUNT_IN_PARENTHESIS_PDF),r=window.localStorage.getItem(this.ZENI_SESSION_ID);return t!=null&&r!=null?JSON.parse(this.decrypt(t,r)):!0}getSignedInUserTenant(t){const r=window.localStorage.getItem(this.ZENI_SIGNED_IN_USER_TENANTS),n=window.localStorage.getItem(this.ZENI_SESSION_ID);if(r!=null&&n!=null)return JSON.parse(this.decrypt(r,n)).find(i=>i.tenantEmailDomain===t)}getSignedInUserTenantWithId(t){const r=window.localStorage.getItem(this.ZENI_SIGNED_IN_USER_TENANTS),n=window.localStorage.getItem(this.ZENI_SESSION_ID);if(r!=null&&n!=null)return JSON.parse(this.decrypt(r,n)).find(i=>i.tenantId===t)}getForceRefreshedComponents(){const t=window.localStorage.getItem(this.ZENI_SESSION_ID),r=window.localStorage.getItem(this.ZENI_FORCE_REFRESHED_COMPONENTS);if(r&&t!=null){const n=this.decrypt(r,t);return n?JSON.parse(n):[]}return[]}saveForceRefreshedComponents(t){const r=window.localStorage.getItem(this.ZENI_SESSION_ID);r!=null?window.localStorage.setItem(this.ZENI_FORCE_REFRESHED_COMPONENTS,this.encrypt(JSON.stringify(t),r)):console.warn("Can't update the force refreshed components when the user is logged out!")}saveSignedInUserWithSession(t,r){if(t==null||r==null)throw new Error("Can't accept nil for user or session Id");window.localStorage.setItem(this.ZENI_SESSION_ID,r),window.localStorage.setItem(this.ZENI_SIGNED_IN_USER,this.encrypt(JSON.stringify(t),r))}saveSignedInUserTenants(t,r){const n=r??window.localStorage.getItem(this.ZENI_SESSION_ID);n!=null?window.localStorage.setItem(this.ZENI_SIGNED_IN_USER_TENANTS,this.encrypt(JSON.stringify(t),n)):console.warn("Can't update the setting when the user is logged out!")}saveShowNegativeAmountInParenthesis(t){const r=window.localStorage.getItem(this.ZENI_SESSION_ID);if(r!=null)window.localStorage.setItem(this.ZENI_SHOW_NEGATIVE_AMOUNT_IN_PARENTHESIS,this.encrypt(JSON.stringify(t),r));else throw new Error("Can't update the setting when the user is logged out!")}saveShowNegativeAmountInParenthesisPDF(t){const r=window.localStorage.getItem(this.ZENI_SESSION_ID);if(r!=null)window.localStorage.setItem(this.ZENI_SHOW_NEGATIVE_AMOUNT_IN_PARENTHESIS_PDF,this.encrypt(JSON.stringify(t),r));else throw new Error("Can't update the setting when the user is logged out!")}isSignedIn(){return[this.ZENI_SESSION_ID,this.ZENI_SIGNED_IN_USER].map(r=>window.localStorage.getItem(r)!=null).reduce((r,n)=>r&&n)}clearAll(){this.ALL_IDs.forEach(t=>window.localStorage.removeItem(t))}setTheme(t){const r=window.localStorage.getItem(this.ZENI_SESSION_ID);r!=null&&window.localStorage.setItem(this.ZENI_THEME,this.encrypt(t,r))}getTheme(){const t=window.localStorage.getItem(this.ZENI_THEME),r=window.localStorage.getItem(this.ZENI_SESSION_ID);if(t!=null&&r!==null)return this.decrypt(t,r)}encrypt(t,r){return c7.AES.encrypt(t,r).toString()}decrypt(t,r){return c7.AES.decrypt(t,r).toString(c7.enc.Utf8)}ZENI_SESSION_ID="ZENI_SESSION_ID";ZENI_SIGNED_IN_USER="ZENI_SIGNED_IN_USER";ZENI_SIGNED_IN_USER_TENANTS="ZENI_SIGNED_IN_USER_TENANTS";ZENI_SHOW_NEGATIVE_AMOUNT_IN_PARENTHESIS="ZENI_SHOW_NEGATIVE_AMOUNT_IN_PARENTHESIS";ZENI_SHOW_NEGATIVE_AMOUNT_IN_PARENTHESIS_PDF="ZENI_SHOW_NEGATIVE_AMOUNT_IN_PARENTHESIS_PDF";ZENI_THEME="ZENI_THEME";ZENI_FORCE_REFRESHED_COMPONENTS="ZENI_FORCE_REFRESHED_COMPONENTS";ALL_IDs=[this.ZENI_SESSION_ID,this.ZENI_SIGNED_IN_USER,this.ZENI_SHOW_NEGATIVE_AMOUNT_IN_PARENTHESIS,this.ZENI_SHOW_NEGATIVE_AMOUNT_IN_PARENTHESIS_PDF,this.ZENI_SIGNED_IN_USER_TENANTS,this.ZENI_THEME,this.ZENI_FORCE_REFRESHED_COMPONENTS]}const ca=new QUr,JUr=({children:e})=>{const t=_be("(prefers-color-scheme: dark)"),[r,n]=C.useState({dark:t});b.useEffect(()=>{const a=ca.getTheme()==null?t:ca.getTheme()==="dark";r.dark!==a&&n({dark:a})},[r,t]);const o=()=>{const a=!r.dark;ca.setTheme(a?"dark":"light"),n({...r,dark:a})},i=r.dark?gur():fur();return Wt.jsx(cur,{dark:r.dark,webAppTheme:i,toggle:o,children:e})},eWr=["sandbox","production"],tWr=e=>B0(e,eWr),rWr=e=>{switch(e){case"DEV":case"QA":case"PUNE":case"SUNNYVALE":case"DELHI":case"MOHALI":return"sandbox";case"PROD":case"NEXT":return"production";default:return"sandbox"}},nWr=["development","staging","production"],oWr=e=>B0(e,nWr),iWr=e=>{switch(e){case"QA":case"PUNE":case"SUNNYVALE":case"DELHI":case"MOHALI":return"staging";case"PROD":case"NEXT":return"production";case"DEV":default:return"development"}},aWr=["DEV","QA","PUNE","SUNNYVALE","DELHI","MOHALI","PROD","NEXT"],sWr=e=>B0(e,aWr),d1=sWr("DEV"),SR=()=>d1==="DEV"||d1==="QA"||d1==="PUNE"||d1==="SUNNYVALE"||d1==="DELHI"||d1==="MOHALI",gz="https://zeni-webapp-dev.uc.r.appspot.com",lWr="63d3a2406505a5737a2b4debdb513f20",DQr=tWr(rWr(d1)),cWr=oWr(iWr(d1));function dWr(e,t){return c7.AES.decrypt(e,t).toString(c7.enc.Utf8)}const uWr="ZENI-WEB-APP-",vye=.9,di={sentryDsn:"",sentryTraceSamplingRate:1,googleClientId:"",googleMapsAPIKey:"",microsoftClientId:"",mixpanelToken:"",pusherClientSecret:"",pusherCluster:"",quickbooksKey:"",appUrl:"",featureClientSecret:"",featureClientSecretCockpit:"",cardVaultId:"",stripeKey:"",qboRedirectionUrl:"",mixpanelUrl:"",mixpanelHMUrl:""};let bm,yz;function pWr(e){di.sentryDsn=e.keys.SENTRY_DSN,di.sentryTraceSamplingRate=e.keys.SENTRY_TRACE_SAMPLE_RATES!=null?parseInt(e.keys.SENTRY_TRACE_SAMPLE_RATES):vye,di.googleClientId=e.keys.GOOGLE_CLIENT_ID,di.googleMapsAPIKey=e.keys.GOOGLE_MAP_KEY,di.microsoftClientId=e.keys.MICROSOFT_CLIENT_ID,di.mixpanelToken=e.keys.MIXPANEL_TOKEN,di.pusherClientSecret=e.keys.PUSHER_CLIENT_SECRET,di.pusherCluster=e.keys.PUSHER_CLUSTER,di.quickbooksKey=e.keys.QUICKBOOK_TOKEN,di.appUrl=e.keys.WEB_ENDPOINT,di.featureClientSecret=e.keys.STATSIG_CLIENT_SECRET,di.featureClientSecretCockpit=e.keys.STATSIG_CLIENT_SECRET_COCKPIT,di.cardVaultId=e.keys.UNIT_VAULT_ID,di.stripeKey=e.keys.STRIPE_KEY,di.qboRedirectionUrl=e.keys.QBO_URL,di.mixpanelUrl=e.keys.MIXPANEL_URL,di.mixpanelHMUrl=e.keys.MIXPANEL_HM_URL,yz=e.externalEndPoints,bm=e.apiEndPoints,hWr()}function hWr(){try{const e=new Set;if(bm!=null){for(const t of Object.values(bm))if(typeof t=="string"&&t.startsWith("http"))try{e.add(new URL(t).origin)}catch{}}for(const t of e){const r=document.createElement("link");r.rel="preconnect",r.href=t,r.crossOrigin="anonymous",document.head.appendChild(r)}}catch{}}async function mWr(){const t=encodeURIComponent(JSON.stringify({environment:d1}));try{const r=await fetch(`${gz}/api/keys?query=${t}`);if(!r.ok)throw new Error(`HTTP error! status: ${r.status}`);return await r.json()}catch(r){return console.error("Error fetching details:",r),null}}let lce=!1;function dy(){lce||(yh.init(lWr,{api_host:yz.mixpanelBaseUrl,ignore_dnt:!0}),lce=!0)}class Ph{identify(t,r){if(dy(),this.#r=t,t!=null&&r!=null&&(Ph.#t==null||hbe({userId:t,traits:r},Ph.#t)!==!0)){const{$email:n,...o}={...r};yh.identify(t),n&&n!=null&&yh.people.set_once({$email:n}),yh.people.set(o),Ph.#t={userId:t,traits:r},SR()&&console.log(`*** Called people set with userId ${t} traits ${JSON.stringify(r)} `)}}identifyUserAndCompany(t,r,n,o,i){throw Error("Use identify in the web-app!!")}track(t,r){if(dy(),this.#r!=null){const n={distinct_id:this.#r,...r};yh.track(t,n)}else console.error("user is not identified :(, so can not fire event");SR()&&console.log(`*** firing ${t} with props ${JSON.stringify(r)}`)}alias(t,r){dy(),yh.alias(t,r)}reset(){dy(),yh.identify(void 0),this.#r=void 0,Ph.#t=void 0}static get analytics(){return this.#e}static#e=new $n.Analytics(new Ph);static#t;#r}const F$=Ph.analytics,fWr=()=>{const e=sw(),t=b1(r=>r.companyState);if(e.pathname.includes("/management/parent/")){const r=e.pathname.split("/")[3],n=t.companiesById[r];if(n!=null)return`${n.companyInfo.name} ${ce.getLocalizedStrings().cockpit.cockpitHeaderSubsidiaryText}`}if(e.pathname.includes("management/month-end-report/company/")){const r=e.pathname.split("/")[4],n=t.companiesById[r];if(n!=null)return n.companyInfo.name}},cce=e=>{switch(e){case"healthMonitor":return"health-monitor";case"taskManager":return"task-manager";default:return e}},MQr=e=>{switch(e){case"healthMonitor":return"health monitor";case"taskManager":return"task manager";default:return e}};function gWr(e,t){return{updateDownloadStateHandler:r=>{e(mbe(r))},onZeniLogoClick:()=>{t.themeState.toggle()},onLogOutClick:()=>{e(jce()),e(Rce(!1)),ca.clearAll();const r=t.locationHook.state?.origin??"/";t.navigate(r,{replace:!0})},onNewCustomerClick:()=>{t.navigate("/onboarding/new"),F$?.trackOnboardingNewCustomerStarted()},onThreadClick:(r,n,o)=>{const i=r.entityType.split(".");if(i.length===2){const a=Dse(i[0]);if(a!=null){const l=cce(a);t.navigate(`/${l}`),o(r,n)}else console.warn(`Invalid navigation target in thread: ${i[0]}`)}},onNotificationClick:(r,n,o)=>{const i=r.entityType.split(".");if(r.isGlobalComment&&i.length===2){const a=Dse(i[0]);if(a!=null){const l=cce(a);t.navigate(`/${l}`),o(r,n)}else console.warn(`Invalid navigation target in notification: ${i[0]}`)}}}}function yWr(e,t){const{signedInUser:r,cockpitHeader:n}=t,o=e.tenantState.currentTenantId,a=dw(e)?.companyName??"",l={userId:r?.userId??"",sessionId:r?.zeniSessionId??"",tenantId:o??""};return{signedInUser:r,cockpitHeader:n,downloadState:e.companyViewState.downloadState,downloadParams:{currentTenantCompanyName:a,cockpitEndPoint:`${gz}/cockpitTabs`,authParams:l}}}const vWr=lve(yWr,gWr)(J_r);function bWr(){const e=lur(),t=ca.getSignedInUser(),r=ER(),n=sw(),o=fWr(),i=b1(d=>fbe(d)),a={tabsFileType:"excel",tabs:["management","subscription","portfolio","onboarding","healthMonitor"],filterByTabs:i.filterByTabs,timezone:gbe()},l=n.pathname.split("/")[1];return Wt.jsx(vWr,{locationHook:n,themeState:e,signedInUser:t,cockpitHeader:o,allTabsViews:i,defaultOptions:a,analytics:F$,currentTab:l,navigate:r})}const wWr=["/management/*","/subscription/*","/onboarding/*","/portfolio/*","/audit/*","/health-monitor/*","/task-manager/*"];function xWr({appContent:e}){const t=wWr.filter(r=>cve(r)).length===0;return Wt.jsxs(Wt.Fragment,{children:[t?null:Wt.jsx(bWr,{}),Wt.jsx(Wt.Fragment,{children:e})]})}const CWr="cockpit",bye="init-enter";function $Wr({location:e,visitedUrl:t}){const{pathname:r}=e;return b.useLayoutEffect(()=>{const n=t.get(r||bye);dce(n!==void 0?n:0)}),null}const SWr=b.memo($Wr,(e,t)=>{const{location:r,visitedUrl:n}=e,{location:o}=t,i=r.pathname||bye,a=kWr();return n.set(i,a),!((o.pathname!==r.pathname||o.search!==r.search)&&o.hash==="")}),dce=(e=0)=>window.requestAnimationFrame(()=>{window.scrollTo(0,e)}),kWr=()=>{let e=0;return document!=null&&document.documentElement!==null&&(e=document.documentElement.scrollTop),window.pageYOffset||e},wye=e=>b.lazy(async()=>{const t=e.toString(),r=ca.getForceRefreshedComponents(),n=new Set(r),o=n.has(t);try{const i=await e();return n.delete(t),ca.saveForceRefreshedComponents(Array.from(n)),i}catch(i){throw o||(n.add(t),ca.saveForceRefreshedComponents(Array.from(n)),location.reload()),i}}),EWr=wye(()=>bt(()=>import("./ScreenRoutes-CrZHoFIY.js"),__vite__mapDeps([242,5,1,6,17,8,243,16,7,2,14,4,9,11,18,19,20]))),_Wr=wye(()=>bt(()=>import("./SignInScreen-B08t21nJ.js"),__vite__mapDeps([244,17,1,6,8,5,243,16,18,19,20,7])));function TWr(){const e=b.useRef();e.current==null&&(e.current=new Map);const t=ER(),r=sw(),n=new URLSearchParams(r.search),o=n?.get("utm_source"),i=n?.get("utm_medium");return b.useEffect(()=>{const a="signin/auth";ca.isSignedIn()===!1&&!r.pathname.includes(a)&&t(a,{replace:!0,state:{...r.state,message:"...",origin:r.pathname,queryParams:{utmSource:o,utmMedium:i}}})}),Wt.jsxs(DWr,{children:[Wt.jsx(SWr,{visitedUrl:e.current,location:r}),Wt.jsx(AWr,{})]})}const AWr=()=>{const e=ca.isSignedIn(),t=ca.getSignedInUser(),r=e&&TR(t),n=b1(d=>dw(d)),o={userId:t?.userId??"",sessionId:t?.zeniSessionId??"",tenantId:n.tenantId??""},i=b1(d=>ybe(d)),l=b1(d=>vbe(d)).map(d=>({companyId:d.companyId,tenantId:d.tenantId,companyName:d.name}));return Wt.jsx(ffr,{roomId:CWr,authParams:o,users:i,companies:l,authUrlEndPoint:`${bm.tenantMicroServiceBaseUrl}/1.0/commenting/auth`,fetchZeniUsers:!1,commentingUsersUrlEndPoint:`${bm.tenantMicroServiceBaseUrl}/1.0/users/zeni-users`,autoConnect:r,withRoomProvider:!1,loggedInUser:t,withThreadsProvider:!0,filter:{application:"cockpit"},children:Wt.jsx(LWr,{})})},LWr=()=>Wt.jsx(b.Suspense,{fallback:Wt.jsx(MWr,{children:Wt.jsx(vr,{size:"Large",start:!0})}),children:Wt.jsxs(dve,{children:[Wt.jsx(Y$,{path:"/",element:Wt.jsx(uve,{to:"management",replace:!0})}),Wt.jsx(Y$,{path:"/signin/auth",element:Wt.jsx(_Wr,{})}),Wt.jsx(Y$,{path:"*",element:Wt.jsx(xWr,{appContent:Wt.jsx(EWr,{})})})]})}),DWr=qt("div")``,MWr=qt("div")`
29379
29379
  display: flex;
29380
29380
  flex: 1 1 auto;
29381
29381
  flex-direction: row;
@@ -29386,4 +29386,4 @@ ${e}`,WAr=e=>b.createElement("svg",{width:38,height:39,viewBox:"0 0 38 39",fill:
29386
29386
  background-color: ${e=>e.theme.colors.background};
29387
29387
  `;function PWr(){ce.updateAppLocaleID("en"),FWr();const e=OWr(),[t,r]=b.useState(!1),n=b.useCallback(i=>{i.data?.type==="UPDATE_READY"?r(!0):i.data?.type==="HIDE_UPDATE_POPUP"&&r(!1)},[]);b.useEffect(()=>("serviceWorker"in navigator&&(navigator.serviceWorker.addEventListener("message",n),navigator.serviceWorker.addEventListener("controllerchange",()=>{r(!1)})),()=>{navigator.serviceWorker.removeEventListener("message",n)}),[n]);const o=()=>{r(!1),window.location.reload()};return Wt.jsx(JUr,{children:Wt.jsx(pve,{store:e,children:Wt.jsx(fmt,{children:Wt.jsxs(PDt,{children:[t?Wt.jsx(rRt,{onPrimaryClick:o}):null,Wt.jsx(jWr,{})]})})})})}const IWr=()=>{const e=ca.getSignedInUser(),t=b1($=>dw($)),r=b1($=>Cbe($,t.companyId)),n=sw(),o=ER(),i=hve(),a=t?.excludedResources?.fetchState=="Completed"?t.excludedResources.resources:[];b.useEffect(()=>()=>{i(Oz())},[]);const l=b1($=>$be($)),d=t?.externalConnections?.accounting[0]?.connectionName,u=()=>{i(Oz())},p=b.useMemo(()=>Sbe(t.userRole),[t.userRole]),h=b1($=>$.companyViewState.zeniUsers),f=b.useMemo(()=>{const $=h.fetchState==="Error"&&kbe(h.error);return $&&console.warn("Auto-logout triggered due to invalid session"),$},[h.fetchState,h.error]),g=b.useMemo(()=>{const $=h.fetchState==="Error"&&Ebe(h.error)===!0;return $&&console.warn("Page is not accessible, show 404"),$},[h.fetchState,h.error]),y=b.useRef(!1);b.useEffect(()=>(f&&!y.current&&(y.current=!0,v()),()=>{y.current=!1}),[f]),b.useEffect(()=>{g&&window.open("/page-not-found","_self")},[g]);const v=b.useCallback(()=>{i(jce()),i(Rce(!1)),ca.clearAll();const $=n.state?.origin??"/";o($,{replace:!0})},[]),w=b.useMemo(()=>ca.getSignedInUser(),[]),x=b.useMemo(()=>({userId:w?.userId??"",sessionId:w?.zeniSessionId??"",tenantId:t.tenantId??""}),[w,t.tenantId]);return Wt.jsx(YDt,{globalInfo:{loggedInUser:e,loggedInUserRole:t?.userRole,excludedResources:a,loggedInUserRoleMap:p,currentTenant:t,connectionName:d,controllersList:r},children:Wt.jsx(FDt,{toolkit:{analytics:F$,sentry:Pye,authParams:x},children:Wt.jsxs(zLt,{endPoint:{url:gz},children:[Wt.jsx(p8r,{isOnDashboard:!1,showSnackbar:l.isSnackbarOpen,snackbar:{message:l.message,messageType:l.messageType,onRemoveSnackbar:u,showStatusIcon:l.showStatusIcon}}),Wt.jsx(TWr,{})]})})})},jWr=()=>{const e=ca.isSignedIn(),r=b1(n=>dw(n)).companyId;return Wt.jsx(zIt,{isUserSignedIn:e,featureGateCustomFields:{companyId:r},zeniFeatureConfig:{currentFeatureEnv:cWr,featureClientSecret:di.featureClientSecretCockpit,providerEndPoint:yz.statsigBaseUrl},children:Wt.jsx(IWr,{})})},RWr=Dye(PWr);function FWr(){console.log("Initialize any 3rd party libs!")}let vP=null;function OWr(){return vP===null&&(vP=NWr(),bbe().catch(e=>{console.error("Failed to load feature epics:",e),Mye(e,{tags:{critical:"true",module:"epicManager"}}),alert(`The application failed to load required modules. Some features may not work correctly.
29388
29388
 
29389
- Please refresh the page to try again.`)})),vP}function NWr(){console.warn(`initializing epic state with url ${JSON.stringify(bm)}`);const e=ca.getSignedInUser(),t=wbe(bm,e?.userId,e?.zeniSessionId,void 0,SR()),r=xbe();return r.userId!=null&&F$.identify(r.userId,{tenant_id:r.tenantId}),t}const zWr=!!(window.location.hostname==="localhost"||window.location.hostname==="[::1]"||window.location.hostname.match(/^127(?:\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)){3}$/)),BWr="PROD",HWr="https://zeni-webapp.uc.r.appspot.com",uce=`/service-worker.js?v=${Date.now()}&env=${BWr}&endpoint=${encodeURIComponent(HWr)}`;function VWr(e){if("serviceWorker"in navigator){if(new URL("https://app.zeni.ai",window.location.href).origin!==window.location.origin)return;window.addEventListener("load",()=>{zWr?UWr(uce):xye(uce)})}}function xye(e,t){navigator.serviceWorker.register(e).then(r=>{r.onupdatefound=()=>{const n=r.installing;n!=null&&(n.onstatechange=()=>{n.state==="installed"&&(navigator.serviceWorker.controller?(console.log("New content available; will be used when all tabs are closed."),navigator.serviceWorker.controller?.postMessage({type:"UPDATE_READY"}),r.waiting?.postMessage({type:"SKIP_WAITING"})):console.log("Content is cached for offline use."))})},r.waiting&&r.waiting.postMessage({type:"SKIP_WAITING"}),navigator.serviceWorker.addEventListener("controllerchange",()=>{console.log("New service worker activated."),r.active?.postMessage({type:"CLIENTS_CLAIM"})})}).catch(r=>{console.error("Error during service worker registration:",r)})}function UWr(e,t){fetch(e,{headers:{"Service-Worker":"script"}}).then(r=>{const n=r.headers.get("content-type");r.status===404||n!=null&&!n.includes("javascript")?navigator.serviceWorker.ready.then(o=>{o.unregister().then(()=>window.location.reload())}):xye(e)}).catch(()=>{console.log("No internet connection found. App is running in offline mode.")})}const WWr=ca.getSignedInUser(),YWr=WWr?.zeniSessionId;async function GWr(){try{const e=await mWr(),t=dWr(e,uWr+d1);pWr(JSON.parse(t)),Mbe.createRoot(document.getElementById("root")).render(Wt.jsx(C.StrictMode,{children:Wt.jsx(mve,{basename:"/cockpit",children:Wt.jsx(RWr,{})})})),qWr()}catch(e){console.error("Error initializing app:",e)}}function qWr(){const e=()=>{Iye({dsn:di.sentryDsn,integrations:[jye(),Rye({maskAllText:!0,blockAllMedia:!0})],tracesSampleRate:di.sentryTraceSamplingRate??vye,replaysSessionSampleRate:0,replaysOnErrorSampleRate:1,beforeSendTransaction(t){return t.breadcrumbs&&(t.breadcrumbs=t.breadcrumbs.filter(r=>r.category!=="console"?!0:(r.message??"").toLowerCase().includes("called people set")||Array.isArray(r.data?.arguments)&&r.data.arguments.some(o=>typeof o=="string"&&o.toLowerCase().includes("called people set"))?!1:(Array.isArray(r.data?.arguments)&&(r.data.arguments=r.data.arguments.map(o=>{if(typeof o=="string"&&o.includes("user_roles"))try{const i=o.match(/\{.*\}/s);if(i!==null){const a=JSON.parse(i[0]);if(a.user_roles!=null)return delete a.user_roles,o.replace(i[0],JSON.stringify(a))}}catch{}return o})),!0))),t}}),Fye("session-id",YWr)};typeof requestIdleCallback=="function"?requestIdleCallback(e):setTimeout(e,0)}GWr();VWr();export{PKr as $,tQr as A,Qn as B,$n as C,al as D,oQr as E,ce as F,KYr as G,kQr as H,SQr as I,$Qr as J,nQr as K,Ar as L,a$ as M,Qm as N,EKr as O,aQr as P,sQr as Q,l$ as R,iQr as S,LQr as T,TQr as U,s as V,vQr as W,RKr as X,_Qr as Y,EQr as Z,CQr as _,Ot as a,Ic as a$,IKr as a0,xQr as a1,wQr as a2,yQr as a3,wye as a4,rQr as a5,lur as a6,sl as a7,Ao as a8,bo as a9,Pn as aA,$Yr as aB,wYr as aC,SYr as aD,xYr as aE,CYr as aF,Ya as aG,MKr as aH,DKr as aI,_Kr as aJ,tr as aK,C6 as aL,ke as aM,bn as aN,Ma as aO,TKr as aP,Go as aQ,kd as aR,gt as aS,yt as aT,AKr as aU,Pc as aV,Mc as aW,Pg as aX,Eo as aY,pa as aZ,ep as a_,vYr as aa,To as ab,jg as ac,V9 as ad,Z1 as ae,r$t as af,ot as ag,S$ as ah,bYr as ai,yYr as aj,Ze as ak,$t as al,mo as am,qr as an,Od as ao,Sn as ap,d2 as aq,aee as ar,oo as as,Xa as at,jy as au,ua as av,EMt as aw,o6 as ax,kYr as ay,Tqr as az,K as b,sc as b$,LKr as b0,km as b1,i7r as b2,I1 as b3,Yh as b4,Br as b5,fN as b6,On as b7,un as b8,ec as b9,xKr as bA,jw as bB,gN as bC,ln as bD,Do as bE,pt as bF,PYr as bG,Qa as bH,VGr as bI,U1 as bJ,UGr as bK,Hg as bL,mi as bM,CEt as bN,N0 as bO,l5e as bP,Et as bQ,_Ut as bR,Ka as bS,hYr as bT,itt as bU,T6 as bV,Dyr as bW,Myr as bX,Vi as bY,Y1 as bZ,dN as b_,Fxt as ba,Tkt as bb,fvt as bc,Dd as bd,rc as be,h2 as bf,SN as bg,zXr as bh,YXr as bi,HXr as bj,BXr as bk,doe as bl,Ul as bm,kN as bn,ud as bo,mYr as bp,UCt as bq,G1 as br,kp as bs,E6 as bt,P1 as bu,v5e as bv,Xl as bw,wDt as bx,CGr as by,M1 as bz,R as c,_Kt as c$,S6 as c0,uDt as c1,I9e as c2,m6e as c3,PN as c4,s5e as c5,zb as c6,jN as c7,RN as c8,D6 as c9,y6 as cA,Za as cB,A7 as cC,OYr as cD,Kn as cE,ULt as cF,wa as cG,j7 as cH,UUt as cI,P9e as cJ,gm as cK,v7e as cL,oGr as cM,c$r as cN,Tt as cO,NYr as cP,tGr as cQ,Q9e as cR,tz as cS,p2 as cT,tn as cU,Ja as cV,It as cW,zr as cX,ni as cY,ixt as cZ,h5e as c_,qDt as ca,sZr as cb,z6e as cc,B6e as cd,Uw as ce,fr as cf,m8r as cg,xN as ch,z1 as ci,gKr as cj,bne as ck,fYr as cl,O1 as cm,F0 as cn,a2 as co,Rwr as cp,V1 as cq,cZr as cr,Lie as cs,jb as ct,plr as cu,Qs as cv,mb as cw,iNt as cx,Ts as cy,Rd as cz,wt as d,Rqr as d$,W1 as d0,LJ as d1,Bg as d2,o5e as d3,La as d4,A$ as d5,TYr as d6,_Yr as d7,EYr as d8,E6e as d9,DZr as dA,LZr as dB,wN as dC,tqt as dD,ste as dE,lte as dF,oqt as dG,iqt as dH,H4e as dI,Ehr as dJ,X9e as dK,UFt as dL,Ng as dM,N1r as dN,EOt as dO,TOt as dP,PXr as dQ,U3r as dR,OZr as dS,Lqr as dT,Yqr as dU,zqr as dV,Nqr as dW,Vqr as dX,Hqr as dY,Bqr as dZ,Fqr as d_,E$ as da,JN as db,LYr as dc,AYr as dd,DYr as de,wKr as df,MYr as dg,ho as dh,IYr as di,Oit as dj,jYr as dk,t$r as dl,RYr as dm,hdr as dn,x$ as dp,Og as dq,Vl as dr,H3 as ds,cte as dt,rqt as du,nqt as dv,yN as dw,MZr as dx,PZr as dy,IZr as dz,F$ as e,kor as e$,Wqr as e0,Uqr as e1,jqr as e2,Iqr as e3,bee as e4,Oqr as e5,Qqr as e6,Pqr as e7,Mqr as e8,Xqr as e9,k3r as eA,E3r as eB,S3r as eC,zg as eD,jKr as eE,Dp as eF,q1 as eG,Da as eH,K9e as eI,L$ as eJ,Em as eK,gNt as eL,yNt as eM,lIt as eN,ist as eO,Df as eP,HZr as eQ,VLt as eR,zYr as eS,BZr as eT,A6 as eU,y$ as eV,j7e as eW,Ym as eX,aWe as eY,GZe as eZ,$Zr as e_,Dqr as ea,Kqr as eb,Jqr as ec,FYr as ed,eZr as ee,MXr as ef,o9e as eg,a6 as eh,qqr as ei,_h as ej,L6 as ek,bmr as el,LOt as em,AOt as en,_Ot as eo,L7 as ep,hm as eq,vmr as er,AL as es,FN as et,yOt as eu,tZr as ev,pb as ew,Vtt as ex,w6 as ey,hN as ez,gfr as f,sNt as f$,P7 as f0,qN as f1,Sor as f2,eg as f3,Ftr as f4,iHt as f5,Yw as f6,wor as f7,oHt as f8,nHt as f9,og as fA,O0 as fB,c1 as fC,I5r as fD,F5e as fE,bjt as fF,gjt as fG,K7e as fH,h4r as fI,M4r as fJ,k6 as fK,v6 as fL,CN as fM,gGr as fN,aZr as fO,_qr as fP,zZr as fQ,rZr as fR,iZr as fS,nZr as fT,lZr as fU,p$r as fV,bFt as fW,M$ as fX,Fd as fY,ql as fZ,oZr as f_,Nee as fa,FEe as fb,f$ as fc,$a as fd,FZr as fe,xa as ff,Ca as fg,_or as fh,Eor as fi,_6 as fj,$7e as fk,v6e as fl,Aqr as fm,pm as fn,jgr as fo,Qj as fp,M5r as fq,YFt as fr,Fgr as fs,bb as ft,AZr as fu,lN as fv,J4r as fw,P5r as fx,fm as fy,ig as fz,di as g,BYr as g$,yjt as g0,t_r as g1,Gj as g2,J5e as g3,K5e as g4,Hgr as g5,wb as g6,G7e as g7,rGr as g8,ofe as g9,Zqr as gA,tg as gB,fGr as gC,d$ as gD,S6e as gE,$J as gF,$b as gG,im as gH,$mr as gI,w$ as gJ,W$r as gK,XYr as gL,wue as gM,il as gN,F7e as gO,_Zr as gP,bJt as gQ,vN as gR,s$ as gS,vt as gT,$6 as gU,Gyr as gV,A9e as gW,m9e as gX,B8r as gY,Y8r as gZ,eyr as g_,g6 as ga,Y7e as gb,io as gc,W5e as gd,u2 as ge,Dr as gf,tHt as gg,DBt as gh,Par as gi,M7 as gj,t7 as gk,Zrr as gl,Fee as gm,Lp as gn,Rt as go,XN as gp,k$ as gq,Jf as gr,Itr as gs,D7 as gt,YHt as gu,TZr as gv,cVt as gw,C7e as gx,avt as gy,nRt as gz,p$ as h,oRt as h$,G8r as h0,W8r as h1,e7 as h2,Dj as h3,fWt as h4,rg as h5,y7e as h6,f7e as h7,g7e as h8,PZt as h9,B4r as hA,J4e as hB,g$r as hC,z_ as hD,mGr as hE,dHt as hF,pN as hG,SO as hH,$O as hI,Y4 as hJ,zKr as hK,NKr as hL,BKr as hM,Nne as hN,t9e as hO,FKr as hP,OKr as hQ,e9e as hR,D7e as hS,elr as hT,nGr as hU,YLt as hV,c2 as hW,lQr as hX,tR as hY,yKr as hZ,bKr as h_,KZt as ha,JYr as hb,eGr as hc,HN as hd,VN as he,iGr as hf,REt as hg,m7e as hh,pp as hi,_Yt as hj,kZr as hk,EZr as hl,x7e as hm,ZN as hn,Pd as ho,KN as hp,jZr as hq,Byr as hr,Y3r as hs,$$ as ht,hZr as hu,tp as hv,k6e as hw,RZr as hx,aZt as hy,H4r as hz,bQr as i,ZXr as i$,vKr as i0,YKr as i1,KKr as i2,XKr as i3,qKr as i4,ZKr as i5,GKr as i6,QKr as i7,Oir as i8,hGr as i9,SKr as iA,vXr as iB,iXr as iC,QYr as iD,iKr as iE,Q4e as iF,Soe as iG,bDt as iH,cQr as iI,dQr as iJ,uQr as iK,pQr as iL,Cie as iM,Sxt as iN,X6e as iO,H2r as iP,Eyr as iQ,tFt as iR,JXr as iS,j6e as iT,Vwr as iU,Hwr as iV,_yr as iW,QXr as iX,z4r as iY,NZr as iZ,uFt as i_,hjt as ia,DXr as ib,HYt as ic,pGr as id,dkr as ie,lXr as ig,bXr as ih,sXr as ii,LXr as ij,oXr as ik,aXr as il,Bpr as im,mXr as io,Kne as ip,wXr as iq,wmr as ir,lmr as is,iXt as it,kXr as iu,d9e as iv,l9e as iw,Hhr as ix,xXr as iy,Bb as iz,MQr as j,VYr as j$,sGr as j0,ZZr as j1,XXr as j2,aGr as j3,lGr as j4,KXr as j5,b$ as j6,jbt as j7,Zlr as j8,FLt as j9,Gbr as jA,F9e as jB,Rg as jC,uN as jD,HYr as jE,fQr as jF,tCr as jG,Txr as jH,eCr as jI,_u as jJ,sg as jK,rCr as jL,iz as jM,az as jN,uh as jO,Nwr as jP,q4e as jQ,cGr as jR,fjt as jS,Mvr as jT,Ayr as jU,Lyr as jV,uGr as jW,h8r as jX,XCt as jY,dGr as jZ,pDt as j_,zj as ja,mZr as jb,hDt as jc,wGr as jd,xGr as je,icr as jf,yDt as jg,ac as jh,WIt as ji,KZr as jj,uHt as jk,bd as jl,MYt as jm,qbr as jn,Ybr as jo,mN as jp,Yy as jq,V9e as jr,B7 as js,H9e as jt,lg as ju,B9e as jv,z9e as jw,N9e as jx,O9e as jy,R9e as jz,cce as k,MKt as k$,r_r as k0,pZr as k1,VXr as k2,I5e as k3,bGr as k4,hmt as k5,vGr as k6,yGr as k7,Tyr as k8,MIt as k9,p8e as kA,Akr as kB,B4e as kC,F5 as kD,kKr as kE,F7 as kF,Tmr as kG,AKt as kH,Ij as kI,SZr as kJ,I7e as kK,jBt as kL,uBt as kM,z7e as kN,hJt as kO,zwr as kP,eQr as kQ,yZr as kR,mQr as kS,uZr as kT,fZr as kU,vZr as kV,bZr as kW,gZr as kX,CZr as kY,xZr as kZ,wZr as k_,Gqr as ka,r8e as kb,c8e as kc,k1 as kd,j$ as ke,cg as kf,d8e as kg,Xb as kh,l8e as ki,GLt as kj,Qy as kk,Q6e as kl,a8e as km,Ykr as kn,i8e as ko,u8e as kp,hR as kq,R6 as kr,ZEr as ks,V7 as kt,s8e as ku,a5e as kv,n8e as kw,f8e as kx,Ese as ky,TN as kz,qo as l,hQr as l0,dZr as l1,Bwr as l2,vr as m,Ut as n,c as o,M as p,Ye as q,AQr as r,Fg as s,_5e as t,Nd as u,S5e as v,gQr as w,DQr as x,G as y,ca as z};
29389
+ Please refresh the page to try again.`)})),vP}function NWr(){console.warn(`initializing epic state with url ${JSON.stringify(bm)}`);const e=ca.getSignedInUser(),t=wbe(bm,e?.userId,e?.zeniSessionId,void 0,SR()),r=xbe();return r.userId!=null&&F$.identify(r.userId,{tenant_id:r.tenantId}),t}const zWr=!!(window.location.hostname==="localhost"||window.location.hostname==="[::1]"||window.location.hostname.match(/^127(?:\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)){3}$/)),BWr="DEV",HWr="https://zeni-webapp-dev.uc.r.appspot.com",uce=`/service-worker.js?v=${Date.now()}&env=${BWr}&endpoint=${encodeURIComponent(HWr)}`;function VWr(e){if("serviceWorker"in navigator){if(new URL("https://dev.app.zeni.ai",window.location.href).origin!==window.location.origin)return;window.addEventListener("load",()=>{zWr?UWr(uce):xye(uce)})}}function xye(e,t){navigator.serviceWorker.register(e).then(r=>{r.onupdatefound=()=>{const n=r.installing;n!=null&&(n.onstatechange=()=>{n.state==="installed"&&(navigator.serviceWorker.controller?(console.log("New content available; will be used when all tabs are closed."),navigator.serviceWorker.controller?.postMessage({type:"UPDATE_READY"}),r.waiting?.postMessage({type:"SKIP_WAITING"})):console.log("Content is cached for offline use."))})},r.waiting&&r.waiting.postMessage({type:"SKIP_WAITING"}),navigator.serviceWorker.addEventListener("controllerchange",()=>{console.log("New service worker activated."),r.active?.postMessage({type:"CLIENTS_CLAIM"})})}).catch(r=>{console.error("Error during service worker registration:",r)})}function UWr(e,t){fetch(e,{headers:{"Service-Worker":"script"}}).then(r=>{const n=r.headers.get("content-type");r.status===404||n!=null&&!n.includes("javascript")?navigator.serviceWorker.ready.then(o=>{o.unregister().then(()=>window.location.reload())}):xye(e)}).catch(()=>{console.log("No internet connection found. App is running in offline mode.")})}const WWr=ca.getSignedInUser(),YWr=WWr?.zeniSessionId;async function GWr(){try{const e=await mWr(),t=dWr(e,uWr+d1);pWr(JSON.parse(t)),Mbe.createRoot(document.getElementById("root")).render(Wt.jsx(C.StrictMode,{children:Wt.jsx(mve,{basename:"/cockpit",children:Wt.jsx(RWr,{})})})),qWr()}catch(e){console.error("Error initializing app:",e)}}function qWr(){const e=()=>{Iye({dsn:di.sentryDsn,integrations:[jye(),Rye({maskAllText:!0,blockAllMedia:!0})],tracesSampleRate:di.sentryTraceSamplingRate??vye,replaysSessionSampleRate:0,replaysOnErrorSampleRate:1,beforeSendTransaction(t){return t.breadcrumbs&&(t.breadcrumbs=t.breadcrumbs.filter(r=>r.category!=="console"?!0:(r.message??"").toLowerCase().includes("called people set")||Array.isArray(r.data?.arguments)&&r.data.arguments.some(o=>typeof o=="string"&&o.toLowerCase().includes("called people set"))?!1:(Array.isArray(r.data?.arguments)&&(r.data.arguments=r.data.arguments.map(o=>{if(typeof o=="string"&&o.includes("user_roles"))try{const i=o.match(/\{.*\}/s);if(i!==null){const a=JSON.parse(i[0]);if(a.user_roles!=null)return delete a.user_roles,o.replace(i[0],JSON.stringify(a))}}catch{}return o})),!0))),t}}),Fye("session-id",YWr)};typeof requestIdleCallback=="function"?requestIdleCallback(e):setTimeout(e,0)}GWr();VWr();export{PKr as $,tQr as A,Qn as B,$n as C,al as D,oQr as E,ce as F,KYr as G,kQr as H,SQr as I,$Qr as J,nQr as K,Ar as L,a$ as M,Qm as N,EKr as O,aQr as P,sQr as Q,l$ as R,iQr as S,LQr as T,TQr as U,s as V,vQr as W,RKr as X,_Qr as Y,EQr as Z,CQr as _,Ot as a,Ic as a$,IKr as a0,xQr as a1,wQr as a2,yQr as a3,wye as a4,rQr as a5,lur as a6,sl as a7,Ao as a8,bo as a9,Pn as aA,$Yr as aB,wYr as aC,SYr as aD,xYr as aE,CYr as aF,Ya as aG,MKr as aH,DKr as aI,_Kr as aJ,tr as aK,C6 as aL,ke as aM,bn as aN,Ma as aO,TKr as aP,Go as aQ,kd as aR,gt as aS,yt as aT,AKr as aU,Pc as aV,Mc as aW,Pg as aX,Eo as aY,pa as aZ,ep as a_,vYr as aa,To as ab,jg as ac,V9 as ad,Z1 as ae,r$t as af,ot as ag,S$ as ah,bYr as ai,yYr as aj,Ze as ak,$t as al,mo as am,qr as an,Od as ao,Sn as ap,d2 as aq,aee as ar,oo as as,Xa as at,jy as au,ua as av,EMt as aw,o6 as ax,kYr as ay,Tqr as az,K as b,sc as b$,LKr as b0,km as b1,i7r as b2,I1 as b3,Yh as b4,Br as b5,fN as b6,On as b7,un as b8,ec as b9,xKr as bA,jw as bB,gN as bC,ln as bD,Do as bE,pt as bF,PYr as bG,Qa as bH,VGr as bI,U1 as bJ,UGr as bK,Hg as bL,mi as bM,CEt as bN,N0 as bO,l5e as bP,Et as bQ,_Ut as bR,Ka as bS,hYr as bT,itt as bU,T6 as bV,Dyr as bW,Myr as bX,Vi as bY,Y1 as bZ,dN as b_,Fxt as ba,Tkt as bb,fvt as bc,Dd as bd,rc as be,h2 as bf,SN as bg,zXr as bh,YXr as bi,HXr as bj,BXr as bk,doe as bl,Ul as bm,kN as bn,ud as bo,mYr as bp,UCt as bq,G1 as br,kp as bs,E6 as bt,P1 as bu,v5e as bv,Xl as bw,wDt as bx,CGr as by,M1 as bz,R as c,_Kt as c$,S6 as c0,uDt as c1,I9e as c2,m6e as c3,PN as c4,s5e as c5,zb as c6,jN as c7,RN as c8,D6 as c9,y6 as cA,Za as cB,A7 as cC,OYr as cD,Kn as cE,ULt as cF,wa as cG,j7 as cH,UUt as cI,P9e as cJ,gm as cK,v7e as cL,oGr as cM,c$r as cN,Tt as cO,NYr as cP,tGr as cQ,Q9e as cR,tz as cS,p2 as cT,tn as cU,Ja as cV,It as cW,zr as cX,ni as cY,ixt as cZ,h5e as c_,qDt as ca,sZr as cb,z6e as cc,B6e as cd,Uw as ce,fr as cf,m8r as cg,xN as ch,z1 as ci,gKr as cj,bne as ck,fYr as cl,O1 as cm,F0 as cn,a2 as co,Rwr as cp,V1 as cq,cZr as cr,Lie as cs,jb as ct,plr as cu,Qs as cv,mb as cw,iNt as cx,Ts as cy,Rd as cz,wt as d,Rqr as d$,W1 as d0,LJ as d1,Bg as d2,o5e as d3,La as d4,A$ as d5,TYr as d6,_Yr as d7,EYr as d8,E6e as d9,DZr as dA,LZr as dB,wN as dC,tqt as dD,ste as dE,lte as dF,oqt as dG,iqt as dH,H4e as dI,Ehr as dJ,X9e as dK,UFt as dL,Ng as dM,N1r as dN,EOt as dO,TOt as dP,PXr as dQ,U3r as dR,OZr as dS,Lqr as dT,Yqr as dU,zqr as dV,Nqr as dW,Vqr as dX,Hqr as dY,Bqr as dZ,Fqr as d_,E$ as da,JN as db,LYr as dc,AYr as dd,DYr as de,wKr as df,MYr as dg,ho as dh,IYr as di,Oit as dj,jYr as dk,t$r as dl,RYr as dm,hdr as dn,x$ as dp,Og as dq,Vl as dr,H3 as ds,cte as dt,rqt as du,nqt as dv,yN as dw,MZr as dx,PZr as dy,IZr as dz,F$ as e,kor as e$,Wqr as e0,Uqr as e1,jqr as e2,Iqr as e3,bee as e4,Oqr as e5,Qqr as e6,Pqr as e7,Mqr as e8,Xqr as e9,k3r as eA,E3r as eB,S3r as eC,zg as eD,jKr as eE,Dp as eF,q1 as eG,Da as eH,K9e as eI,L$ as eJ,Em as eK,gNt as eL,yNt as eM,lIt as eN,ist as eO,Df as eP,HZr as eQ,VLt as eR,zYr as eS,BZr as eT,A6 as eU,y$ as eV,j7e as eW,Ym as eX,aWe as eY,GZe as eZ,$Zr as e_,Dqr as ea,Kqr as eb,Jqr as ec,FYr as ed,eZr as ee,MXr as ef,o9e as eg,a6 as eh,qqr as ei,_h as ej,L6 as ek,bmr as el,LOt as em,AOt as en,_Ot as eo,L7 as ep,hm as eq,vmr as er,AL as es,FN as et,yOt as eu,tZr as ev,pb as ew,Vtt as ex,w6 as ey,hN as ez,gfr as f,sNt as f$,P7 as f0,qN as f1,Sor as f2,eg as f3,Ftr as f4,iHt as f5,Yw as f6,wor as f7,oHt as f8,nHt as f9,og as fA,O0 as fB,c1 as fC,I5r as fD,F5e as fE,bjt as fF,gjt as fG,K7e as fH,h4r as fI,M4r as fJ,k6 as fK,v6 as fL,CN as fM,gGr as fN,aZr as fO,_qr as fP,zZr as fQ,rZr as fR,iZr as fS,nZr as fT,lZr as fU,p$r as fV,bFt as fW,M$ as fX,Fd as fY,ql as fZ,oZr as f_,Nee as fa,FEe as fb,f$ as fc,$a as fd,FZr as fe,xa as ff,Ca as fg,_or as fh,Eor as fi,_6 as fj,$7e as fk,v6e as fl,Aqr as fm,pm as fn,jgr as fo,Qj as fp,M5r as fq,YFt as fr,Fgr as fs,bb as ft,AZr as fu,lN as fv,J4r as fw,P5r as fx,fm as fy,ig as fz,di as g,BYr as g$,yjt as g0,t_r as g1,Gj as g2,J5e as g3,K5e as g4,Hgr as g5,wb as g6,G7e as g7,rGr as g8,ofe as g9,Zqr as gA,tg as gB,fGr as gC,d$ as gD,S6e as gE,$J as gF,$b as gG,im as gH,$mr as gI,w$ as gJ,W$r as gK,XYr as gL,wue as gM,il as gN,F7e as gO,_Zr as gP,bJt as gQ,vN as gR,s$ as gS,vt as gT,$6 as gU,Gyr as gV,A9e as gW,m9e as gX,B8r as gY,Y8r as gZ,eyr as g_,g6 as ga,Y7e as gb,io as gc,W5e as gd,u2 as ge,Dr as gf,tHt as gg,DBt as gh,Par as gi,M7 as gj,t7 as gk,Zrr as gl,Fee as gm,Lp as gn,Rt as go,XN as gp,k$ as gq,Jf as gr,Itr as gs,D7 as gt,YHt as gu,TZr as gv,cVt as gw,C7e as gx,avt as gy,nRt as gz,p$ as h,oRt as h$,G8r as h0,W8r as h1,e7 as h2,Dj as h3,fWt as h4,rg as h5,y7e as h6,f7e as h7,g7e as h8,PZt as h9,B4r as hA,J4e as hB,g$r as hC,z_ as hD,mGr as hE,dHt as hF,pN as hG,SO as hH,$O as hI,Y4 as hJ,zKr as hK,NKr as hL,BKr as hM,Nne as hN,t9e as hO,FKr as hP,OKr as hQ,e9e as hR,D7e as hS,elr as hT,nGr as hU,YLt as hV,c2 as hW,lQr as hX,tR as hY,yKr as hZ,bKr as h_,KZt as ha,JYr as hb,eGr as hc,HN as hd,VN as he,iGr as hf,REt as hg,m7e as hh,pp as hi,_Yt as hj,kZr as hk,EZr as hl,x7e as hm,ZN as hn,Pd as ho,KN as hp,jZr as hq,Byr as hr,Y3r as hs,$$ as ht,hZr as hu,tp as hv,k6e as hw,RZr as hx,aZt as hy,H4r as hz,bQr as i,ZXr as i$,vKr as i0,YKr as i1,KKr as i2,XKr as i3,qKr as i4,ZKr as i5,GKr as i6,QKr as i7,Oir as i8,hGr as i9,SKr as iA,vXr as iB,iXr as iC,QYr as iD,iKr as iE,Q4e as iF,Soe as iG,bDt as iH,cQr as iI,dQr as iJ,uQr as iK,pQr as iL,Cie as iM,Sxt as iN,X6e as iO,H2r as iP,Eyr as iQ,tFt as iR,JXr as iS,j6e as iT,Vwr as iU,Hwr as iV,_yr as iW,QXr as iX,z4r as iY,NZr as iZ,uFt as i_,hjt as ia,DXr as ib,HYt as ic,pGr as id,dkr as ie,lXr as ig,bXr as ih,sXr as ii,LXr as ij,oXr as ik,aXr as il,Bpr as im,mXr as io,Kne as ip,wXr as iq,wmr as ir,lmr as is,iXt as it,kXr as iu,d9e as iv,l9e as iw,Hhr as ix,xXr as iy,Bb as iz,MQr as j,VYr as j$,sGr as j0,ZZr as j1,XXr as j2,aGr as j3,lGr as j4,KXr as j5,b$ as j6,jbt as j7,Zlr as j8,FLt as j9,Gbr as jA,F9e as jB,Rg as jC,uN as jD,HYr as jE,fQr as jF,tCr as jG,Txr as jH,eCr as jI,_u as jJ,sg as jK,rCr as jL,iz as jM,az as jN,uh as jO,Nwr as jP,q4e as jQ,cGr as jR,fjt as jS,Mvr as jT,Ayr as jU,Lyr as jV,uGr as jW,h8r as jX,XCt as jY,dGr as jZ,pDt as j_,zj as ja,mZr as jb,hDt as jc,wGr as jd,xGr as je,icr as jf,yDt as jg,ac as jh,WIt as ji,KZr as jj,uHt as jk,bd as jl,MYt as jm,qbr as jn,Ybr as jo,mN as jp,Yy as jq,V9e as jr,B7 as js,H9e as jt,lg as ju,B9e as jv,z9e as jw,N9e as jx,O9e as jy,R9e as jz,cce as k,MKt as k$,r_r as k0,pZr as k1,VXr as k2,I5e as k3,bGr as k4,hmt as k5,vGr as k6,yGr as k7,Tyr as k8,MIt as k9,p8e as kA,Akr as kB,B4e as kC,F5 as kD,kKr as kE,F7 as kF,Tmr as kG,AKt as kH,Ij as kI,SZr as kJ,I7e as kK,jBt as kL,uBt as kM,z7e as kN,hJt as kO,zwr as kP,eQr as kQ,yZr as kR,mQr as kS,uZr as kT,fZr as kU,vZr as kV,bZr as kW,gZr as kX,CZr as kY,xZr as kZ,wZr as k_,Gqr as ka,r8e as kb,c8e as kc,k1 as kd,j$ as ke,cg as kf,d8e as kg,Xb as kh,l8e as ki,GLt as kj,Qy as kk,Q6e as kl,a8e as km,Ykr as kn,i8e as ko,u8e as kp,hR as kq,R6 as kr,ZEr as ks,V7 as kt,s8e as ku,a5e as kv,n8e as kw,f8e as kx,Ese as ky,TN as kz,qo as l,hQr as l0,dZr as l1,Bwr as l2,vr as m,Ut as n,c as o,M as p,Ye as q,AQr as r,Fg as s,_5e as t,Nd as u,S5e as v,gQr as w,DQr as x,G as y,ca as z};