chainlesschain 0.162.15 → 0.162.16

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 (138) hide show
  1. package/package.json +2 -2
  2. package/src/assets/web-panel/assets/{AIOps-Dr5poTWh.js → AIOps-6yP2WySy.js} +1 -1
  3. package/src/assets/web-panel/assets/{ActionButton-DLOGPHQ-.js → ActionButton-BvpIMxiU.js} +1 -1
  4. package/src/assets/web-panel/assets/{Analytics-DBlO3FPX.js → Analytics-Bvg88oOa.js} +1 -1
  5. package/src/assets/web-panel/assets/{AppLayout-BrMarmWx.js → AppLayout-Do30UWbY.js} +2 -2
  6. package/src/assets/web-panel/assets/{Audit-DX6omFqA.js → Audit-Bfshrs5j.js} +1 -1
  7. package/src/assets/web-panel/assets/{Backup-0QSLlQkB.js → Backup-yKQbHMJr.js} +1 -1
  8. package/src/assets/web-panel/assets/{BaseInput-Dn4GFfR8.js → BaseInput-CxpV1ZXM.js} +1 -1
  9. package/src/assets/web-panel/assets/{Chat-CMTeA0Zo.js → Chat-y1SfGDl1.js} +1 -1
  10. package/src/assets/web-panel/assets/{Checkbox-BQQxf6iA.js → Checkbox-Dpoth43k.js} +1 -1
  11. package/src/assets/web-panel/assets/{Codegen-D2vrazFC.js → Codegen-DbwH-QDz.js} +1 -1
  12. package/src/assets/web-panel/assets/{Col-P1hVDVKm.js → Col-B-MGUxt2.js} +1 -1
  13. package/src/assets/web-panel/assets/{Community-CPcDkABv.js → Community-B521TAcS.js} +1 -1
  14. package/src/assets/web-panel/assets/{Compact-DvBQwE-b.js → Compact-CislP3fF.js} +1 -1
  15. package/src/assets/web-panel/assets/{Compliance-GX2qsHkq.js → Compliance-BXqrD-tO.js} +1 -1
  16. package/src/assets/web-panel/assets/{Cowork-CEEISrBb.js → Cowork-DtRMjAz_.js} +1 -1
  17. package/src/assets/web-panel/assets/{Cron-Y3D6wB4C.js → Cron-CX8dYcdW.js} +1 -1
  18. package/src/assets/web-panel/assets/{Crosschain-CnCjDKKD.js → Crosschain-DeEwabS0.js} +1 -1
  19. package/src/assets/web-panel/assets/{DID-CJ2EFB5b.js → DID-DjDE7pgB.js} +1 -1
  20. package/src/assets/web-panel/assets/{Dashboard-CWujrs70.js → Dashboard-pr7dCgLq.js} +2 -2
  21. package/src/assets/web-panel/assets/{Dropdown-BzKSQA5P.js → Dropdown-DuDw9Nfe.js} +1 -1
  22. package/src/assets/web-panel/assets/{Federation-DgaAWIwd.js → Federation-BiDyaRHe.js} +1 -1
  23. package/src/assets/web-panel/assets/{FormItemContext-BitgB4Gb.js → FormItemContext-BEF_PW-L.js} +1 -1
  24. package/src/assets/web-panel/assets/{Git-Bzj4vLLf.js → Git-DIbvoylw.js} +1 -1
  25. package/src/assets/web-panel/assets/{Governance-D7DEdSBD.js → Governance-FFY2QV_a.js} +1 -1
  26. package/src/assets/web-panel/assets/{Inference-CVsGLfcX.js → Inference-Clgxm2a1.js} +1 -1
  27. package/src/assets/web-panel/assets/{KnowledgeGraph-CF6C6ZNo.js → KnowledgeGraph-CNmtI1QB.js} +1 -1
  28. package/src/assets/web-panel/assets/{Logs-C0Er-tt8.js → Logs-ibszFmVA.js} +1 -1
  29. package/src/assets/web-panel/assets/{Marketplace-_E7uwUUU.js → Marketplace-CeBhDY6f.js} +1 -1
  30. package/src/assets/web-panel/assets/{McpTools-dHbktLMV.js → McpTools-Bl4misFt.js} +1 -1
  31. package/src/assets/web-panel/assets/{Memory-CaQ4UY7b.js → Memory-CTGi-Zcb.js} +1 -1
  32. package/src/assets/web-panel/assets/{MobileBridge-BbOh0uJt.js → MobileBridge-F7jJrt63.js} +1 -1
  33. package/src/assets/web-panel/assets/{MobileProjects-CfdNEimZ.js → MobileProjects--p2v4WUQ.js} +1 -1
  34. package/src/assets/web-panel/assets/{Mtc-HLvyepRP.js → Mtc-Cw0DfWPd.js} +1 -1
  35. package/src/assets/web-panel/assets/{MtcAudit-DMaHGoIr.js → MtcAudit-BNAv66VX.js} +1 -1
  36. package/src/assets/web-panel/assets/{Multisig-DFNZf0AB.js → Multisig-B4IxV-6K.js} +1 -1
  37. package/src/assets/web-panel/assets/{NLProgramming-cZwXhWy2.js → NLProgramming-J5Nfy4jx.js} +1 -1
  38. package/src/assets/web-panel/assets/{Notes-U_3n8Zid.js → Notes-BQl5wafk.js} +1 -1
  39. package/src/assets/web-panel/assets/{NotificationSettings-B4VvhkKf.js → NotificationSettings-1Sur2hZk.js} +1 -1
  40. package/src/assets/web-panel/assets/{Organization-BIwBFrdX.js → Organization-DSJGSd5V.js} +1 -1
  41. package/src/assets/web-panel/assets/{Overflow-_zxR8gF2.js → Overflow-6TgFQZGw.js} +1 -1
  42. package/src/assets/web-panel/assets/{P2P-DJXmWhLC.js → P2P-Cb-eWAUF.js} +1 -1
  43. package/src/assets/web-panel/assets/{Permissions-DwJ35K8Z.js → Permissions-C_xekWqT.js} +1 -1
  44. package/src/assets/web-panel/assets/{PersonalDataHub-CzZXLXGN.js → PersonalDataHub-C6X0ilxN.js} +1 -1
  45. package/src/assets/web-panel/assets/{Pipeline-DjtRGM8X.js → Pipeline-CQlD8pLe.js} +1 -1
  46. package/src/assets/web-panel/assets/{Privacy-BJhsIhGf.js → Privacy-DlTQcdGg.js} +1 -1
  47. package/src/assets/web-panel/assets/{ProjectInit-DEx5SDLh.js → ProjectInit-BicKKZtR.js} +1 -1
  48. package/src/assets/web-panel/assets/{ProjectSettings-B6qDg7nn.js → ProjectSettings-CXTbWgIg.js} +1 -1
  49. package/src/assets/web-panel/assets/{Projects-CKkTgrBf.js → Projects-Diq_IZJO.js} +1 -1
  50. package/src/assets/web-panel/assets/{Providers-3GEshcW_.js → Providers-CKXjLBNU.js} +1 -1
  51. package/src/assets/web-panel/assets/{QuickAsk-BfUXbKxa.js → QuickAsk-BnUavy-a.js} +1 -1
  52. package/src/assets/web-panel/assets/{Recommend-DgxYasSJ.js → Recommend-qbDO-M0M.js} +1 -1
  53. package/src/assets/web-panel/assets/{Reputation-CWvVg_V1.js → Reputation-BnkI4I_D.js} +1 -1
  54. package/src/assets/web-panel/assets/{Row-42M5ot1v.js → Row-sVpTpVTK.js} +1 -1
  55. package/src/assets/web-panel/assets/{RssFeed-Do3isL1x.js → RssFeed-CN85L1Ph.js} +1 -1
  56. package/src/assets/web-panel/assets/{Search-_7wgwjaR.js → Search-Dxxlr3ob.js} +1 -1
  57. package/src/assets/web-panel/assets/{Security-DKB6pe8t.js → Security-CVjWa1ad.js} +1 -1
  58. package/src/assets/web-panel/assets/{Services-BHrBJAcB.js → Services-BPiPhH6q.js} +1 -1
  59. package/src/assets/web-panel/assets/{Skeleton-C8L-EfGp.js → Skeleton-BpJEB3Px.js} +1 -1
  60. package/src/assets/web-panel/assets/{Skills-CU66huTh.js → Skills-Cjiy1gsC.js} +1 -1
  61. package/src/assets/web-panel/assets/{Sla-DA8AKNmI.js → Sla-CW2YJRZw.js} +1 -1
  62. package/src/assets/web-panel/assets/{SpeechSettings-CufjYTzV.js → SpeechSettings-DBGDc9cz.js} +1 -1
  63. package/src/assets/web-panel/assets/{SyncSettings-D_VAYHIg.js → SyncSettings-CWiQLmKL.js} +1 -1
  64. package/src/assets/web-panel/assets/{Tasks-BE6nYh9k.js → Tasks-CVsvO2yt.js} +1 -1
  65. package/src/assets/web-panel/assets/{Templates-BfRbttd6.js → Templates-BEXmGilK.js} +1 -1
  66. package/src/assets/web-panel/assets/{Tenant-YO71CL80.js → Tenant-Dd_xNf2O.js} +1 -1
  67. package/src/assets/web-panel/assets/{Terminal-D1mQaE_Z.js → Terminal-JIkt-KLk.js} +1 -1
  68. package/src/assets/web-panel/assets/{Tokens-CvnNQtX4.js → Tokens-Ca8aA-4X.js} +1 -1
  69. package/src/assets/web-panel/assets/{Trigger-BnN19FJt.js → Trigger-CLDtLBuR.js} +1 -1
  70. package/src/assets/web-panel/assets/{Trust-C6oZLHqp.js → Trust-DSzmH0eN.js} +1 -1
  71. package/src/assets/web-panel/assets/{UkeySign-BOhFYuWu.js → UkeySign-D7yOYajn.js} +1 -1
  72. package/src/assets/web-panel/assets/{VideoEditing-NMc6-qc-.js → VideoEditing-Dk3jUxyG.js} +1 -1
  73. package/src/assets/web-panel/assets/{Wallet-BALmcKtd.js → Wallet-BSB2tO_C.js} +1 -1
  74. package/src/assets/web-panel/assets/{WebAuthn-6IVe-W6O.js → WebAuthn-DAPZsZNw.js} +1 -1
  75. package/src/assets/web-panel/assets/{WorkflowEditor-BIv20DXb.js → WorkflowEditor-DinHN1vM.js} +1 -1
  76. package/src/assets/web-panel/assets/{chat-CiceyA69.js → chat-BLyN3kuS.js} +1 -1
  77. package/src/assets/web-panel/assets/{colors-CxwvpRW0.js → colors-B-IfN2x7.js} +1 -1
  78. package/src/assets/web-panel/assets/{compact-item-N6ASDseQ.js → compact-item-tVJNTa_f.js} +1 -1
  79. package/src/assets/web-panel/assets/{createContext-CQ8PEhyP.js → createContext-CeHSYhwo.js} +1 -1
  80. package/src/assets/web-panel/assets/{hasIn-DDiIuryC.js → hasIn-CP8akQuY.js} +1 -1
  81. package/src/assets/web-panel/assets/{index-xQlQRo2j.js → index-3T9u2Hlb.js} +1 -1
  82. package/src/assets/web-panel/assets/{index-DobYLmfZ.js → index-B6RV21Hn.js} +1 -1
  83. package/src/assets/web-panel/assets/{index-Bj-mAQFK.js → index-BAhYPqmm.js} +1 -1
  84. package/src/assets/web-panel/assets/{index-92sMXPmR.js → index-BDS9QmmD.js} +1 -1
  85. package/src/assets/web-panel/assets/{index-BKmY57ry.js → index-BRH7hf5q.js} +1 -1
  86. package/src/assets/web-panel/assets/{index-D0yG93O4.js → index-BZhvUfFb.js} +1 -1
  87. package/src/assets/web-panel/assets/{index-Cwk0olXV.js → index-B_pAhN3p.js} +1 -1
  88. package/src/assets/web-panel/assets/{index-BCgZTQf8.js → index-BsMpKD71.js} +1 -1
  89. package/src/assets/web-panel/assets/{index-ClASVywF.js → index-ByqjsQPb.js} +1 -1
  90. package/src/assets/web-panel/assets/{index-mmpauJ3E.js → index-C44pVyK1.js} +1 -1
  91. package/src/assets/web-panel/assets/{index-DEjAgx2R.js → index-C6NyhfFI.js} +1 -1
  92. package/src/assets/web-panel/assets/index-C6dKiBgm.js +1 -0
  93. package/src/assets/web-panel/assets/{index-DcMESTJs.js → index-COqTEK1x.js} +1 -1
  94. package/src/assets/web-panel/assets/{index-CnArbjXg.js → index-CP5ax2Ox.js} +1 -1
  95. package/src/assets/web-panel/assets/{index-Cur_KKpV.js → index-CPdpqzTz.js} +1 -1
  96. package/src/assets/web-panel/assets/{index-BZ4O1Vp7.js → index-C_sA6V0-.js} +1 -1
  97. package/src/assets/web-panel/assets/{index-Bw6UqIkJ.js → index-C_we-zLv.js} +1 -1
  98. package/src/assets/web-panel/assets/{index-D58a5SL3.js → index-Cjg_lXkn.js} +1 -1
  99. package/src/assets/web-panel/assets/{index-DWKigrAM.js → index-CkMJbSJn.js} +1 -1
  100. package/src/assets/web-panel/assets/{index-BjvirvV4.js → index-CmFox476.js} +1 -1
  101. package/src/assets/web-panel/assets/{index-Dj2wgF3A.js → index-CrxfAG6t.js} +1 -1
  102. package/src/assets/web-panel/assets/{index-C_dbCu-F.js → index-CtgPPk47.js} +1 -1
  103. package/src/assets/web-panel/assets/{index-_BHtKVC_.js → index-CxRjf-uA.js} +1 -1
  104. package/src/assets/web-panel/assets/{index-BzdEj9_B.js → index-D0Lw2-GE.js} +1 -1
  105. package/src/assets/web-panel/assets/{index-CcUK2M7W.js → index-D338fQ78.js} +1 -1
  106. package/src/assets/web-panel/assets/{index-C43WIe_p.js → index-D7xlQtKS.js} +1 -1
  107. package/src/assets/web-panel/assets/{index-COIxnEwP.js → index-DISTBJJ4.js} +1 -1
  108. package/src/assets/web-panel/assets/{index-Cb0QVAZL.js → index-DL2e2Kwh.js} +3 -3
  109. package/src/assets/web-panel/assets/{index-1jBrqw2R.js → index-DNpXi3KX.js} +1 -1
  110. package/src/assets/web-panel/assets/{index-DgwpVvQq.js → index-DVbSr5gk.js} +1 -1
  111. package/src/assets/web-panel/assets/{index-hn9LVkIY.js → index-DYEooXtQ.js} +1 -1
  112. package/src/assets/web-panel/assets/{index-CHsNn-Qv.js → index-DaXMEgmQ.js} +1 -1
  113. package/src/assets/web-panel/assets/{index-DtpWqJ-2.js → index-DfzQT6CX.js} +1 -1
  114. package/src/assets/web-panel/assets/{index-BKLatStI.js → index-Dk_cKbpp.js} +1 -1
  115. package/src/assets/web-panel/assets/{index-Dp3r80qO.js → index-pO_TKKcK.js} +1 -1
  116. package/src/assets/web-panel/assets/{index-BdmcwwMp.js → index-q4cwusSB.js} +1 -1
  117. package/src/assets/web-panel/assets/{index-bYorCa3r.js → index-rdeSvPj9.js} +1 -1
  118. package/src/assets/web-panel/assets/index-vl01xWcc.js +1 -0
  119. package/src/assets/web-panel/assets/{index-DUKjS4kF.js → index-xaqrvGuG.js} +1 -1
  120. package/src/assets/web-panel/assets/{initDefaultProps-1MKZtqXZ.js → initDefaultProps-Cw37W7y2.js} +1 -1
  121. package/src/assets/web-panel/assets/{motion-DFBQpRS8.js → motion-DOWpjqMY.js} +1 -1
  122. package/src/assets/web-panel/assets/{move-CiI8Ada0.js → move-Ha0Ha2IK.js} +1 -1
  123. package/src/assets/web-panel/assets/{omit-CjeFoPcC.js → omit-DwGrzMoG.js} +1 -1
  124. package/src/assets/web-panel/assets/{pickAttrs-Be3kefJq.js → pickAttrs-BRVWfNub.js} +1 -1
  125. package/src/assets/web-panel/assets/{placementArrow-Be5Ra1_B.js → placementArrow-hV_RKr6c.js} +1 -1
  126. package/src/assets/web-panel/assets/{responsiveObserve-NCu3YHiX.js → responsiveObserve-PWGubgde.js} +1 -1
  127. package/src/assets/web-panel/assets/{slide-f23lSB4X.js → slide-TRaJdEGF.js} +1 -1
  128. package/src/assets/web-panel/assets/{statusUtils-Dq99US_U.js → statusUtils-Dtpf-U70.js} +1 -1
  129. package/src/assets/web-panel/assets/{styleChecker-B-UUq5Ww.js → styleChecker-pWt7CTDQ.js} +1 -1
  130. package/src/assets/web-panel/assets/{useFlexGapSupport-D6aUzeVO.js → useFlexGapSupport-BojArhOx.js} +1 -1
  131. package/src/assets/web-panel/assets/{useFs-DU-R5a4I.js → useFs-ZGDRvFRC.js} +1 -1
  132. package/src/assets/web-panel/assets/{vnode-N7r8LSGe.js → vnode-CBtr3ooD.js} +1 -1
  133. package/src/assets/web-panel/assets/{zoom-07xoxB1t.js → zoom-DyGC413M.js} +1 -1
  134. package/src/assets/web-panel/index.html +1 -1
  135. package/src/commands/hub.js +162 -1
  136. package/src/lib/personal-data-hub-aichat-wizard.js +29 -15
  137. package/src/assets/web-panel/assets/index-1losWCP0.js +0 -1
  138. package/src/assets/web-panel/assets/index-EoP_WtDt.js +0 -1
@@ -1,4 +1,4 @@
1
- import{l as Ce,m as Te,h as r,r as ze,o as A,X as ie,q as v,f as m,i as I,aa as y,J as Be,ab as Me,P as x,ac as q,ad as j}from"./index-Cb0QVAZL.js";import oe from"./index-BzdEj9_B.js";import{i as we}from"./isPlainObject-_gz-soRW.js";import{d as Ae}from"./devWarning-CNIS3FrJ.js";import{u as D,E as X,s as H,S as s,a as ne}from"./Skeleton-C8L-EfGp.js";import{i as re}from"./initDefaultProps-1MKZtqXZ.js";import{d as $,c as o,f as T,k as ae}from"./vendor-DhFY8mDK.js";import{o as le}from"./omit-CjeFoPcC.js";import{a as Ie}from"./vnode-N7r8LSGe.js";import"./icons-BOPtEWK4.js";import"./raf-Deuc0E8-.js";import"./KeyCode-D63Tfrq7.js";import"./index-mmpauJ3E.js";import"./Trigger-BnN19FJt.js";import"./motion-DFBQpRS8.js";import"./isVisible-C7tPsqfj.js";import"./ResizeObserver.es-D6qJbdzf.js";import"./_getTag-BVc6NQ_K.js";import"./_arrayIncludes-B8uzE354.js";import"./injectionKey-BXVc-oGP.js";import"./Overflow-_zxR8gF2.js";import"./index-BCgZTQf8.js";import"./index-DtpWqJ-2.js";import"./placementArrow-Be5Ra1_B.js";import"./firstNotUndefined-CLFzEa0p.js";import"./colors-CxwvpRW0.js";import"./zoom-07xoxB1t.js";import"./collapseMotion-DfnRZex1.js";import"./slide-f23lSB4X.js";import"./OverrideContext-C_4H9tGA.js";import"./Dropdown-BzKSQA5P.js";import"./useState-DGS1NOyn.js";import"./useRefs-Cdq8EWeF.js";import"./hasIn-DDiIuryC.js";import"./isSymbol-DAy2hlR5.js";import"./isMobile--2fOlCHx.js";import"./useMergedState-WwedrFR0.js";import"./warning-Pq00owYb.js";const De=e=>{const{antCls:t,componentCls:a,cardHeadHeight:i,cardPaddingBase:n,cardHeadTabsMarginBottom:d}=e;return r(r({display:"flex",justifyContent:"center",flexDirection:"column",minHeight:i,marginBottom:-1,padding:`0 ${n}px`,color:e.colorTextHeading,fontWeight:e.fontWeightStrong,fontSize:e.fontSizeLG,background:"transparent",borderBottom:`${e.lineWidth}px ${e.lineType} ${e.colorBorderSecondary}`,borderRadius:`${e.borderRadiusLG}px ${e.borderRadiusLG}px 0 0`},A()),{"&-wrapper":{width:"100%",display:"flex",alignItems:"center"},"&-title":r(r({display:"inline-block",flex:1},ie),{[`
1
+ import{l as Ce,m as Te,h as r,r as ze,o as A,X as ie,q as v,f as m,i as I,aa as y,J as Be,ab as Me,P as x,ac as q,ad as j}from"./index-DL2e2Kwh.js";import oe from"./index-D0Lw2-GE.js";import{i as we}from"./isPlainObject-_gz-soRW.js";import{d as Ae}from"./devWarning-CNIS3FrJ.js";import{u as D,E as X,s as H,S as s,a as ne}from"./Skeleton-BpJEB3Px.js";import{i as re}from"./initDefaultProps-Cw37W7y2.js";import{d as $,c as o,f as T,k as ae}from"./vendor-DhFY8mDK.js";import{o as le}from"./omit-DwGrzMoG.js";import{a as Ie}from"./vnode-CBtr3ooD.js";import"./icons-BOPtEWK4.js";import"./raf-Deuc0E8-.js";import"./KeyCode-D63Tfrq7.js";import"./index-C44pVyK1.js";import"./Trigger-CLDtLBuR.js";import"./motion-DOWpjqMY.js";import"./isVisible-C7tPsqfj.js";import"./ResizeObserver.es-D6qJbdzf.js";import"./_getTag-BVc6NQ_K.js";import"./_arrayIncludes-B8uzE354.js";import"./injectionKey-BXVc-oGP.js";import"./Overflow-6TgFQZGw.js";import"./index-BsMpKD71.js";import"./index-DfzQT6CX.js";import"./placementArrow-hV_RKr6c.js";import"./firstNotUndefined-CLFzEa0p.js";import"./colors-B-IfN2x7.js";import"./zoom-DyGC413M.js";import"./collapseMotion-DfnRZex1.js";import"./slide-TRaJdEGF.js";import"./OverrideContext-C_4H9tGA.js";import"./Dropdown-DuDw9Nfe.js";import"./useState-DGS1NOyn.js";import"./useRefs-Cdq8EWeF.js";import"./hasIn-CP8akQuY.js";import"./isSymbol-DAy2hlR5.js";import"./isMobile--2fOlCHx.js";import"./useMergedState-WwedrFR0.js";import"./warning-Pq00owYb.js";const De=e=>{const{antCls:t,componentCls:a,cardHeadHeight:i,cardPaddingBase:n,cardHeadTabsMarginBottom:d}=e;return r(r({display:"flex",justifyContent:"center",flexDirection:"column",minHeight:i,marginBottom:-1,padding:`0 ${n}px`,color:e.colorTextHeading,fontWeight:e.fontWeightStrong,fontSize:e.fontSizeLG,background:"transparent",borderBottom:`${e.lineWidth}px ${e.lineType} ${e.colorBorderSecondary}`,borderRadius:`${e.borderRadiusLG}px ${e.borderRadiusLG}px 0 0`},A()),{"&-wrapper":{width:"100%",display:"flex",alignItems:"center"},"&-title":r(r({display:"inline-block",flex:1},ie),{[`
2
2
  > ${a}-typography,
3
3
  > ${a}-typography-edit-content
4
4
  `]:{insetInlineStart:0,marginTop:0,marginBottom:0}}),[`${t}-tabs-top`]:{clear:"both",marginBottom:d,color:e.colorText,fontWeight:"normal",fontSize:e.fontSize,"&-bar":{borderBottom:`${e.lineWidth}px ${e.lineType} ${e.colorBorderSecondary}`}}})},He=e=>{const{cardPaddingBase:t,colorBorderSecondary:a,cardShadow:i,lineWidth:n}=e;return{width:"33.33%",padding:t,border:0,borderRadius:0,boxShadow:`
@@ -1,4 +1,4 @@
1
- import{l as te,m as le,K as ie,h as s,r as E,an as se,G as m,V as I,Z as A,P as ce,$ as de,q as K,L as ue,w as be,J as ve,i as N,f as D}from"./index-Cb0QVAZL.js";import{V as fe}from"./Checkbox-BQQxf6iA.js";import{a as X,F as he}from"./FormItemContext-BitgB4Gb.js";import{d as L,i as me,b as pe,e as ge,o as xe,c as P,f as S,r as w,w as U,p as Ce}from"./vendor-DhFY8mDK.js";const $e=new ie("antCheckboxEffect",{"0%":{transform:"scale(1)",opacity:.5},"100%":{transform:"scale(1.6)",opacity:0}}),ye=e=>{const{checkboxCls:a}=e,n=`${a}-wrapper`;return[{[`${a}-group`]:s(s({},E(e)),{display:"inline-flex",flexWrap:"wrap",columnGap:e.marginXS,[`> ${e.antCls}-row`]:{flex:1}}),[n]:s(s({},E(e)),{display:"inline-flex",alignItems:"baseline",cursor:"pointer","&:after":{display:"inline-block",width:0,overflow:"hidden",content:"'\\a0'"},[`& + ${n}`]:{marginInlineStart:0},[`&${n}-in-form-item`]:{'input[type="checkbox"]':{width:14,height:14}}}),[a]:s(s({},E(e)),{position:"relative",whiteSpace:"nowrap",lineHeight:1,cursor:"pointer",alignSelf:"center",[`${a}-input`]:{position:"absolute",inset:0,zIndex:1,cursor:"pointer",opacity:0,margin:0,[`&:focus-visible + ${a}-inner`]:s({},se(e))},[`${a}-inner`]:{boxSizing:"border-box",position:"relative",top:0,insetInlineStart:0,display:"block",width:e.checkboxSize,height:e.checkboxSize,direction:"ltr",backgroundColor:e.colorBgContainer,border:`${e.lineWidth}px ${e.lineType} ${e.colorBorder}`,borderRadius:e.borderRadiusSM,borderCollapse:"separate",transition:`all ${e.motionDurationSlow}`,"&:after":{boxSizing:"border-box",position:"absolute",top:"50%",insetInlineStart:"21.5%",display:"table",width:e.checkboxSize/14*5,height:e.checkboxSize/14*8,border:`${e.lineWidthBold}px solid ${e.colorWhite}`,borderTop:0,borderInlineStart:0,transform:"rotate(45deg) scale(0) translate(-50%,-50%)",opacity:0,content:'""',transition:`all ${e.motionDurationFast} ${e.motionEaseInBack}, opacity ${e.motionDurationFast}`}},"& + span":{paddingInlineStart:e.paddingXS,paddingInlineEnd:e.paddingXS}})},{[a]:{"&-indeterminate":{[`${a}-inner`]:{"&:after":{top:"50%",insetInlineStart:"50%",width:e.fontSizeLG/2,height:e.fontSizeLG/2,backgroundColor:e.colorPrimary,border:0,transform:"translate(-50%, -50%) scale(1)",opacity:1,content:'""'}}}}},{[`${n}:hover ${a}:after`]:{visibility:"visible"},[`
1
+ import{l as te,m as le,K as ie,h as s,r as E,an as se,G as m,V as I,Z as A,P as ce,$ as de,q as K,L as ue,w as be,J as ve,i as N,f as D}from"./index-DL2e2Kwh.js";import{V as fe}from"./Checkbox-Dpoth43k.js";import{a as X,F as he}from"./FormItemContext-BEF_PW-L.js";import{d as L,i as me,b as pe,e as ge,o as xe,c as P,f as S,r as w,w as U,p as Ce}from"./vendor-DhFY8mDK.js";const $e=new ie("antCheckboxEffect",{"0%":{transform:"scale(1)",opacity:.5},"100%":{transform:"scale(1.6)",opacity:0}}),ye=e=>{const{checkboxCls:a}=e,n=`${a}-wrapper`;return[{[`${a}-group`]:s(s({},E(e)),{display:"inline-flex",flexWrap:"wrap",columnGap:e.marginXS,[`> ${e.antCls}-row`]:{flex:1}}),[n]:s(s({},E(e)),{display:"inline-flex",alignItems:"baseline",cursor:"pointer","&:after":{display:"inline-block",width:0,overflow:"hidden",content:"'\\a0'"},[`& + ${n}`]:{marginInlineStart:0},[`&${n}-in-form-item`]:{'input[type="checkbox"]':{width:14,height:14}}}),[a]:s(s({},E(e)),{position:"relative",whiteSpace:"nowrap",lineHeight:1,cursor:"pointer",alignSelf:"center",[`${a}-input`]:{position:"absolute",inset:0,zIndex:1,cursor:"pointer",opacity:0,margin:0,[`&:focus-visible + ${a}-inner`]:s({},se(e))},[`${a}-inner`]:{boxSizing:"border-box",position:"relative",top:0,insetInlineStart:0,display:"block",width:e.checkboxSize,height:e.checkboxSize,direction:"ltr",backgroundColor:e.colorBgContainer,border:`${e.lineWidth}px ${e.lineType} ${e.colorBorder}`,borderRadius:e.borderRadiusSM,borderCollapse:"separate",transition:`all ${e.motionDurationSlow}`,"&:after":{boxSizing:"border-box",position:"absolute",top:"50%",insetInlineStart:"21.5%",display:"table",width:e.checkboxSize/14*5,height:e.checkboxSize/14*8,border:`${e.lineWidthBold}px solid ${e.colorWhite}`,borderTop:0,borderInlineStart:0,transform:"rotate(45deg) scale(0) translate(-50%,-50%)",opacity:0,content:'""',transition:`all ${e.motionDurationFast} ${e.motionEaseInBack}, opacity ${e.motionDurationFast}`}},"& + span":{paddingInlineStart:e.paddingXS,paddingInlineEnd:e.paddingXS}})},{[a]:{"&-indeterminate":{[`${a}-inner`]:{"&:after":{top:"50%",insetInlineStart:"50%",width:e.fontSizeLG/2,height:e.fontSizeLG/2,backgroundColor:e.colorPrimary,border:0,transform:"translate(-50%, -50%) scale(1)",opacity:1,content:'""'}}}}},{[`${n}:hover ${a}:after`]:{visibility:"visible"},[`
2
2
  ${n}:not(${n}-disabled),
3
3
  ${a}:not(${a}-disabled)
4
4
  `]:{[`&:hover ${a}-inner`]:{borderColor:e.colorPrimary}},[`${n}:not(${n}-disabled)`]:{[`&:hover ${a}-checked:not(${a}-disabled) ${a}-inner`]:{backgroundColor:e.colorPrimaryHover,borderColor:"transparent"},[`&:hover ${a}-checked:not(${a}-disabled):after`]:{borderColor:e.colorPrimaryHover}}},{[`${a}-checked`]:{[`${a}-inner`]:{backgroundColor:e.colorPrimary,borderColor:e.colorPrimary,"&:after":{opacity:1,transform:"rotate(45deg) scale(1) translate(-50%,-50%)",transition:`all ${e.motionDurationMid} ${e.motionEaseOutBack} ${e.motionDurationFast}`}},"&:after":{position:"absolute",top:0,insetInlineStart:0,width:"100%",height:"100%",borderRadius:e.borderRadiusSM,visibility:"hidden",border:`${e.lineWidthBold}px solid ${e.colorPrimary}`,animationName:$e,animationDuration:e.motionDurationSlow,animationTimingFunction:"ease-in-out",animationFillMode:"backwards",content:'""',transition:`all ${e.motionDurationSlow}`}},[`
@@ -1 +1 @@
1
- import{l as q,m as J,h as N,r as Q,$ as P,t as tt,f as b,S as et,p as nt,q as ot,I as st}from"./index-Cb0QVAZL.js";import it from"./index-Dp3r80qO.js";import{B as rt}from"./index-C_dbCu-F.js";import{d as L,b as F,w as lt,c as C,F as D,f as O,s as y,r as at}from"./vendor-DhFY8mDK.js";import{R as ut}from"./icons-BOPtEWK4.js";import"./initDefaultProps-1MKZtqXZ.js";import"./index-DUKjS4kF.js";import"./isVisible-C7tPsqfj.js";import"./useState-DGS1NOyn.js";import"./raf-Deuc0E8-.js";import"./devWarning-CNIS3FrJ.js";import"./warning-Pq00owYb.js";import"./compact-item-N6ASDseQ.js";import"./createContext-CQ8PEhyP.js";import"./Compact-DvBQwE-b.js";import"./_getTag-BVc6NQ_K.js";const ct=r=>{const{componentCls:s}=r;return{[s]:N(N({},Q(r)),{display:"flex",justifyContent:"center",alignItems:"center",padding:r.paddingSM,backgroundColor:r.colorWhite,borderRadius:r.borderRadiusLG,border:`${r.lineWidth}px ${r.lineType} ${r.colorSplit}`,position:"relative",width:"100%",height:"100%",overflow:"hidden",[`& > ${s}-mask`]:{position:"absolute",insetBlockStart:0,insetInlineStart:0,zIndex:10,display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",width:"100%",height:"100%",color:r.colorText,lineHeight:r.lineHeight,background:r.QRCodeMaskBackgroundColor,textAlign:"center",[`& > ${s}-expired , & > ${s}-scanned`]:{color:r.QRCodeTextColor}},"&-icon":{marginBlockEnd:r.marginXS,fontSize:r.controlHeight}}),[`${s}-borderless`]:{borderColor:"transparent"}}},ht=q("QRCode",r=>ct(J(r,{QRCodeTextColor:"rgba(0, 0, 0, 0.88)",QRCodeMaskBackgroundColor:"rgba(255, 255, 255, 0.96)"}))),z=()=>({size:{type:Number,default:160},value:{type:String,required:!0},type:P("canvas"),color:String,bgColor:String,includeMargin:Boolean,imageSettings:tt()}),ft=()=>N(N({},z()),{errorLevel:P("M"),icon:String,iconSize:{type:Number,default:40},status:P("active"),bordered:{type:Boolean,default:!0}});var p;(function(r){class s{static encodeText(t,n){const e=r.QrSegment.makeSegments(t);return s.encodeSegments(e,n)}static encodeBinary(t,n){const e=r.QrSegment.makeBytes(t);return s.encodeSegments([e],n)}static encodeSegments(t,n){let e=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,o=arguments.length>3&&arguments[3]!==void 0?arguments[3]:40,i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:-1,c=arguments.length>5&&arguments[5]!==void 0?arguments[5]:!0;if(!(s.MIN_VERSION<=e&&e<=o&&o<=s.MAX_VERSION)||i<-1||i>7)throw new RangeError("Invalid value");let a,g;for(a=e;;a++){const m=s.getNumDataCodewords(a,n)*8,M=l.getTotalBits(t,a);if(M<=m){g=M;break}if(a>=o)throw new RangeError("Data too long")}for(const m of[s.Ecc.MEDIUM,s.Ecc.QUARTILE,s.Ecc.HIGH])c&&g<=s.getNumDataCodewords(a,m)*8&&(n=m);const f=[];for(const m of t){u(m.mode.modeBits,4,f),u(m.numChars,m.mode.numCharCountBits(a),f);for(const M of m.getData())f.push(M)}h(f.length==g);const R=s.getNumDataCodewords(a,n)*8;h(f.length<=R),u(0,Math.min(4,R-f.length),f),u(0,(8-f.length%8)%8,f),h(f.length%8==0);for(let m=236;f.length<R;m^=253)u(m,8,f);const w=[];for(;w.length*8<f.length;)w.push(0);return f.forEach((m,M)=>w[M>>>3]|=m<<7-(M&7)),new s(a,n,w,i)}constructor(t,n,e,o){if(this.version=t,this.errorCorrectionLevel=n,this.modules=[],this.isFunction=[],t<s.MIN_VERSION||t>s.MAX_VERSION)throw new RangeError("Version value out of range");if(o<-1||o>7)throw new RangeError("Mask value out of range");this.size=t*4+17;const i=[];for(let a=0;a<this.size;a++)i.push(!1);for(let a=0;a<this.size;a++)this.modules.push(i.slice()),this.isFunction.push(i.slice());this.drawFunctionPatterns();const c=this.addEccAndInterleave(e);if(this.drawCodewords(c),o==-1){let a=1e9;for(let g=0;g<8;g++){this.applyMask(g),this.drawFormatBits(g);const f=this.getPenaltyScore();f<a&&(o=g,a=f),this.applyMask(g)}}h(0<=o&&o<=7),this.mask=o,this.applyMask(o),this.drawFormatBits(o),this.isFunction=[]}getModule(t,n){return 0<=t&&t<this.size&&0<=n&&n<this.size&&this.modules[n][t]}getModules(){return this.modules}drawFunctionPatterns(){for(let e=0;e<this.size;e++)this.setFunctionModule(6,e,e%2==0),this.setFunctionModule(e,6,e%2==0);this.drawFinderPattern(3,3),this.drawFinderPattern(this.size-4,3),this.drawFinderPattern(3,this.size-4);const t=this.getAlignmentPatternPositions(),n=t.length;for(let e=0;e<n;e++)for(let o=0;o<n;o++)e==0&&o==0||e==0&&o==n-1||e==n-1&&o==0||this.drawAlignmentPattern(t[e],t[o]);this.drawFormatBits(0),this.drawVersion()}drawFormatBits(t){const n=this.errorCorrectionLevel.formatBits<<3|t;let e=n;for(let i=0;i<10;i++)e=e<<1^(e>>>9)*1335;const o=(n<<10|e)^21522;h(o>>>15==0);for(let i=0;i<=5;i++)this.setFunctionModule(8,i,d(o,i));this.setFunctionModule(8,7,d(o,6)),this.setFunctionModule(8,8,d(o,7)),this.setFunctionModule(7,8,d(o,8));for(let i=9;i<15;i++)this.setFunctionModule(14-i,8,d(o,i));for(let i=0;i<8;i++)this.setFunctionModule(this.size-1-i,8,d(o,i));for(let i=8;i<15;i++)this.setFunctionModule(8,this.size-15+i,d(o,i));this.setFunctionModule(8,this.size-8,!0)}drawVersion(){if(this.version<7)return;let t=this.version;for(let e=0;e<12;e++)t=t<<1^(t>>>11)*7973;const n=this.version<<12|t;h(n>>>18==0);for(let e=0;e<18;e++){const o=d(n,e),i=this.size-11+e%3,c=Math.floor(e/3);this.setFunctionModule(i,c,o),this.setFunctionModule(c,i,o)}}drawFinderPattern(t,n){for(let e=-4;e<=4;e++)for(let o=-4;o<=4;o++){const i=Math.max(Math.abs(o),Math.abs(e)),c=t+o,a=n+e;0<=c&&c<this.size&&0<=a&&a<this.size&&this.setFunctionModule(c,a,i!=2&&i!=4)}}drawAlignmentPattern(t,n){for(let e=-2;e<=2;e++)for(let o=-2;o<=2;o++)this.setFunctionModule(t+o,n+e,Math.max(Math.abs(o),Math.abs(e))!=1)}setFunctionModule(t,n,e){this.modules[n][t]=e,this.isFunction[n][t]=!0}addEccAndInterleave(t){const n=this.version,e=this.errorCorrectionLevel;if(t.length!=s.getNumDataCodewords(n,e))throw new RangeError("Invalid argument");const o=s.NUM_ERROR_CORRECTION_BLOCKS[e.ordinal][n],i=s.ECC_CODEWORDS_PER_BLOCK[e.ordinal][n],c=Math.floor(s.getNumRawDataModules(n)/8),a=o-c%o,g=Math.floor(c/o),f=[],R=s.reedSolomonComputeDivisor(i);for(let m=0,M=0;m<o;m++){const v=t.slice(M,M+g-i+(m<a?0:1));M+=v.length;const A=s.reedSolomonComputeRemainder(v,R);m<a&&v.push(0),f.push(v.concat(A))}const w=[];for(let m=0;m<f[0].length;m++)f.forEach((M,v)=>{(m!=g-i||v>=a)&&w.push(M[m])});return h(w.length==c),w}drawCodewords(t){if(t.length!=Math.floor(s.getNumRawDataModules(this.version)/8))throw new RangeError("Invalid argument");let n=0;for(let e=this.size-1;e>=1;e-=2){e==6&&(e=5);for(let o=0;o<this.size;o++)for(let i=0;i<2;i++){const c=e-i,g=(e+1&2)==0?this.size-1-o:o;!this.isFunction[g][c]&&n<t.length*8&&(this.modules[g][c]=d(t[n>>>3],7-(n&7)),n++)}}h(n==t.length*8)}applyMask(t){if(t<0||t>7)throw new RangeError("Mask value out of range");for(let n=0;n<this.size;n++)for(let e=0;e<this.size;e++){let o;switch(t){case 0:o=(e+n)%2==0;break;case 1:o=n%2==0;break;case 2:o=e%3==0;break;case 3:o=(e+n)%3==0;break;case 4:o=(Math.floor(e/3)+Math.floor(n/2))%2==0;break;case 5:o=e*n%2+e*n%3==0;break;case 6:o=(e*n%2+e*n%3)%2==0;break;case 7:o=((e+n)%2+e*n%3)%2==0;break;default:throw new Error("Unreachable")}!this.isFunction[n][e]&&o&&(this.modules[n][e]=!this.modules[n][e])}}getPenaltyScore(){let t=0;for(let i=0;i<this.size;i++){let c=!1,a=0;const g=[0,0,0,0,0,0,0];for(let f=0;f<this.size;f++)this.modules[i][f]==c?(a++,a==5?t+=s.PENALTY_N1:a>5&&t++):(this.finderPenaltyAddHistory(a,g),c||(t+=this.finderPenaltyCountPatterns(g)*s.PENALTY_N3),c=this.modules[i][f],a=1);t+=this.finderPenaltyTerminateAndCount(c,a,g)*s.PENALTY_N3}for(let i=0;i<this.size;i++){let c=!1,a=0;const g=[0,0,0,0,0,0,0];for(let f=0;f<this.size;f++)this.modules[f][i]==c?(a++,a==5?t+=s.PENALTY_N1:a>5&&t++):(this.finderPenaltyAddHistory(a,g),c||(t+=this.finderPenaltyCountPatterns(g)*s.PENALTY_N3),c=this.modules[f][i],a=1);t+=this.finderPenaltyTerminateAndCount(c,a,g)*s.PENALTY_N3}for(let i=0;i<this.size-1;i++)for(let c=0;c<this.size-1;c++){const a=this.modules[i][c];a==this.modules[i][c+1]&&a==this.modules[i+1][c]&&a==this.modules[i+1][c+1]&&(t+=s.PENALTY_N2)}let n=0;for(const i of this.modules)n=i.reduce((c,a)=>c+(a?1:0),n);const e=this.size*this.size,o=Math.ceil(Math.abs(n*20-e*10)/e)-1;return h(0<=o&&o<=9),t+=o*s.PENALTY_N4,h(0<=t&&t<=2568888),t}getAlignmentPatternPositions(){if(this.version==1)return[];{const t=Math.floor(this.version/7)+2,n=this.version==32?26:Math.ceil((this.version*4+4)/(t*2-2))*2,e=[6];for(let o=this.size-7;e.length<t;o-=n)e.splice(1,0,o);return e}}static getNumRawDataModules(t){if(t<s.MIN_VERSION||t>s.MAX_VERSION)throw new RangeError("Version number out of range");let n=(16*t+128)*t+64;if(t>=2){const e=Math.floor(t/7)+2;n-=(25*e-10)*e-55,t>=7&&(n-=36)}return h(208<=n&&n<=29648),n}static getNumDataCodewords(t,n){return Math.floor(s.getNumRawDataModules(t)/8)-s.ECC_CODEWORDS_PER_BLOCK[n.ordinal][t]*s.NUM_ERROR_CORRECTION_BLOCKS[n.ordinal][t]}static reedSolomonComputeDivisor(t){if(t<1||t>255)throw new RangeError("Degree out of range");const n=[];for(let o=0;o<t-1;o++)n.push(0);n.push(1);let e=1;for(let o=0;o<t;o++){for(let i=0;i<n.length;i++)n[i]=s.reedSolomonMultiply(n[i],e),i+1<n.length&&(n[i]^=n[i+1]);e=s.reedSolomonMultiply(e,2)}return n}static reedSolomonComputeRemainder(t,n){const e=n.map(o=>0);for(const o of t){const i=o^e.shift();e.push(0),n.forEach((c,a)=>e[a]^=s.reedSolomonMultiply(c,i))}return e}static reedSolomonMultiply(t,n){if(t>>>8||n>>>8)throw new RangeError("Byte out of range");let e=0;for(let o=7;o>=0;o--)e=e<<1^(e>>>7)*285,e^=(n>>>o&1)*t;return h(e>>>8==0),e}finderPenaltyCountPatterns(t){const n=t[1];h(n<=this.size*3);const e=n>0&&t[2]==n&&t[3]==n*3&&t[4]==n&&t[5]==n;return(e&&t[0]>=n*4&&t[6]>=n?1:0)+(e&&t[6]>=n*4&&t[0]>=n?1:0)}finderPenaltyTerminateAndCount(t,n,e){return t&&(this.finderPenaltyAddHistory(n,e),n=0),n+=this.size,this.finderPenaltyAddHistory(n,e),this.finderPenaltyCountPatterns(e)}finderPenaltyAddHistory(t,n){n[0]==0&&(t+=this.size),n.pop(),n.unshift(t)}}s.MIN_VERSION=1,s.MAX_VERSION=40,s.PENALTY_N1=3,s.PENALTY_N2=3,s.PENALTY_N3=40,s.PENALTY_N4=10,s.ECC_CODEWORDS_PER_BLOCK=[[-1,7,10,15,20,26,18,20,24,30,18,20,24,26,30,22,24,28,30,28,28,28,28,30,30,26,28,30,30,30,30,30,30,30,30,30,30,30,30,30,30],[-1,10,16,26,18,24,16,18,22,22,26,30,22,22,24,24,28,28,26,26,26,26,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28],[-1,13,22,18,26,18,24,18,22,20,24,28,26,24,20,30,24,28,28,26,30,28,30,30,30,30,28,30,30,30,30,30,30,30,30,30,30,30,30,30,30],[-1,17,28,22,16,22,28,26,26,24,28,24,28,22,24,24,30,28,28,26,28,30,24,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30]],s.NUM_ERROR_CORRECTION_BLOCKS=[[-1,1,1,1,1,1,2,2,2,2,4,4,4,4,4,6,6,6,6,7,8,8,9,9,10,12,12,12,13,14,15,16,17,18,19,19,20,21,22,24,25],[-1,1,1,1,2,2,4,4,4,5,5,5,8,9,9,10,10,11,13,14,16,17,17,18,20,21,23,25,26,28,29,31,33,35,37,38,40,43,45,47,49],[-1,1,1,2,2,4,4,6,6,8,8,8,10,12,16,12,17,16,18,21,20,23,23,25,27,29,34,34,35,38,40,43,45,48,51,53,56,59,62,65,68],[-1,1,1,2,4,4,4,5,6,8,8,11,11,16,16,18,16,19,21,25,25,25,34,30,32,35,37,40,42,45,48,51,54,57,60,63,66,70,74,77,81]],r.QrCode=s;function u(E,t,n){if(t<0||t>31||E>>>t)throw new RangeError("Value out of range");for(let e=t-1;e>=0;e--)n.push(E>>>e&1)}function d(E,t){return(E>>>t&1)!=0}function h(E){if(!E)throw new Error("Assertion error")}class l{static makeBytes(t){const n=[];for(const e of t)u(e,8,n);return new l(l.Mode.BYTE,t.length,n)}static makeNumeric(t){if(!l.isNumeric(t))throw new RangeError("String contains non-numeric characters");const n=[];for(let e=0;e<t.length;){const o=Math.min(t.length-e,3);u(parseInt(t.substring(e,e+o),10),o*3+1,n),e+=o}return new l(l.Mode.NUMERIC,t.length,n)}static makeAlphanumeric(t){if(!l.isAlphanumeric(t))throw new RangeError("String contains unencodable characters in alphanumeric mode");const n=[];let e;for(e=0;e+2<=t.length;e+=2){let o=l.ALPHANUMERIC_CHARSET.indexOf(t.charAt(e))*45;o+=l.ALPHANUMERIC_CHARSET.indexOf(t.charAt(e+1)),u(o,11,n)}return e<t.length&&u(l.ALPHANUMERIC_CHARSET.indexOf(t.charAt(e)),6,n),new l(l.Mode.ALPHANUMERIC,t.length,n)}static makeSegments(t){return t==""?[]:l.isNumeric(t)?[l.makeNumeric(t)]:l.isAlphanumeric(t)?[l.makeAlphanumeric(t)]:[l.makeBytes(l.toUtf8ByteArray(t))]}static makeEci(t){const n=[];if(t<0)throw new RangeError("ECI assignment value out of range");if(t<128)u(t,8,n);else if(t<16384)u(2,2,n),u(t,14,n);else if(t<1e6)u(6,3,n),u(t,21,n);else throw new RangeError("ECI assignment value out of range");return new l(l.Mode.ECI,0,n)}static isNumeric(t){return l.NUMERIC_REGEX.test(t)}static isAlphanumeric(t){return l.ALPHANUMERIC_REGEX.test(t)}constructor(t,n,e){if(this.mode=t,this.numChars=n,this.bitData=e,n<0)throw new RangeError("Invalid argument");this.bitData=e.slice()}getData(){return this.bitData.slice()}static getTotalBits(t,n){let e=0;for(const o of t){const i=o.mode.numCharCountBits(n);if(o.numChars>=1<<i)return 1/0;e+=4+i+o.bitData.length}return e}static toUtf8ByteArray(t){t=encodeURI(t);const n=[];for(let e=0;e<t.length;e++)t.charAt(e)!="%"?n.push(t.charCodeAt(e)):(n.push(parseInt(t.substring(e+1,e+3),16)),e+=2);return n}}l.NUMERIC_REGEX=/^[0-9]*$/,l.ALPHANUMERIC_REGEX=/^[A-Z0-9 $%*+.\/:-]*$/,l.ALPHANUMERIC_CHARSET="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ $%*+-./:",r.QrSegment=l})(p||(p={}));(function(r){(function(s){class u{constructor(h,l){this.ordinal=h,this.formatBits=l}}u.LOW=new u(0,1),u.MEDIUM=new u(1,0),u.QUARTILE=new u(2,3),u.HIGH=new u(3,2),s.Ecc=u})(r.QrCode||(r.QrCode={}))})(p||(p={}));(function(r){(function(s){class u{constructor(h,l){this.modeBits=h,this.numBitsCharCount=l}numCharCountBits(h){return this.numBitsCharCount[Math.floor((h+7)/17)]}}u.NUMERIC=new u(1,[10,12,14]),u.ALPHANUMERIC=new u(2,[9,11,13]),u.BYTE=new u(4,[8,16,16]),u.KANJI=new u(8,[8,10,12]),u.ECI=new u(7,[0,0,0]),s.Mode=u})(r.QrSegment||(r.QrSegment={}))})(p||(p={}));const U={L:p.QrCode.Ecc.LOW,M:p.QrCode.Ecc.MEDIUM,Q:p.QrCode.Ecc.QUARTILE,H:p.QrCode.Ecc.HIGH},S=128,$="L",k="#FFFFFF",H="#000000",G=!1,dt=4,gt=0,mt=.1;function Y(r){let s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;const u=[];return r.forEach(function(d,h){let l=null;d.forEach(function(E,t){if(!E&&l!==null){u.push(`M${l+s} ${h+s}h${t-l}v1H${l+s}z`),l=null;return}if(t===d.length-1){if(!E)return;l===null?u.push(`M${t+s},${h+s} h1v1H${t+s}z`):u.push(`M${l+s},${h+s} h${t+1-l}v1H${l+s}z`);return}E&&l===null&&(l=t)})}),u.join("")}function V(r,s){return r.slice().map((u,d)=>d<s.y||d>=s.y+s.h?u:u.map((h,l)=>l<s.x||l>=s.x+s.w?h:!1))}function X(r,s,u,d){if(d==null)return null;const h=r.length+u*2,l=Math.floor(s*mt),E=h/s,t=(d.width||l)*E,n=(d.height||l)*E,e=d.x==null?r.length/2-t/2:d.x*E,o=d.y==null?r.length/2-n/2:d.y*E;let i=null;if(d.excavate){const c=Math.floor(e),a=Math.floor(o),g=Math.ceil(t+e-c),f=Math.ceil(n+o-a);i={x:c,y:a,w:g,h:f}}return{x:e,y:o,h:n,w:t,excavation:i}}function _(r,s){return s!=null?Math.floor(s):r?dt:gt}const Et=(function(){try{new Path2D().addPath(new Path2D)}catch{return!1}return!0})(),Mt=L({name:"QRCodeCanvas",inheritAttrs:!1,props:N(N({},z()),{level:String,bgColor:String,fgColor:String,marginSize:Number}),setup(r,s){let{attrs:u,expose:d}=s;const h=O(()=>{var n;return(n=r.imageSettings)===null||n===void 0?void 0:n.src}),l=y(null),E=y(null),t=y(!1);return d({toDataURL:(n,e)=>{var o;return(o=l.value)===null||o===void 0?void 0:o.toDataURL(n,e)}}),F(()=>{const{value:n,size:e=S,level:o=$,bgColor:i=k,fgColor:c=H,includeMargin:a=G,marginSize:g,imageSettings:f}=r;if(l.value!=null){const R=l.value,w=R.getContext("2d");if(!w)return;let m=p.QrCode.encodeText(n,U[o]).getModules();const M=_(a,g),v=m.length+M*2,A=X(m,e,M,f),I=E.value,x=t.value&&A!=null&&I!==null&&I.complete&&I.naturalHeight!==0&&I.naturalWidth!==0;x&&A.excavation!=null&&(m=V(m,A.excavation));const B=window.devicePixelRatio||1;R.height=R.width=e*B;const T=e/v*B;w.scale(T,T),w.fillStyle=i,w.fillRect(0,0,v,v),w.fillStyle=c,Et?w.fill(new Path2D(Y(m,M))):m.forEach(function(W,j){W.forEach(function(K,Z){K&&w.fillRect(Z+M,j+M,1,1)})}),x&&w.drawImage(I,A.x+M,A.y+M,A.w,A.h)}},{flush:"post"}),lt(h,()=>{t.value=!1}),()=>{var n;const e=(n=r.size)!==null&&n!==void 0?n:S,o={height:`${e}px`,width:`${e}px`};let i=null;return h.value!=null&&(i=C("img",{src:h.value,key:h.value,style:{display:"none"},onLoad:()=>{t.value=!0},ref:E},null)),C(D,null,[C("canvas",b(b({},u),{},{style:[o,u.style],ref:l}),null),i])}}}),wt=L({name:"QRCodeSVG",inheritAttrs:!1,props:N(N({},z()),{color:String,level:String,bgColor:String,fgColor:String,marginSize:Number,title:String}),setup(r){let s=null,u=null,d=null,h=null,l=null,E=null;return F(()=>{const{value:t,size:n=S,level:e=$,includeMargin:o=G,marginSize:i,imageSettings:c}=r;s=p.QrCode.encodeText(t,U[e]).getModules(),u=_(o,i),d=s.length+u*2,h=X(s,n,u,c),c!=null&&h!=null&&(h.excavation!=null&&(s=V(s,h.excavation)),E=C("image",{"xlink:href":c.src,height:h.h,width:h.w,x:h.x+u,y:h.y+u,preserveAspectRatio:"none"},null)),l=Y(s,u)}),()=>{const t=r.bgColor&&k,n=r.fgColor&&H;return C("svg",{height:r.size,width:r.size,viewBox:`0 0 ${d} ${d}`},[!!r.title&&C("title",null,[r.title]),C("path",{fill:t,d:`M0,0 h${d}v${d}H0z`,"shape-rendering":"crispEdges"},null),C("path",{fill:n,d:l,"shape-rendering":"crispEdges"},null),E])}}}),Ct=L({name:"AQrcode",inheritAttrs:!1,props:ft(),emits:["refresh"],setup(r,s){let{emit:u,attrs:d,expose:h}=s;const[l]=nt("QRCode"),{prefixCls:E}=ot("qrcode",r),[t,n]=ht(E),[,e]=st(),o=at();h({toDataURL:(c,a)=>{var g;return(g=o.value)===null||g===void 0?void 0:g.toDataURL(c,a)}});const i=O(()=>{const{value:c,icon:a="",size:g=160,iconSize:f=40,color:R=e.value.colorText,bgColor:w="transparent",errorLevel:m="M"}=r,M={src:a,x:void 0,y:void 0,height:f,width:f,excavate:!0};return{value:c,size:g-(e.value.paddingSM+e.value.lineWidth)*2,level:m,bgColor:w,fgColor:R,imageSettings:a?M:void 0}});return()=>{const c=E.value;return t(C("div",b(b({},d),{},{style:[d.style,{width:`${r.size}px`,height:`${r.size}px`,backgroundColor:i.value.bgColor}],class:[n.value,c,{[`${c}-borderless`]:!r.bordered}]}),[r.status!=="active"&&C("div",{class:`${c}-mask`},[r.status==="loading"&&C(it,null,null),r.status==="expired"&&C(D,null,[C("p",{class:`${c}-expired`},[l.value.expired]),C(rt,{type:"link",onClick:a=>u("refresh",a)},{default:()=>[l.value.refresh],icon:()=>C(ut,null,null)})]),r.status==="scanned"&&C("p",{class:`${c}-scanned`},[l.value.scanned])]),r.type==="canvas"?C(Mt,b({ref:o},i.value),null):C(wt,i.value,null)]))}}}),Dt=et(Ct);export{Dt as default};
1
+ import{l as q,m as J,h as N,r as Q,$ as P,t as tt,f as b,S as et,p as nt,q as ot,I as st}from"./index-DL2e2Kwh.js";import it from"./index-pO_TKKcK.js";import{B as rt}from"./index-CtgPPk47.js";import{d as L,b as F,w as lt,c as C,F as D,f as O,s as y,r as at}from"./vendor-DhFY8mDK.js";import{R as ut}from"./icons-BOPtEWK4.js";import"./initDefaultProps-Cw37W7y2.js";import"./index-xaqrvGuG.js";import"./isVisible-C7tPsqfj.js";import"./useState-DGS1NOyn.js";import"./raf-Deuc0E8-.js";import"./devWarning-CNIS3FrJ.js";import"./warning-Pq00owYb.js";import"./compact-item-tVJNTa_f.js";import"./createContext-CeHSYhwo.js";import"./Compact-CislP3fF.js";import"./_getTag-BVc6NQ_K.js";const ct=r=>{const{componentCls:s}=r;return{[s]:N(N({},Q(r)),{display:"flex",justifyContent:"center",alignItems:"center",padding:r.paddingSM,backgroundColor:r.colorWhite,borderRadius:r.borderRadiusLG,border:`${r.lineWidth}px ${r.lineType} ${r.colorSplit}`,position:"relative",width:"100%",height:"100%",overflow:"hidden",[`& > ${s}-mask`]:{position:"absolute",insetBlockStart:0,insetInlineStart:0,zIndex:10,display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",width:"100%",height:"100%",color:r.colorText,lineHeight:r.lineHeight,background:r.QRCodeMaskBackgroundColor,textAlign:"center",[`& > ${s}-expired , & > ${s}-scanned`]:{color:r.QRCodeTextColor}},"&-icon":{marginBlockEnd:r.marginXS,fontSize:r.controlHeight}}),[`${s}-borderless`]:{borderColor:"transparent"}}},ht=q("QRCode",r=>ct(J(r,{QRCodeTextColor:"rgba(0, 0, 0, 0.88)",QRCodeMaskBackgroundColor:"rgba(255, 255, 255, 0.96)"}))),z=()=>({size:{type:Number,default:160},value:{type:String,required:!0},type:P("canvas"),color:String,bgColor:String,includeMargin:Boolean,imageSettings:tt()}),ft=()=>N(N({},z()),{errorLevel:P("M"),icon:String,iconSize:{type:Number,default:40},status:P("active"),bordered:{type:Boolean,default:!0}});var p;(function(r){class s{static encodeText(t,n){const e=r.QrSegment.makeSegments(t);return s.encodeSegments(e,n)}static encodeBinary(t,n){const e=r.QrSegment.makeBytes(t);return s.encodeSegments([e],n)}static encodeSegments(t,n){let e=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,o=arguments.length>3&&arguments[3]!==void 0?arguments[3]:40,i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:-1,c=arguments.length>5&&arguments[5]!==void 0?arguments[5]:!0;if(!(s.MIN_VERSION<=e&&e<=o&&o<=s.MAX_VERSION)||i<-1||i>7)throw new RangeError("Invalid value");let a,g;for(a=e;;a++){const m=s.getNumDataCodewords(a,n)*8,M=l.getTotalBits(t,a);if(M<=m){g=M;break}if(a>=o)throw new RangeError("Data too long")}for(const m of[s.Ecc.MEDIUM,s.Ecc.QUARTILE,s.Ecc.HIGH])c&&g<=s.getNumDataCodewords(a,m)*8&&(n=m);const f=[];for(const m of t){u(m.mode.modeBits,4,f),u(m.numChars,m.mode.numCharCountBits(a),f);for(const M of m.getData())f.push(M)}h(f.length==g);const R=s.getNumDataCodewords(a,n)*8;h(f.length<=R),u(0,Math.min(4,R-f.length),f),u(0,(8-f.length%8)%8,f),h(f.length%8==0);for(let m=236;f.length<R;m^=253)u(m,8,f);const w=[];for(;w.length*8<f.length;)w.push(0);return f.forEach((m,M)=>w[M>>>3]|=m<<7-(M&7)),new s(a,n,w,i)}constructor(t,n,e,o){if(this.version=t,this.errorCorrectionLevel=n,this.modules=[],this.isFunction=[],t<s.MIN_VERSION||t>s.MAX_VERSION)throw new RangeError("Version value out of range");if(o<-1||o>7)throw new RangeError("Mask value out of range");this.size=t*4+17;const i=[];for(let a=0;a<this.size;a++)i.push(!1);for(let a=0;a<this.size;a++)this.modules.push(i.slice()),this.isFunction.push(i.slice());this.drawFunctionPatterns();const c=this.addEccAndInterleave(e);if(this.drawCodewords(c),o==-1){let a=1e9;for(let g=0;g<8;g++){this.applyMask(g),this.drawFormatBits(g);const f=this.getPenaltyScore();f<a&&(o=g,a=f),this.applyMask(g)}}h(0<=o&&o<=7),this.mask=o,this.applyMask(o),this.drawFormatBits(o),this.isFunction=[]}getModule(t,n){return 0<=t&&t<this.size&&0<=n&&n<this.size&&this.modules[n][t]}getModules(){return this.modules}drawFunctionPatterns(){for(let e=0;e<this.size;e++)this.setFunctionModule(6,e,e%2==0),this.setFunctionModule(e,6,e%2==0);this.drawFinderPattern(3,3),this.drawFinderPattern(this.size-4,3),this.drawFinderPattern(3,this.size-4);const t=this.getAlignmentPatternPositions(),n=t.length;for(let e=0;e<n;e++)for(let o=0;o<n;o++)e==0&&o==0||e==0&&o==n-1||e==n-1&&o==0||this.drawAlignmentPattern(t[e],t[o]);this.drawFormatBits(0),this.drawVersion()}drawFormatBits(t){const n=this.errorCorrectionLevel.formatBits<<3|t;let e=n;for(let i=0;i<10;i++)e=e<<1^(e>>>9)*1335;const o=(n<<10|e)^21522;h(o>>>15==0);for(let i=0;i<=5;i++)this.setFunctionModule(8,i,d(o,i));this.setFunctionModule(8,7,d(o,6)),this.setFunctionModule(8,8,d(o,7)),this.setFunctionModule(7,8,d(o,8));for(let i=9;i<15;i++)this.setFunctionModule(14-i,8,d(o,i));for(let i=0;i<8;i++)this.setFunctionModule(this.size-1-i,8,d(o,i));for(let i=8;i<15;i++)this.setFunctionModule(8,this.size-15+i,d(o,i));this.setFunctionModule(8,this.size-8,!0)}drawVersion(){if(this.version<7)return;let t=this.version;for(let e=0;e<12;e++)t=t<<1^(t>>>11)*7973;const n=this.version<<12|t;h(n>>>18==0);for(let e=0;e<18;e++){const o=d(n,e),i=this.size-11+e%3,c=Math.floor(e/3);this.setFunctionModule(i,c,o),this.setFunctionModule(c,i,o)}}drawFinderPattern(t,n){for(let e=-4;e<=4;e++)for(let o=-4;o<=4;o++){const i=Math.max(Math.abs(o),Math.abs(e)),c=t+o,a=n+e;0<=c&&c<this.size&&0<=a&&a<this.size&&this.setFunctionModule(c,a,i!=2&&i!=4)}}drawAlignmentPattern(t,n){for(let e=-2;e<=2;e++)for(let o=-2;o<=2;o++)this.setFunctionModule(t+o,n+e,Math.max(Math.abs(o),Math.abs(e))!=1)}setFunctionModule(t,n,e){this.modules[n][t]=e,this.isFunction[n][t]=!0}addEccAndInterleave(t){const n=this.version,e=this.errorCorrectionLevel;if(t.length!=s.getNumDataCodewords(n,e))throw new RangeError("Invalid argument");const o=s.NUM_ERROR_CORRECTION_BLOCKS[e.ordinal][n],i=s.ECC_CODEWORDS_PER_BLOCK[e.ordinal][n],c=Math.floor(s.getNumRawDataModules(n)/8),a=o-c%o,g=Math.floor(c/o),f=[],R=s.reedSolomonComputeDivisor(i);for(let m=0,M=0;m<o;m++){const v=t.slice(M,M+g-i+(m<a?0:1));M+=v.length;const A=s.reedSolomonComputeRemainder(v,R);m<a&&v.push(0),f.push(v.concat(A))}const w=[];for(let m=0;m<f[0].length;m++)f.forEach((M,v)=>{(m!=g-i||v>=a)&&w.push(M[m])});return h(w.length==c),w}drawCodewords(t){if(t.length!=Math.floor(s.getNumRawDataModules(this.version)/8))throw new RangeError("Invalid argument");let n=0;for(let e=this.size-1;e>=1;e-=2){e==6&&(e=5);for(let o=0;o<this.size;o++)for(let i=0;i<2;i++){const c=e-i,g=(e+1&2)==0?this.size-1-o:o;!this.isFunction[g][c]&&n<t.length*8&&(this.modules[g][c]=d(t[n>>>3],7-(n&7)),n++)}}h(n==t.length*8)}applyMask(t){if(t<0||t>7)throw new RangeError("Mask value out of range");for(let n=0;n<this.size;n++)for(let e=0;e<this.size;e++){let o;switch(t){case 0:o=(e+n)%2==0;break;case 1:o=n%2==0;break;case 2:o=e%3==0;break;case 3:o=(e+n)%3==0;break;case 4:o=(Math.floor(e/3)+Math.floor(n/2))%2==0;break;case 5:o=e*n%2+e*n%3==0;break;case 6:o=(e*n%2+e*n%3)%2==0;break;case 7:o=((e+n)%2+e*n%3)%2==0;break;default:throw new Error("Unreachable")}!this.isFunction[n][e]&&o&&(this.modules[n][e]=!this.modules[n][e])}}getPenaltyScore(){let t=0;for(let i=0;i<this.size;i++){let c=!1,a=0;const g=[0,0,0,0,0,0,0];for(let f=0;f<this.size;f++)this.modules[i][f]==c?(a++,a==5?t+=s.PENALTY_N1:a>5&&t++):(this.finderPenaltyAddHistory(a,g),c||(t+=this.finderPenaltyCountPatterns(g)*s.PENALTY_N3),c=this.modules[i][f],a=1);t+=this.finderPenaltyTerminateAndCount(c,a,g)*s.PENALTY_N3}for(let i=0;i<this.size;i++){let c=!1,a=0;const g=[0,0,0,0,0,0,0];for(let f=0;f<this.size;f++)this.modules[f][i]==c?(a++,a==5?t+=s.PENALTY_N1:a>5&&t++):(this.finderPenaltyAddHistory(a,g),c||(t+=this.finderPenaltyCountPatterns(g)*s.PENALTY_N3),c=this.modules[f][i],a=1);t+=this.finderPenaltyTerminateAndCount(c,a,g)*s.PENALTY_N3}for(let i=0;i<this.size-1;i++)for(let c=0;c<this.size-1;c++){const a=this.modules[i][c];a==this.modules[i][c+1]&&a==this.modules[i+1][c]&&a==this.modules[i+1][c+1]&&(t+=s.PENALTY_N2)}let n=0;for(const i of this.modules)n=i.reduce((c,a)=>c+(a?1:0),n);const e=this.size*this.size,o=Math.ceil(Math.abs(n*20-e*10)/e)-1;return h(0<=o&&o<=9),t+=o*s.PENALTY_N4,h(0<=t&&t<=2568888),t}getAlignmentPatternPositions(){if(this.version==1)return[];{const t=Math.floor(this.version/7)+2,n=this.version==32?26:Math.ceil((this.version*4+4)/(t*2-2))*2,e=[6];for(let o=this.size-7;e.length<t;o-=n)e.splice(1,0,o);return e}}static getNumRawDataModules(t){if(t<s.MIN_VERSION||t>s.MAX_VERSION)throw new RangeError("Version number out of range");let n=(16*t+128)*t+64;if(t>=2){const e=Math.floor(t/7)+2;n-=(25*e-10)*e-55,t>=7&&(n-=36)}return h(208<=n&&n<=29648),n}static getNumDataCodewords(t,n){return Math.floor(s.getNumRawDataModules(t)/8)-s.ECC_CODEWORDS_PER_BLOCK[n.ordinal][t]*s.NUM_ERROR_CORRECTION_BLOCKS[n.ordinal][t]}static reedSolomonComputeDivisor(t){if(t<1||t>255)throw new RangeError("Degree out of range");const n=[];for(let o=0;o<t-1;o++)n.push(0);n.push(1);let e=1;for(let o=0;o<t;o++){for(let i=0;i<n.length;i++)n[i]=s.reedSolomonMultiply(n[i],e),i+1<n.length&&(n[i]^=n[i+1]);e=s.reedSolomonMultiply(e,2)}return n}static reedSolomonComputeRemainder(t,n){const e=n.map(o=>0);for(const o of t){const i=o^e.shift();e.push(0),n.forEach((c,a)=>e[a]^=s.reedSolomonMultiply(c,i))}return e}static reedSolomonMultiply(t,n){if(t>>>8||n>>>8)throw new RangeError("Byte out of range");let e=0;for(let o=7;o>=0;o--)e=e<<1^(e>>>7)*285,e^=(n>>>o&1)*t;return h(e>>>8==0),e}finderPenaltyCountPatterns(t){const n=t[1];h(n<=this.size*3);const e=n>0&&t[2]==n&&t[3]==n*3&&t[4]==n&&t[5]==n;return(e&&t[0]>=n*4&&t[6]>=n?1:0)+(e&&t[6]>=n*4&&t[0]>=n?1:0)}finderPenaltyTerminateAndCount(t,n,e){return t&&(this.finderPenaltyAddHistory(n,e),n=0),n+=this.size,this.finderPenaltyAddHistory(n,e),this.finderPenaltyCountPatterns(e)}finderPenaltyAddHistory(t,n){n[0]==0&&(t+=this.size),n.pop(),n.unshift(t)}}s.MIN_VERSION=1,s.MAX_VERSION=40,s.PENALTY_N1=3,s.PENALTY_N2=3,s.PENALTY_N3=40,s.PENALTY_N4=10,s.ECC_CODEWORDS_PER_BLOCK=[[-1,7,10,15,20,26,18,20,24,30,18,20,24,26,30,22,24,28,30,28,28,28,28,30,30,26,28,30,30,30,30,30,30,30,30,30,30,30,30,30,30],[-1,10,16,26,18,24,16,18,22,22,26,30,22,22,24,24,28,28,26,26,26,26,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28],[-1,13,22,18,26,18,24,18,22,20,24,28,26,24,20,30,24,28,28,26,30,28,30,30,30,30,28,30,30,30,30,30,30,30,30,30,30,30,30,30,30],[-1,17,28,22,16,22,28,26,26,24,28,24,28,22,24,24,30,28,28,26,28,30,24,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30]],s.NUM_ERROR_CORRECTION_BLOCKS=[[-1,1,1,1,1,1,2,2,2,2,4,4,4,4,4,6,6,6,6,7,8,8,9,9,10,12,12,12,13,14,15,16,17,18,19,19,20,21,22,24,25],[-1,1,1,1,2,2,4,4,4,5,5,5,8,9,9,10,10,11,13,14,16,17,17,18,20,21,23,25,26,28,29,31,33,35,37,38,40,43,45,47,49],[-1,1,1,2,2,4,4,6,6,8,8,8,10,12,16,12,17,16,18,21,20,23,23,25,27,29,34,34,35,38,40,43,45,48,51,53,56,59,62,65,68],[-1,1,1,2,4,4,4,5,6,8,8,11,11,16,16,18,16,19,21,25,25,25,34,30,32,35,37,40,42,45,48,51,54,57,60,63,66,70,74,77,81]],r.QrCode=s;function u(E,t,n){if(t<0||t>31||E>>>t)throw new RangeError("Value out of range");for(let e=t-1;e>=0;e--)n.push(E>>>e&1)}function d(E,t){return(E>>>t&1)!=0}function h(E){if(!E)throw new Error("Assertion error")}class l{static makeBytes(t){const n=[];for(const e of t)u(e,8,n);return new l(l.Mode.BYTE,t.length,n)}static makeNumeric(t){if(!l.isNumeric(t))throw new RangeError("String contains non-numeric characters");const n=[];for(let e=0;e<t.length;){const o=Math.min(t.length-e,3);u(parseInt(t.substring(e,e+o),10),o*3+1,n),e+=o}return new l(l.Mode.NUMERIC,t.length,n)}static makeAlphanumeric(t){if(!l.isAlphanumeric(t))throw new RangeError("String contains unencodable characters in alphanumeric mode");const n=[];let e;for(e=0;e+2<=t.length;e+=2){let o=l.ALPHANUMERIC_CHARSET.indexOf(t.charAt(e))*45;o+=l.ALPHANUMERIC_CHARSET.indexOf(t.charAt(e+1)),u(o,11,n)}return e<t.length&&u(l.ALPHANUMERIC_CHARSET.indexOf(t.charAt(e)),6,n),new l(l.Mode.ALPHANUMERIC,t.length,n)}static makeSegments(t){return t==""?[]:l.isNumeric(t)?[l.makeNumeric(t)]:l.isAlphanumeric(t)?[l.makeAlphanumeric(t)]:[l.makeBytes(l.toUtf8ByteArray(t))]}static makeEci(t){const n=[];if(t<0)throw new RangeError("ECI assignment value out of range");if(t<128)u(t,8,n);else if(t<16384)u(2,2,n),u(t,14,n);else if(t<1e6)u(6,3,n),u(t,21,n);else throw new RangeError("ECI assignment value out of range");return new l(l.Mode.ECI,0,n)}static isNumeric(t){return l.NUMERIC_REGEX.test(t)}static isAlphanumeric(t){return l.ALPHANUMERIC_REGEX.test(t)}constructor(t,n,e){if(this.mode=t,this.numChars=n,this.bitData=e,n<0)throw new RangeError("Invalid argument");this.bitData=e.slice()}getData(){return this.bitData.slice()}static getTotalBits(t,n){let e=0;for(const o of t){const i=o.mode.numCharCountBits(n);if(o.numChars>=1<<i)return 1/0;e+=4+i+o.bitData.length}return e}static toUtf8ByteArray(t){t=encodeURI(t);const n=[];for(let e=0;e<t.length;e++)t.charAt(e)!="%"?n.push(t.charCodeAt(e)):(n.push(parseInt(t.substring(e+1,e+3),16)),e+=2);return n}}l.NUMERIC_REGEX=/^[0-9]*$/,l.ALPHANUMERIC_REGEX=/^[A-Z0-9 $%*+.\/:-]*$/,l.ALPHANUMERIC_CHARSET="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ $%*+-./:",r.QrSegment=l})(p||(p={}));(function(r){(function(s){class u{constructor(h,l){this.ordinal=h,this.formatBits=l}}u.LOW=new u(0,1),u.MEDIUM=new u(1,0),u.QUARTILE=new u(2,3),u.HIGH=new u(3,2),s.Ecc=u})(r.QrCode||(r.QrCode={}))})(p||(p={}));(function(r){(function(s){class u{constructor(h,l){this.modeBits=h,this.numBitsCharCount=l}numCharCountBits(h){return this.numBitsCharCount[Math.floor((h+7)/17)]}}u.NUMERIC=new u(1,[10,12,14]),u.ALPHANUMERIC=new u(2,[9,11,13]),u.BYTE=new u(4,[8,16,16]),u.KANJI=new u(8,[8,10,12]),u.ECI=new u(7,[0,0,0]),s.Mode=u})(r.QrSegment||(r.QrSegment={}))})(p||(p={}));const U={L:p.QrCode.Ecc.LOW,M:p.QrCode.Ecc.MEDIUM,Q:p.QrCode.Ecc.QUARTILE,H:p.QrCode.Ecc.HIGH},S=128,$="L",k="#FFFFFF",H="#000000",G=!1,dt=4,gt=0,mt=.1;function Y(r){let s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;const u=[];return r.forEach(function(d,h){let l=null;d.forEach(function(E,t){if(!E&&l!==null){u.push(`M${l+s} ${h+s}h${t-l}v1H${l+s}z`),l=null;return}if(t===d.length-1){if(!E)return;l===null?u.push(`M${t+s},${h+s} h1v1H${t+s}z`):u.push(`M${l+s},${h+s} h${t+1-l}v1H${l+s}z`);return}E&&l===null&&(l=t)})}),u.join("")}function V(r,s){return r.slice().map((u,d)=>d<s.y||d>=s.y+s.h?u:u.map((h,l)=>l<s.x||l>=s.x+s.w?h:!1))}function X(r,s,u,d){if(d==null)return null;const h=r.length+u*2,l=Math.floor(s*mt),E=h/s,t=(d.width||l)*E,n=(d.height||l)*E,e=d.x==null?r.length/2-t/2:d.x*E,o=d.y==null?r.length/2-n/2:d.y*E;let i=null;if(d.excavate){const c=Math.floor(e),a=Math.floor(o),g=Math.ceil(t+e-c),f=Math.ceil(n+o-a);i={x:c,y:a,w:g,h:f}}return{x:e,y:o,h:n,w:t,excavation:i}}function _(r,s){return s!=null?Math.floor(s):r?dt:gt}const Et=(function(){try{new Path2D().addPath(new Path2D)}catch{return!1}return!0})(),Mt=L({name:"QRCodeCanvas",inheritAttrs:!1,props:N(N({},z()),{level:String,bgColor:String,fgColor:String,marginSize:Number}),setup(r,s){let{attrs:u,expose:d}=s;const h=O(()=>{var n;return(n=r.imageSettings)===null||n===void 0?void 0:n.src}),l=y(null),E=y(null),t=y(!1);return d({toDataURL:(n,e)=>{var o;return(o=l.value)===null||o===void 0?void 0:o.toDataURL(n,e)}}),F(()=>{const{value:n,size:e=S,level:o=$,bgColor:i=k,fgColor:c=H,includeMargin:a=G,marginSize:g,imageSettings:f}=r;if(l.value!=null){const R=l.value,w=R.getContext("2d");if(!w)return;let m=p.QrCode.encodeText(n,U[o]).getModules();const M=_(a,g),v=m.length+M*2,A=X(m,e,M,f),I=E.value,x=t.value&&A!=null&&I!==null&&I.complete&&I.naturalHeight!==0&&I.naturalWidth!==0;x&&A.excavation!=null&&(m=V(m,A.excavation));const B=window.devicePixelRatio||1;R.height=R.width=e*B;const T=e/v*B;w.scale(T,T),w.fillStyle=i,w.fillRect(0,0,v,v),w.fillStyle=c,Et?w.fill(new Path2D(Y(m,M))):m.forEach(function(W,j){W.forEach(function(K,Z){K&&w.fillRect(Z+M,j+M,1,1)})}),x&&w.drawImage(I,A.x+M,A.y+M,A.w,A.h)}},{flush:"post"}),lt(h,()=>{t.value=!1}),()=>{var n;const e=(n=r.size)!==null&&n!==void 0?n:S,o={height:`${e}px`,width:`${e}px`};let i=null;return h.value!=null&&(i=C("img",{src:h.value,key:h.value,style:{display:"none"},onLoad:()=>{t.value=!0},ref:E},null)),C(D,null,[C("canvas",b(b({},u),{},{style:[o,u.style],ref:l}),null),i])}}}),wt=L({name:"QRCodeSVG",inheritAttrs:!1,props:N(N({},z()),{color:String,level:String,bgColor:String,fgColor:String,marginSize:Number,title:String}),setup(r){let s=null,u=null,d=null,h=null,l=null,E=null;return F(()=>{const{value:t,size:n=S,level:e=$,includeMargin:o=G,marginSize:i,imageSettings:c}=r;s=p.QrCode.encodeText(t,U[e]).getModules(),u=_(o,i),d=s.length+u*2,h=X(s,n,u,c),c!=null&&h!=null&&(h.excavation!=null&&(s=V(s,h.excavation)),E=C("image",{"xlink:href":c.src,height:h.h,width:h.w,x:h.x+u,y:h.y+u,preserveAspectRatio:"none"},null)),l=Y(s,u)}),()=>{const t=r.bgColor&&k,n=r.fgColor&&H;return C("svg",{height:r.size,width:r.size,viewBox:`0 0 ${d} ${d}`},[!!r.title&&C("title",null,[r.title]),C("path",{fill:t,d:`M0,0 h${d}v${d}H0z`,"shape-rendering":"crispEdges"},null),C("path",{fill:n,d:l,"shape-rendering":"crispEdges"},null),E])}}}),Ct=L({name:"AQrcode",inheritAttrs:!1,props:ft(),emits:["refresh"],setup(r,s){let{emit:u,attrs:d,expose:h}=s;const[l]=nt("QRCode"),{prefixCls:E}=ot("qrcode",r),[t,n]=ht(E),[,e]=st(),o=at();h({toDataURL:(c,a)=>{var g;return(g=o.value)===null||g===void 0?void 0:g.toDataURL(c,a)}});const i=O(()=>{const{value:c,icon:a="",size:g=160,iconSize:f=40,color:R=e.value.colorText,bgColor:w="transparent",errorLevel:m="M"}=r,M={src:a,x:void 0,y:void 0,height:f,width:f,excavate:!0};return{value:c,size:g-(e.value.paddingSM+e.value.lineWidth)*2,level:m,bgColor:w,fgColor:R,imageSettings:a?M:void 0}});return()=>{const c=E.value;return t(C("div",b(b({},d),{},{style:[d.style,{width:`${r.size}px`,height:`${r.size}px`,backgroundColor:i.value.bgColor}],class:[n.value,c,{[`${c}-borderless`]:!r.bordered}]}),[r.status!=="active"&&C("div",{class:`${c}-mask`},[r.status==="loading"&&C(it,null,null),r.status==="expired"&&C(D,null,[C("p",{class:`${c}-expired`},[l.value.expired]),C(rt,{type:"link",onClick:a=>u("refresh",a)},{default:()=>[l.value.refresh],icon:()=>C(ut,null,null)})]),r.status==="scanned"&&C("p",{class:`${c}-scanned`},[l.value.scanned])]),r.type==="canvas"?C(Mt,b({ref:o},i.value),null):C(wt,i.value,null)]))}}}),Dt=et(Ct);export{Dt as default};