rookery-agent 0.4.0 → 0.5.0

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 (125) hide show
  1. package/README.md +6 -0
  2. package/package.json +1 -2
  3. package/packages/cli/package.json +1 -1
  4. package/packages/core/dist/computer/mcp-server.js +3 -2
  5. package/packages/core/dist/computer/mcp-server.js.map +1 -1
  6. package/packages/core/dist/computer/tools.d.ts +38 -1
  7. package/packages/core/dist/computer/tools.d.ts.map +1 -1
  8. package/packages/core/dist/computer/tools.js +92 -5
  9. package/packages/core/dist/computer/tools.js.map +1 -1
  10. package/packages/core/dist/computer/validation.d.ts +32 -32
  11. package/packages/core/dist/config.d.ts.map +1 -1
  12. package/packages/core/dist/config.js +27 -3
  13. package/packages/core/dist/config.js.map +1 -1
  14. package/packages/core/dist/external/shared.d.ts +20 -0
  15. package/packages/core/dist/external/shared.d.ts.map +1 -1
  16. package/packages/core/dist/external/shared.js +42 -7
  17. package/packages/core/dist/external/shared.js.map +1 -1
  18. package/packages/core/dist/memory/recall.d.ts.map +1 -1
  19. package/packages/core/dist/memory/recall.js +13 -4
  20. package/packages/core/dist/memory/recall.js.map +1 -1
  21. package/packages/core/dist/org/controller.d.ts.map +1 -1
  22. package/packages/core/dist/org/controller.js +22 -2
  23. package/packages/core/dist/org/controller.js.map +1 -1
  24. package/packages/core/dist/org/tools.d.ts.map +1 -1
  25. package/packages/core/dist/org/tools.js +10 -2
  26. package/packages/core/dist/org/tools.js.map +1 -1
  27. package/packages/core/dist/skills/builtin.d.ts.map +1 -1
  28. package/packages/core/dist/skills/builtin.js +2 -1
  29. package/packages/core/dist/skills/builtin.js.map +1 -1
  30. package/packages/core/dist/tools/catalog.d.ts +14 -1
  31. package/packages/core/dist/tools/catalog.d.ts.map +1 -1
  32. package/packages/core/dist/tools/catalog.js +19 -7
  33. package/packages/core/dist/tools/catalog.js.map +1 -1
  34. package/packages/core/dist/tools/hub.d.ts +4 -1
  35. package/packages/core/dist/tools/hub.d.ts.map +1 -1
  36. package/packages/core/dist/tools/hub.js +22 -9
  37. package/packages/core/dist/tools/hub.js.map +1 -1
  38. package/packages/core/dist/types.d.ts +29 -0
  39. package/packages/core/dist/types.d.ts.map +1 -1
  40. package/packages/core/dist/types.js +1 -0
  41. package/packages/core/dist/types.js.map +1 -1
  42. package/packages/core/package.json +1 -1
  43. package/packages/server/dist/auth.d.ts +19 -9
  44. package/packages/server/dist/auth.d.ts.map +1 -1
  45. package/packages/server/dist/auth.js +67 -9
  46. package/packages/server/dist/auth.js.map +1 -1
  47. package/packages/server/dist/context.d.ts.map +1 -1
  48. package/packages/server/dist/context.js +5 -0
  49. package/packages/server/dist/context.js.map +1 -1
  50. package/packages/server/dist/routes/tools.d.ts.map +1 -1
  51. package/packages/server/dist/routes/tools.js +2 -0
  52. package/packages/server/dist/routes/tools.js.map +1 -1
  53. package/packages/server/dist/schemas.d.ts +17 -8
  54. package/packages/server/dist/schemas.d.ts.map +1 -1
  55. package/packages/server/dist/schemas.js +4 -0
  56. package/packages/server/dist/schemas.js.map +1 -1
  57. package/packages/server/dist/server.d.ts.map +1 -1
  58. package/packages/server/dist/server.js +7 -8
  59. package/packages/server/dist/server.js.map +1 -1
  60. package/packages/server/dist/services/updates.d.ts.map +1 -1
  61. package/packages/server/dist/services/updates.js +8 -5
  62. package/packages/server/dist/services/updates.js.map +1 -1
  63. package/packages/server/package.json +1 -1
  64. package/packages/web/dist/assets/{abnfDiagram-O67JEVCF-c90Gs7pG.js → abnfDiagram-O67JEVCF-BUyKViAz.js} +1 -1
  65. package/packages/web/dist/assets/{arc-C28-SQX8.js → arc-kwHa1cmz.js} +1 -1
  66. package/packages/web/dist/assets/{architectureDiagram-NJMV4G6O-CBPhVAKx.js → architectureDiagram-NJMV4G6O-D-xQvAiC.js} +1 -1
  67. package/packages/web/dist/assets/{blockDiagram-BEXU5L5S-CwKMvCbh.js → blockDiagram-BEXU5L5S-B6l7c5zJ.js} +1 -1
  68. package/packages/web/dist/assets/{c4Diagram-YGBWAQC7-CsL4YtmG.js → c4Diagram-YGBWAQC7-C8O4RJPa.js} +1 -1
  69. package/packages/web/dist/assets/channel-DwYrG7Bm.js +1 -0
  70. package/packages/web/dist/assets/{chunk-2Q5K7J3B-C9Bji_Nr.js → chunk-2Q5K7J3B-DlHaZjY8.js} +1 -1
  71. package/packages/web/dist/assets/{chunk-3FUC2YCW-BUnPWClf.js → chunk-3FUC2YCW-o9UXPDSH.js} +2 -2
  72. package/packages/web/dist/assets/{chunk-5VM5RSS4-CdfpfDTC.js → chunk-5VM5RSS4-2WR7_ieX.js} +1 -1
  73. package/packages/web/dist/assets/{chunk-GTNCS2PH-BZrKT8Ne.js → chunk-GTNCS2PH-pFAVSZk9.js} +1 -1
  74. package/packages/web/dist/assets/{chunk-GWA4HPMP-C0jEzDJu.js → chunk-GWA4HPMP-BzRQhudR.js} +1 -1
  75. package/packages/web/dist/assets/{chunk-JWPE2WC7-CkLRmEro.js → chunk-JWPE2WC7-CnvQdH0o.js} +1 -1
  76. package/packages/web/dist/assets/{chunk-NETBCI7D-BBeWMDmk.js → chunk-NETBCI7D-B_e4u4I_.js} +1 -1
  77. package/packages/web/dist/assets/{chunk-WEXAMYUT-B6IqsBxs.js → chunk-WEXAMYUT-DJ5sW_Wu.js} +1 -1
  78. package/packages/web/dist/assets/{chunk-XXDRQBXY-BPXeDnB2.js → chunk-XXDRQBXY-CEszpmv-.js} +1 -1
  79. package/packages/web/dist/assets/{classDiagram-v2-NBCMYWYE-2kqq2mJ8.js → classDiagram-v2-NBCMYWYE-ajadicMa.js} +1 -1
  80. package/packages/web/dist/assets/{cose-bilkent-JH36ORCC-G49FKtk6.js → cose-bilkent-JH36ORCC-C6bpUvwX.js} +1 -1
  81. package/packages/web/dist/assets/{cynefin-OW5HDTMX-98M_mPg9.js → cynefin-OW5HDTMX-Ba9Ve3LO.js} +1 -1
  82. package/packages/web/dist/assets/{cynefinDiagram-VND7K2PF-BYJTAxOT.js → cynefinDiagram-VND7K2PF-Bzlksast.js} +1 -1
  83. package/packages/web/dist/assets/{dagre-6A5THRUB-Bxcb5kkl.js → dagre-6A5THRUB-DUSmy_Iv.js} +1 -1
  84. package/packages/web/dist/assets/{diagram-22UHCM2B-DK7wAztC.js → diagram-22UHCM2B-1wwxIyTN.js} +1 -1
  85. package/packages/web/dist/assets/{diagram-3UASUU5V-BMRz0ele.js → diagram-3UASUU5V-oTZpMdf3.js} +1 -1
  86. package/packages/web/dist/assets/{diagram-ATOU4E4O-O23sdVpm.js → diagram-ATOU4E4O-DmC9I7ag.js} +1 -1
  87. package/packages/web/dist/assets/{diagram-CDSNMT55-CGxai-zV.js → diagram-CDSNMT55-BZCL0aan.js} +1 -1
  88. package/packages/web/dist/assets/{diagram-MLGK6HIB-B_29W-sW.js → diagram-MLGK6HIB-BH7T0zfk.js} +1 -1
  89. package/packages/web/dist/assets/{diagram-MPIPVDR6-OSt1qPU_.js → diagram-MPIPVDR6-_JUUCwhb.js} +1 -1
  90. package/packages/web/dist/assets/{ebnfDiagram-ZINNZB2B-DnZcwiew.js → ebnfDiagram-ZINNZB2B-CxUJCtip.js} +1 -1
  91. package/packages/web/dist/assets/{elk-276RUBZZ-BP6-xQAF.js → elk-276RUBZZ-DCg6GBkZ.js} +1 -1
  92. package/packages/web/dist/assets/{erDiagram-OPXOYQCR-DhG7UZtA.js → erDiagram-OPXOYQCR-BkhI_gGA.js} +1 -1
  93. package/packages/web/dist/assets/{flowDiagram-KWPJA3E3-CNTS1YPA.js → flowDiagram-KWPJA3E3-DZzv08xE.js} +1 -1
  94. package/packages/web/dist/assets/{ganttDiagram-FUAMR5RP-_eKkbUxc.js → ganttDiagram-FUAMR5RP-DyjG2b2O.js} +1 -1
  95. package/packages/web/dist/assets/{gitGraphDiagram-X574FWY7-N_PXNE-o.js → gitGraphDiagram-X574FWY7-baoSOA7r.js} +1 -1
  96. package/packages/web/dist/assets/index-BMYKZrup.css +32 -0
  97. package/packages/web/dist/assets/{index-DGq8BOVF.js → index-Bp8EjOaI.js} +125 -125
  98. package/packages/web/dist/assets/{infoDiagram-VRGFBTTK-vj_EDhft.js → infoDiagram-VRGFBTTK-BPZ0A976.js} +1 -1
  99. package/packages/web/dist/assets/{ishikawaDiagram-OU5B5YK6-Dr0BodVq.js → ishikawaDiagram-OU5B5YK6-ClKYnfth.js} +1 -1
  100. package/packages/web/dist/assets/{journeyDiagram-ZHPQQLJL-DykOPAu9.js → journeyDiagram-ZHPQQLJL-CDC7My9D.js} +1 -1
  101. package/packages/web/dist/assets/{kanban-definition-PNTS6WVX-zslQcJnX.js → kanban-definition-PNTS6WVX-Y4HnyK8-.js} +1 -1
  102. package/packages/web/dist/assets/{mermaid.core-C888eQE1.js → mermaid.core-B1vpXQvD.js} +4 -4
  103. package/packages/web/dist/assets/{mindmap-definition-NLK3R4M7-CpdltDoL.js → mindmap-definition-NLK3R4M7-CnwuhxUC.js} +1 -1
  104. package/packages/web/dist/assets/{pegDiagram-GJSIUBJH-Dsx3NmVN.js → pegDiagram-GJSIUBJH-DYhs3O1C.js} +1 -1
  105. package/packages/web/dist/assets/{pieDiagram-5QR66LMP-D_4DJLkr.js → pieDiagram-5QR66LMP--nq1FvKE.js} +1 -1
  106. package/packages/web/dist/assets/{quadrantDiagram-O4NWA36T-BXgGWrJ1.js → quadrantDiagram-O4NWA36T-QVO2EMWm.js} +1 -1
  107. package/packages/web/dist/assets/{railroadDiagram-XR7U4H2S-WMsrl4TR.js → railroadDiagram-XR7U4H2S--UrZd4vu.js} +1 -1
  108. package/packages/web/dist/assets/{requirementDiagram-PLB6GJNP-m2PpXDpq.js → requirementDiagram-PLB6GJNP-C6d0ZwDl.js} +1 -1
  109. package/packages/web/dist/assets/{sankeyDiagram-IPEJSGJF-DfcxNy3C.js → sankeyDiagram-IPEJSGJF-B_RJAzDd.js} +1 -1
  110. package/packages/web/dist/assets/{scene-BA1PRRU7.js → scene-DwM6-QXz.js} +1 -1
  111. package/packages/web/dist/assets/{sequenceDiagram-PO4LG4MO-B8yIKbJ8.js → sequenceDiagram-PO4LG4MO-wbXARwTZ.js} +1 -1
  112. package/packages/web/dist/assets/{sizeCapture-INFHLROL-Cic9nV7h.js → sizeCapture-INFHLROL-BzxFoDHG.js} +1 -1
  113. package/packages/web/dist/assets/{stateDiagram-v2-GCMORJYK-oOFJPdg1.js → stateDiagram-v2-GCMORJYK-B6AfFRf4.js} +1 -1
  114. package/packages/web/dist/assets/{swimlanes-2SLR337P-UCvVVk9j.js → swimlanes-2SLR337P-y2Ifsv8V.js} +1 -1
  115. package/packages/web/dist/assets/swimlanesDiagram-TC7HE7FX-DfPC--pU.js +8 -0
  116. package/packages/web/dist/assets/{timeline-definition-EJHVYXUP-BLgviPCi.js → timeline-definition-EJHVYXUP-DMJe0CMw.js} +1 -1
  117. package/packages/web/dist/assets/{usecaseDiagram-POWQR4AR-CV7U5Y4h.js → usecaseDiagram-POWQR4AR-DKTgP6C3.js} +1 -1
  118. package/packages/web/dist/assets/{vennDiagram-UO4OBE2U-C8OA0JqM.js → vennDiagram-UO4OBE2U-B86eFN57.js} +1 -1
  119. package/packages/web/dist/assets/{wardleyDiagram-VNRHLVJA-F55WtNqt.js → wardleyDiagram-VNRHLVJA-DRf3slou.js} +1 -1
  120. package/packages/web/dist/assets/{xychartDiagram-PMCCYNJV-C93Bzul9.js → xychartDiagram-PMCCYNJV-CgxhLQnx.js} +1 -1
  121. package/packages/web/dist/index.html +2 -2
  122. package/packages/web/package.json +1 -1
  123. package/packages/web/dist/assets/channel-gYp6Rt3b.js +0 -1
  124. package/packages/web/dist/assets/index-DgMuFFt3.css +0 -32
  125. package/packages/web/dist/assets/swimlanesDiagram-TC7HE7FX-B8q2Z_Nb.js +0 -8
@@ -1,4 +1,4 @@
1
- import{_ as l,L as gt,F as nt,C as Pt,a2 as Bt,a3 as Vt,a4 as Ft,c as ft,l as S,Q as zt,W as Gt,a5 as yt,k as Q,K as Ot,a6 as Dt,A as Kt}from"./mermaid.core-C888eQE1.js";import{d as lt}from"./arc-C28-SQX8.js";import"./index-DGq8BOVF.js";var tt=(function(){var e=l(function(k,i,d,h){for(d=d||{},h=k.length;h--;d[k[h]]=i);return d},"o"),t=[6,11,13,14,15,17,19,20,23,24],s=[1,12],r=[1,13],n=[1,14],a=[1,15],o=[1,16],c=[1,19],p=[1,20],y={trace:l(function(){},"trace"),yy:{},symbols_:{error:2,start:3,timeline_header:4,document:5,EOF:6,timeline:7,timeline_lr:8,timeline_td:9,line:10,SPACE:11,statement:12,NEWLINE:13,title:14,acc_title:15,acc_title_value:16,acc_descr:17,acc_descr_value:18,acc_descr_multiline_value:19,section:20,period_statement:21,event_statement:22,period:23,event:24,$accept:0,$end:1},terminals_:{2:"error",6:"EOF",7:"timeline",8:"timeline_lr",9:"timeline_td",11:"SPACE",13:"NEWLINE",14:"title",15:"acc_title",16:"acc_title_value",17:"acc_descr",18:"acc_descr_value",19:"acc_descr_multiline_value",20:"section",23:"period",24:"event"},productions_:[0,[3,3],[4,1],[4,1],[4,1],[5,0],[5,2],[10,2],[10,1],[10,1],[10,1],[12,1],[12,2],[12,2],[12,1],[12,1],[12,1],[12,1],[21,1],[22,1]],performAction:l(function(i,d,h,g,x,u,w){var v=u.length-1;switch(x){case 1:return u[v-1];case 3:g.setDirection("LR");break;case 4:g.setDirection("TD");break;case 5:this.$=[];break;case 6:u[v-1].push(u[v]),this.$=u[v-1];break;case 7:case 8:this.$=u[v];break;case 9:case 10:this.$=[];break;case 11:g.getCommonDb().setDiagramTitle(u[v].substr(6)),this.$=u[v].substr(6);break;case 12:this.$=u[v].trim(),g.getCommonDb().setAccTitle(this.$);break;case 13:case 14:this.$=u[v].trim(),g.getCommonDb().setAccDescription(this.$);break;case 15:g.addSection(u[v].substr(8)),this.$=u[v].substr(8);break;case 18:g.addTask(u[v],0,""),this.$=u[v];break;case 19:g.addEvent(u[v].substr(2)),this.$=u[v];break}},"anonymous"),table:[{3:1,4:2,7:[1,3],8:[1,4],9:[1,5]},{1:[3]},e(t,[2,5],{5:6}),e(t,[2,2]),e(t,[2,3]),e(t,[2,4]),{6:[1,7],10:8,11:[1,9],12:10,13:[1,11],14:s,15:r,17:n,19:a,20:o,21:17,22:18,23:c,24:p},e(t,[2,10],{1:[2,1]}),e(t,[2,6]),{12:21,14:s,15:r,17:n,19:a,20:o,21:17,22:18,23:c,24:p},e(t,[2,8]),e(t,[2,9]),e(t,[2,11]),{16:[1,22]},{18:[1,23]},e(t,[2,14]),e(t,[2,15]),e(t,[2,16]),e(t,[2,17]),e(t,[2,18]),e(t,[2,19]),e(t,[2,7]),e(t,[2,12]),e(t,[2,13])],defaultActions:{},parseError:l(function(i,d){if(d.recoverable)this.trace(i);else{var h=new Error(i);throw h.hash=d,h}},"parseError"),parse:l(function(i){var d=this,h=[0],g=[],x=[null],u=[],w=this.table,v="",M=0,R=0,P=2,V=1,L=u.slice.call(arguments,1),_=Object.create(this.lexer),C={yy:{}};for(var F in this.yy)Object.prototype.hasOwnProperty.call(this.yy,F)&&(C.yy[F]=this.yy[F]);_.setInput(i,C.yy),C.yy.lexer=_,C.yy.parser=this,typeof _.yylloc>"u"&&(_.yylloc={});var z=_.yylloc;u.push(z);var q=_.options&&_.options.ranges;typeof C.yy.parseError=="function"?this.parseError=C.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function K(A){h.length=h.length-2*A,x.length=x.length-A,u.length=u.length-A}l(K,"popStack");function O(){var A;return A=g.pop()||_.lex()||V,typeof A!="number"&&(A instanceof Array&&(g=A,A=g.pop()),A=d.symbols_[A]||A),A}l(O,"lex");for(var $,N,b,T,E={},H,I,B,D;;){if(N=h[h.length-1],this.defaultActions[N]?b=this.defaultActions[N]:(($===null||typeof $>"u")&&($=O()),b=w[N]&&w[N][$]),typeof b>"u"||!b.length||!b[0]){var U="";D=[];for(H in w[N])this.terminals_[H]&&H>P&&D.push("'"+this.terminals_[H]+"'");_.showPosition?U="Parse error on line "+(M+1)+`:
1
+ import{_ as l,L as gt,F as nt,C as Pt,a2 as Bt,a3 as Vt,a4 as Ft,c as ft,l as S,Q as zt,W as Gt,a5 as yt,k as Q,K as Ot,a6 as Dt,A as Kt}from"./mermaid.core-B1vpXQvD.js";import{d as lt}from"./arc-kwHa1cmz.js";import"./index-Bp8EjOaI.js";var tt=(function(){var e=l(function(k,i,d,h){for(d=d||{},h=k.length;h--;d[k[h]]=i);return d},"o"),t=[6,11,13,14,15,17,19,20,23,24],s=[1,12],r=[1,13],n=[1,14],a=[1,15],o=[1,16],c=[1,19],p=[1,20],y={trace:l(function(){},"trace"),yy:{},symbols_:{error:2,start:3,timeline_header:4,document:5,EOF:6,timeline:7,timeline_lr:8,timeline_td:9,line:10,SPACE:11,statement:12,NEWLINE:13,title:14,acc_title:15,acc_title_value:16,acc_descr:17,acc_descr_value:18,acc_descr_multiline_value:19,section:20,period_statement:21,event_statement:22,period:23,event:24,$accept:0,$end:1},terminals_:{2:"error",6:"EOF",7:"timeline",8:"timeline_lr",9:"timeline_td",11:"SPACE",13:"NEWLINE",14:"title",15:"acc_title",16:"acc_title_value",17:"acc_descr",18:"acc_descr_value",19:"acc_descr_multiline_value",20:"section",23:"period",24:"event"},productions_:[0,[3,3],[4,1],[4,1],[4,1],[5,0],[5,2],[10,2],[10,1],[10,1],[10,1],[12,1],[12,2],[12,2],[12,1],[12,1],[12,1],[12,1],[21,1],[22,1]],performAction:l(function(i,d,h,g,x,u,w){var v=u.length-1;switch(x){case 1:return u[v-1];case 3:g.setDirection("LR");break;case 4:g.setDirection("TD");break;case 5:this.$=[];break;case 6:u[v-1].push(u[v]),this.$=u[v-1];break;case 7:case 8:this.$=u[v];break;case 9:case 10:this.$=[];break;case 11:g.getCommonDb().setDiagramTitle(u[v].substr(6)),this.$=u[v].substr(6);break;case 12:this.$=u[v].trim(),g.getCommonDb().setAccTitle(this.$);break;case 13:case 14:this.$=u[v].trim(),g.getCommonDb().setAccDescription(this.$);break;case 15:g.addSection(u[v].substr(8)),this.$=u[v].substr(8);break;case 18:g.addTask(u[v],0,""),this.$=u[v];break;case 19:g.addEvent(u[v].substr(2)),this.$=u[v];break}},"anonymous"),table:[{3:1,4:2,7:[1,3],8:[1,4],9:[1,5]},{1:[3]},e(t,[2,5],{5:6}),e(t,[2,2]),e(t,[2,3]),e(t,[2,4]),{6:[1,7],10:8,11:[1,9],12:10,13:[1,11],14:s,15:r,17:n,19:a,20:o,21:17,22:18,23:c,24:p},e(t,[2,10],{1:[2,1]}),e(t,[2,6]),{12:21,14:s,15:r,17:n,19:a,20:o,21:17,22:18,23:c,24:p},e(t,[2,8]),e(t,[2,9]),e(t,[2,11]),{16:[1,22]},{18:[1,23]},e(t,[2,14]),e(t,[2,15]),e(t,[2,16]),e(t,[2,17]),e(t,[2,18]),e(t,[2,19]),e(t,[2,7]),e(t,[2,12]),e(t,[2,13])],defaultActions:{},parseError:l(function(i,d){if(d.recoverable)this.trace(i);else{var h=new Error(i);throw h.hash=d,h}},"parseError"),parse:l(function(i){var d=this,h=[0],g=[],x=[null],u=[],w=this.table,v="",M=0,R=0,P=2,V=1,L=u.slice.call(arguments,1),_=Object.create(this.lexer),C={yy:{}};for(var F in this.yy)Object.prototype.hasOwnProperty.call(this.yy,F)&&(C.yy[F]=this.yy[F]);_.setInput(i,C.yy),C.yy.lexer=_,C.yy.parser=this,typeof _.yylloc>"u"&&(_.yylloc={});var z=_.yylloc;u.push(z);var q=_.options&&_.options.ranges;typeof C.yy.parseError=="function"?this.parseError=C.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function K(A){h.length=h.length-2*A,x.length=x.length-A,u.length=u.length-A}l(K,"popStack");function O(){var A;return A=g.pop()||_.lex()||V,typeof A!="number"&&(A instanceof Array&&(g=A,A=g.pop()),A=d.symbols_[A]||A),A}l(O,"lex");for(var $,N,b,T,E={},H,I,B,D;;){if(N=h[h.length-1],this.defaultActions[N]?b=this.defaultActions[N]:(($===null||typeof $>"u")&&($=O()),b=w[N]&&w[N][$]),typeof b>"u"||!b.length||!b[0]){var U="";D=[];for(H in w[N])this.terminals_[H]&&H>P&&D.push("'"+this.terminals_[H]+"'");_.showPosition?U="Parse error on line "+(M+1)+`:
2
2
  `+_.showPosition()+`
3
3
  Expecting `+D.join(", ")+", got '"+(this.terminals_[$]||$)+"'":U="Parse error on line "+(M+1)+": Unexpected "+($==V?"end of input":"'"+(this.terminals_[$]||$)+"'"),this.parseError(U,{text:_.match,token:this.terminals_[$]||$,line:_.yylineno,loc:z,expected:D})}if(b[0]instanceof Array&&b.length>1)throw new Error("Parse Error: multiple actions possible at state: "+N+", token: "+$);switch(b[0]){case 1:h.push($),x.push(_.yytext),u.push(_.yylloc),h.push(b[1]),$=null,R=_.yyleng,v=_.yytext,M=_.yylineno,z=_.yylloc;break;case 2:if(I=this.productions_[b[1]][1],E.$=x[x.length-I],E._$={first_line:u[u.length-(I||1)].first_line,last_line:u[u.length-1].last_line,first_column:u[u.length-(I||1)].first_column,last_column:u[u.length-1].last_column},q&&(E._$.range=[u[u.length-(I||1)].range[0],u[u.length-1].range[1]]),T=this.performAction.apply(E,[v,R,M,C.yy,b[1],x,u].concat(L)),typeof T<"u")return T;I&&(h=h.slice(0,-1*I*2),x=x.slice(0,-1*I),u=u.slice(0,-1*I)),h.push(this.productions_[b[1]][0]),x.push(E.$),u.push(E._$),B=w[h[h.length-2]][h[h.length-1]],h.push(B);break;case 3:return!0}}return!0},"parse")},m=(function(){var k={EOF:1,parseError:l(function(d,h){if(this.yy.parser)this.yy.parser.parseError(d,h);else throw new Error(d)},"parseError"),setInput:l(function(i,d){return this.yy=d||this.yy||{},this._input=i,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:l(function(){var i=this._input[0];this.yytext+=i,this.yyleng++,this.offset++,this.match+=i,this.matched+=i;var d=i.match(/(?:\r\n?|\n).*/g);return d?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),i},"input"),unput:l(function(i){var d=i.length,h=i.split(/(?:\r\n?|\n)/g);this._input=i+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-d),this.offset-=d;var g=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),h.length-1&&(this.yylineno-=h.length-1);var x=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:h?(h.length===g.length?this.yylloc.first_column:0)+g[g.length-h.length].length-h[0].length:this.yylloc.first_column-d},this.options.ranges&&(this.yylloc.range=[x[0],x[0]+this.yyleng-d]),this.yyleng=this.yytext.length,this},"unput"),more:l(function(){return this._more=!0,this},"more"),reject:l(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
4
4
  `+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:l(function(i){this.unput(this.match.slice(i))},"less"),pastInput:l(function(){var i=this.matched.substr(0,this.matched.length-this.match.length);return(i.length>20?"...":"")+i.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:l(function(){var i=this.match;return i.length<20&&(i+=this._input.substr(0,20-i.length)),(i.substr(0,20)+(i.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:l(function(){var i=this.pastInput(),d=new Array(i.length+1).join("-");return i+this.upcomingInput()+`
@@ -1,4 +1,4 @@
1
- import{g as fl}from"./chunk-XXDRQBXY-BPXeDnB2.js";import{s as pl}from"./chunk-WEXAMYUT-B6IqsBxs.js";import{g as Ba,s as Vs,a as Ga,b as Ys,t as gl,q as ml,_ as u,D as Vt,l as Tl,c as Wa,p as El,r as yl,u as Al,j as Sl,A as Ol,O as Rl,C as Ll,L as Il,E as Nl,I as bl,aI as vl,k as _l}from"./mermaid.core-C888eQE1.js";import"./index-DGq8BOVF.js";var ja=typeof global=="object"&&global&&global.Object===Object&&global,Cl=typeof self=="object"&&self&&self.Object===Object&&self,be=ja||Cl||Function("return this")(),he=be.Symbol,Ka=Object.prototype,kl=Ka.hasOwnProperty,wl=Ka.toString,Wt=he?he.toStringTag:void 0;function xl(t){var e=kl.call(t,Wt),n=t[Wt];try{t[Wt]=void 0;var s=!0}catch{}var r=wl.call(t);return s&&(e?t[Wt]=n:delete t[Wt]),r}var Ml=Object.prototype,$l=Ml.toString;function Pl(t){return $l.call(t)}var Ul="[object Null]",Dl="[object Undefined]",ai=he?he.toStringTag:void 0;function rt(t){return t==null?t===void 0?Dl:Ul:ai&&ai in Object(t)?xl(t):Pl(t)}function Ee(t){return t!=null&&typeof t=="object"}var Fl="[object Symbol]";function rs(t){return typeof t=="symbol"||Ee(t)&&rt(t)==Fl}function is(t,e){for(var n=-1,s=t==null?0:t.length,r=Array(s);++n<s;)r[n]=e(t[n],n,t);return r}var v=Array.isArray,oi=he?he.prototype:void 0,ci=oi?oi.toString:void 0;function za(t){if(typeof t=="string")return t;if(v(t))return is(t,za)+"";if(rs(t))return ci?ci.call(t):"";var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}var Bl=/\s/;function Gl(t){for(var e=t.length;e--&&Bl.test(t.charAt(e)););return e}var Wl=/^\s+/;function jl(t){return t&&t.slice(0,Gl(t)+1).replace(Wl,"")}function ue(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}var li=NaN,Kl=/^[-+]0x[0-9a-f]+$/i,zl=/^0b[01]+$/i,Hl=/^0o[0-7]+$/i,Vl=parseInt;function Yl(t){if(typeof t=="number")return t;if(rs(t))return li;if(ue(t)){var e=typeof t.valueOf=="function"?t.valueOf():t;t=ue(e)?e+"":e}if(typeof t!="string")return t===0?t:+t;t=jl(t);var n=zl.test(t);return n||Hl.test(t)?Vl(t.slice(2),n?2:8):Kl.test(t)?li:+t}var hi=1/0,Xl=17976931348623157e292;function ql(t){if(!t)return t===0?t:0;if(t=Yl(t),t===hi||t===-hi){var e=t<0?-1:1;return e*Xl}return t===t?t:0}function as(t){var e=ql(t),n=e%1;return e===e?n?e-n:e:0}function un(t){return t}var Jl="[object AsyncFunction]",Zl="[object Function]",Ql="[object GeneratorFunction]",eh="[object Proxy]";function je(t){if(!ue(t))return!1;var e=rt(t);return e==Zl||e==Ql||e==Jl||e==eh}var $s=be["__core-js_shared__"],ui=(function(){var t=/[^.]+$/.exec($s&&$s.keys&&$s.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""})();function th(t){return!!ui&&ui in t}var nh=Function.prototype,sh=nh.toString;function mt(t){if(t!=null){try{return sh.call(t)}catch{}try{return t+""}catch{}}return""}var rh=/[\\^$.*+?()[\]{}|]/g,ih=/^\[object .+?Constructor\]$/,ah=Function.prototype,oh=Object.prototype,ch=ah.toString,lh=oh.hasOwnProperty,hh=RegExp("^"+ch.call(lh).replace(rh,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function uh(t){if(!ue(t)||th(t))return!1;var e=je(t)?hh:ih;return e.test(mt(t))}function dh(t,e){return t==null?void 0:t[e]}function Tt(t,e){var n=dh(t,e);return uh(n)?n:void 0}var Xs=Tt(be,"WeakMap"),di=Object.create,fh=(function(){function t(){}return function(e){if(!ue(e))return{};if(di)return di(e);t.prototype=e;var n=new t;return t.prototype=void 0,n}})();function ph(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)}function W(){}function gh(t,e){var n=-1,s=t.length;for(e||(e=Array(s));++n<s;)e[n]=t[n];return e}var mh=800,Th=16,Eh=Date.now;function yh(t){var e=0,n=0;return function(){var s=Eh(),r=Th-(s-n);if(n=s,r>0){if(++e>=mh)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}function Ah(t){return function(){return t}}var Wn=(function(){try{var t=Tt(Object,"defineProperty");return t({},"",{}),t}catch{}})(),Sh=Wn?function(t,e){return Wn(t,"toString",{configurable:!0,enumerable:!1,value:Ah(e),writable:!0})}:un,Oh=yh(Sh);function Ha(t,e){for(var n=-1,s=t==null?0:t.length;++n<s&&e(t[n],n,t)!==!1;);return t}function Va(t,e,n,s){for(var r=t.length,i=n+-1;++i<r;)if(e(t[i],i,t))return i;return-1}function Rh(t){return t!==t}function Lh(t,e,n){for(var s=n-1,r=t.length;++s<r;)if(t[s]===e)return s;return-1}function Ar(t,e,n){return e===e?Lh(t,e,n):Va(t,Rh,n)}function Ya(t,e){var n=t==null?0:t.length;return!!n&&Ar(t,e,0)>-1}var Ih=9007199254740991,Nh=/^(?:0|[1-9]\d*)$/;function os(t,e){var n=typeof t;return e=e??Ih,!!e&&(n=="number"||n!="symbol"&&Nh.test(t))&&t>-1&&t%1==0&&t<e}function Sr(t,e,n){e=="__proto__"&&Wn?Wn(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}function dn(t,e){return t===e||t!==t&&e!==e}var bh=Object.prototype,vh=bh.hasOwnProperty;function cs(t,e,n){var s=t[e];(!(vh.call(t,e)&&dn(s,n))||n===void 0&&!(e in t))&&Sr(t,e,n)}function fn(t,e,n,s){var r=!n;n||(n={});for(var i=-1,a=e.length;++i<a;){var o=e[i],c=void 0;c===void 0&&(c=t[o]),r?Sr(n,o,c):cs(n,o,c)}return n}var fi=Math.max;function _h(t,e,n){return e=fi(e===void 0?t.length-1:e,0),function(){for(var s=arguments,r=-1,i=fi(s.length-e,0),a=Array(i);++r<i;)a[r]=s[e+r];r=-1;for(var o=Array(e+1);++r<e;)o[r]=s[r];return o[e]=n(a),ph(t,this,o)}}function Or(t,e){return Oh(_h(t,e,un),t+"")}var Ch=9007199254740991;function Rr(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=Ch}function ve(t){return t!=null&&Rr(t.length)&&!je(t)}function Xa(t,e,n){if(!ue(n))return!1;var s=typeof e;return(s=="number"?ve(n)&&os(e,n.length):s=="string"&&e in n)?dn(n[e],t):!1}function kh(t){return Or(function(e,n){var s=-1,r=n.length,i=r>1?n[r-1]:void 0,a=r>2?n[2]:void 0;for(i=t.length>3&&typeof i=="function"?(r--,i):void 0,a&&Xa(n[0],n[1],a)&&(i=r<3?void 0:i,r=1),e=Object(e);++s<r;){var o=n[s];o&&t(e,o,s,i)}return e})}var wh=Object.prototype;function pn(t){var e=t&&t.constructor,n=typeof e=="function"&&e.prototype||wh;return t===n}function xh(t,e){for(var n=-1,s=Array(t);++n<t;)s[n]=e(n);return s}var Mh="[object Arguments]";function pi(t){return Ee(t)&&rt(t)==Mh}var qa=Object.prototype,$h=qa.hasOwnProperty,Ph=qa.propertyIsEnumerable,ls=pi((function(){return arguments})())?pi:function(t){return Ee(t)&&$h.call(t,"callee")&&!Ph.call(t,"callee")};function Uh(){return!1}var Ja=typeof exports=="object"&&exports&&!exports.nodeType&&exports,gi=Ja&&typeof module=="object"&&module&&!module.nodeType&&module,Dh=gi&&gi.exports===Ja,mi=Dh?be.Buffer:void 0,Fh=mi?mi.isBuffer:void 0,rn=Fh||Uh,Bh="[object Arguments]",Gh="[object Array]",Wh="[object Boolean]",jh="[object Date]",Kh="[object Error]",zh="[object Function]",Hh="[object Map]",Vh="[object Number]",Yh="[object Object]",Xh="[object RegExp]",qh="[object Set]",Jh="[object String]",Zh="[object WeakMap]",Qh="[object ArrayBuffer]",eu="[object DataView]",tu="[object Float32Array]",nu="[object Float64Array]",su="[object Int8Array]",ru="[object Int16Array]",iu="[object Int32Array]",au="[object Uint8Array]",ou="[object Uint8ClampedArray]",cu="[object Uint16Array]",lu="[object Uint32Array]",w={};w[tu]=w[nu]=w[su]=w[ru]=w[iu]=w[au]=w[ou]=w[cu]=w[lu]=!0;w[Bh]=w[Gh]=w[Qh]=w[Wh]=w[eu]=w[jh]=w[Kh]=w[zh]=w[Hh]=w[Vh]=w[Yh]=w[Xh]=w[qh]=w[Jh]=w[Zh]=!1;function hu(t){return Ee(t)&&Rr(t.length)&&!!w[rt(t)]}function hs(t){return function(e){return t(e)}}var Za=typeof exports=="object"&&exports&&!exports.nodeType&&exports,tn=Za&&typeof module=="object"&&module&&!module.nodeType&&module,uu=tn&&tn.exports===Za,Ps=uu&&ja.process,Qe=(function(){try{var t=tn&&tn.require&&tn.require("util").types;return t||Ps&&Ps.binding&&Ps.binding("util")}catch{}})(),Ti=Qe&&Qe.isTypedArray,Lr=Ti?hs(Ti):hu,du=Object.prototype,fu=du.hasOwnProperty;function Qa(t,e){var n=v(t),s=!n&&ls(t),r=!n&&!s&&rn(t),i=!n&&!s&&!r&&Lr(t),a=n||s||r||i,o=a?xh(t.length,String):[],c=o.length;for(var l in t)(e||fu.call(t,l))&&!(a&&(l=="length"||r&&(l=="offset"||l=="parent")||i&&(l=="buffer"||l=="byteLength"||l=="byteOffset")||os(l,c)))&&o.push(l);return o}function eo(t,e){return function(n){return t(e(n))}}var pu=eo(Object.keys,Object),gu=Object.prototype,mu=gu.hasOwnProperty;function to(t){if(!pn(t))return pu(t);var e=[];for(var n in Object(t))mu.call(t,n)&&n!="constructor"&&e.push(n);return e}function de(t){return ve(t)?Qa(t):to(t)}var Tu=Object.prototype,Eu=Tu.hasOwnProperty,qs=kh(function(t,e){if(pn(e)||ve(e)){fn(e,de(e),t);return}for(var n in e)Eu.call(e,n)&&cs(t,n,e[n])});function yu(t){var e=[];if(t!=null)for(var n in Object(t))e.push(n);return e}var Au=Object.prototype,Su=Au.hasOwnProperty;function Ou(t){if(!ue(t))return yu(t);var e=pn(t),n=[];for(var s in t)s=="constructor"&&(e||!Su.call(t,s))||n.push(s);return n}function Ir(t){return ve(t)?Qa(t,!0):Ou(t)}var Ru=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Lu=/^\w*$/;function Nr(t,e){if(v(t))return!1;var n=typeof t;return n=="number"||n=="symbol"||n=="boolean"||t==null||rs(t)?!0:Lu.test(t)||!Ru.test(t)||e!=null&&t in Object(e)}var an=Tt(Object,"create");function Iu(){this.__data__=an?an(null):{},this.size=0}function Nu(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}var bu="__lodash_hash_undefined__",vu=Object.prototype,_u=vu.hasOwnProperty;function Cu(t){var e=this.__data__;if(an){var n=e[t];return n===bu?void 0:n}return _u.call(e,t)?e[t]:void 0}var ku=Object.prototype,wu=ku.hasOwnProperty;function xu(t){var e=this.__data__;return an?e[t]!==void 0:wu.call(e,t)}var Mu="__lodash_hash_undefined__";function $u(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=an&&e===void 0?Mu:e,this}function dt(t){var e=-1,n=t==null?0:t.length;for(this.clear();++e<n;){var s=t[e];this.set(s[0],s[1])}}dt.prototype.clear=Iu;dt.prototype.delete=Nu;dt.prototype.get=Cu;dt.prototype.has=xu;dt.prototype.set=$u;function Pu(){this.__data__=[],this.size=0}function us(t,e){for(var n=t.length;n--;)if(dn(t[n][0],e))return n;return-1}var Uu=Array.prototype,Du=Uu.splice;function Fu(t){var e=this.__data__,n=us(e,t);if(n<0)return!1;var s=e.length-1;return n==s?e.pop():Du.call(e,n,1),--this.size,!0}function Bu(t){var e=this.__data__,n=us(e,t);return n<0?void 0:e[n][1]}function Gu(t){return us(this.__data__,t)>-1}function Wu(t,e){var n=this.__data__,s=us(n,t);return s<0?(++this.size,n.push([t,e])):n[s][1]=e,this}function Ke(t){var e=-1,n=t==null?0:t.length;for(this.clear();++e<n;){var s=t[e];this.set(s[0],s[1])}}Ke.prototype.clear=Pu;Ke.prototype.delete=Fu;Ke.prototype.get=Bu;Ke.prototype.has=Gu;Ke.prototype.set=Wu;var on=Tt(be,"Map");function ju(){this.size=0,this.__data__={hash:new dt,map:new(on||Ke),string:new dt}}function Ku(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}function ds(t,e){var n=t.__data__;return Ku(e)?n[typeof e=="string"?"string":"hash"]:n.map}function zu(t){var e=ds(this,t).delete(t);return this.size-=e?1:0,e}function Hu(t){return ds(this,t).get(t)}function Vu(t){return ds(this,t).has(t)}function Yu(t,e){var n=ds(this,t),s=n.size;return n.set(t,e),this.size+=n.size==s?0:1,this}function ze(t){var e=-1,n=t==null?0:t.length;for(this.clear();++e<n;){var s=t[e];this.set(s[0],s[1])}}ze.prototype.clear=ju;ze.prototype.delete=zu;ze.prototype.get=Hu;ze.prototype.has=Vu;ze.prototype.set=Yu;var Xu="Expected a function";function br(t,e){if(typeof t!="function"||e!=null&&typeof e!="function")throw new TypeError(Xu);var n=function(){var s=arguments,r=e?e.apply(this,s):s[0],i=n.cache;if(i.has(r))return i.get(r);var a=t.apply(this,s);return n.cache=i.set(r,a)||i,a};return n.cache=new(br.Cache||ze),n}br.Cache=ze;var qu=500;function Ju(t){var e=br(t,function(s){return n.size===qu&&n.clear(),s}),n=e.cache;return e}var Zu=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Qu=/\\(\\)?/g,ed=Ju(function(t){var e=[];return t.charCodeAt(0)===46&&e.push(""),t.replace(Zu,function(n,s,r,i){e.push(r?i.replace(Qu,"$1"):s||n)}),e});function td(t){return t==null?"":za(t)}function fs(t,e){return v(t)?t:Nr(t,e)?[t]:ed(td(t))}function gn(t){if(typeof t=="string"||rs(t))return t;var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}function vr(t,e){e=fs(e,t);for(var n=0,s=e.length;t!=null&&n<s;)t=t[gn(e[n++])];return n&&n==s?t:void 0}function nd(t,e,n){var s=t==null?void 0:vr(t,e);return s===void 0?n:s}function _r(t,e){for(var n=-1,s=e.length,r=t.length;++n<s;)t[r+n]=e[n];return t}var Ei=he?he.isConcatSpreadable:void 0;function sd(t){return v(t)||ls(t)||!!(Ei&&t&&t[Ei])}function Cr(t,e,n,s,r){var i=-1,a=t.length;for(n||(n=sd),r||(r=[]);++i<a;){var o=t[i];n(o)?_r(r,o):s||(r[r.length]=o)}return r}function Te(t){var e=t==null?0:t.length;return e?Cr(t):[]}var no=eo(Object.getPrototypeOf,Object);function so(t,e,n){var s=-1,r=t.length;e<0&&(e=-e>r?0:r+e),n=n>r?r:n,n<0&&(n+=r),r=e>n?0:n-e>>>0,e>>>=0;for(var i=Array(r);++s<r;)i[s]=t[s+e];return i}function rd(t,e,n,s){var r=-1,i=t==null?0:t.length;for(s&&i&&(n=t[++r]);++r<i;)n=e(n,t[r],r,t);return n}function id(){this.__data__=new Ke,this.size=0}function ad(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n}function od(t){return this.__data__.get(t)}function cd(t){return this.__data__.has(t)}var ld=200;function hd(t,e){var n=this.__data__;if(n instanceof Ke){var s=n.__data__;if(!on||s.length<ld-1)return s.push([t,e]),this.size=++n.size,this;n=this.__data__=new ze(s)}return n.set(t,e),this.size=n.size,this}function Ie(t){var e=this.__data__=new Ke(t);this.size=e.size}Ie.prototype.clear=id;Ie.prototype.delete=ad;Ie.prototype.get=od;Ie.prototype.has=cd;Ie.prototype.set=hd;function ud(t,e){return t&&fn(e,de(e),t)}function dd(t,e){return t&&fn(e,Ir(e),t)}var ro=typeof exports=="object"&&exports&&!exports.nodeType&&exports,yi=ro&&typeof module=="object"&&module&&!module.nodeType&&module,fd=yi&&yi.exports===ro,Ai=fd?be.Buffer:void 0,Si=Ai?Ai.allocUnsafe:void 0;function pd(t,e){var n=t.length,s=Si?Si(n):new t.constructor(n);return t.copy(s),s}function kr(t,e){for(var n=-1,s=t==null?0:t.length,r=0,i=[];++n<s;){var a=t[n];e(a,n,t)&&(i[r++]=a)}return i}function io(){return[]}var gd=Object.prototype,md=gd.propertyIsEnumerable,Oi=Object.getOwnPropertySymbols,wr=Oi?function(t){return t==null?[]:(t=Object(t),kr(Oi(t),function(e){return md.call(t,e)}))}:io;function Td(t,e){return fn(t,wr(t),e)}var Ed=Object.getOwnPropertySymbols,ao=Ed?function(t){for(var e=[];t;)_r(e,wr(t)),t=no(t);return e}:io;function yd(t,e){return fn(t,ao(t),e)}function oo(t,e,n){var s=e(t);return v(t)?s:_r(s,n(t))}function Js(t){return oo(t,de,wr)}function Ad(t){return oo(t,Ir,ao)}var Zs=Tt(be,"DataView"),Qs=Tt(be,"Promise"),It=Tt(be,"Set"),Ri="[object Map]",Sd="[object Object]",Li="[object Promise]",Ii="[object Set]",Ni="[object WeakMap]",bi="[object DataView]",Od=mt(Zs),Rd=mt(on),Ld=mt(Qs),Id=mt(It),Nd=mt(Xs),ce=rt;(Zs&&ce(new Zs(new ArrayBuffer(1)))!=bi||on&&ce(new on)!=Ri||Qs&&ce(Qs.resolve())!=Li||It&&ce(new It)!=Ii||Xs&&ce(new Xs)!=Ni)&&(ce=function(t){var e=rt(t),n=e==Sd?t.constructor:void 0,s=n?mt(n):"";if(s)switch(s){case Od:return bi;case Rd:return Ri;case Ld:return Li;case Id:return Ii;case Nd:return Ni}return e});var bd=Object.prototype,vd=bd.hasOwnProperty;function _d(t){var e=t.length,n=new t.constructor(e);return e&&typeof t[0]=="string"&&vd.call(t,"index")&&(n.index=t.index,n.input=t.input),n}var jn=be.Uint8Array;function Cd(t){var e=new t.constructor(t.byteLength);return new jn(e).set(new jn(t)),e}function kd(t,e){var n=t.buffer;return new t.constructor(n,t.byteOffset,t.byteLength)}var wd=/\w*$/;function xd(t){var e=new t.constructor(t.source,wd.exec(t));return e.lastIndex=t.lastIndex,e}var vi=he?he.prototype:void 0,_i=vi?vi.valueOf:void 0;function Md(t){return _i?Object(_i.call(t)):{}}function $d(t,e){var n=t.buffer;return new t.constructor(n,t.byteOffset,t.length)}var Pd="[object Boolean]",Ud="[object Date]",Dd="[object Map]",Fd="[object Number]",Bd="[object RegExp]",Gd="[object Set]",Wd="[object String]",jd="[object Symbol]",Kd="[object ArrayBuffer]",zd="[object DataView]",Hd="[object Float32Array]",Vd="[object Float64Array]",Yd="[object Int8Array]",Xd="[object Int16Array]",qd="[object Int32Array]",Jd="[object Uint8Array]",Zd="[object Uint8ClampedArray]",Qd="[object Uint16Array]",ef="[object Uint32Array]";function tf(t,e,n){var s=t.constructor;switch(e){case Kd:return Cd(t);case Pd:case Ud:return new s(+t);case zd:return kd(t);case Hd:case Vd:case Yd:case Xd:case qd:case Jd:case Zd:case Qd:case ef:return $d(t);case Dd:return new s;case Fd:case Wd:return new s(t);case Bd:return xd(t);case Gd:return new s;case jd:return Md(t)}}function nf(t){return typeof t.constructor=="function"&&!pn(t)?fh(no(t)):{}}var sf="[object Map]";function rf(t){return Ee(t)&&ce(t)==sf}var Ci=Qe&&Qe.isMap,af=Ci?hs(Ci):rf,of="[object Set]";function cf(t){return Ee(t)&&ce(t)==of}var ki=Qe&&Qe.isSet,lf=ki?hs(ki):cf,hf=2,co="[object Arguments]",uf="[object Array]",df="[object Boolean]",ff="[object Date]",pf="[object Error]",lo="[object Function]",gf="[object GeneratorFunction]",mf="[object Map]",Tf="[object Number]",ho="[object Object]",Ef="[object RegExp]",yf="[object Set]",Af="[object String]",Sf="[object Symbol]",Of="[object WeakMap]",Rf="[object ArrayBuffer]",Lf="[object DataView]",If="[object Float32Array]",Nf="[object Float64Array]",bf="[object Int8Array]",vf="[object Int16Array]",_f="[object Int32Array]",Cf="[object Uint8Array]",kf="[object Uint8ClampedArray]",wf="[object Uint16Array]",xf="[object Uint32Array]",C={};C[co]=C[uf]=C[Rf]=C[Lf]=C[df]=C[ff]=C[If]=C[Nf]=C[bf]=C[vf]=C[_f]=C[mf]=C[Tf]=C[ho]=C[Ef]=C[yf]=C[Af]=C[Sf]=C[Cf]=C[kf]=C[wf]=C[xf]=!0;C[pf]=C[lo]=C[Of]=!1;function Cn(t,e,n,s,r,i){var a,o=e&hf;if(a!==void 0)return a;if(!ue(t))return t;var c=v(t);if(c)return a=_d(t),gh(t,a);var l=ce(t),d=l==lo||l==gf;if(rn(t))return pd(t);if(l==ho||l==co||d&&!r)return a=d?{}:nf(t),o?yd(t,dd(a,t)):Td(t,ud(a,t));if(!C[l])return r?t:{};a=tf(t,l),i||(i=new Ie);var h=i.get(t);if(h)return h;i.set(t,a),lf(t)?t.forEach(function(g){a.add(Cn(g,e,n,g,t,i))}):af(t)&&t.forEach(function(g,T){a.set(T,Cn(g,e,n,T,t,i))});var f=Js,p=c?void 0:f(t);return Ha(p||t,function(g,T){p&&(T=g,g=t[T]),cs(a,T,Cn(g,e,n,T,t,i))}),a}var Mf=4;function H(t){return Cn(t,Mf)}function mn(t){for(var e=-1,n=t==null?0:t.length,s=0,r=[];++e<n;){var i=t[e];i&&(r[s++]=i)}return r}var $f="__lodash_hash_undefined__";function Pf(t){return this.__data__.set(t,$f),this}function Uf(t){return this.__data__.has(t)}function xt(t){var e=-1,n=t==null?0:t.length;for(this.__data__=new ze;++e<n;)this.add(t[e])}xt.prototype.add=xt.prototype.push=Pf;xt.prototype.has=Uf;function uo(t,e){for(var n=-1,s=t==null?0:t.length;++n<s;)if(e(t[n],n,t))return!0;return!1}function xr(t,e){return t.has(e)}var Df=1,Ff=2;function fo(t,e,n,s,r,i){var a=n&Df,o=t.length,c=e.length;if(o!=c&&!(a&&c>o))return!1;var l=i.get(t),d=i.get(e);if(l&&d)return l==e&&d==t;var h=-1,f=!0,p=n&Ff?new xt:void 0;for(i.set(t,e),i.set(e,t);++h<o;){var g=t[h],T=e[h];if(s)var L=a?s(T,g,h,e,t,i):s(g,T,h,t,e,i);if(L!==void 0){if(L)continue;f=!1;break}if(p){if(!uo(e,function(y,E){if(!xr(p,E)&&(g===y||r(g,y,n,s,i)))return p.push(E)})){f=!1;break}}else if(!(g===T||r(g,T,n,s,i))){f=!1;break}}return i.delete(t),i.delete(e),f}function Bf(t){var e=-1,n=Array(t.size);return t.forEach(function(s,r){n[++e]=[r,s]}),n}function Mr(t){var e=-1,n=Array(t.size);return t.forEach(function(s){n[++e]=s}),n}var Gf=1,Wf=2,jf="[object Boolean]",Kf="[object Date]",zf="[object Error]",Hf="[object Map]",Vf="[object Number]",Yf="[object RegExp]",Xf="[object Set]",qf="[object String]",Jf="[object Symbol]",Zf="[object ArrayBuffer]",Qf="[object DataView]",wi=he?he.prototype:void 0,Us=wi?wi.valueOf:void 0;function ep(t,e,n,s,r,i,a){switch(n){case Qf:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case Zf:return!(t.byteLength!=e.byteLength||!i(new jn(t),new jn(e)));case jf:case Kf:case Vf:return dn(+t,+e);case zf:return t.name==e.name&&t.message==e.message;case Yf:case qf:return t==e+"";case Hf:var o=Bf;case Xf:var c=s&Gf;if(o||(o=Mr),t.size!=e.size&&!c)return!1;var l=a.get(t);if(l)return l==e;s|=Wf,a.set(t,e);var d=fo(o(t),o(e),s,r,i,a);return a.delete(t),d;case Jf:if(Us)return Us.call(t)==Us.call(e)}return!1}var tp=1,np=Object.prototype,sp=np.hasOwnProperty;function rp(t,e,n,s,r,i){var a=n&tp,o=Js(t),c=o.length,l=Js(e),d=l.length;if(c!=d&&!a)return!1;for(var h=c;h--;){var f=o[h];if(!(a?f in e:sp.call(e,f)))return!1}var p=i.get(t),g=i.get(e);if(p&&g)return p==e&&g==t;var T=!0;i.set(t,e),i.set(e,t);for(var L=a;++h<c;){f=o[h];var y=t[f],E=e[f];if(s)var m=a?s(E,y,f,e,t,i):s(y,E,f,t,e,i);if(!(m===void 0?y===E||r(y,E,n,s,i):m)){T=!1;break}L||(L=f=="constructor")}if(T&&!L){var A=t.constructor,_=e.constructor;A!=_&&"constructor"in t&&"constructor"in e&&!(typeof A=="function"&&A instanceof A&&typeof _=="function"&&_ instanceof _)&&(T=!1)}return i.delete(t),i.delete(e),T}var ip=1,xi="[object Arguments]",Mi="[object Array]",Ln="[object Object]",ap=Object.prototype,$i=ap.hasOwnProperty;function op(t,e,n,s,r,i){var a=v(t),o=v(e),c=a?Mi:ce(t),l=o?Mi:ce(e);c=c==xi?Ln:c,l=l==xi?Ln:l;var d=c==Ln,h=l==Ln,f=c==l;if(f&&rn(t)){if(!rn(e))return!1;a=!0,d=!1}if(f&&!d)return i||(i=new Ie),a||Lr(t)?fo(t,e,n,s,r,i):ep(t,e,c,n,s,r,i);if(!(n&ip)){var p=d&&$i.call(t,"__wrapped__"),g=h&&$i.call(e,"__wrapped__");if(p||g){var T=p?t.value():t,L=g?e.value():e;return i||(i=new Ie),r(T,L,n,s,i)}}return f?(i||(i=new Ie),rp(t,e,n,s,r,i)):!1}function $r(t,e,n,s,r){return t===e?!0:t==null||e==null||!Ee(t)&&!Ee(e)?t!==t&&e!==e:op(t,e,n,s,$r,r)}var cp=1,lp=2;function hp(t,e,n,s){var r=n.length,i=r;if(t==null)return!i;for(t=Object(t);r--;){var a=n[r];if(a[2]?a[1]!==t[a[0]]:!(a[0]in t))return!1}for(;++r<i;){a=n[r];var o=a[0],c=t[o],l=a[1];if(a[2]){if(c===void 0&&!(o in t))return!1}else{var d=new Ie,h;if(!(h===void 0?$r(l,c,cp|lp,s,d):h))return!1}}return!0}function po(t){return t===t&&!ue(t)}function up(t){for(var e=de(t),n=e.length;n--;){var s=e[n],r=t[s];e[n]=[s,r,po(r)]}return e}function go(t,e){return function(n){return n==null?!1:n[t]===e&&(e!==void 0||t in Object(n))}}function dp(t){var e=up(t);return e.length==1&&e[0][2]?go(e[0][0],e[0][1]):function(n){return n===t||hp(n,t,e)}}function fp(t,e){return t!=null&&e in Object(t)}function mo(t,e,n){e=fs(e,t);for(var s=-1,r=e.length,i=!1;++s<r;){var a=gn(e[s]);if(!(i=t!=null&&n(t,a)))break;t=t[a]}return i||++s!=r?i:(r=t==null?0:t.length,!!r&&Rr(r)&&os(a,r)&&(v(t)||ls(t)))}function pp(t,e){return t!=null&&mo(t,e,fp)}var gp=1,mp=2;function Tp(t,e){return Nr(t)&&po(e)?go(gn(t),e):function(n){var s=nd(n,t);return s===void 0&&s===e?pp(n,t):$r(e,s,gp|mp)}}function Ep(t){return function(e){return e==null?void 0:e[t]}}function yp(t){return function(e){return vr(e,t)}}function Ap(t){return Nr(t)?Ep(gn(t)):yp(t)}function _e(t){return typeof t=="function"?t:t==null?un:typeof t=="object"?v(t)?Tp(t[0],t[1]):dp(t):Ap(t)}function Sp(t,e,n,s){for(var r=-1,i=t==null?0:t.length;++r<i;){var a=t[r];e(s,a,n(a),t)}return s}function Op(t){return function(e,n,s){for(var r=-1,i=Object(e),a=s(e),o=a.length;o--;){var c=a[++r];if(n(i[c],c,i)===!1)break}return e}}var Rp=Op();function Lp(t,e){return t&&Rp(t,e,de)}function Ip(t,e){return function(n,s){if(n==null)return n;if(!ve(n))return t(n,s);for(var r=n.length,i=-1,a=Object(n);++i<r&&s(a[i],i,a)!==!1;);return n}}var Et=Ip(Lp);function Np(t,e,n,s){return Et(t,function(r,i,a){e(s,r,n(r),a)}),s}function bp(t,e){return function(n,s){var r=v(n)?Sp:Np,i=e?e():{};return r(n,t,_e(s),i)}}var To=Object.prototype,vp=To.hasOwnProperty,Pr=Or(function(t,e){t=Object(t);var n=-1,s=e.length,r=s>2?e[2]:void 0;for(r&&Xa(e[0],e[1],r)&&(s=1);++n<s;)for(var i=e[n],a=Ir(i),o=-1,c=a.length;++o<c;){var l=a[o],d=t[l];(d===void 0||dn(d,To[l])&&!vp.call(t,l))&&(t[l]=i[l])}return t});function Pi(t){return Ee(t)&&ve(t)}var _p=200;function Cp(t,e,n,s){var r=-1,i=Ya,a=!0,o=t.length,c=[],l=e.length;if(!o)return c;e.length>=_p&&(i=xr,a=!1,e=new xt(e));e:for(;++r<o;){var d=t[r],h=d;if(d=d!==0?d:0,a&&h===h){for(var f=l;f--;)if(e[f]===h)continue e;c.push(d)}else i(e,h,s)||c.push(d)}return c}var ps=Or(function(t,e){return Pi(t)?Cp(t,Cr(e,1,Pi,!0)):[]});function ft(t){var e=t==null?0:t.length;return e?t[e-1]:void 0}function z(t,e,n){var s=t==null?0:t.length;return s?(e=e===void 0?1:as(e),so(t,e<0?0:e,s)):[]}function cn(t,e,n){var s=t==null?0:t.length;return s?(e=e===void 0?1:as(e),e=s-e,so(t,0,e<0?0:e)):[]}function kp(t){return typeof t=="function"?t:un}function N(t,e){var n=v(t)?Ha:Et;return n(t,kp(e))}function wp(t,e){for(var n=-1,s=t==null?0:t.length;++n<s;)if(!e(t[n],n,t))return!1;return!0}function xp(t,e){var n=!0;return Et(t,function(s,r,i){return n=!!e(s,r,i),n}),n}function Ne(t,e,n){var s=v(t)?wp:xp;return s(t,_e(e))}function Eo(t,e){var n=[];return Et(t,function(s,r,i){e(s,r,i)&&n.push(s)}),n}function fe(t,e){var n=v(t)?kr:Eo;return n(t,_e(e))}function Mp(t){return function(e,n,s){var r=Object(e);if(!ve(e)){var i=_e(n);e=de(e),n=function(o){return i(r[o],o,r)}}var a=t(e,n,s);return a>-1?r[i?e[a]:a]:void 0}}var $p=Math.max;function Pp(t,e,n){var s=t==null?0:t.length;if(!s)return-1;var r=n==null?0:as(n);return r<0&&(r=$p(s+r,0)),Va(t,_e(e),r)}var Mt=Mp(Pp);function ye(t){return t&&t.length?t[0]:void 0}function Up(t,e){var n=-1,s=ve(t)?Array(t.length):[];return Et(t,function(r,i,a){s[++n]=e(r,i,a)}),s}function S(t,e){var n=v(t)?is:Up;return n(t,_e(e))}function le(t,e){return Cr(S(t,e))}var Dp=Object.prototype,Fp=Dp.hasOwnProperty,Bp=bp(function(t,e,n){Fp.call(t,n)?t[n].push(e):Sr(t,n,[e])}),Gp=Object.prototype,Wp=Gp.hasOwnProperty;function jp(t,e){return t!=null&&Wp.call(t,e)}function R(t,e){return t!=null&&mo(t,e,jp)}var Kp="[object String]";function Ae(t){return typeof t=="string"||!v(t)&&Ee(t)&&rt(t)==Kp}function zp(t,e){return is(e,function(n){return t[n]})}function B(t){return t==null?[]:zp(t,de(t))}var Hp=Math.max;function te(t,e,n,s){t=ve(t)?t:B(t),n=n?as(n):0;var r=t.length;return n<0&&(n=Hp(r+n,0)),Ae(t)?n<=r&&t.indexOf(e,n)>-1:!!r&&Ar(t,e,n)>-1}function Ui(t,e,n){var s=t==null?0:t.length;if(!s)return-1;var r=0;return Ar(t,e,r)}var Vp="[object Map]",Yp="[object Set]",Xp=Object.prototype,qp=Xp.hasOwnProperty;function k(t){if(t==null)return!0;if(ve(t)&&(v(t)||typeof t=="string"||typeof t.splice=="function"||rn(t)||Lr(t)||ls(t)))return!t.length;var e=ce(t);if(e==Vp||e==Yp)return!t.size;if(pn(t))return!to(t).length;for(var n in t)if(qp.call(t,n))return!1;return!0}var Jp="[object RegExp]";function Zp(t){return Ee(t)&&rt(t)==Jp}var Di=Qe&&Qe.isRegExp,et=Di?hs(Di):Zp;function Fe(t){return t===void 0}var Qp="Expected a function";function eg(t){if(typeof t!="function")throw new TypeError(Qp);return function(){var e=arguments;switch(e.length){case 0:return!t.call(this);case 1:return!t.call(this,e[0]);case 2:return!t.call(this,e[0],e[1]);case 3:return!t.call(this,e[0],e[1],e[2])}return!t.apply(this,e)}}function tg(t,e,n,s){if(!ue(t))return t;e=fs(e,t);for(var r=-1,i=e.length,a=i-1,o=t;o!=null&&++r<i;){var c=gn(e[r]),l=n;if(c==="__proto__"||c==="constructor"||c==="prototype")return t;if(r!=a){var d=o[c];l=void 0,l===void 0&&(l=ue(d)?d:os(e[r+1])?[]:{})}cs(o,c,l),o=o[c]}return t}function ng(t,e,n){for(var s=-1,r=e.length,i={};++s<r;){var a=e[s],o=vr(t,a);n(o,a)&&tg(i,fs(a,t),o)}return i}function sg(t,e){if(t==null)return{};var n=is(Ad(t),function(s){return[s]});return e=_e(e),ng(t,n,function(s,r){return e(s,r[0])})}function rg(t,e,n,s,r){return r(t,function(i,a,o){n=s?(s=!1,i):e(n,i,a,o)}),n}function ne(t,e,n){var s=v(t)?rd:rg,r=arguments.length<3;return s(t,_e(e),n,r,Et)}function gs(t,e){var n=v(t)?kr:Eo;return n(t,eg(_e(e)))}function ig(t,e){var n;return Et(t,function(s,r,i){return n=e(s,r,i),!n}),!!n}function ag(t,e,n){var s=v(t)?uo:ig;return s(t,_e(e))}var og=1/0,cg=It&&1/Mr(new It([,-0]))[1]==og?function(t){return new It(t)}:W,lg=200;function hg(t,e,n){var s=-1,r=Ya,i=t.length,a=!0,o=[],c=o;if(i>=lg){var l=cg(t);if(l)return Mr(l);a=!1,r=xr,c=new xt}else c=o;e:for(;++s<i;){var d=t[s],h=d;if(d=d!==0?d:0,a&&h===h){for(var f=c.length;f--;)if(c[f]===h)continue e;o.push(d)}else r(c,h,n)||(c!==o&&c.push(h),o.push(d))}return o}function Ur(t){return t&&t.length?hg(t):[]}function er(t){console&&console.error&&console.error(`Error: ${t}`)}function yo(t){console&&console.warn&&console.warn(`Warning: ${t}`)}function Ao(t){const e=new Date().getTime(),n=t();return{time:new Date().getTime()-e,value:n}}function So(t){function e(){}e.prototype=t;const n=new e;function s(){return typeof n.bar}return s(),s(),t}var Oo=typeof global=="object"&&global&&global.Object===Object&&global,ug=typeof self=="object"&&self&&self.Object===Object&&self,He=Oo||ug||Function("return this")(),tt=He.Symbol,Ro=Object.prototype,dg=Ro.hasOwnProperty,fg=Ro.toString,jt=tt?tt.toStringTag:void 0;function pg(t){var e=dg.call(t,jt),n=t[jt];try{t[jt]=void 0;var s=!0}catch{}var r=fg.call(t);return s&&(e?t[jt]=n:delete t[jt]),r}var gg=Object.prototype,mg=gg.toString;function Tg(t){return mg.call(t)}var Eg="[object Null]",yg="[object Undefined]",Fi=tt?tt.toStringTag:void 0;function it(t){return t==null?t===void 0?yg:Eg:Fi&&Fi in Object(t)?pg(t):Tg(t)}function nt(t){return t!=null&&typeof t=="object"}var Ag="[object Symbol]";function ms(t){return typeof t=="symbol"||nt(t)&&it(t)==Ag}function Ts(t,e){for(var n=-1,s=t==null?0:t.length,r=Array(s);++n<s;)r[n]=e(t[n],n,t);return r}var Q=Array.isArray,Bi=tt?tt.prototype:void 0,Gi=Bi?Bi.toString:void 0;function Lo(t){if(typeof t=="string")return t;if(Q(t))return Ts(t,Lo)+"";if(ms(t))return Gi?Gi.call(t):"";var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}var Sg=/\s/;function Og(t){for(var e=t.length;e--&&Sg.test(t.charAt(e)););return e}var Rg=/^\s+/;function Lg(t){return t&&t.slice(0,Og(t)+1).replace(Rg,"")}function Be(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}var Wi=NaN,Ig=/^[-+]0x[0-9a-f]+$/i,Ng=/^0b[01]+$/i,bg=/^0o[0-7]+$/i,vg=parseInt;function _g(t){if(typeof t=="number")return t;if(ms(t))return Wi;if(Be(t)){var e=typeof t.valueOf=="function"?t.valueOf():t;t=Be(e)?e+"":e}if(typeof t!="string")return t===0?t:+t;t=Lg(t);var n=Ng.test(t);return n||bg.test(t)?vg(t.slice(2),n?2:8):Ig.test(t)?Wi:+t}var ji=1/0,Cg=17976931348623157e292;function kg(t){if(!t)return t===0?t:0;if(t=_g(t),t===ji||t===-ji){var e=t<0?-1:1;return e*Cg}return t===t?t:0}function wg(t){var e=kg(t),n=e%1;return e===e?n?e-n:e:0}function Es(t){return t}var xg="[object AsyncFunction]",Mg="[object Function]",$g="[object GeneratorFunction]",Pg="[object Proxy]";function Io(t){if(!Be(t))return!1;var e=it(t);return e==Mg||e==$g||e==xg||e==Pg}var Ds=He["__core-js_shared__"],Ki=(function(){var t=/[^.]+$/.exec(Ds&&Ds.keys&&Ds.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""})();function Ug(t){return!!Ki&&Ki in t}var Dg=Function.prototype,Fg=Dg.toString;function yt(t){if(t!=null){try{return Fg.call(t)}catch{}try{return t+""}catch{}}return""}var Bg=/[\\^$.*+?()[\]{}|]/g,Gg=/^\[object .+?Constructor\]$/,Wg=Function.prototype,jg=Object.prototype,Kg=Wg.toString,zg=jg.hasOwnProperty,Hg=RegExp("^"+Kg.call(zg).replace(Bg,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Vg(t){if(!Be(t)||Ug(t))return!1;var e=Io(t)?Hg:Gg;return e.test(yt(t))}function Yg(t,e){return t==null?void 0:t[e]}function At(t,e){var n=Yg(t,e);return Vg(n)?n:void 0}var tr=At(He,"WeakMap");function Xg(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)}var qg=800,Jg=16,Zg=Date.now;function Qg(t){var e=0,n=0;return function(){var s=Zg(),r=Jg-(s-n);if(n=s,r>0){if(++e>=qg)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}function em(t){return function(){return t}}var Kn=(function(){try{var t=At(Object,"defineProperty");return t({},"",{}),t}catch{}})(),tm=Kn?function(t,e){return Kn(t,"toString",{configurable:!0,enumerable:!1,value:em(e),writable:!0})}:Es,nm=Qg(tm);function sm(t,e){for(var n=-1,s=t==null?0:t.length;++n<s&&e(t[n],n,t)!==!1;);return t}function rm(t,e,n,s){for(var r=t.length,i=n+-1;++i<r;)if(e(t[i],i,t))return i;return-1}function im(t){return t!==t}function am(t,e,n){for(var s=n-1,r=t.length;++s<r;)if(t[s]===e)return s;return-1}function om(t,e,n){return e===e?am(t,e,n):rm(t,im,n)}var cm=9007199254740991,lm=/^(?:0|[1-9]\d*)$/;function ys(t,e){var n=typeof t;return e=e??cm,!!e&&(n=="number"||n!="symbol"&&lm.test(t))&&t>-1&&t%1==0&&t<e}function No(t,e,n){e=="__proto__"&&Kn?Kn(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}function As(t,e){return t===e||t!==t&&e!==e}var hm=Object.prototype,um=hm.hasOwnProperty;function Dr(t,e,n){var s=t[e];(!(um.call(t,e)&&As(s,n))||n===void 0&&!(e in t))&&No(t,e,n)}function dm(t,e,n,s){var r=!n;n||(n={});for(var i=-1,a=e.length;++i<a;){var o=e[i],c=void 0;c===void 0&&(c=t[o]),r?No(n,o,c):Dr(n,o,c)}return n}var zi=Math.max;function fm(t,e,n){return e=zi(e===void 0?t.length-1:e,0),function(){for(var s=arguments,r=-1,i=zi(s.length-e,0),a=Array(i);++r<i;)a[r]=s[e+r];r=-1;for(var o=Array(e+1);++r<e;)o[r]=s[r];return o[e]=n(a),Xg(t,this,o)}}function pm(t,e){return nm(fm(t,e,Es),t+"")}var gm=9007199254740991;function Fr(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=gm}function St(t){return t!=null&&Fr(t.length)&&!Io(t)}function mm(t,e,n){if(!Be(n))return!1;var s=typeof e;return(s=="number"?St(n)&&ys(e,n.length):s=="string"&&e in n)?As(n[e],t):!1}function Tm(t){return pm(function(e,n){var s=-1,r=n.length,i=r>1?n[r-1]:void 0,a=r>2?n[2]:void 0;for(i=t.length>3&&typeof i=="function"?(r--,i):void 0,a&&mm(n[0],n[1],a)&&(i=r<3?void 0:i,r=1),e=Object(e);++s<r;){var o=n[s];o&&t(e,o,s,i)}return e})}var Em=Object.prototype;function Br(t){var e=t&&t.constructor,n=typeof e=="function"&&e.prototype||Em;return t===n}function ym(t,e){for(var n=-1,s=Array(t);++n<t;)s[n]=e(n);return s}var Am="[object Arguments]";function Hi(t){return nt(t)&&it(t)==Am}var bo=Object.prototype,Sm=bo.hasOwnProperty,Om=bo.propertyIsEnumerable,vo=Hi((function(){return arguments})())?Hi:function(t){return nt(t)&&Sm.call(t,"callee")&&!Om.call(t,"callee")};function Rm(){return!1}var _o=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Vi=_o&&typeof module=="object"&&module&&!module.nodeType&&module,Lm=Vi&&Vi.exports===_o,Yi=Lm?He.Buffer:void 0,Im=Yi?Yi.isBuffer:void 0,nr=Im||Rm,Nm="[object Arguments]",bm="[object Array]",vm="[object Boolean]",_m="[object Date]",Cm="[object Error]",km="[object Function]",wm="[object Map]",xm="[object Number]",Mm="[object Object]",$m="[object RegExp]",Pm="[object Set]",Um="[object String]",Dm="[object WeakMap]",Fm="[object ArrayBuffer]",Bm="[object DataView]",Gm="[object Float32Array]",Wm="[object Float64Array]",jm="[object Int8Array]",Km="[object Int16Array]",zm="[object Int32Array]",Hm="[object Uint8Array]",Vm="[object Uint8ClampedArray]",Ym="[object Uint16Array]",Xm="[object Uint32Array]",x={};x[Gm]=x[Wm]=x[jm]=x[Km]=x[zm]=x[Hm]=x[Vm]=x[Ym]=x[Xm]=!0;x[Nm]=x[bm]=x[Fm]=x[vm]=x[Bm]=x[_m]=x[Cm]=x[km]=x[wm]=x[xm]=x[Mm]=x[$m]=x[Pm]=x[Um]=x[Dm]=!1;function qm(t){return nt(t)&&Fr(t.length)&&!!x[it(t)]}function Co(t){return function(e){return t(e)}}var ko=typeof exports=="object"&&exports&&!exports.nodeType&&exports,nn=ko&&typeof module=="object"&&module&&!module.nodeType&&module,Jm=nn&&nn.exports===ko,Fs=Jm&&Oo.process,zn=(function(){try{var t=nn&&nn.require&&nn.require("util").types;return t||Fs&&Fs.binding&&Fs.binding("util")}catch{}})(),Xi=zn&&zn.isTypedArray,wo=Xi?Co(Xi):qm,Zm=Object.prototype,Qm=Zm.hasOwnProperty;function xo(t,e){var n=Q(t),s=!n&&vo(t),r=!n&&!s&&nr(t),i=!n&&!s&&!r&&wo(t),a=n||s||r||i,o=a?ym(t.length,String):[],c=o.length;for(var l in t)(e||Qm.call(t,l))&&!(a&&(l=="length"||r&&(l=="offset"||l=="parent")||i&&(l=="buffer"||l=="byteLength"||l=="byteOffset")||ys(l,c)))&&o.push(l);return o}function Mo(t,e){return function(n){return t(e(n))}}var eT=Mo(Object.keys,Object),tT=Object.prototype,nT=tT.hasOwnProperty;function sT(t){if(!Br(t))return eT(t);var e=[];for(var n in Object(t))nT.call(t,n)&&n!="constructor"&&e.push(n);return e}function Tn(t){return St(t)?xo(t):sT(t)}var rT=Object.prototype,iT=rT.hasOwnProperty,Ce=Tm(function(t,e){if(Br(e)||St(e)){dm(e,Tn(e),t);return}for(var n in e)iT.call(e,n)&&Dr(t,n,e[n])});function aT(t){var e=[];if(t!=null)for(var n in Object(t))e.push(n);return e}var oT=Object.prototype,cT=oT.hasOwnProperty;function lT(t){if(!Be(t))return aT(t);var e=Br(t),n=[];for(var s in t)s=="constructor"&&(e||!cT.call(t,s))||n.push(s);return n}function hT(t){return St(t)?xo(t,!0):lT(t)}var uT=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,dT=/^\w*$/;function Gr(t,e){if(Q(t))return!1;var n=typeof t;return n=="number"||n=="symbol"||n=="boolean"||t==null||ms(t)?!0:dT.test(t)||!uT.test(t)||e!=null&&t in Object(e)}var ln=At(Object,"create");function fT(){this.__data__=ln?ln(null):{},this.size=0}function pT(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}var gT="__lodash_hash_undefined__",mT=Object.prototype,TT=mT.hasOwnProperty;function ET(t){var e=this.__data__;if(ln){var n=e[t];return n===gT?void 0:n}return TT.call(e,t)?e[t]:void 0}var yT=Object.prototype,AT=yT.hasOwnProperty;function ST(t){var e=this.__data__;return ln?e[t]!==void 0:AT.call(e,t)}var OT="__lodash_hash_undefined__";function RT(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=ln&&e===void 0?OT:e,this}function pt(t){var e=-1,n=t==null?0:t.length;for(this.clear();++e<n;){var s=t[e];this.set(s[0],s[1])}}pt.prototype.clear=fT;pt.prototype.delete=pT;pt.prototype.get=ET;pt.prototype.has=ST;pt.prototype.set=RT;function LT(){this.__data__=[],this.size=0}function Ss(t,e){for(var n=t.length;n--;)if(As(t[n][0],e))return n;return-1}var IT=Array.prototype,NT=IT.splice;function bT(t){var e=this.__data__,n=Ss(e,t);if(n<0)return!1;var s=e.length-1;return n==s?e.pop():NT.call(e,n,1),--this.size,!0}function vT(t){var e=this.__data__,n=Ss(e,t);return n<0?void 0:e[n][1]}function _T(t){return Ss(this.__data__,t)>-1}function CT(t,e){var n=this.__data__,s=Ss(n,t);return s<0?(++this.size,n.push([t,e])):n[s][1]=e,this}function Ve(t){var e=-1,n=t==null?0:t.length;for(this.clear();++e<n;){var s=t[e];this.set(s[0],s[1])}}Ve.prototype.clear=LT;Ve.prototype.delete=bT;Ve.prototype.get=vT;Ve.prototype.has=_T;Ve.prototype.set=CT;var hn=At(He,"Map");function kT(){this.size=0,this.__data__={hash:new pt,map:new(hn||Ve),string:new pt}}function wT(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}function Os(t,e){var n=t.__data__;return wT(e)?n[typeof e=="string"?"string":"hash"]:n.map}function xT(t){var e=Os(this,t).delete(t);return this.size-=e?1:0,e}function MT(t){return Os(this,t).get(t)}function $T(t){return Os(this,t).has(t)}function PT(t,e){var n=Os(this,t),s=n.size;return n.set(t,e),this.size+=n.size==s?0:1,this}function Ye(t){var e=-1,n=t==null?0:t.length;for(this.clear();++e<n;){var s=t[e];this.set(s[0],s[1])}}Ye.prototype.clear=kT;Ye.prototype.delete=xT;Ye.prototype.get=MT;Ye.prototype.has=$T;Ye.prototype.set=PT;var UT="Expected a function";function Wr(t,e){if(typeof t!="function"||e!=null&&typeof e!="function")throw new TypeError(UT);var n=function(){var s=arguments,r=e?e.apply(this,s):s[0],i=n.cache;if(i.has(r))return i.get(r);var a=t.apply(this,s);return n.cache=i.set(r,a)||i,a};return n.cache=new(Wr.Cache||Ye),n}Wr.Cache=Ye;var DT=500;function FT(t){var e=Wr(t,function(s){return n.size===DT&&n.clear(),s}),n=e.cache;return e}var BT=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,GT=/\\(\\)?/g,WT=FT(function(t){var e=[];return t.charCodeAt(0)===46&&e.push(""),t.replace(BT,function(n,s,r,i){e.push(r?i.replace(GT,"$1"):s||n)}),e});function jT(t){return t==null?"":Lo(t)}function Rs(t,e){return Q(t)?t:Gr(t,e)?[t]:WT(jT(t))}function En(t){if(typeof t=="string"||ms(t))return t;var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}function jr(t,e){e=Rs(e,t);for(var n=0,s=e.length;t!=null&&n<s;)t=t[En(e[n++])];return n&&n==s?t:void 0}function KT(t,e,n){var s=t==null?void 0:jr(t,e);return s===void 0?n:s}function $o(t,e){for(var n=-1,s=e.length,r=t.length;++n<s;)t[r+n]=e[n];return t}var zT=Mo(Object.getPrototypeOf,Object);function HT(){this.__data__=new Ve,this.size=0}function VT(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n}function YT(t){return this.__data__.get(t)}function XT(t){return this.__data__.has(t)}var qT=200;function JT(t,e){var n=this.__data__;if(n instanceof Ve){var s=n.__data__;if(!hn||s.length<qT-1)return s.push([t,e]),this.size=++n.size,this;n=this.__data__=new Ye(s)}return n.set(t,e),this.size=n.size,this}function De(t){var e=this.__data__=new Ve(t);this.size=e.size}De.prototype.clear=HT;De.prototype.delete=VT;De.prototype.get=YT;De.prototype.has=XT;De.prototype.set=JT;function ZT(t,e){for(var n=-1,s=t==null?0:t.length,r=0,i=[];++n<s;){var a=t[n];e(a,n,t)&&(i[r++]=a)}return i}function Po(){return[]}var QT=Object.prototype,eE=QT.propertyIsEnumerable,qi=Object.getOwnPropertySymbols,Uo=qi?function(t){return t==null?[]:(t=Object(t),ZT(qi(t),function(e){return eE.call(t,e)}))}:Po,tE=Object.getOwnPropertySymbols,nE=tE?function(t){for(var e=[];t;)$o(e,Uo(t)),t=zT(t);return e}:Po;function Do(t,e,n){var s=e(t);return Q(t)?s:$o(s,n(t))}function Ji(t){return Do(t,Tn,Uo)}function sE(t){return Do(t,hT,nE)}var sr=At(He,"DataView"),rr=At(He,"Promise"),ir=At(He,"Set"),Zi="[object Map]",rE="[object Object]",Qi="[object Promise]",ea="[object Set]",ta="[object WeakMap]",na="[object DataView]",iE=yt(sr),aE=yt(hn),oE=yt(rr),cE=yt(ir),lE=yt(tr),Ze=it;(sr&&Ze(new sr(new ArrayBuffer(1)))!=na||hn&&Ze(new hn)!=Zi||rr&&Ze(rr.resolve())!=Qi||ir&&Ze(new ir)!=ea||tr&&Ze(new tr)!=ta)&&(Ze=function(t){var e=it(t),n=e==rE?t.constructor:void 0,s=n?yt(n):"";if(s)switch(s){case iE:return na;case aE:return Zi;case oE:return Qi;case cE:return ea;case lE:return ta}return e});var sa=He.Uint8Array,hE="__lodash_hash_undefined__";function uE(t){return this.__data__.set(t,hE),this}function dE(t){return this.__data__.has(t)}function Hn(t){var e=-1,n=t==null?0:t.length;for(this.__data__=new Ye;++e<n;)this.add(t[e])}Hn.prototype.add=Hn.prototype.push=uE;Hn.prototype.has=dE;function Fo(t,e){for(var n=-1,s=t==null?0:t.length;++n<s;)if(e(t[n],n,t))return!0;return!1}function fE(t,e){return t.has(e)}var pE=1,gE=2;function Bo(t,e,n,s,r,i){var a=n&pE,o=t.length,c=e.length;if(o!=c&&!(a&&c>o))return!1;var l=i.get(t),d=i.get(e);if(l&&d)return l==e&&d==t;var h=-1,f=!0,p=n&gE?new Hn:void 0;for(i.set(t,e),i.set(e,t);++h<o;){var g=t[h],T=e[h];if(s)var L=a?s(T,g,h,e,t,i):s(g,T,h,t,e,i);if(L!==void 0){if(L)continue;f=!1;break}if(p){if(!Fo(e,function(y,E){if(!fE(p,E)&&(g===y||r(g,y,n,s,i)))return p.push(E)})){f=!1;break}}else if(!(g===T||r(g,T,n,s,i))){f=!1;break}}return i.delete(t),i.delete(e),f}function mE(t){var e=-1,n=Array(t.size);return t.forEach(function(s,r){n[++e]=[r,s]}),n}function TE(t){var e=-1,n=Array(t.size);return t.forEach(function(s){n[++e]=s}),n}var EE=1,yE=2,AE="[object Boolean]",SE="[object Date]",OE="[object Error]",RE="[object Map]",LE="[object Number]",IE="[object RegExp]",NE="[object Set]",bE="[object String]",vE="[object Symbol]",_E="[object ArrayBuffer]",CE="[object DataView]",ra=tt?tt.prototype:void 0,Bs=ra?ra.valueOf:void 0;function kE(t,e,n,s,r,i,a){switch(n){case CE:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case _E:return!(t.byteLength!=e.byteLength||!i(new sa(t),new sa(e)));case AE:case SE:case LE:return As(+t,+e);case OE:return t.name==e.name&&t.message==e.message;case IE:case bE:return t==e+"";case RE:var o=mE;case NE:var c=s&EE;if(o||(o=TE),t.size!=e.size&&!c)return!1;var l=a.get(t);if(l)return l==e;s|=yE,a.set(t,e);var d=Bo(o(t),o(e),s,r,i,a);return a.delete(t),d;case vE:if(Bs)return Bs.call(t)==Bs.call(e)}return!1}var wE=1,xE=Object.prototype,ME=xE.hasOwnProperty;function $E(t,e,n,s,r,i){var a=n&wE,o=Ji(t),c=o.length,l=Ji(e),d=l.length;if(c!=d&&!a)return!1;for(var h=c;h--;){var f=o[h];if(!(a?f in e:ME.call(e,f)))return!1}var p=i.get(t),g=i.get(e);if(p&&g)return p==e&&g==t;var T=!0;i.set(t,e),i.set(e,t);for(var L=a;++h<c;){f=o[h];var y=t[f],E=e[f];if(s)var m=a?s(E,y,f,e,t,i):s(y,E,f,t,e,i);if(!(m===void 0?y===E||r(y,E,n,s,i):m)){T=!1;break}L||(L=f=="constructor")}if(T&&!L){var A=t.constructor,_=e.constructor;A!=_&&"constructor"in t&&"constructor"in e&&!(typeof A=="function"&&A instanceof A&&typeof _=="function"&&_ instanceof _)&&(T=!1)}return i.delete(t),i.delete(e),T}var PE=1,ia="[object Arguments]",aa="[object Array]",In="[object Object]",UE=Object.prototype,oa=UE.hasOwnProperty;function DE(t,e,n,s,r,i){var a=Q(t),o=Q(e),c=a?aa:Ze(t),l=o?aa:Ze(e);c=c==ia?In:c,l=l==ia?In:l;var d=c==In,h=l==In,f=c==l;if(f&&nr(t)){if(!nr(e))return!1;a=!0,d=!1}if(f&&!d)return i||(i=new De),a||wo(t)?Bo(t,e,n,s,r,i):kE(t,e,c,n,s,r,i);if(!(n&PE)){var p=d&&oa.call(t,"__wrapped__"),g=h&&oa.call(e,"__wrapped__");if(p||g){var T=p?t.value():t,L=g?e.value():e;return i||(i=new De),r(T,L,n,s,i)}}return f?(i||(i=new De),$E(t,e,n,s,r,i)):!1}function Kr(t,e,n,s,r){return t===e?!0:t==null||e==null||!nt(t)&&!nt(e)?t!==t&&e!==e:DE(t,e,n,s,Kr,r)}var FE=1,BE=2;function GE(t,e,n,s){var r=n.length,i=r;if(t==null)return!i;for(t=Object(t);r--;){var a=n[r];if(a[2]?a[1]!==t[a[0]]:!(a[0]in t))return!1}for(;++r<i;){a=n[r];var o=a[0],c=t[o],l=a[1];if(a[2]){if(c===void 0&&!(o in t))return!1}else{var d=new De,h;if(!(h===void 0?Kr(l,c,FE|BE,s,d):h))return!1}}return!0}function Go(t){return t===t&&!Be(t)}function WE(t){for(var e=Tn(t),n=e.length;n--;){var s=e[n],r=t[s];e[n]=[s,r,Go(r)]}return e}function Wo(t,e){return function(n){return n==null?!1:n[t]===e&&(e!==void 0||t in Object(n))}}function jE(t){var e=WE(t);return e.length==1&&e[0][2]?Wo(e[0][0],e[0][1]):function(n){return n===t||GE(n,t,e)}}function KE(t,e){return t!=null&&e in Object(t)}function zE(t,e,n){e=Rs(e,t);for(var s=-1,r=e.length,i=!1;++s<r;){var a=En(e[s]);if(!(i=t!=null&&n(t,a)))break;t=t[a]}return i||++s!=r?i:(r=t==null?0:t.length,!!r&&Fr(r)&&ys(a,r)&&(Q(t)||vo(t)))}function HE(t,e){return t!=null&&zE(t,e,KE)}var VE=1,YE=2;function XE(t,e){return Gr(t)&&Go(e)?Wo(En(t),e):function(n){var s=KT(n,t);return s===void 0&&s===e?HE(n,t):Kr(e,s,VE|YE)}}function qE(t){return function(e){return e==null?void 0:e[t]}}function JE(t){return function(e){return jr(e,t)}}function ZE(t){return Gr(t)?qE(En(t)):JE(t)}function Ls(t){return typeof t=="function"?t:t==null?Es:typeof t=="object"?Q(t)?XE(t[0],t[1]):jE(t):ZE(t)}function QE(t){return function(e,n,s){for(var r=-1,i=Object(e),a=s(e),o=a.length;o--;){var c=a[++r];if(n(i[c],c,i)===!1)break}return e}}var ey=QE();function ty(t,e){return t&&ey(t,e,Tn)}function ny(t,e){return function(n,s){if(n==null)return n;if(!St(n))return t(n,s);for(var r=n.length,i=-1,a=Object(n);++i<r&&s(a[i],i,a)!==!1;);return n}}var Is=ny(ty);function sy(t){return typeof t=="function"?t:Es}function ry(t,e){var n=Q(t)?sm:Is;return n(t,sy(e))}function iy(t,e){for(var n=-1,s=t==null?0:t.length;++n<s;)if(!e(t[n],n,t))return!1;return!0}function ay(t,e){var n=!0;return Is(t,function(s,r,i){return n=!!e(s,r,i),n}),n}function oy(t,e,n){var s=Q(t)?iy:ay;return s(t,Ls(e))}function cy(t,e){var n=-1,s=St(t)?Array(t.length):[];return Is(t,function(r,i,a){s[++n]=e(r,i,a)}),s}function jo(t,e){var n=Q(t)?Ts:cy;return n(t,Ls(e))}var ly="[object String]";function Vn(t){return typeof t=="string"||!Q(t)&&nt(t)&&it(t)==ly}function hy(t,e){return Ts(e,function(n){return t[n]})}function uy(t){return t==null?[]:hy(t,Tn(t))}var dy=Math.max;function fy(t,e,n,s){t=St(t)?t:uy(t),n=n?wg(n):0;var r=t.length;return n<0&&(n=dy(r+n,0)),Vn(t)?n<=r&&t.indexOf(e,n)>-1:!!r&&om(t,e,n)>-1}var py="[object RegExp]";function gy(t){return nt(t)&&it(t)==py}var ca=zn&&zn.isRegExp,my=ca?Co(ca):gy;function Ty(t,e,n,s){if(!Be(t))return t;e=Rs(e,t);for(var r=-1,i=e.length,a=i-1,o=t;o!=null&&++r<i;){var c=En(e[r]),l=n;if(c==="__proto__"||c==="constructor"||c==="prototype")return t;if(r!=a){var d=o[c];l=void 0,l===void 0&&(l=Be(d)?d:ys(e[r+1])?[]:{})}Dr(o,c,l),o=o[c]}return t}function Ey(t,e,n){for(var s=-1,r=e.length,i={};++s<r;){var a=e[s],o=jr(t,a);n(o,a)&&Ty(i,Rs(a,t),o)}return i}function ke(t,e){if(t==null)return{};var n=Ts(sE(t),function(s){return[s]});return e=Ls(e),Ey(t,n,function(s,r){return e(s,r[0])})}function yy(t,e){var n;return Is(t,function(s,r,i){return n=e(s,r,i),!n}),!!n}function Ay(t,e,n){var s=Q(t)?Fo:yy;return s(t,Ls(e))}function Sy(t){return Oy(t)?t.LABEL:t.name}function Oy(t){return Vn(t.LABEL)&&t.LABEL!==""}class we{get definition(){return this._definition}set definition(e){this._definition=e}constructor(e){this._definition=e}accept(e){e.visit(this),ry(this.definition,n=>{n.accept(e)})}}class se extends we{constructor(e){super([]),this.idx=1,Ce(this,ke(e,n=>n!==void 0))}set definition(e){}get definition(){return this.referencedRule!==void 0?this.referencedRule.definition:[]}accept(e){e.visit(this)}}class $t extends we{constructor(e){super(e.definition),this.orgText="",Ce(this,ke(e,n=>n!==void 0))}}class ee extends we{constructor(e){super(e.definition),this.ignoreAmbiguities=!1,Ce(this,ke(e,n=>n!==void 0))}}class Z extends we{constructor(e){super(e.definition),this.idx=1,Ce(this,ke(e,n=>n!==void 0))}}class xe extends we{constructor(e){super(e.definition),this.idx=1,Ce(this,ke(e,n=>n!==void 0))}}class Me extends we{constructor(e){super(e.definition),this.idx=1,Ce(this,ke(e,n=>n!==void 0))}}class G extends we{constructor(e){super(e.definition),this.idx=1,Ce(this,ke(e,n=>n!==void 0))}}class Se extends we{constructor(e){super(e.definition),this.idx=1,Ce(this,ke(e,n=>n!==void 0))}}class Oe extends we{get definition(){return this._definition}set definition(e){this._definition=e}constructor(e){super(e.definition),this.idx=1,this.ignoreAmbiguities=!1,this.hasPredicates=!1,Ce(this,ke(e,n=>n!==void 0))}}class ${constructor(e){this.idx=1,Ce(this,ke(e,n=>n!==void 0))}accept(e){e.visit(this)}}function Ry(t){return jo(t,kn)}function kn(t){function e(n){return jo(n,kn)}if(t instanceof se){const n={type:"NonTerminal",name:t.nonTerminalName,idx:t.idx};return Vn(t.label)&&(n.label=t.label),n}else{if(t instanceof ee)return{type:"Alternative",definition:e(t.definition)};if(t instanceof Z)return{type:"Option",idx:t.idx,definition:e(t.definition)};if(t instanceof xe)return{type:"RepetitionMandatory",idx:t.idx,definition:e(t.definition)};if(t instanceof Me)return{type:"RepetitionMandatoryWithSeparator",idx:t.idx,separator:kn(new $({terminalType:t.separator})),definition:e(t.definition)};if(t instanceof Se)return{type:"RepetitionWithSeparator",idx:t.idx,separator:kn(new $({terminalType:t.separator})),definition:e(t.definition)};if(t instanceof G)return{type:"Repetition",idx:t.idx,definition:e(t.definition)};if(t instanceof Oe)return{type:"Alternation",idx:t.idx,definition:e(t.definition)};if(t instanceof $){const n={type:"Terminal",name:t.terminalType.name,label:Sy(t.terminalType),idx:t.idx};Vn(t.label)&&(n.terminalLabel=t.label);const s=t.terminalType.PATTERN;return t.terminalType.PATTERN&&(n.pattern=my(s)?s.source:s),n}else{if(t instanceof $t)return{type:"Rule",name:t.name,orgText:t.orgText,definition:e(t.definition)};throw Error("non exhaustive match")}}}class Pt{visit(e){const n=e;switch(n.constructor){case se:return this.visitNonTerminal(n);case ee:return this.visitAlternative(n);case Z:return this.visitOption(n);case xe:return this.visitRepetitionMandatory(n);case Me:return this.visitRepetitionMandatoryWithSeparator(n);case Se:return this.visitRepetitionWithSeparator(n);case G:return this.visitRepetition(n);case Oe:return this.visitAlternation(n);case $:return this.visitTerminal(n);case $t:return this.visitRule(n);default:throw Error("non exhaustive match")}}visitNonTerminal(e){}visitAlternative(e){}visitOption(e){}visitRepetition(e){}visitRepetitionMandatory(e){}visitRepetitionMandatoryWithSeparator(e){}visitRepetitionWithSeparator(e){}visitAlternation(e){}visitTerminal(e){}visitRule(e){}}function Ly(t){return t instanceof ee||t instanceof Z||t instanceof G||t instanceof xe||t instanceof Me||t instanceof Se||t instanceof $||t instanceof $t}function Yn(t,e=[]){return t instanceof Z||t instanceof G||t instanceof Se?!0:t instanceof Oe?Ay(t.definition,s=>Yn(s,e)):t instanceof se&&fy(e,t)?!1:t instanceof we?(t instanceof se&&e.push(t),oy(t.definition,s=>Yn(s,e))):!1}function Iy(t){return t instanceof Oe}function Le(t){if(t instanceof se)return"SUBRULE";if(t instanceof Z)return"OPTION";if(t instanceof Oe)return"OR";if(t instanceof xe)return"AT_LEAST_ONE";if(t instanceof Me)return"AT_LEAST_ONE_SEP";if(t instanceof Se)return"MANY_SEP";if(t instanceof G)return"MANY";if(t instanceof $)return"CONSUME";throw Error("non exhaustive match")}class Ns{walk(e,n=[]){N(e.definition,(s,r)=>{const i=z(e.definition,r+1);if(s instanceof se)this.walkProdRef(s,i,n);else if(s instanceof $)this.walkTerminal(s,i,n);else if(s instanceof ee)this.walkFlat(s,i,n);else if(s instanceof Z)this.walkOption(s,i,n);else if(s instanceof xe)this.walkAtLeastOne(s,i,n);else if(s instanceof Me)this.walkAtLeastOneSep(s,i,n);else if(s instanceof Se)this.walkManySep(s,i,n);else if(s instanceof G)this.walkMany(s,i,n);else if(s instanceof Oe)this.walkOr(s,i,n);else throw Error("non exhaustive match")})}walkTerminal(e,n,s){}walkProdRef(e,n,s){}walkFlat(e,n,s){const r=n.concat(s);this.walk(e,r)}walkOption(e,n,s){const r=n.concat(s);this.walk(e,r)}walkAtLeastOne(e,n,s){const r=[new Z({definition:e.definition})].concat(n,s);this.walk(e,r)}walkAtLeastOneSep(e,n,s){const r=la(e,n,s);this.walk(e,r)}walkMany(e,n,s){const r=[new Z({definition:e.definition})].concat(n,s);this.walk(e,r)}walkManySep(e,n,s){const r=la(e,n,s);this.walk(e,r)}walkOr(e,n,s){const r=n.concat(s);N(e.definition,i=>{const a=new ee({definition:[i]});this.walk(a,r)})}}function la(t,e,n){return[new Z({definition:[new $({terminalType:t.separator})].concat(t.definition)})].concat(e,n)}function yn(t){if(t instanceof se)return yn(t.referencedRule);if(t instanceof $)return vy(t);if(Ly(t))return Ny(t);if(Iy(t))return by(t);throw Error("non exhaustive match")}function Ny(t){let e=[];const n=t.definition;let s=0,r=n.length>s,i,a=!0;for(;r&&a;)i=n[s],a=Yn(i),e=e.concat(yn(i)),s=s+1,r=n.length>s;return Ur(e)}function by(t){const e=S(t.definition,n=>yn(n));return Ur(Te(e))}function vy(t){return[t.terminalType]}const Ko="_~IN~_";class _y extends Ns{constructor(e){super(),this.topProd=e,this.follows={}}startWalking(){return this.walk(this.topProd),this.follows}walkTerminal(e,n,s){}walkProdRef(e,n,s){const r=ky(e.referencedRule,e.idx)+this.topProd.name,i=n.concat(s),a=new ee({definition:i}),o=yn(a);this.follows[r]=o}}function Cy(t){const e={};return N(t,n=>{const s=new _y(n).startWalking();qs(e,s)}),e}function ky(t,e){return t.name+e+Ko}function I(t){return t.charCodeAt(0)}function Gs(t,e){Array.isArray(t)?t.forEach(function(n){e.push(n)}):e.push(t)}function Kt(t,e){if(t[e]===!0)throw"duplicate flag "+e;t[e],t[e]=!0}function Rt(t){if(t===void 0)throw Error("Internal Error - Should never get here!");return!0}function wy(){throw Error("Internal Error - Should never get here!")}function ha(t){return t.type==="Character"}const Xn=[];for(let t=I("0");t<=I("9");t++)Xn.push(t);const qn=[I("_")].concat(Xn);for(let t=I("a");t<=I("z");t++)qn.push(t);for(let t=I("A");t<=I("Z");t++)qn.push(t);const ua=[I(" "),I("\f"),I(`
1
+ import{g as fl}from"./chunk-XXDRQBXY-CEszpmv-.js";import{s as pl}from"./chunk-WEXAMYUT-DJ5sW_Wu.js";import{g as Ba,s as Vs,a as Ga,b as Ys,t as gl,q as ml,_ as u,D as Vt,l as Tl,c as Wa,p as El,r as yl,u as Al,j as Sl,A as Ol,O as Rl,C as Ll,L as Il,E as Nl,I as bl,aI as vl,k as _l}from"./mermaid.core-B1vpXQvD.js";import"./index-Bp8EjOaI.js";var ja=typeof global=="object"&&global&&global.Object===Object&&global,Cl=typeof self=="object"&&self&&self.Object===Object&&self,be=ja||Cl||Function("return this")(),he=be.Symbol,Ka=Object.prototype,kl=Ka.hasOwnProperty,wl=Ka.toString,Wt=he?he.toStringTag:void 0;function xl(t){var e=kl.call(t,Wt),n=t[Wt];try{t[Wt]=void 0;var s=!0}catch{}var r=wl.call(t);return s&&(e?t[Wt]=n:delete t[Wt]),r}var Ml=Object.prototype,$l=Ml.toString;function Pl(t){return $l.call(t)}var Ul="[object Null]",Dl="[object Undefined]",ai=he?he.toStringTag:void 0;function rt(t){return t==null?t===void 0?Dl:Ul:ai&&ai in Object(t)?xl(t):Pl(t)}function Ee(t){return t!=null&&typeof t=="object"}var Fl="[object Symbol]";function rs(t){return typeof t=="symbol"||Ee(t)&&rt(t)==Fl}function is(t,e){for(var n=-1,s=t==null?0:t.length,r=Array(s);++n<s;)r[n]=e(t[n],n,t);return r}var v=Array.isArray,oi=he?he.prototype:void 0,ci=oi?oi.toString:void 0;function za(t){if(typeof t=="string")return t;if(v(t))return is(t,za)+"";if(rs(t))return ci?ci.call(t):"";var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}var Bl=/\s/;function Gl(t){for(var e=t.length;e--&&Bl.test(t.charAt(e)););return e}var Wl=/^\s+/;function jl(t){return t&&t.slice(0,Gl(t)+1).replace(Wl,"")}function ue(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}var li=NaN,Kl=/^[-+]0x[0-9a-f]+$/i,zl=/^0b[01]+$/i,Hl=/^0o[0-7]+$/i,Vl=parseInt;function Yl(t){if(typeof t=="number")return t;if(rs(t))return li;if(ue(t)){var e=typeof t.valueOf=="function"?t.valueOf():t;t=ue(e)?e+"":e}if(typeof t!="string")return t===0?t:+t;t=jl(t);var n=zl.test(t);return n||Hl.test(t)?Vl(t.slice(2),n?2:8):Kl.test(t)?li:+t}var hi=1/0,Xl=17976931348623157e292;function ql(t){if(!t)return t===0?t:0;if(t=Yl(t),t===hi||t===-hi){var e=t<0?-1:1;return e*Xl}return t===t?t:0}function as(t){var e=ql(t),n=e%1;return e===e?n?e-n:e:0}function un(t){return t}var Jl="[object AsyncFunction]",Zl="[object Function]",Ql="[object GeneratorFunction]",eh="[object Proxy]";function je(t){if(!ue(t))return!1;var e=rt(t);return e==Zl||e==Ql||e==Jl||e==eh}var $s=be["__core-js_shared__"],ui=(function(){var t=/[^.]+$/.exec($s&&$s.keys&&$s.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""})();function th(t){return!!ui&&ui in t}var nh=Function.prototype,sh=nh.toString;function mt(t){if(t!=null){try{return sh.call(t)}catch{}try{return t+""}catch{}}return""}var rh=/[\\^$.*+?()[\]{}|]/g,ih=/^\[object .+?Constructor\]$/,ah=Function.prototype,oh=Object.prototype,ch=ah.toString,lh=oh.hasOwnProperty,hh=RegExp("^"+ch.call(lh).replace(rh,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function uh(t){if(!ue(t)||th(t))return!1;var e=je(t)?hh:ih;return e.test(mt(t))}function dh(t,e){return t==null?void 0:t[e]}function Tt(t,e){var n=dh(t,e);return uh(n)?n:void 0}var Xs=Tt(be,"WeakMap"),di=Object.create,fh=(function(){function t(){}return function(e){if(!ue(e))return{};if(di)return di(e);t.prototype=e;var n=new t;return t.prototype=void 0,n}})();function ph(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)}function W(){}function gh(t,e){var n=-1,s=t.length;for(e||(e=Array(s));++n<s;)e[n]=t[n];return e}var mh=800,Th=16,Eh=Date.now;function yh(t){var e=0,n=0;return function(){var s=Eh(),r=Th-(s-n);if(n=s,r>0){if(++e>=mh)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}function Ah(t){return function(){return t}}var Wn=(function(){try{var t=Tt(Object,"defineProperty");return t({},"",{}),t}catch{}})(),Sh=Wn?function(t,e){return Wn(t,"toString",{configurable:!0,enumerable:!1,value:Ah(e),writable:!0})}:un,Oh=yh(Sh);function Ha(t,e){for(var n=-1,s=t==null?0:t.length;++n<s&&e(t[n],n,t)!==!1;);return t}function Va(t,e,n,s){for(var r=t.length,i=n+-1;++i<r;)if(e(t[i],i,t))return i;return-1}function Rh(t){return t!==t}function Lh(t,e,n){for(var s=n-1,r=t.length;++s<r;)if(t[s]===e)return s;return-1}function Ar(t,e,n){return e===e?Lh(t,e,n):Va(t,Rh,n)}function Ya(t,e){var n=t==null?0:t.length;return!!n&&Ar(t,e,0)>-1}var Ih=9007199254740991,Nh=/^(?:0|[1-9]\d*)$/;function os(t,e){var n=typeof t;return e=e??Ih,!!e&&(n=="number"||n!="symbol"&&Nh.test(t))&&t>-1&&t%1==0&&t<e}function Sr(t,e,n){e=="__proto__"&&Wn?Wn(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}function dn(t,e){return t===e||t!==t&&e!==e}var bh=Object.prototype,vh=bh.hasOwnProperty;function cs(t,e,n){var s=t[e];(!(vh.call(t,e)&&dn(s,n))||n===void 0&&!(e in t))&&Sr(t,e,n)}function fn(t,e,n,s){var r=!n;n||(n={});for(var i=-1,a=e.length;++i<a;){var o=e[i],c=void 0;c===void 0&&(c=t[o]),r?Sr(n,o,c):cs(n,o,c)}return n}var fi=Math.max;function _h(t,e,n){return e=fi(e===void 0?t.length-1:e,0),function(){for(var s=arguments,r=-1,i=fi(s.length-e,0),a=Array(i);++r<i;)a[r]=s[e+r];r=-1;for(var o=Array(e+1);++r<e;)o[r]=s[r];return o[e]=n(a),ph(t,this,o)}}function Or(t,e){return Oh(_h(t,e,un),t+"")}var Ch=9007199254740991;function Rr(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=Ch}function ve(t){return t!=null&&Rr(t.length)&&!je(t)}function Xa(t,e,n){if(!ue(n))return!1;var s=typeof e;return(s=="number"?ve(n)&&os(e,n.length):s=="string"&&e in n)?dn(n[e],t):!1}function kh(t){return Or(function(e,n){var s=-1,r=n.length,i=r>1?n[r-1]:void 0,a=r>2?n[2]:void 0;for(i=t.length>3&&typeof i=="function"?(r--,i):void 0,a&&Xa(n[0],n[1],a)&&(i=r<3?void 0:i,r=1),e=Object(e);++s<r;){var o=n[s];o&&t(e,o,s,i)}return e})}var wh=Object.prototype;function pn(t){var e=t&&t.constructor,n=typeof e=="function"&&e.prototype||wh;return t===n}function xh(t,e){for(var n=-1,s=Array(t);++n<t;)s[n]=e(n);return s}var Mh="[object Arguments]";function pi(t){return Ee(t)&&rt(t)==Mh}var qa=Object.prototype,$h=qa.hasOwnProperty,Ph=qa.propertyIsEnumerable,ls=pi((function(){return arguments})())?pi:function(t){return Ee(t)&&$h.call(t,"callee")&&!Ph.call(t,"callee")};function Uh(){return!1}var Ja=typeof exports=="object"&&exports&&!exports.nodeType&&exports,gi=Ja&&typeof module=="object"&&module&&!module.nodeType&&module,Dh=gi&&gi.exports===Ja,mi=Dh?be.Buffer:void 0,Fh=mi?mi.isBuffer:void 0,rn=Fh||Uh,Bh="[object Arguments]",Gh="[object Array]",Wh="[object Boolean]",jh="[object Date]",Kh="[object Error]",zh="[object Function]",Hh="[object Map]",Vh="[object Number]",Yh="[object Object]",Xh="[object RegExp]",qh="[object Set]",Jh="[object String]",Zh="[object WeakMap]",Qh="[object ArrayBuffer]",eu="[object DataView]",tu="[object Float32Array]",nu="[object Float64Array]",su="[object Int8Array]",ru="[object Int16Array]",iu="[object Int32Array]",au="[object Uint8Array]",ou="[object Uint8ClampedArray]",cu="[object Uint16Array]",lu="[object Uint32Array]",w={};w[tu]=w[nu]=w[su]=w[ru]=w[iu]=w[au]=w[ou]=w[cu]=w[lu]=!0;w[Bh]=w[Gh]=w[Qh]=w[Wh]=w[eu]=w[jh]=w[Kh]=w[zh]=w[Hh]=w[Vh]=w[Yh]=w[Xh]=w[qh]=w[Jh]=w[Zh]=!1;function hu(t){return Ee(t)&&Rr(t.length)&&!!w[rt(t)]}function hs(t){return function(e){return t(e)}}var Za=typeof exports=="object"&&exports&&!exports.nodeType&&exports,tn=Za&&typeof module=="object"&&module&&!module.nodeType&&module,uu=tn&&tn.exports===Za,Ps=uu&&ja.process,Qe=(function(){try{var t=tn&&tn.require&&tn.require("util").types;return t||Ps&&Ps.binding&&Ps.binding("util")}catch{}})(),Ti=Qe&&Qe.isTypedArray,Lr=Ti?hs(Ti):hu,du=Object.prototype,fu=du.hasOwnProperty;function Qa(t,e){var n=v(t),s=!n&&ls(t),r=!n&&!s&&rn(t),i=!n&&!s&&!r&&Lr(t),a=n||s||r||i,o=a?xh(t.length,String):[],c=o.length;for(var l in t)(e||fu.call(t,l))&&!(a&&(l=="length"||r&&(l=="offset"||l=="parent")||i&&(l=="buffer"||l=="byteLength"||l=="byteOffset")||os(l,c)))&&o.push(l);return o}function eo(t,e){return function(n){return t(e(n))}}var pu=eo(Object.keys,Object),gu=Object.prototype,mu=gu.hasOwnProperty;function to(t){if(!pn(t))return pu(t);var e=[];for(var n in Object(t))mu.call(t,n)&&n!="constructor"&&e.push(n);return e}function de(t){return ve(t)?Qa(t):to(t)}var Tu=Object.prototype,Eu=Tu.hasOwnProperty,qs=kh(function(t,e){if(pn(e)||ve(e)){fn(e,de(e),t);return}for(var n in e)Eu.call(e,n)&&cs(t,n,e[n])});function yu(t){var e=[];if(t!=null)for(var n in Object(t))e.push(n);return e}var Au=Object.prototype,Su=Au.hasOwnProperty;function Ou(t){if(!ue(t))return yu(t);var e=pn(t),n=[];for(var s in t)s=="constructor"&&(e||!Su.call(t,s))||n.push(s);return n}function Ir(t){return ve(t)?Qa(t,!0):Ou(t)}var Ru=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Lu=/^\w*$/;function Nr(t,e){if(v(t))return!1;var n=typeof t;return n=="number"||n=="symbol"||n=="boolean"||t==null||rs(t)?!0:Lu.test(t)||!Ru.test(t)||e!=null&&t in Object(e)}var an=Tt(Object,"create");function Iu(){this.__data__=an?an(null):{},this.size=0}function Nu(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}var bu="__lodash_hash_undefined__",vu=Object.prototype,_u=vu.hasOwnProperty;function Cu(t){var e=this.__data__;if(an){var n=e[t];return n===bu?void 0:n}return _u.call(e,t)?e[t]:void 0}var ku=Object.prototype,wu=ku.hasOwnProperty;function xu(t){var e=this.__data__;return an?e[t]!==void 0:wu.call(e,t)}var Mu="__lodash_hash_undefined__";function $u(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=an&&e===void 0?Mu:e,this}function dt(t){var e=-1,n=t==null?0:t.length;for(this.clear();++e<n;){var s=t[e];this.set(s[0],s[1])}}dt.prototype.clear=Iu;dt.prototype.delete=Nu;dt.prototype.get=Cu;dt.prototype.has=xu;dt.prototype.set=$u;function Pu(){this.__data__=[],this.size=0}function us(t,e){for(var n=t.length;n--;)if(dn(t[n][0],e))return n;return-1}var Uu=Array.prototype,Du=Uu.splice;function Fu(t){var e=this.__data__,n=us(e,t);if(n<0)return!1;var s=e.length-1;return n==s?e.pop():Du.call(e,n,1),--this.size,!0}function Bu(t){var e=this.__data__,n=us(e,t);return n<0?void 0:e[n][1]}function Gu(t){return us(this.__data__,t)>-1}function Wu(t,e){var n=this.__data__,s=us(n,t);return s<0?(++this.size,n.push([t,e])):n[s][1]=e,this}function Ke(t){var e=-1,n=t==null?0:t.length;for(this.clear();++e<n;){var s=t[e];this.set(s[0],s[1])}}Ke.prototype.clear=Pu;Ke.prototype.delete=Fu;Ke.prototype.get=Bu;Ke.prototype.has=Gu;Ke.prototype.set=Wu;var on=Tt(be,"Map");function ju(){this.size=0,this.__data__={hash:new dt,map:new(on||Ke),string:new dt}}function Ku(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}function ds(t,e){var n=t.__data__;return Ku(e)?n[typeof e=="string"?"string":"hash"]:n.map}function zu(t){var e=ds(this,t).delete(t);return this.size-=e?1:0,e}function Hu(t){return ds(this,t).get(t)}function Vu(t){return ds(this,t).has(t)}function Yu(t,e){var n=ds(this,t),s=n.size;return n.set(t,e),this.size+=n.size==s?0:1,this}function ze(t){var e=-1,n=t==null?0:t.length;for(this.clear();++e<n;){var s=t[e];this.set(s[0],s[1])}}ze.prototype.clear=ju;ze.prototype.delete=zu;ze.prototype.get=Hu;ze.prototype.has=Vu;ze.prototype.set=Yu;var Xu="Expected a function";function br(t,e){if(typeof t!="function"||e!=null&&typeof e!="function")throw new TypeError(Xu);var n=function(){var s=arguments,r=e?e.apply(this,s):s[0],i=n.cache;if(i.has(r))return i.get(r);var a=t.apply(this,s);return n.cache=i.set(r,a)||i,a};return n.cache=new(br.Cache||ze),n}br.Cache=ze;var qu=500;function Ju(t){var e=br(t,function(s){return n.size===qu&&n.clear(),s}),n=e.cache;return e}var Zu=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Qu=/\\(\\)?/g,ed=Ju(function(t){var e=[];return t.charCodeAt(0)===46&&e.push(""),t.replace(Zu,function(n,s,r,i){e.push(r?i.replace(Qu,"$1"):s||n)}),e});function td(t){return t==null?"":za(t)}function fs(t,e){return v(t)?t:Nr(t,e)?[t]:ed(td(t))}function gn(t){if(typeof t=="string"||rs(t))return t;var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}function vr(t,e){e=fs(e,t);for(var n=0,s=e.length;t!=null&&n<s;)t=t[gn(e[n++])];return n&&n==s?t:void 0}function nd(t,e,n){var s=t==null?void 0:vr(t,e);return s===void 0?n:s}function _r(t,e){for(var n=-1,s=e.length,r=t.length;++n<s;)t[r+n]=e[n];return t}var Ei=he?he.isConcatSpreadable:void 0;function sd(t){return v(t)||ls(t)||!!(Ei&&t&&t[Ei])}function Cr(t,e,n,s,r){var i=-1,a=t.length;for(n||(n=sd),r||(r=[]);++i<a;){var o=t[i];n(o)?_r(r,o):s||(r[r.length]=o)}return r}function Te(t){var e=t==null?0:t.length;return e?Cr(t):[]}var no=eo(Object.getPrototypeOf,Object);function so(t,e,n){var s=-1,r=t.length;e<0&&(e=-e>r?0:r+e),n=n>r?r:n,n<0&&(n+=r),r=e>n?0:n-e>>>0,e>>>=0;for(var i=Array(r);++s<r;)i[s]=t[s+e];return i}function rd(t,e,n,s){var r=-1,i=t==null?0:t.length;for(s&&i&&(n=t[++r]);++r<i;)n=e(n,t[r],r,t);return n}function id(){this.__data__=new Ke,this.size=0}function ad(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n}function od(t){return this.__data__.get(t)}function cd(t){return this.__data__.has(t)}var ld=200;function hd(t,e){var n=this.__data__;if(n instanceof Ke){var s=n.__data__;if(!on||s.length<ld-1)return s.push([t,e]),this.size=++n.size,this;n=this.__data__=new ze(s)}return n.set(t,e),this.size=n.size,this}function Ie(t){var e=this.__data__=new Ke(t);this.size=e.size}Ie.prototype.clear=id;Ie.prototype.delete=ad;Ie.prototype.get=od;Ie.prototype.has=cd;Ie.prototype.set=hd;function ud(t,e){return t&&fn(e,de(e),t)}function dd(t,e){return t&&fn(e,Ir(e),t)}var ro=typeof exports=="object"&&exports&&!exports.nodeType&&exports,yi=ro&&typeof module=="object"&&module&&!module.nodeType&&module,fd=yi&&yi.exports===ro,Ai=fd?be.Buffer:void 0,Si=Ai?Ai.allocUnsafe:void 0;function pd(t,e){var n=t.length,s=Si?Si(n):new t.constructor(n);return t.copy(s),s}function kr(t,e){for(var n=-1,s=t==null?0:t.length,r=0,i=[];++n<s;){var a=t[n];e(a,n,t)&&(i[r++]=a)}return i}function io(){return[]}var gd=Object.prototype,md=gd.propertyIsEnumerable,Oi=Object.getOwnPropertySymbols,wr=Oi?function(t){return t==null?[]:(t=Object(t),kr(Oi(t),function(e){return md.call(t,e)}))}:io;function Td(t,e){return fn(t,wr(t),e)}var Ed=Object.getOwnPropertySymbols,ao=Ed?function(t){for(var e=[];t;)_r(e,wr(t)),t=no(t);return e}:io;function yd(t,e){return fn(t,ao(t),e)}function oo(t,e,n){var s=e(t);return v(t)?s:_r(s,n(t))}function Js(t){return oo(t,de,wr)}function Ad(t){return oo(t,Ir,ao)}var Zs=Tt(be,"DataView"),Qs=Tt(be,"Promise"),It=Tt(be,"Set"),Ri="[object Map]",Sd="[object Object]",Li="[object Promise]",Ii="[object Set]",Ni="[object WeakMap]",bi="[object DataView]",Od=mt(Zs),Rd=mt(on),Ld=mt(Qs),Id=mt(It),Nd=mt(Xs),ce=rt;(Zs&&ce(new Zs(new ArrayBuffer(1)))!=bi||on&&ce(new on)!=Ri||Qs&&ce(Qs.resolve())!=Li||It&&ce(new It)!=Ii||Xs&&ce(new Xs)!=Ni)&&(ce=function(t){var e=rt(t),n=e==Sd?t.constructor:void 0,s=n?mt(n):"";if(s)switch(s){case Od:return bi;case Rd:return Ri;case Ld:return Li;case Id:return Ii;case Nd:return Ni}return e});var bd=Object.prototype,vd=bd.hasOwnProperty;function _d(t){var e=t.length,n=new t.constructor(e);return e&&typeof t[0]=="string"&&vd.call(t,"index")&&(n.index=t.index,n.input=t.input),n}var jn=be.Uint8Array;function Cd(t){var e=new t.constructor(t.byteLength);return new jn(e).set(new jn(t)),e}function kd(t,e){var n=t.buffer;return new t.constructor(n,t.byteOffset,t.byteLength)}var wd=/\w*$/;function xd(t){var e=new t.constructor(t.source,wd.exec(t));return e.lastIndex=t.lastIndex,e}var vi=he?he.prototype:void 0,_i=vi?vi.valueOf:void 0;function Md(t){return _i?Object(_i.call(t)):{}}function $d(t,e){var n=t.buffer;return new t.constructor(n,t.byteOffset,t.length)}var Pd="[object Boolean]",Ud="[object Date]",Dd="[object Map]",Fd="[object Number]",Bd="[object RegExp]",Gd="[object Set]",Wd="[object String]",jd="[object Symbol]",Kd="[object ArrayBuffer]",zd="[object DataView]",Hd="[object Float32Array]",Vd="[object Float64Array]",Yd="[object Int8Array]",Xd="[object Int16Array]",qd="[object Int32Array]",Jd="[object Uint8Array]",Zd="[object Uint8ClampedArray]",Qd="[object Uint16Array]",ef="[object Uint32Array]";function tf(t,e,n){var s=t.constructor;switch(e){case Kd:return Cd(t);case Pd:case Ud:return new s(+t);case zd:return kd(t);case Hd:case Vd:case Yd:case Xd:case qd:case Jd:case Zd:case Qd:case ef:return $d(t);case Dd:return new s;case Fd:case Wd:return new s(t);case Bd:return xd(t);case Gd:return new s;case jd:return Md(t)}}function nf(t){return typeof t.constructor=="function"&&!pn(t)?fh(no(t)):{}}var sf="[object Map]";function rf(t){return Ee(t)&&ce(t)==sf}var Ci=Qe&&Qe.isMap,af=Ci?hs(Ci):rf,of="[object Set]";function cf(t){return Ee(t)&&ce(t)==of}var ki=Qe&&Qe.isSet,lf=ki?hs(ki):cf,hf=2,co="[object Arguments]",uf="[object Array]",df="[object Boolean]",ff="[object Date]",pf="[object Error]",lo="[object Function]",gf="[object GeneratorFunction]",mf="[object Map]",Tf="[object Number]",ho="[object Object]",Ef="[object RegExp]",yf="[object Set]",Af="[object String]",Sf="[object Symbol]",Of="[object WeakMap]",Rf="[object ArrayBuffer]",Lf="[object DataView]",If="[object Float32Array]",Nf="[object Float64Array]",bf="[object Int8Array]",vf="[object Int16Array]",_f="[object Int32Array]",Cf="[object Uint8Array]",kf="[object Uint8ClampedArray]",wf="[object Uint16Array]",xf="[object Uint32Array]",C={};C[co]=C[uf]=C[Rf]=C[Lf]=C[df]=C[ff]=C[If]=C[Nf]=C[bf]=C[vf]=C[_f]=C[mf]=C[Tf]=C[ho]=C[Ef]=C[yf]=C[Af]=C[Sf]=C[Cf]=C[kf]=C[wf]=C[xf]=!0;C[pf]=C[lo]=C[Of]=!1;function Cn(t,e,n,s,r,i){var a,o=e&hf;if(a!==void 0)return a;if(!ue(t))return t;var c=v(t);if(c)return a=_d(t),gh(t,a);var l=ce(t),d=l==lo||l==gf;if(rn(t))return pd(t);if(l==ho||l==co||d&&!r)return a=d?{}:nf(t),o?yd(t,dd(a,t)):Td(t,ud(a,t));if(!C[l])return r?t:{};a=tf(t,l),i||(i=new Ie);var h=i.get(t);if(h)return h;i.set(t,a),lf(t)?t.forEach(function(g){a.add(Cn(g,e,n,g,t,i))}):af(t)&&t.forEach(function(g,T){a.set(T,Cn(g,e,n,T,t,i))});var f=Js,p=c?void 0:f(t);return Ha(p||t,function(g,T){p&&(T=g,g=t[T]),cs(a,T,Cn(g,e,n,T,t,i))}),a}var Mf=4;function H(t){return Cn(t,Mf)}function mn(t){for(var e=-1,n=t==null?0:t.length,s=0,r=[];++e<n;){var i=t[e];i&&(r[s++]=i)}return r}var $f="__lodash_hash_undefined__";function Pf(t){return this.__data__.set(t,$f),this}function Uf(t){return this.__data__.has(t)}function xt(t){var e=-1,n=t==null?0:t.length;for(this.__data__=new ze;++e<n;)this.add(t[e])}xt.prototype.add=xt.prototype.push=Pf;xt.prototype.has=Uf;function uo(t,e){for(var n=-1,s=t==null?0:t.length;++n<s;)if(e(t[n],n,t))return!0;return!1}function xr(t,e){return t.has(e)}var Df=1,Ff=2;function fo(t,e,n,s,r,i){var a=n&Df,o=t.length,c=e.length;if(o!=c&&!(a&&c>o))return!1;var l=i.get(t),d=i.get(e);if(l&&d)return l==e&&d==t;var h=-1,f=!0,p=n&Ff?new xt:void 0;for(i.set(t,e),i.set(e,t);++h<o;){var g=t[h],T=e[h];if(s)var L=a?s(T,g,h,e,t,i):s(g,T,h,t,e,i);if(L!==void 0){if(L)continue;f=!1;break}if(p){if(!uo(e,function(y,E){if(!xr(p,E)&&(g===y||r(g,y,n,s,i)))return p.push(E)})){f=!1;break}}else if(!(g===T||r(g,T,n,s,i))){f=!1;break}}return i.delete(t),i.delete(e),f}function Bf(t){var e=-1,n=Array(t.size);return t.forEach(function(s,r){n[++e]=[r,s]}),n}function Mr(t){var e=-1,n=Array(t.size);return t.forEach(function(s){n[++e]=s}),n}var Gf=1,Wf=2,jf="[object Boolean]",Kf="[object Date]",zf="[object Error]",Hf="[object Map]",Vf="[object Number]",Yf="[object RegExp]",Xf="[object Set]",qf="[object String]",Jf="[object Symbol]",Zf="[object ArrayBuffer]",Qf="[object DataView]",wi=he?he.prototype:void 0,Us=wi?wi.valueOf:void 0;function ep(t,e,n,s,r,i,a){switch(n){case Qf:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case Zf:return!(t.byteLength!=e.byteLength||!i(new jn(t),new jn(e)));case jf:case Kf:case Vf:return dn(+t,+e);case zf:return t.name==e.name&&t.message==e.message;case Yf:case qf:return t==e+"";case Hf:var o=Bf;case Xf:var c=s&Gf;if(o||(o=Mr),t.size!=e.size&&!c)return!1;var l=a.get(t);if(l)return l==e;s|=Wf,a.set(t,e);var d=fo(o(t),o(e),s,r,i,a);return a.delete(t),d;case Jf:if(Us)return Us.call(t)==Us.call(e)}return!1}var tp=1,np=Object.prototype,sp=np.hasOwnProperty;function rp(t,e,n,s,r,i){var a=n&tp,o=Js(t),c=o.length,l=Js(e),d=l.length;if(c!=d&&!a)return!1;for(var h=c;h--;){var f=o[h];if(!(a?f in e:sp.call(e,f)))return!1}var p=i.get(t),g=i.get(e);if(p&&g)return p==e&&g==t;var T=!0;i.set(t,e),i.set(e,t);for(var L=a;++h<c;){f=o[h];var y=t[f],E=e[f];if(s)var m=a?s(E,y,f,e,t,i):s(y,E,f,t,e,i);if(!(m===void 0?y===E||r(y,E,n,s,i):m)){T=!1;break}L||(L=f=="constructor")}if(T&&!L){var A=t.constructor,_=e.constructor;A!=_&&"constructor"in t&&"constructor"in e&&!(typeof A=="function"&&A instanceof A&&typeof _=="function"&&_ instanceof _)&&(T=!1)}return i.delete(t),i.delete(e),T}var ip=1,xi="[object Arguments]",Mi="[object Array]",Ln="[object Object]",ap=Object.prototype,$i=ap.hasOwnProperty;function op(t,e,n,s,r,i){var a=v(t),o=v(e),c=a?Mi:ce(t),l=o?Mi:ce(e);c=c==xi?Ln:c,l=l==xi?Ln:l;var d=c==Ln,h=l==Ln,f=c==l;if(f&&rn(t)){if(!rn(e))return!1;a=!0,d=!1}if(f&&!d)return i||(i=new Ie),a||Lr(t)?fo(t,e,n,s,r,i):ep(t,e,c,n,s,r,i);if(!(n&ip)){var p=d&&$i.call(t,"__wrapped__"),g=h&&$i.call(e,"__wrapped__");if(p||g){var T=p?t.value():t,L=g?e.value():e;return i||(i=new Ie),r(T,L,n,s,i)}}return f?(i||(i=new Ie),rp(t,e,n,s,r,i)):!1}function $r(t,e,n,s,r){return t===e?!0:t==null||e==null||!Ee(t)&&!Ee(e)?t!==t&&e!==e:op(t,e,n,s,$r,r)}var cp=1,lp=2;function hp(t,e,n,s){var r=n.length,i=r;if(t==null)return!i;for(t=Object(t);r--;){var a=n[r];if(a[2]?a[1]!==t[a[0]]:!(a[0]in t))return!1}for(;++r<i;){a=n[r];var o=a[0],c=t[o],l=a[1];if(a[2]){if(c===void 0&&!(o in t))return!1}else{var d=new Ie,h;if(!(h===void 0?$r(l,c,cp|lp,s,d):h))return!1}}return!0}function po(t){return t===t&&!ue(t)}function up(t){for(var e=de(t),n=e.length;n--;){var s=e[n],r=t[s];e[n]=[s,r,po(r)]}return e}function go(t,e){return function(n){return n==null?!1:n[t]===e&&(e!==void 0||t in Object(n))}}function dp(t){var e=up(t);return e.length==1&&e[0][2]?go(e[0][0],e[0][1]):function(n){return n===t||hp(n,t,e)}}function fp(t,e){return t!=null&&e in Object(t)}function mo(t,e,n){e=fs(e,t);for(var s=-1,r=e.length,i=!1;++s<r;){var a=gn(e[s]);if(!(i=t!=null&&n(t,a)))break;t=t[a]}return i||++s!=r?i:(r=t==null?0:t.length,!!r&&Rr(r)&&os(a,r)&&(v(t)||ls(t)))}function pp(t,e){return t!=null&&mo(t,e,fp)}var gp=1,mp=2;function Tp(t,e){return Nr(t)&&po(e)?go(gn(t),e):function(n){var s=nd(n,t);return s===void 0&&s===e?pp(n,t):$r(e,s,gp|mp)}}function Ep(t){return function(e){return e==null?void 0:e[t]}}function yp(t){return function(e){return vr(e,t)}}function Ap(t){return Nr(t)?Ep(gn(t)):yp(t)}function _e(t){return typeof t=="function"?t:t==null?un:typeof t=="object"?v(t)?Tp(t[0],t[1]):dp(t):Ap(t)}function Sp(t,e,n,s){for(var r=-1,i=t==null?0:t.length;++r<i;){var a=t[r];e(s,a,n(a),t)}return s}function Op(t){return function(e,n,s){for(var r=-1,i=Object(e),a=s(e),o=a.length;o--;){var c=a[++r];if(n(i[c],c,i)===!1)break}return e}}var Rp=Op();function Lp(t,e){return t&&Rp(t,e,de)}function Ip(t,e){return function(n,s){if(n==null)return n;if(!ve(n))return t(n,s);for(var r=n.length,i=-1,a=Object(n);++i<r&&s(a[i],i,a)!==!1;);return n}}var Et=Ip(Lp);function Np(t,e,n,s){return Et(t,function(r,i,a){e(s,r,n(r),a)}),s}function bp(t,e){return function(n,s){var r=v(n)?Sp:Np,i=e?e():{};return r(n,t,_e(s),i)}}var To=Object.prototype,vp=To.hasOwnProperty,Pr=Or(function(t,e){t=Object(t);var n=-1,s=e.length,r=s>2?e[2]:void 0;for(r&&Xa(e[0],e[1],r)&&(s=1);++n<s;)for(var i=e[n],a=Ir(i),o=-1,c=a.length;++o<c;){var l=a[o],d=t[l];(d===void 0||dn(d,To[l])&&!vp.call(t,l))&&(t[l]=i[l])}return t});function Pi(t){return Ee(t)&&ve(t)}var _p=200;function Cp(t,e,n,s){var r=-1,i=Ya,a=!0,o=t.length,c=[],l=e.length;if(!o)return c;e.length>=_p&&(i=xr,a=!1,e=new xt(e));e:for(;++r<o;){var d=t[r],h=d;if(d=d!==0?d:0,a&&h===h){for(var f=l;f--;)if(e[f]===h)continue e;c.push(d)}else i(e,h,s)||c.push(d)}return c}var ps=Or(function(t,e){return Pi(t)?Cp(t,Cr(e,1,Pi,!0)):[]});function ft(t){var e=t==null?0:t.length;return e?t[e-1]:void 0}function z(t,e,n){var s=t==null?0:t.length;return s?(e=e===void 0?1:as(e),so(t,e<0?0:e,s)):[]}function cn(t,e,n){var s=t==null?0:t.length;return s?(e=e===void 0?1:as(e),e=s-e,so(t,0,e<0?0:e)):[]}function kp(t){return typeof t=="function"?t:un}function N(t,e){var n=v(t)?Ha:Et;return n(t,kp(e))}function wp(t,e){for(var n=-1,s=t==null?0:t.length;++n<s;)if(!e(t[n],n,t))return!1;return!0}function xp(t,e){var n=!0;return Et(t,function(s,r,i){return n=!!e(s,r,i),n}),n}function Ne(t,e,n){var s=v(t)?wp:xp;return s(t,_e(e))}function Eo(t,e){var n=[];return Et(t,function(s,r,i){e(s,r,i)&&n.push(s)}),n}function fe(t,e){var n=v(t)?kr:Eo;return n(t,_e(e))}function Mp(t){return function(e,n,s){var r=Object(e);if(!ve(e)){var i=_e(n);e=de(e),n=function(o){return i(r[o],o,r)}}var a=t(e,n,s);return a>-1?r[i?e[a]:a]:void 0}}var $p=Math.max;function Pp(t,e,n){var s=t==null?0:t.length;if(!s)return-1;var r=n==null?0:as(n);return r<0&&(r=$p(s+r,0)),Va(t,_e(e),r)}var Mt=Mp(Pp);function ye(t){return t&&t.length?t[0]:void 0}function Up(t,e){var n=-1,s=ve(t)?Array(t.length):[];return Et(t,function(r,i,a){s[++n]=e(r,i,a)}),s}function S(t,e){var n=v(t)?is:Up;return n(t,_e(e))}function le(t,e){return Cr(S(t,e))}var Dp=Object.prototype,Fp=Dp.hasOwnProperty,Bp=bp(function(t,e,n){Fp.call(t,n)?t[n].push(e):Sr(t,n,[e])}),Gp=Object.prototype,Wp=Gp.hasOwnProperty;function jp(t,e){return t!=null&&Wp.call(t,e)}function R(t,e){return t!=null&&mo(t,e,jp)}var Kp="[object String]";function Ae(t){return typeof t=="string"||!v(t)&&Ee(t)&&rt(t)==Kp}function zp(t,e){return is(e,function(n){return t[n]})}function B(t){return t==null?[]:zp(t,de(t))}var Hp=Math.max;function te(t,e,n,s){t=ve(t)?t:B(t),n=n?as(n):0;var r=t.length;return n<0&&(n=Hp(r+n,0)),Ae(t)?n<=r&&t.indexOf(e,n)>-1:!!r&&Ar(t,e,n)>-1}function Ui(t,e,n){var s=t==null?0:t.length;if(!s)return-1;var r=0;return Ar(t,e,r)}var Vp="[object Map]",Yp="[object Set]",Xp=Object.prototype,qp=Xp.hasOwnProperty;function k(t){if(t==null)return!0;if(ve(t)&&(v(t)||typeof t=="string"||typeof t.splice=="function"||rn(t)||Lr(t)||ls(t)))return!t.length;var e=ce(t);if(e==Vp||e==Yp)return!t.size;if(pn(t))return!to(t).length;for(var n in t)if(qp.call(t,n))return!1;return!0}var Jp="[object RegExp]";function Zp(t){return Ee(t)&&rt(t)==Jp}var Di=Qe&&Qe.isRegExp,et=Di?hs(Di):Zp;function Fe(t){return t===void 0}var Qp="Expected a function";function eg(t){if(typeof t!="function")throw new TypeError(Qp);return function(){var e=arguments;switch(e.length){case 0:return!t.call(this);case 1:return!t.call(this,e[0]);case 2:return!t.call(this,e[0],e[1]);case 3:return!t.call(this,e[0],e[1],e[2])}return!t.apply(this,e)}}function tg(t,e,n,s){if(!ue(t))return t;e=fs(e,t);for(var r=-1,i=e.length,a=i-1,o=t;o!=null&&++r<i;){var c=gn(e[r]),l=n;if(c==="__proto__"||c==="constructor"||c==="prototype")return t;if(r!=a){var d=o[c];l=void 0,l===void 0&&(l=ue(d)?d:os(e[r+1])?[]:{})}cs(o,c,l),o=o[c]}return t}function ng(t,e,n){for(var s=-1,r=e.length,i={};++s<r;){var a=e[s],o=vr(t,a);n(o,a)&&tg(i,fs(a,t),o)}return i}function sg(t,e){if(t==null)return{};var n=is(Ad(t),function(s){return[s]});return e=_e(e),ng(t,n,function(s,r){return e(s,r[0])})}function rg(t,e,n,s,r){return r(t,function(i,a,o){n=s?(s=!1,i):e(n,i,a,o)}),n}function ne(t,e,n){var s=v(t)?rd:rg,r=arguments.length<3;return s(t,_e(e),n,r,Et)}function gs(t,e){var n=v(t)?kr:Eo;return n(t,eg(_e(e)))}function ig(t,e){var n;return Et(t,function(s,r,i){return n=e(s,r,i),!n}),!!n}function ag(t,e,n){var s=v(t)?uo:ig;return s(t,_e(e))}var og=1/0,cg=It&&1/Mr(new It([,-0]))[1]==og?function(t){return new It(t)}:W,lg=200;function hg(t,e,n){var s=-1,r=Ya,i=t.length,a=!0,o=[],c=o;if(i>=lg){var l=cg(t);if(l)return Mr(l);a=!1,r=xr,c=new xt}else c=o;e:for(;++s<i;){var d=t[s],h=d;if(d=d!==0?d:0,a&&h===h){for(var f=c.length;f--;)if(c[f]===h)continue e;o.push(d)}else r(c,h,n)||(c!==o&&c.push(h),o.push(d))}return o}function Ur(t){return t&&t.length?hg(t):[]}function er(t){console&&console.error&&console.error(`Error: ${t}`)}function yo(t){console&&console.warn&&console.warn(`Warning: ${t}`)}function Ao(t){const e=new Date().getTime(),n=t();return{time:new Date().getTime()-e,value:n}}function So(t){function e(){}e.prototype=t;const n=new e;function s(){return typeof n.bar}return s(),s(),t}var Oo=typeof global=="object"&&global&&global.Object===Object&&global,ug=typeof self=="object"&&self&&self.Object===Object&&self,He=Oo||ug||Function("return this")(),tt=He.Symbol,Ro=Object.prototype,dg=Ro.hasOwnProperty,fg=Ro.toString,jt=tt?tt.toStringTag:void 0;function pg(t){var e=dg.call(t,jt),n=t[jt];try{t[jt]=void 0;var s=!0}catch{}var r=fg.call(t);return s&&(e?t[jt]=n:delete t[jt]),r}var gg=Object.prototype,mg=gg.toString;function Tg(t){return mg.call(t)}var Eg="[object Null]",yg="[object Undefined]",Fi=tt?tt.toStringTag:void 0;function it(t){return t==null?t===void 0?yg:Eg:Fi&&Fi in Object(t)?pg(t):Tg(t)}function nt(t){return t!=null&&typeof t=="object"}var Ag="[object Symbol]";function ms(t){return typeof t=="symbol"||nt(t)&&it(t)==Ag}function Ts(t,e){for(var n=-1,s=t==null?0:t.length,r=Array(s);++n<s;)r[n]=e(t[n],n,t);return r}var Q=Array.isArray,Bi=tt?tt.prototype:void 0,Gi=Bi?Bi.toString:void 0;function Lo(t){if(typeof t=="string")return t;if(Q(t))return Ts(t,Lo)+"";if(ms(t))return Gi?Gi.call(t):"";var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}var Sg=/\s/;function Og(t){for(var e=t.length;e--&&Sg.test(t.charAt(e)););return e}var Rg=/^\s+/;function Lg(t){return t&&t.slice(0,Og(t)+1).replace(Rg,"")}function Be(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}var Wi=NaN,Ig=/^[-+]0x[0-9a-f]+$/i,Ng=/^0b[01]+$/i,bg=/^0o[0-7]+$/i,vg=parseInt;function _g(t){if(typeof t=="number")return t;if(ms(t))return Wi;if(Be(t)){var e=typeof t.valueOf=="function"?t.valueOf():t;t=Be(e)?e+"":e}if(typeof t!="string")return t===0?t:+t;t=Lg(t);var n=Ng.test(t);return n||bg.test(t)?vg(t.slice(2),n?2:8):Ig.test(t)?Wi:+t}var ji=1/0,Cg=17976931348623157e292;function kg(t){if(!t)return t===0?t:0;if(t=_g(t),t===ji||t===-ji){var e=t<0?-1:1;return e*Cg}return t===t?t:0}function wg(t){var e=kg(t),n=e%1;return e===e?n?e-n:e:0}function Es(t){return t}var xg="[object AsyncFunction]",Mg="[object Function]",$g="[object GeneratorFunction]",Pg="[object Proxy]";function Io(t){if(!Be(t))return!1;var e=it(t);return e==Mg||e==$g||e==xg||e==Pg}var Ds=He["__core-js_shared__"],Ki=(function(){var t=/[^.]+$/.exec(Ds&&Ds.keys&&Ds.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""})();function Ug(t){return!!Ki&&Ki in t}var Dg=Function.prototype,Fg=Dg.toString;function yt(t){if(t!=null){try{return Fg.call(t)}catch{}try{return t+""}catch{}}return""}var Bg=/[\\^$.*+?()[\]{}|]/g,Gg=/^\[object .+?Constructor\]$/,Wg=Function.prototype,jg=Object.prototype,Kg=Wg.toString,zg=jg.hasOwnProperty,Hg=RegExp("^"+Kg.call(zg).replace(Bg,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Vg(t){if(!Be(t)||Ug(t))return!1;var e=Io(t)?Hg:Gg;return e.test(yt(t))}function Yg(t,e){return t==null?void 0:t[e]}function At(t,e){var n=Yg(t,e);return Vg(n)?n:void 0}var tr=At(He,"WeakMap");function Xg(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)}var qg=800,Jg=16,Zg=Date.now;function Qg(t){var e=0,n=0;return function(){var s=Zg(),r=Jg-(s-n);if(n=s,r>0){if(++e>=qg)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}function em(t){return function(){return t}}var Kn=(function(){try{var t=At(Object,"defineProperty");return t({},"",{}),t}catch{}})(),tm=Kn?function(t,e){return Kn(t,"toString",{configurable:!0,enumerable:!1,value:em(e),writable:!0})}:Es,nm=Qg(tm);function sm(t,e){for(var n=-1,s=t==null?0:t.length;++n<s&&e(t[n],n,t)!==!1;);return t}function rm(t,e,n,s){for(var r=t.length,i=n+-1;++i<r;)if(e(t[i],i,t))return i;return-1}function im(t){return t!==t}function am(t,e,n){for(var s=n-1,r=t.length;++s<r;)if(t[s]===e)return s;return-1}function om(t,e,n){return e===e?am(t,e,n):rm(t,im,n)}var cm=9007199254740991,lm=/^(?:0|[1-9]\d*)$/;function ys(t,e){var n=typeof t;return e=e??cm,!!e&&(n=="number"||n!="symbol"&&lm.test(t))&&t>-1&&t%1==0&&t<e}function No(t,e,n){e=="__proto__"&&Kn?Kn(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}function As(t,e){return t===e||t!==t&&e!==e}var hm=Object.prototype,um=hm.hasOwnProperty;function Dr(t,e,n){var s=t[e];(!(um.call(t,e)&&As(s,n))||n===void 0&&!(e in t))&&No(t,e,n)}function dm(t,e,n,s){var r=!n;n||(n={});for(var i=-1,a=e.length;++i<a;){var o=e[i],c=void 0;c===void 0&&(c=t[o]),r?No(n,o,c):Dr(n,o,c)}return n}var zi=Math.max;function fm(t,e,n){return e=zi(e===void 0?t.length-1:e,0),function(){for(var s=arguments,r=-1,i=zi(s.length-e,0),a=Array(i);++r<i;)a[r]=s[e+r];r=-1;for(var o=Array(e+1);++r<e;)o[r]=s[r];return o[e]=n(a),Xg(t,this,o)}}function pm(t,e){return nm(fm(t,e,Es),t+"")}var gm=9007199254740991;function Fr(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=gm}function St(t){return t!=null&&Fr(t.length)&&!Io(t)}function mm(t,e,n){if(!Be(n))return!1;var s=typeof e;return(s=="number"?St(n)&&ys(e,n.length):s=="string"&&e in n)?As(n[e],t):!1}function Tm(t){return pm(function(e,n){var s=-1,r=n.length,i=r>1?n[r-1]:void 0,a=r>2?n[2]:void 0;for(i=t.length>3&&typeof i=="function"?(r--,i):void 0,a&&mm(n[0],n[1],a)&&(i=r<3?void 0:i,r=1),e=Object(e);++s<r;){var o=n[s];o&&t(e,o,s,i)}return e})}var Em=Object.prototype;function Br(t){var e=t&&t.constructor,n=typeof e=="function"&&e.prototype||Em;return t===n}function ym(t,e){for(var n=-1,s=Array(t);++n<t;)s[n]=e(n);return s}var Am="[object Arguments]";function Hi(t){return nt(t)&&it(t)==Am}var bo=Object.prototype,Sm=bo.hasOwnProperty,Om=bo.propertyIsEnumerable,vo=Hi((function(){return arguments})())?Hi:function(t){return nt(t)&&Sm.call(t,"callee")&&!Om.call(t,"callee")};function Rm(){return!1}var _o=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Vi=_o&&typeof module=="object"&&module&&!module.nodeType&&module,Lm=Vi&&Vi.exports===_o,Yi=Lm?He.Buffer:void 0,Im=Yi?Yi.isBuffer:void 0,nr=Im||Rm,Nm="[object Arguments]",bm="[object Array]",vm="[object Boolean]",_m="[object Date]",Cm="[object Error]",km="[object Function]",wm="[object Map]",xm="[object Number]",Mm="[object Object]",$m="[object RegExp]",Pm="[object Set]",Um="[object String]",Dm="[object WeakMap]",Fm="[object ArrayBuffer]",Bm="[object DataView]",Gm="[object Float32Array]",Wm="[object Float64Array]",jm="[object Int8Array]",Km="[object Int16Array]",zm="[object Int32Array]",Hm="[object Uint8Array]",Vm="[object Uint8ClampedArray]",Ym="[object Uint16Array]",Xm="[object Uint32Array]",x={};x[Gm]=x[Wm]=x[jm]=x[Km]=x[zm]=x[Hm]=x[Vm]=x[Ym]=x[Xm]=!0;x[Nm]=x[bm]=x[Fm]=x[vm]=x[Bm]=x[_m]=x[Cm]=x[km]=x[wm]=x[xm]=x[Mm]=x[$m]=x[Pm]=x[Um]=x[Dm]=!1;function qm(t){return nt(t)&&Fr(t.length)&&!!x[it(t)]}function Co(t){return function(e){return t(e)}}var ko=typeof exports=="object"&&exports&&!exports.nodeType&&exports,nn=ko&&typeof module=="object"&&module&&!module.nodeType&&module,Jm=nn&&nn.exports===ko,Fs=Jm&&Oo.process,zn=(function(){try{var t=nn&&nn.require&&nn.require("util").types;return t||Fs&&Fs.binding&&Fs.binding("util")}catch{}})(),Xi=zn&&zn.isTypedArray,wo=Xi?Co(Xi):qm,Zm=Object.prototype,Qm=Zm.hasOwnProperty;function xo(t,e){var n=Q(t),s=!n&&vo(t),r=!n&&!s&&nr(t),i=!n&&!s&&!r&&wo(t),a=n||s||r||i,o=a?ym(t.length,String):[],c=o.length;for(var l in t)(e||Qm.call(t,l))&&!(a&&(l=="length"||r&&(l=="offset"||l=="parent")||i&&(l=="buffer"||l=="byteLength"||l=="byteOffset")||ys(l,c)))&&o.push(l);return o}function Mo(t,e){return function(n){return t(e(n))}}var eT=Mo(Object.keys,Object),tT=Object.prototype,nT=tT.hasOwnProperty;function sT(t){if(!Br(t))return eT(t);var e=[];for(var n in Object(t))nT.call(t,n)&&n!="constructor"&&e.push(n);return e}function Tn(t){return St(t)?xo(t):sT(t)}var rT=Object.prototype,iT=rT.hasOwnProperty,Ce=Tm(function(t,e){if(Br(e)||St(e)){dm(e,Tn(e),t);return}for(var n in e)iT.call(e,n)&&Dr(t,n,e[n])});function aT(t){var e=[];if(t!=null)for(var n in Object(t))e.push(n);return e}var oT=Object.prototype,cT=oT.hasOwnProperty;function lT(t){if(!Be(t))return aT(t);var e=Br(t),n=[];for(var s in t)s=="constructor"&&(e||!cT.call(t,s))||n.push(s);return n}function hT(t){return St(t)?xo(t,!0):lT(t)}var uT=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,dT=/^\w*$/;function Gr(t,e){if(Q(t))return!1;var n=typeof t;return n=="number"||n=="symbol"||n=="boolean"||t==null||ms(t)?!0:dT.test(t)||!uT.test(t)||e!=null&&t in Object(e)}var ln=At(Object,"create");function fT(){this.__data__=ln?ln(null):{},this.size=0}function pT(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}var gT="__lodash_hash_undefined__",mT=Object.prototype,TT=mT.hasOwnProperty;function ET(t){var e=this.__data__;if(ln){var n=e[t];return n===gT?void 0:n}return TT.call(e,t)?e[t]:void 0}var yT=Object.prototype,AT=yT.hasOwnProperty;function ST(t){var e=this.__data__;return ln?e[t]!==void 0:AT.call(e,t)}var OT="__lodash_hash_undefined__";function RT(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=ln&&e===void 0?OT:e,this}function pt(t){var e=-1,n=t==null?0:t.length;for(this.clear();++e<n;){var s=t[e];this.set(s[0],s[1])}}pt.prototype.clear=fT;pt.prototype.delete=pT;pt.prototype.get=ET;pt.prototype.has=ST;pt.prototype.set=RT;function LT(){this.__data__=[],this.size=0}function Ss(t,e){for(var n=t.length;n--;)if(As(t[n][0],e))return n;return-1}var IT=Array.prototype,NT=IT.splice;function bT(t){var e=this.__data__,n=Ss(e,t);if(n<0)return!1;var s=e.length-1;return n==s?e.pop():NT.call(e,n,1),--this.size,!0}function vT(t){var e=this.__data__,n=Ss(e,t);return n<0?void 0:e[n][1]}function _T(t){return Ss(this.__data__,t)>-1}function CT(t,e){var n=this.__data__,s=Ss(n,t);return s<0?(++this.size,n.push([t,e])):n[s][1]=e,this}function Ve(t){var e=-1,n=t==null?0:t.length;for(this.clear();++e<n;){var s=t[e];this.set(s[0],s[1])}}Ve.prototype.clear=LT;Ve.prototype.delete=bT;Ve.prototype.get=vT;Ve.prototype.has=_T;Ve.prototype.set=CT;var hn=At(He,"Map");function kT(){this.size=0,this.__data__={hash:new pt,map:new(hn||Ve),string:new pt}}function wT(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}function Os(t,e){var n=t.__data__;return wT(e)?n[typeof e=="string"?"string":"hash"]:n.map}function xT(t){var e=Os(this,t).delete(t);return this.size-=e?1:0,e}function MT(t){return Os(this,t).get(t)}function $T(t){return Os(this,t).has(t)}function PT(t,e){var n=Os(this,t),s=n.size;return n.set(t,e),this.size+=n.size==s?0:1,this}function Ye(t){var e=-1,n=t==null?0:t.length;for(this.clear();++e<n;){var s=t[e];this.set(s[0],s[1])}}Ye.prototype.clear=kT;Ye.prototype.delete=xT;Ye.prototype.get=MT;Ye.prototype.has=$T;Ye.prototype.set=PT;var UT="Expected a function";function Wr(t,e){if(typeof t!="function"||e!=null&&typeof e!="function")throw new TypeError(UT);var n=function(){var s=arguments,r=e?e.apply(this,s):s[0],i=n.cache;if(i.has(r))return i.get(r);var a=t.apply(this,s);return n.cache=i.set(r,a)||i,a};return n.cache=new(Wr.Cache||Ye),n}Wr.Cache=Ye;var DT=500;function FT(t){var e=Wr(t,function(s){return n.size===DT&&n.clear(),s}),n=e.cache;return e}var BT=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,GT=/\\(\\)?/g,WT=FT(function(t){var e=[];return t.charCodeAt(0)===46&&e.push(""),t.replace(BT,function(n,s,r,i){e.push(r?i.replace(GT,"$1"):s||n)}),e});function jT(t){return t==null?"":Lo(t)}function Rs(t,e){return Q(t)?t:Gr(t,e)?[t]:WT(jT(t))}function En(t){if(typeof t=="string"||ms(t))return t;var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}function jr(t,e){e=Rs(e,t);for(var n=0,s=e.length;t!=null&&n<s;)t=t[En(e[n++])];return n&&n==s?t:void 0}function KT(t,e,n){var s=t==null?void 0:jr(t,e);return s===void 0?n:s}function $o(t,e){for(var n=-1,s=e.length,r=t.length;++n<s;)t[r+n]=e[n];return t}var zT=Mo(Object.getPrototypeOf,Object);function HT(){this.__data__=new Ve,this.size=0}function VT(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n}function YT(t){return this.__data__.get(t)}function XT(t){return this.__data__.has(t)}var qT=200;function JT(t,e){var n=this.__data__;if(n instanceof Ve){var s=n.__data__;if(!hn||s.length<qT-1)return s.push([t,e]),this.size=++n.size,this;n=this.__data__=new Ye(s)}return n.set(t,e),this.size=n.size,this}function De(t){var e=this.__data__=new Ve(t);this.size=e.size}De.prototype.clear=HT;De.prototype.delete=VT;De.prototype.get=YT;De.prototype.has=XT;De.prototype.set=JT;function ZT(t,e){for(var n=-1,s=t==null?0:t.length,r=0,i=[];++n<s;){var a=t[n];e(a,n,t)&&(i[r++]=a)}return i}function Po(){return[]}var QT=Object.prototype,eE=QT.propertyIsEnumerable,qi=Object.getOwnPropertySymbols,Uo=qi?function(t){return t==null?[]:(t=Object(t),ZT(qi(t),function(e){return eE.call(t,e)}))}:Po,tE=Object.getOwnPropertySymbols,nE=tE?function(t){for(var e=[];t;)$o(e,Uo(t)),t=zT(t);return e}:Po;function Do(t,e,n){var s=e(t);return Q(t)?s:$o(s,n(t))}function Ji(t){return Do(t,Tn,Uo)}function sE(t){return Do(t,hT,nE)}var sr=At(He,"DataView"),rr=At(He,"Promise"),ir=At(He,"Set"),Zi="[object Map]",rE="[object Object]",Qi="[object Promise]",ea="[object Set]",ta="[object WeakMap]",na="[object DataView]",iE=yt(sr),aE=yt(hn),oE=yt(rr),cE=yt(ir),lE=yt(tr),Ze=it;(sr&&Ze(new sr(new ArrayBuffer(1)))!=na||hn&&Ze(new hn)!=Zi||rr&&Ze(rr.resolve())!=Qi||ir&&Ze(new ir)!=ea||tr&&Ze(new tr)!=ta)&&(Ze=function(t){var e=it(t),n=e==rE?t.constructor:void 0,s=n?yt(n):"";if(s)switch(s){case iE:return na;case aE:return Zi;case oE:return Qi;case cE:return ea;case lE:return ta}return e});var sa=He.Uint8Array,hE="__lodash_hash_undefined__";function uE(t){return this.__data__.set(t,hE),this}function dE(t){return this.__data__.has(t)}function Hn(t){var e=-1,n=t==null?0:t.length;for(this.__data__=new Ye;++e<n;)this.add(t[e])}Hn.prototype.add=Hn.prototype.push=uE;Hn.prototype.has=dE;function Fo(t,e){for(var n=-1,s=t==null?0:t.length;++n<s;)if(e(t[n],n,t))return!0;return!1}function fE(t,e){return t.has(e)}var pE=1,gE=2;function Bo(t,e,n,s,r,i){var a=n&pE,o=t.length,c=e.length;if(o!=c&&!(a&&c>o))return!1;var l=i.get(t),d=i.get(e);if(l&&d)return l==e&&d==t;var h=-1,f=!0,p=n&gE?new Hn:void 0;for(i.set(t,e),i.set(e,t);++h<o;){var g=t[h],T=e[h];if(s)var L=a?s(T,g,h,e,t,i):s(g,T,h,t,e,i);if(L!==void 0){if(L)continue;f=!1;break}if(p){if(!Fo(e,function(y,E){if(!fE(p,E)&&(g===y||r(g,y,n,s,i)))return p.push(E)})){f=!1;break}}else if(!(g===T||r(g,T,n,s,i))){f=!1;break}}return i.delete(t),i.delete(e),f}function mE(t){var e=-1,n=Array(t.size);return t.forEach(function(s,r){n[++e]=[r,s]}),n}function TE(t){var e=-1,n=Array(t.size);return t.forEach(function(s){n[++e]=s}),n}var EE=1,yE=2,AE="[object Boolean]",SE="[object Date]",OE="[object Error]",RE="[object Map]",LE="[object Number]",IE="[object RegExp]",NE="[object Set]",bE="[object String]",vE="[object Symbol]",_E="[object ArrayBuffer]",CE="[object DataView]",ra=tt?tt.prototype:void 0,Bs=ra?ra.valueOf:void 0;function kE(t,e,n,s,r,i,a){switch(n){case CE:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case _E:return!(t.byteLength!=e.byteLength||!i(new sa(t),new sa(e)));case AE:case SE:case LE:return As(+t,+e);case OE:return t.name==e.name&&t.message==e.message;case IE:case bE:return t==e+"";case RE:var o=mE;case NE:var c=s&EE;if(o||(o=TE),t.size!=e.size&&!c)return!1;var l=a.get(t);if(l)return l==e;s|=yE,a.set(t,e);var d=Bo(o(t),o(e),s,r,i,a);return a.delete(t),d;case vE:if(Bs)return Bs.call(t)==Bs.call(e)}return!1}var wE=1,xE=Object.prototype,ME=xE.hasOwnProperty;function $E(t,e,n,s,r,i){var a=n&wE,o=Ji(t),c=o.length,l=Ji(e),d=l.length;if(c!=d&&!a)return!1;for(var h=c;h--;){var f=o[h];if(!(a?f in e:ME.call(e,f)))return!1}var p=i.get(t),g=i.get(e);if(p&&g)return p==e&&g==t;var T=!0;i.set(t,e),i.set(e,t);for(var L=a;++h<c;){f=o[h];var y=t[f],E=e[f];if(s)var m=a?s(E,y,f,e,t,i):s(y,E,f,t,e,i);if(!(m===void 0?y===E||r(y,E,n,s,i):m)){T=!1;break}L||(L=f=="constructor")}if(T&&!L){var A=t.constructor,_=e.constructor;A!=_&&"constructor"in t&&"constructor"in e&&!(typeof A=="function"&&A instanceof A&&typeof _=="function"&&_ instanceof _)&&(T=!1)}return i.delete(t),i.delete(e),T}var PE=1,ia="[object Arguments]",aa="[object Array]",In="[object Object]",UE=Object.prototype,oa=UE.hasOwnProperty;function DE(t,e,n,s,r,i){var a=Q(t),o=Q(e),c=a?aa:Ze(t),l=o?aa:Ze(e);c=c==ia?In:c,l=l==ia?In:l;var d=c==In,h=l==In,f=c==l;if(f&&nr(t)){if(!nr(e))return!1;a=!0,d=!1}if(f&&!d)return i||(i=new De),a||wo(t)?Bo(t,e,n,s,r,i):kE(t,e,c,n,s,r,i);if(!(n&PE)){var p=d&&oa.call(t,"__wrapped__"),g=h&&oa.call(e,"__wrapped__");if(p||g){var T=p?t.value():t,L=g?e.value():e;return i||(i=new De),r(T,L,n,s,i)}}return f?(i||(i=new De),$E(t,e,n,s,r,i)):!1}function Kr(t,e,n,s,r){return t===e?!0:t==null||e==null||!nt(t)&&!nt(e)?t!==t&&e!==e:DE(t,e,n,s,Kr,r)}var FE=1,BE=2;function GE(t,e,n,s){var r=n.length,i=r;if(t==null)return!i;for(t=Object(t);r--;){var a=n[r];if(a[2]?a[1]!==t[a[0]]:!(a[0]in t))return!1}for(;++r<i;){a=n[r];var o=a[0],c=t[o],l=a[1];if(a[2]){if(c===void 0&&!(o in t))return!1}else{var d=new De,h;if(!(h===void 0?Kr(l,c,FE|BE,s,d):h))return!1}}return!0}function Go(t){return t===t&&!Be(t)}function WE(t){for(var e=Tn(t),n=e.length;n--;){var s=e[n],r=t[s];e[n]=[s,r,Go(r)]}return e}function Wo(t,e){return function(n){return n==null?!1:n[t]===e&&(e!==void 0||t in Object(n))}}function jE(t){var e=WE(t);return e.length==1&&e[0][2]?Wo(e[0][0],e[0][1]):function(n){return n===t||GE(n,t,e)}}function KE(t,e){return t!=null&&e in Object(t)}function zE(t,e,n){e=Rs(e,t);for(var s=-1,r=e.length,i=!1;++s<r;){var a=En(e[s]);if(!(i=t!=null&&n(t,a)))break;t=t[a]}return i||++s!=r?i:(r=t==null?0:t.length,!!r&&Fr(r)&&ys(a,r)&&(Q(t)||vo(t)))}function HE(t,e){return t!=null&&zE(t,e,KE)}var VE=1,YE=2;function XE(t,e){return Gr(t)&&Go(e)?Wo(En(t),e):function(n){var s=KT(n,t);return s===void 0&&s===e?HE(n,t):Kr(e,s,VE|YE)}}function qE(t){return function(e){return e==null?void 0:e[t]}}function JE(t){return function(e){return jr(e,t)}}function ZE(t){return Gr(t)?qE(En(t)):JE(t)}function Ls(t){return typeof t=="function"?t:t==null?Es:typeof t=="object"?Q(t)?XE(t[0],t[1]):jE(t):ZE(t)}function QE(t){return function(e,n,s){for(var r=-1,i=Object(e),a=s(e),o=a.length;o--;){var c=a[++r];if(n(i[c],c,i)===!1)break}return e}}var ey=QE();function ty(t,e){return t&&ey(t,e,Tn)}function ny(t,e){return function(n,s){if(n==null)return n;if(!St(n))return t(n,s);for(var r=n.length,i=-1,a=Object(n);++i<r&&s(a[i],i,a)!==!1;);return n}}var Is=ny(ty);function sy(t){return typeof t=="function"?t:Es}function ry(t,e){var n=Q(t)?sm:Is;return n(t,sy(e))}function iy(t,e){for(var n=-1,s=t==null?0:t.length;++n<s;)if(!e(t[n],n,t))return!1;return!0}function ay(t,e){var n=!0;return Is(t,function(s,r,i){return n=!!e(s,r,i),n}),n}function oy(t,e,n){var s=Q(t)?iy:ay;return s(t,Ls(e))}function cy(t,e){var n=-1,s=St(t)?Array(t.length):[];return Is(t,function(r,i,a){s[++n]=e(r,i,a)}),s}function jo(t,e){var n=Q(t)?Ts:cy;return n(t,Ls(e))}var ly="[object String]";function Vn(t){return typeof t=="string"||!Q(t)&&nt(t)&&it(t)==ly}function hy(t,e){return Ts(e,function(n){return t[n]})}function uy(t){return t==null?[]:hy(t,Tn(t))}var dy=Math.max;function fy(t,e,n,s){t=St(t)?t:uy(t),n=n?wg(n):0;var r=t.length;return n<0&&(n=dy(r+n,0)),Vn(t)?n<=r&&t.indexOf(e,n)>-1:!!r&&om(t,e,n)>-1}var py="[object RegExp]";function gy(t){return nt(t)&&it(t)==py}var ca=zn&&zn.isRegExp,my=ca?Co(ca):gy;function Ty(t,e,n,s){if(!Be(t))return t;e=Rs(e,t);for(var r=-1,i=e.length,a=i-1,o=t;o!=null&&++r<i;){var c=En(e[r]),l=n;if(c==="__proto__"||c==="constructor"||c==="prototype")return t;if(r!=a){var d=o[c];l=void 0,l===void 0&&(l=Be(d)?d:ys(e[r+1])?[]:{})}Dr(o,c,l),o=o[c]}return t}function Ey(t,e,n){for(var s=-1,r=e.length,i={};++s<r;){var a=e[s],o=jr(t,a);n(o,a)&&Ty(i,Rs(a,t),o)}return i}function ke(t,e){if(t==null)return{};var n=Ts(sE(t),function(s){return[s]});return e=Ls(e),Ey(t,n,function(s,r){return e(s,r[0])})}function yy(t,e){var n;return Is(t,function(s,r,i){return n=e(s,r,i),!n}),!!n}function Ay(t,e,n){var s=Q(t)?Fo:yy;return s(t,Ls(e))}function Sy(t){return Oy(t)?t.LABEL:t.name}function Oy(t){return Vn(t.LABEL)&&t.LABEL!==""}class we{get definition(){return this._definition}set definition(e){this._definition=e}constructor(e){this._definition=e}accept(e){e.visit(this),ry(this.definition,n=>{n.accept(e)})}}class se extends we{constructor(e){super([]),this.idx=1,Ce(this,ke(e,n=>n!==void 0))}set definition(e){}get definition(){return this.referencedRule!==void 0?this.referencedRule.definition:[]}accept(e){e.visit(this)}}class $t extends we{constructor(e){super(e.definition),this.orgText="",Ce(this,ke(e,n=>n!==void 0))}}class ee extends we{constructor(e){super(e.definition),this.ignoreAmbiguities=!1,Ce(this,ke(e,n=>n!==void 0))}}class Z extends we{constructor(e){super(e.definition),this.idx=1,Ce(this,ke(e,n=>n!==void 0))}}class xe extends we{constructor(e){super(e.definition),this.idx=1,Ce(this,ke(e,n=>n!==void 0))}}class Me extends we{constructor(e){super(e.definition),this.idx=1,Ce(this,ke(e,n=>n!==void 0))}}class G extends we{constructor(e){super(e.definition),this.idx=1,Ce(this,ke(e,n=>n!==void 0))}}class Se extends we{constructor(e){super(e.definition),this.idx=1,Ce(this,ke(e,n=>n!==void 0))}}class Oe extends we{get definition(){return this._definition}set definition(e){this._definition=e}constructor(e){super(e.definition),this.idx=1,this.ignoreAmbiguities=!1,this.hasPredicates=!1,Ce(this,ke(e,n=>n!==void 0))}}class ${constructor(e){this.idx=1,Ce(this,ke(e,n=>n!==void 0))}accept(e){e.visit(this)}}function Ry(t){return jo(t,kn)}function kn(t){function e(n){return jo(n,kn)}if(t instanceof se){const n={type:"NonTerminal",name:t.nonTerminalName,idx:t.idx};return Vn(t.label)&&(n.label=t.label),n}else{if(t instanceof ee)return{type:"Alternative",definition:e(t.definition)};if(t instanceof Z)return{type:"Option",idx:t.idx,definition:e(t.definition)};if(t instanceof xe)return{type:"RepetitionMandatory",idx:t.idx,definition:e(t.definition)};if(t instanceof Me)return{type:"RepetitionMandatoryWithSeparator",idx:t.idx,separator:kn(new $({terminalType:t.separator})),definition:e(t.definition)};if(t instanceof Se)return{type:"RepetitionWithSeparator",idx:t.idx,separator:kn(new $({terminalType:t.separator})),definition:e(t.definition)};if(t instanceof G)return{type:"Repetition",idx:t.idx,definition:e(t.definition)};if(t instanceof Oe)return{type:"Alternation",idx:t.idx,definition:e(t.definition)};if(t instanceof $){const n={type:"Terminal",name:t.terminalType.name,label:Sy(t.terminalType),idx:t.idx};Vn(t.label)&&(n.terminalLabel=t.label);const s=t.terminalType.PATTERN;return t.terminalType.PATTERN&&(n.pattern=my(s)?s.source:s),n}else{if(t instanceof $t)return{type:"Rule",name:t.name,orgText:t.orgText,definition:e(t.definition)};throw Error("non exhaustive match")}}}class Pt{visit(e){const n=e;switch(n.constructor){case se:return this.visitNonTerminal(n);case ee:return this.visitAlternative(n);case Z:return this.visitOption(n);case xe:return this.visitRepetitionMandatory(n);case Me:return this.visitRepetitionMandatoryWithSeparator(n);case Se:return this.visitRepetitionWithSeparator(n);case G:return this.visitRepetition(n);case Oe:return this.visitAlternation(n);case $:return this.visitTerminal(n);case $t:return this.visitRule(n);default:throw Error("non exhaustive match")}}visitNonTerminal(e){}visitAlternative(e){}visitOption(e){}visitRepetition(e){}visitRepetitionMandatory(e){}visitRepetitionMandatoryWithSeparator(e){}visitRepetitionWithSeparator(e){}visitAlternation(e){}visitTerminal(e){}visitRule(e){}}function Ly(t){return t instanceof ee||t instanceof Z||t instanceof G||t instanceof xe||t instanceof Me||t instanceof Se||t instanceof $||t instanceof $t}function Yn(t,e=[]){return t instanceof Z||t instanceof G||t instanceof Se?!0:t instanceof Oe?Ay(t.definition,s=>Yn(s,e)):t instanceof se&&fy(e,t)?!1:t instanceof we?(t instanceof se&&e.push(t),oy(t.definition,s=>Yn(s,e))):!1}function Iy(t){return t instanceof Oe}function Le(t){if(t instanceof se)return"SUBRULE";if(t instanceof Z)return"OPTION";if(t instanceof Oe)return"OR";if(t instanceof xe)return"AT_LEAST_ONE";if(t instanceof Me)return"AT_LEAST_ONE_SEP";if(t instanceof Se)return"MANY_SEP";if(t instanceof G)return"MANY";if(t instanceof $)return"CONSUME";throw Error("non exhaustive match")}class Ns{walk(e,n=[]){N(e.definition,(s,r)=>{const i=z(e.definition,r+1);if(s instanceof se)this.walkProdRef(s,i,n);else if(s instanceof $)this.walkTerminal(s,i,n);else if(s instanceof ee)this.walkFlat(s,i,n);else if(s instanceof Z)this.walkOption(s,i,n);else if(s instanceof xe)this.walkAtLeastOne(s,i,n);else if(s instanceof Me)this.walkAtLeastOneSep(s,i,n);else if(s instanceof Se)this.walkManySep(s,i,n);else if(s instanceof G)this.walkMany(s,i,n);else if(s instanceof Oe)this.walkOr(s,i,n);else throw Error("non exhaustive match")})}walkTerminal(e,n,s){}walkProdRef(e,n,s){}walkFlat(e,n,s){const r=n.concat(s);this.walk(e,r)}walkOption(e,n,s){const r=n.concat(s);this.walk(e,r)}walkAtLeastOne(e,n,s){const r=[new Z({definition:e.definition})].concat(n,s);this.walk(e,r)}walkAtLeastOneSep(e,n,s){const r=la(e,n,s);this.walk(e,r)}walkMany(e,n,s){const r=[new Z({definition:e.definition})].concat(n,s);this.walk(e,r)}walkManySep(e,n,s){const r=la(e,n,s);this.walk(e,r)}walkOr(e,n,s){const r=n.concat(s);N(e.definition,i=>{const a=new ee({definition:[i]});this.walk(a,r)})}}function la(t,e,n){return[new Z({definition:[new $({terminalType:t.separator})].concat(t.definition)})].concat(e,n)}function yn(t){if(t instanceof se)return yn(t.referencedRule);if(t instanceof $)return vy(t);if(Ly(t))return Ny(t);if(Iy(t))return by(t);throw Error("non exhaustive match")}function Ny(t){let e=[];const n=t.definition;let s=0,r=n.length>s,i,a=!0;for(;r&&a;)i=n[s],a=Yn(i),e=e.concat(yn(i)),s=s+1,r=n.length>s;return Ur(e)}function by(t){const e=S(t.definition,n=>yn(n));return Ur(Te(e))}function vy(t){return[t.terminalType]}const Ko="_~IN~_";class _y extends Ns{constructor(e){super(),this.topProd=e,this.follows={}}startWalking(){return this.walk(this.topProd),this.follows}walkTerminal(e,n,s){}walkProdRef(e,n,s){const r=ky(e.referencedRule,e.idx)+this.topProd.name,i=n.concat(s),a=new ee({definition:i}),o=yn(a);this.follows[r]=o}}function Cy(t){const e={};return N(t,n=>{const s=new _y(n).startWalking();qs(e,s)}),e}function ky(t,e){return t.name+e+Ko}function I(t){return t.charCodeAt(0)}function Gs(t,e){Array.isArray(t)?t.forEach(function(n){e.push(n)}):e.push(t)}function Kt(t,e){if(t[e]===!0)throw"duplicate flag "+e;t[e],t[e]=!0}function Rt(t){if(t===void 0)throw Error("Internal Error - Should never get here!");return!0}function wy(){throw Error("Internal Error - Should never get here!")}function ha(t){return t.type==="Character"}const Xn=[];for(let t=I("0");t<=I("9");t++)Xn.push(t);const qn=[I("_")].concat(Xn);for(let t=I("a");t<=I("z");t++)qn.push(t);for(let t=I("A");t<=I("Z");t++)qn.push(t);const ua=[I(" "),I("\f"),I(`
2
2
  `),I("\r"),I(" "),I("\v"),I(" "),I(" "),I(" "),I(" "),I(" "),I(" "),I(" "),I(" "),I(" "),I(" "),I(" "),I(" "),I(" "),I(" "),I("\u2028"),I("\u2029"),I(" "),I(" "),I(" "),I("\uFEFF")],xy=/[0-9a-fA-F]/,Nn=/[0-9]/,My=/[1-9]/;class $y{constructor(){this.idx=0,this.input="",this.groupIdx=0}saveState(){return{idx:this.idx,input:this.input,groupIdx:this.groupIdx}}restoreState(e){this.idx=e.idx,this.input=e.input,this.groupIdx=e.groupIdx}pattern(e){this.idx=0,this.input=e,this.groupIdx=0,this.consumeChar("/");const n=this.disjunction();this.consumeChar("/");const s={type:"Flags",loc:{begin:this.idx,end:e.length},global:!1,ignoreCase:!1,multiLine:!1,unicode:!1,sticky:!1};for(;this.isRegExpFlag();)switch(this.popChar()){case"g":Kt(s,"global");break;case"i":Kt(s,"ignoreCase");break;case"m":Kt(s,"multiLine");break;case"u":Kt(s,"unicode");break;case"y":Kt(s,"sticky");break}if(this.idx!==this.input.length)throw Error("Redundant input: "+this.input.substring(this.idx));return{type:"Pattern",flags:s,value:n,loc:this.loc(0)}}disjunction(){const e=[],n=this.idx;for(e.push(this.alternative());this.peekChar()==="|";)this.consumeChar("|"),e.push(this.alternative());return{type:"Disjunction",value:e,loc:this.loc(n)}}alternative(){const e=[],n=this.idx;for(;this.isTerm();)e.push(this.term());return{type:"Alternative",value:e,loc:this.loc(n)}}term(){return this.isAssertion()?this.assertion():this.atom()}assertion(){const e=this.idx;switch(this.popChar()){case"^":return{type:"StartAnchor",loc:this.loc(e)};case"$":return{type:"EndAnchor",loc:this.loc(e)};case"\\":switch(this.popChar()){case"b":return{type:"WordBoundary",loc:this.loc(e)};case"B":return{type:"NonWordBoundary",loc:this.loc(e)}}throw Error("Invalid Assertion Escape");case"(":this.consumeChar("?");let n;switch(this.popChar()){case"=":n="Lookahead";break;case"!":n="NegativeLookahead";break;case"<":{switch(this.popChar()){case"=":n="Lookbehind";break;case"!":n="NegativeLookbehind"}break}}Rt(n);const s=this.disjunction();return this.consumeChar(")"),{type:n,value:s,loc:this.loc(e)}}return wy()}quantifier(e=!1){let n;const s=this.idx;switch(this.popChar()){case"*":n={atLeast:0,atMost:1/0};break;case"+":n={atLeast:1,atMost:1/0};break;case"?":n={atLeast:0,atMost:1};break;case"{":const r=this.integerIncludingZero();switch(this.popChar()){case"}":n={atLeast:r,atMost:r};break;case",":let i;this.isDigit()?(i=this.integerIncludingZero(),n={atLeast:r,atMost:i}):n={atLeast:r,atMost:1/0},this.consumeChar("}");break}if(e===!0&&n===void 0)return;Rt(n);break}if(!(e===!0&&n===void 0)&&Rt(n))return this.peekChar(0)==="?"?(this.consumeChar("?"),n.greedy=!1):n.greedy=!0,n.type="Quantifier",n.loc=this.loc(s),n}atom(){let e;const n=this.idx;switch(this.peekChar()){case".":e=this.dotAll();break;case"\\":e=this.atomEscape();break;case"[":e=this.characterClass();break;case"(":e=this.group();break}if(e===void 0&&this.isPatternCharacter()&&(e=this.patternCharacter()),Rt(e))return e.loc=this.loc(n),this.isQuantifier()&&(e.quantifier=this.quantifier()),e}dotAll(){return this.consumeChar("."),{type:"Set",complement:!0,value:[I(`
3
3
  `),I("\r"),I("\u2028"),I("\u2029")]}}atomEscape(){switch(this.consumeChar("\\"),this.peekChar()){case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":return this.decimalEscapeAtom();case"d":case"D":case"s":case"S":case"w":case"W":return this.characterClassEscape();case"f":case"n":case"r":case"t":case"v":return this.controlEscapeAtom();case"c":return this.controlLetterEscapeAtom();case"0":return this.nulCharacterAtom();case"x":return this.hexEscapeSequenceAtom();case"u":return this.regExpUnicodeEscapeSequenceAtom();default:return this.identityEscapeAtom()}}decimalEscapeAtom(){return{type:"GroupBackReference",value:this.positiveInteger()}}characterClassEscape(){let e,n=!1;switch(this.popChar()){case"d":e=Xn;break;case"D":e=Xn,n=!0;break;case"s":e=ua;break;case"S":e=ua,n=!0;break;case"w":e=qn;break;case"W":e=qn,n=!0;break}if(Rt(e))return{type:"Set",value:e,complement:n}}controlEscapeAtom(){let e;switch(this.popChar()){case"f":e=I("\f");break;case"n":e=I(`
4
4
  `);break;case"r":e=I("\r");break;case"t":e=I(" ");break;case"v":e=I("\v");break}if(Rt(e))return{type:"Character",value:e}}controlLetterEscapeAtom(){this.consumeChar("c");const e=this.popChar();if(/[a-zA-Z]/.test(e)===!1)throw Error("Invalid ");return{type:"Character",value:e.toUpperCase().charCodeAt(0)-64}}nulCharacterAtom(){return this.consumeChar("0"),{type:"Character",value:I("\0")}}hexEscapeSequenceAtom(){return this.consumeChar("x"),this.parseHexDigits(2)}regExpUnicodeEscapeSequenceAtom(){return this.consumeChar("u"),this.parseHexDigits(4)}identityEscapeAtom(){const e=this.popChar();return{type:"Character",value:I(e)}}classPatternCharacterAtom(){switch(this.peekChar()){case`
@@ -1,4 +1,4 @@
1
- import{ax as Wt,s as Kt,g as Ht,t as Yt,q as Xt,a as Zt,b as Qt,_ as S,L as St,Q as Jt,k as rt,af as $t,a2 as te,a3 as ee,a4 as ne,d as se,A as ie,N as re,O as oe}from"./mermaid.core-C888eQE1.js";import"./index-DGq8BOVF.js";const It=(t,n)=>Wt(t,"a",-n),_t=1e-10;function st(t,n){const s=le(t),e=s.filter(l=>ae(l,t));let i=0,r=0;const o=[];if(e.length>1){const l=Et(e);for(let u=0;u<e.length;++u){const a=e[u];a.angle=Math.atan2(a.x-l.x,a.y-l.y)}e.sort((u,a)=>a.angle-u.angle);let h=e[e.length-1];for(let u=0;u<e.length;++u){const a=e[u];r+=(h.x+a.x)*(a.y-h.y);const p={x:(a.x+h.x)/2,y:(a.y+h.y)/2};let d=null;for(let m=0;m<a.parentIndex.length;++m)if(h.parentIndex.includes(a.parentIndex[m])){const y=t[a.parentIndex[m]],M=Math.atan2(a.x-y.x,a.y-y.y),E=Math.atan2(h.x-y.x,h.y-y.y);let T=E-M;T<0&&(T+=2*Math.PI);const w=E-T/2;let g=K(p,{x:y.x+y.radius*Math.sin(w),y:y.y+y.radius*Math.cos(w)});g>y.radius*2&&(g=y.radius*2),(d==null||d.width>g)&&(d={circle:y,width:g,p1:a,p2:h,large:g>y.radius,sweep:!0})}d!=null&&(o.push(d),i+=lt(d.circle.radius,d.width),h=a)}}else{let l=t[0];for(let u=1;u<t.length;++u)t[u].radius<l.radius&&(l=t[u]);let h=!1;for(let u=0;u<t.length;++u)if(K(t[u],l)>Math.abs(l.radius-t[u].radius)){h=!0;break}h?i=r=0:(i=l.radius*l.radius*Math.PI,o.push({circle:l,p1:{x:l.x,y:l.y+l.radius},p2:{x:l.x-_t,y:l.y+l.radius},width:l.radius*2,large:!0,sweep:!0}))}return r/=2,n&&(n.area=i+r,n.arcArea=i,n.polygonArea=r,n.arcs=o,n.innerPoints=e,n.intersectionPoints=s),i+r}function ae(t,n){return n.every(s=>K(t,s)<s.radius+_t)}function le(t){const n=[];for(let s=0;s<t.length;++s)for(let e=s+1;e<t.length;++e){const i=Tt(t[s],t[e]);for(const r of i)r.parentIndex=[s,e],n.push(r)}return n}function lt(t,n){return t*t*Math.acos(1-n/t)-(t-n)*Math.sqrt(n*(2*t-n))}function K(t,n){return Math.sqrt((t.x-n.x)*(t.x-n.x)+(t.y-n.y)*(t.y-n.y))}function xt(t,n,s){if(s>=t+n)return 0;if(s<=Math.abs(t-n))return Math.PI*Math.min(t,n)*Math.min(t,n);const e=t-(s*s-n*n+t*t)/(2*s),i=n-(s*s-t*t+n*n)/(2*s);return lt(t,e)+lt(n,i)}function Tt(t,n){const s=K(t,n),e=t.radius,i=n.radius;if(s>=e+i||s<=Math.abs(e-i))return[];const r=(e*e-i*i+s*s)/(2*s),o=Math.sqrt(e*e-r*r),l=t.x+r*(n.x-t.x)/s,h=t.y+r*(n.y-t.y)/s,u=-(n.y-t.y)*(o/s),a=-(n.x-t.x)*(o/s);return[{x:l+u,y:h-a},{x:l-u,y:h+a}]}function Et(t){const n={x:0,y:0};for(const s of t)n.x+=s.x,n.y+=s.y;return n.x/=t.length,n.y/=t.length,n}function ce(t,n,s,e){e=e||{};const i=e.maxIterations||100,r=e.tolerance||1e-10,o=t(n),l=t(s);let h=s-n;if(o*l>0)throw"Initial bisect points must have opposite signs";if(o===0)return n;if(l===0)return s;for(let u=0;u<i;++u){h/=2;const a=n+h,p=t(a);if(p*o>=0&&(n=a),Math.abs(h)<r||p===0)return a}return n+h}function ct(t){const n=new Array(t);for(let s=0;s<t;++s)n[s]=0;return n}function Mt(t,n){return ct(t).map(()=>ct(n))}function tt(t,n){let s=0;for(let e=0;e<t.length;++e)s+=t[e]*n[e];return s}function ut(t){return Math.sqrt(tt(t,t))}function ht(t,n,s){for(let e=0;e<n.length;++e)t[e]=n[e]*s}function Q(t,n,s,e,i){for(let r=0;r<t.length;++r)t[r]=n*s[r]+e*i[r]}function zt(t,n,s){s=s||{};const e=s.maxIterations||n.length*200,i=s.nonZeroDelta||1.05,r=s.zeroDelta||.001,o=s.minErrorDelta||1e-6,l=s.minErrorDelta||1e-5,h=s.rho!==void 0?s.rho:1,u=s.chi!==void 0?s.chi:2,a=s.psi!==void 0?s.psi:-.5,p=s.sigma!==void 0?s.sigma:.5;let d;const m=n.length,y=new Array(m+1);y[0]=n,y[0].fx=t(n),y[0].id=0;for(let v=0;v<m;++v){const c=n.slice();c[v]=c[v]?c[v]*i:r,y[v+1]=c,y[v+1].fx=t(c),y[v+1].id=v+1}function M(v){for(let c=0;c<v.length;c++)y[m][c]=v[c];y[m].fx=v.fx}const E=(v,c)=>v.fx-c.fx,T=n.slice(),w=n.slice(),g=n.slice(),b=n.slice();for(let v=0;v<e;++v){if(y.sort(E),s.history){const x=y.map(f=>{const N=f.slice();return N.fx=f.fx,N.id=f.id,N});x.sort((f,N)=>f.id-N.id),s.history.push({x:y[0].slice(),fx:y[0].fx,simplex:x})}d=0;for(let x=0;x<m;++x)d=Math.max(d,Math.abs(y[0][x]-y[1][x]));if(Math.abs(y[0].fx-y[m].fx)<o&&d<l)break;for(let x=0;x<m;++x){T[x]=0;for(let f=0;f<m;++f)T[x]+=y[f][x];T[x]/=m}const c=y[m];if(Q(w,1+h,T,-h,c),w.fx=t(w),w.fx<y[0].fx)Q(b,1+u,T,-u,c),b.fx=t(b),b.fx<w.fx?M(b):M(w);else if(w.fx>=y[m-1].fx){let x=!1;if(w.fx>c.fx?(Q(g,1+a,T,-a,c),g.fx=t(g),g.fx<c.fx?M(g):x=!0):(Q(g,1-a*h,T,a*h,c),g.fx=t(g),g.fx<w.fx?M(g):x=!0),x){if(p>=1)break;for(let f=1;f<y.length;++f)Q(y[f],1-p,y[0],p,y[f]),y[f].fx=t(y[f])}}else M(w)}return y.sort(E),{fx:y[0].fx,x:y[0]}}function ue(t,n,s,e,i,r,o){const l=s.fx,h=tt(s.fxprime,n);let u=l,a=l,p=h,d=0;i=i||1,r=r||1e-6,o=o||.1;function m(y,M,E){for(let T=0;T<16;++T)if(i=(y+M)/2,Q(e.x,1,s.x,i,n),u=e.fx=t(e.x,e.fxprime),p=tt(e.fxprime,n),u>l+r*i*h||u>=E)M=i;else{if(Math.abs(p)<=-o*h)return i;p*(M-y)>=0&&(M=y),y=i,E=u}return 0}for(let y=0;y<10;++y){if(Q(e.x,1,s.x,i,n),u=e.fx=t(e.x,e.fxprime),p=tt(e.fxprime,n),u>l+r*i*h||y&&u>=a)return m(d,i,a);if(Math.abs(p)<=-o*h)return i;if(p>=0)return m(i,d,u);a=u,d=i,i*=2}return i}function he(t,n,s){let e={x:n.slice(),fx:0,fxprime:n.slice()},i={x:n.slice(),fx:0,fxprime:n.slice()};const r=n.slice();let o,l,h=1,u;s=s||{},u=s.maxIterations||n.length*20,e.fx=t(e.x,e.fxprime),o=e.fxprime.slice(),ht(o,e.fxprime,-1);for(let a=0;a<u;++a){if(h=ue(t,o,e,i,h),s.history&&s.history.push({x:e.x.slice(),fx:e.fx,fxprime:e.fxprime.slice(),alpha:h}),!h)ht(o,e.fxprime,-1);else{Q(r,1,i.fxprime,-1,e.fxprime);const p=tt(e.fxprime,e.fxprime),d=Math.max(0,tt(r,i.fxprime)/p);Q(o,d,o,-1,i.fxprime),l=e,e=i,i=l}if(ut(e.fxprime)<=1e-5)break}return s.history&&s.history.push({x:e.x.slice(),fx:e.fx,fxprime:e.fxprime.slice(),alpha:h}),e}function At(t,n={}){n.maxIterations=n.maxIterations||500;const s=n.initialLayout||xe,e=n.lossFunction||et,i=fe(t,n),r=s(i,n),o=Object.keys(r),l=[];for(const a of o)l.push(r[a].x),l.push(r[a].y);const u=zt(a=>{const p={};for(let d=0;d<o.length;++d){const m=o[d];p[m]={x:a[2*d],y:a[2*d+1],radius:r[m].radius}}return e(p,i)},l,n).x;for(let a=0;a<o.length;++a){const p=o[a];r[p].x=u[2*a],r[p].y=u[2*a+1]}return r}const Rt=1e-10;function ft(t,n,s){return Math.min(t,n)*Math.min(t,n)*Math.PI<=s+Rt?Math.abs(t-n):ce(e=>xt(t,n,e)-s,0,t+n)}function fe(t,n={}){const s=n.distinct,e=t.map(l=>Object.assign({},l));function i(l){return l.join(";")}if(s){const l=new Map;for(const h of e)for(let u=0;u<h.sets.length;u++){const a=String(h.sets[u]);l.set(a,h.size+(l.get(a)||0));for(let p=u+1;p<h.sets.length;p++){const d=String(h.sets[p]),m=`${a};${d}`,y=`${d};${a}`;l.set(m,h.size+(l.get(m)||0)),l.set(y,h.size+(l.get(y)||0))}}for(const h of e)h.sets.length<3&&(h.size=l.get(i(h.sets)))}const r=[],o=new Set;for(const l of e)if(l.sets.length===1)r.push(l.sets[0]);else if(l.sets.length===2){const h=l.sets[0],u=l.sets[1];o.add(i(l.sets)),o.add(i([u,h]))}r.sort((l,h)=>l===h?0:l<h?-1:1);for(let l=0;l<r.length;++l){const h=r[l];for(let u=l+1;u<r.length;++u){const a=r[u];o.has(i([h,a]))||e.push({sets:[h,a],size:0})}}return e}function de(t,n,s){const e=Mt(n.length,n.length),i=Mt(n.length,n.length);return t.filter(r=>r.sets.length===2).forEach(r=>{const o=s[r.sets[0]],l=s[r.sets[1]],h=Math.sqrt(n[o].size/Math.PI),u=Math.sqrt(n[l].size/Math.PI),a=ft(h,u,r.size);e[o][l]=e[l][o]=a;let p=0;r.size+1e-10>=Math.min(n[o].size,n[l].size)?p=1:r.size<=1e-10&&(p=-1),i[o][l]=i[l][o]=p}),{distances:e,constraints:i}}function ge(t,n,s,e){for(let r=0;r<n.length;++r)n[r]=0;let i=0;for(let r=0;r<s.length;++r){const o=t[2*r],l=t[2*r+1];for(let h=r+1;h<s.length;++h){const u=t[2*h],a=t[2*h+1],p=s[r][h],d=e[r][h],m=(u-o)*(u-o)+(a-l)*(a-l),y=Math.sqrt(m),M=m-p*p;d>0&&y<=p||d<0&&y>=p||(i+=2*M*M,n[2*r]+=4*M*(o-u),n[2*r+1]+=4*M*(l-a),n[2*h]+=4*M*(u-o),n[2*h+1]+=4*M*(a-l))}}return i}function xe(t,n={}){let s=pe(t,n);const e=n.lossFunction||et;if(t.length>=8){const i=ye(t,n),r=e(i,t),o=e(s,t);r+1e-8<o&&(s=i)}return s}function ye(t,n={}){const s=n.restarts||10,e=[],i={};for(const d of t)d.sets.length===1&&(i[d.sets[0]]=e.length,e.push(d));let{distances:r,constraints:o}=de(t,e,i);const l=ut(r.map(ut))/r.length;r=r.map(d=>d.map(m=>m/l));const h=(d,m)=>ge(d,m,r,o);let u=null;for(let d=0;d<s;++d){const m=ct(r.length*2).map(Math.random),y=he(h,m,n);(!u||y.fx<u.fx)&&(u=y)}const a=u.x,p={};for(let d=0;d<e.length;++d){const m=e[d];p[m.sets[0]]={x:a[2*d]*l,y:a[2*d+1]*l,radius:Math.sqrt(m.size/Math.PI)}}if(n.history)for(const d of n.history)ht(d.x,l);return p}function pe(t,n){const s=n&&n.lossFunction?n.lossFunction:et,e={},i={};for(const p of t)if(p.sets.length===1){const d=p.sets[0];e[d]={x:1e10,y:1e10,rowid:e.length,size:p.size,radius:Math.sqrt(p.size/Math.PI)},i[d]=[]}t=t.filter(p=>p.sets.length===2);for(const p of t){let d=p.weight!=null?p.weight:1;const m=p.sets[0],y=p.sets[1];p.size+Rt>=Math.min(e[m].size,e[y].size)&&(d=0),i[m].push({set:y,size:p.size,weight:d}),i[y].push({set:m,size:p.size,weight:d})}const r=[];Object.keys(i).forEach(p=>{let d=0;for(let m=0;m<i[p].length;++m)d+=i[p][m].size*i[p][m].weight;r.push({set:p,size:d})});function o(p,d){return d.size-p.size}r.sort(o);const l={};function h(p){return p.set in l}function u(p,d){e[d].x=p.x,e[d].y=p.y,l[d]=!0}u({x:0,y:0},r[0].set);for(let p=1;p<r.length;++p){const d=r[p].set,m=i[d].filter(h),y=e[d];if(m.sort(o),m.length===0)throw"ERROR: missing pairwise overlap information";const M=[];for(var a=0;a<m.length;++a){const w=e[m[a].set],g=ft(y.radius,w.radius,m[a].size);M.push({x:w.x+g,y:w.y}),M.push({x:w.x-g,y:w.y}),M.push({y:w.y+g,x:w.x}),M.push({y:w.y-g,x:w.x});for(let b=a+1;b<m.length;++b){const v=e[m[b].set],c=ft(y.radius,v.radius,m[b].size),x=Tt({x:w.x,y:w.y,radius:g},{x:v.x,y:v.y,radius:c});M.push(...x)}}let E=1e50,T=M[0];for(const w of M){e[d].x=w.x,e[d].y=w.y;const g=s(e,t);g<E&&(E=g,T=w)}u(T,d)}return e}function et(t,n){let s=0;for(const e of n){if(e.sets.length===1)continue;let i;if(e.sets.length===2){const o=t[e.sets[0]],l=t[e.sets[1]];i=xt(o.radius,l.radius,K(o,l))}else i=st(e.sets.map(o=>t[o]));const r=e.weight!=null?e.weight:1;s+=r*(i-e.size)*(i-e.size)}return s}function Ct(t,n){let s=0;for(const e of n){if(e.sets.length===1)continue;let i;if(e.sets.length===2){const l=t[e.sets[0]],h=t[e.sets[1]];i=xt(l.radius,h.radius,K(l,h))}else i=st(e.sets.map(l=>t[l]));const r=e.weight!=null?e.weight:1,o=Math.log((i+1)/(e.size+1));s+=r*o*o}return s}function me(t,n,s){if(s==null?t.sort((i,r)=>r.radius-i.radius):t.sort(s),t.length>0){const i=t[0].x,r=t[0].y;for(const o of t)o.x-=i,o.y-=r}if(t.length===2&&K(t[0],t[1])<Math.abs(t[1].radius-t[0].radius)&&(t[1].x=t[0].x+t[0].radius-t[1].radius-1e-10,t[1].y=t[0].y),t.length>1){const i=Math.atan2(t[1].x,t[1].y)-n,r=Math.cos(i),o=Math.sin(i);for(const l of t){const h=l.x,u=l.y;l.x=r*h-o*u,l.y=o*h+r*u}}if(t.length>2){let i=Math.atan2(t[2].x,t[2].y)-n;for(;i<0;)i+=2*Math.PI;for(;i>2*Math.PI;)i-=2*Math.PI;if(i>Math.PI){const r=t[1].y/(1e-10+t[1].x);for(const o of t){var e=(o.x+r*o.y)/(1+r*r);o.x=2*e-o.x,o.y=2*e*r-o.y}}}}function be(t){t.forEach(i=>{i.parent=i});function n(i){return i.parent!==i&&(i.parent=n(i.parent)),i.parent}function s(i,r){const o=n(i),l=n(r);o.parent=l}for(let i=0;i<t.length;++i)for(let r=i+1;r<t.length;++r){const o=t[i].radius+t[r].radius;K(t[i],t[r])+1e-10<o&&s(t[r],t[i])}const e=new Map;for(let i=0;i<t.length;++i){const r=n(t[i]).parent.setid;e.has(r)||e.set(r,[]),e.get(r).push(t[i])}return t.forEach(i=>{delete i.parent}),Array.from(e.values())}function dt(t){const n=s=>{const e=t.reduce((r,o)=>Math.max(r,o[s]+o.radius),Number.NEGATIVE_INFINITY),i=t.reduce((r,o)=>Math.min(r,o[s]-o.radius),Number.POSITIVE_INFINITY);return{max:e,min:i}};return{xRange:n("x"),yRange:n("y")}}function Dt(t,n,s){n==null&&(n=Math.PI/2);let e=Ft(t).map(u=>Object.assign({},u));const i=be(e);for(const u of i){me(u,n,s);const a=dt(u);u.size=(a.xRange.max-a.xRange.min)*(a.yRange.max-a.yRange.min),u.bounds=a}i.sort((u,a)=>a.size-u.size),e=i[0];let r=e.bounds;const o=(r.xRange.max-r.xRange.min)/50;function l(u,a,p){if(!u)return;const d=u.bounds;let m,y;if(a)m=r.xRange.max-d.xRange.min+o;else{m=r.xRange.max-d.xRange.max;const M=(d.xRange.max-d.xRange.min)/2-(r.xRange.max-r.xRange.min)/2;M<0&&(m+=M)}if(p)y=r.yRange.max-d.yRange.min+o;else{y=r.yRange.max-d.yRange.max;const M=(d.yRange.max-d.yRange.min)/2-(r.yRange.max-r.yRange.min)/2;M<0&&(y+=M)}for(const M of u)M.x+=m,M.y+=y,e.push(M)}let h=1;for(;h<i.length;)l(i[h],!0,!1),l(i[h+1],!1,!0),l(i[h+2],!0,!0),h+=3,r=dt(e);return Ot(e)}function Nt(t,n,s,e,i){const r=Ft(t);n-=2*e,s-=2*e;const{xRange:o,yRange:l}=dt(r);if(o.max===o.min||l.max===l.min)return console.log("not scaling solution: zero size detected"),t;let h,u;if(i){const m=Math.sqrt(i/Math.PI)*2;h=n/m,u=s/m}else h=n/(o.max-o.min),u=s/(l.max-l.min);const a=Math.min(u,h),p=(n-(o.max-o.min)*a)/2,d=(s-(l.max-l.min)*a)/2;return Ot(r.map(m=>({radius:a*m.radius,x:e+p+(m.x-o.min)*a,y:e+d+(m.y-l.min)*a,setid:m.setid})))}function Ot(t){const n={};for(const s of t)n[s.setid]=s;return n}function Ft(t){return Object.keys(t).map(s=>Object.assign(t[s],{setid:s}))}function ve(t={}){let n=!1,s=600,e=350,i=15,r=1e3,o=Math.PI/2,l=!0,h=null,u=!0,a=!0,p=null,d=null,m=!1,y=null,M=t&&t.symmetricalTextCentre?t.symmetricalTextCentre:!1,E={},T=t&&t.colourScheme?t.colourScheme:t&&t.colorScheme?t.colorScheme:["#1f77b4","#ff7f0e","#2ca02c","#d62728","#9467bd","#8c564b","#e377c2","#7f7f7f","#bcbd22","#17becf"],w=0,g=function(x){if(x in E)return E[x];var f=E[x]=T[w];return w+=1,w>=T.length&&(w=0),f},b=At,v=et;function c(x){let f=x.datum();const N=new Set;f.forEach(k=>{k.size==0&&k.sets.length==1&&N.add(k.sets[0])}),f=f.filter(k=>!k.sets.some(C=>N.has(C)));let I={},D={};if(f.length>0){let k=b(f,{lossFunction:v,distinct:m});l&&(k=Dt(k,o,d)),I=Nt(k,s,e,i,h),D=Lt(I,f,M)}const X={};f.forEach(k=>{k.label&&(X[k.sets]=k.label)});function G(k){if(k.sets in X)return X[k.sets];if(k.sets.length==1)return""+k.sets[0]}x.selectAll("svg").data([I]).enter().append("svg");const B=x.select("svg");n?B.attr("viewBox",`0 0 ${s} ${e}`):B.attr("width",s).attr("height",e);const V={};let z=!1;B.selectAll(".venn-area path").each(function(k){const C=this.getAttribute("d");k.sets.length==1&&C&&!m&&(z=!0,V[k.sets[0]]=Me(C))});function q(k){return C=>{const H=k.sets.map(J=>{let W=V[J],Y=I[J];return W||(W={x:s/2,y:e/2,radius:1}),Y||(Y={x:s/2,y:e/2,radius:1}),{x:W.x*(1-C)+Y.x*C,y:W.y*(1-C)+Y.y*C,radius:W.radius*(1-C)+Y.radius*C}});return wt(H,y)}}const R=B.selectAll(".venn-area").data(f,k=>k.sets),O=R.enter().append("g").attr("class",k=>`venn-area venn-${k.sets.length==1?"circle":"intersection"}${k.colour||k.color?" venn-coloured":""}`).attr("data-venn-sets",k=>k.sets.join("_")),j=O.append("path"),L=O.append("text").attr("class","label").text(k=>G(k)).attr("text-anchor","middle").attr("dy",".35em").attr("x",s/2).attr("y",e/2);a&&(j.style("fill-opacity","0").filter(k=>k.sets.length==1).style("fill",k=>k.colour?k.colour:k.color?k.color:g(k.sets)).style("fill-opacity",".25"),L.style("fill",k=>k.colour||k.color?"#FFF":t.textFill?t.textFill:k.sets.length==1?g(k.sets):"#444"));function P(k){return typeof k.transition=="function"?k.transition("venn").duration(r):k}let _=x;z&&typeof _.transition=="function"?(_=P(x),_.selectAll("path").attrTween("d",q)):_.selectAll("path").attr("d",k=>wt(k.sets.map(C=>I[C])),y);const F=_.selectAll("text").filter(k=>k.sets in D).text(k=>G(k)).attr("x",k=>Math.floor(D[k.sets].x)).attr("y",k=>Math.floor(D[k.sets].y));u&&(z?"on"in F?F.on("end",ot(I,G)):F.each("end",ot(I,G)):F.each(ot(I,G)));const A=P(R.exit()).remove();typeof R.transition=="function"&&A.selectAll("path").attrTween("d",q);const Z=A.selectAll("text").attr("x",s/2).attr("y",e/2);return p!==null&&(L.style("font-size","0px"),F.style("font-size",p),Z.style("font-size","0px")),{circles:I,textCentres:D,nodes:R,enter:O,update:_,exit:A}}return c.wrap=function(x){return arguments.length?(u=x,c):u},c.useViewBox=function(){return n=!0,c},c.width=function(x){return arguments.length?(s=x,c):s},c.height=function(x){return arguments.length?(e=x,c):e},c.padding=function(x){return arguments.length?(i=x,c):i},c.distinct=function(x){return arguments.length?(m=x,c):m},c.colours=function(x){return arguments.length?(g=x,c):g},c.colors=function(x){return arguments.length?(g=x,c):g},c.fontSize=function(x){return arguments.length?(p=x,c):p},c.round=function(x){return arguments.length?(y=x,c):y},c.duration=function(x){return arguments.length?(r=x,c):r},c.layoutFunction=function(x){return arguments.length?(b=x,c):b},c.normalize=function(x){return arguments.length?(l=x,c):l},c.scaleToFit=function(x){return arguments.length?(h=x,c):h},c.styled=function(x){return arguments.length?(a=x,c):a},c.orientation=function(x){return arguments.length?(o=x,c):o},c.orientationOrder=function(x){return arguments.length?(d=x,c):d},c.lossFunction=function(x){return arguments.length?(v=x==="default"?et:x==="logRatio"?Ct:x,c):v},c}function ot(t,n){return function(s){const e=this,i=t[s.sets[0]].radius||50,r=n(s)||"",o=r.split(/\s+/).reverse(),h=(r.length+o.length)/3;let u=o.pop(),a=[u],p=0;const d=1.1;e.textContent=null;const m=[];function y(g){const b=e.ownerDocument.createElementNS(e.namespaceURI,"tspan");return b.textContent=g,m.push(b),e.append(b),b}let M=y(u);for(;u=o.pop(),!!u;){a.push(u);const g=a.join(" ");M.textContent=g,g.length>h&&M.getComputedTextLength()>i&&(a.pop(),M.textContent=a.join(" "),a=[u],M=y(u),p++)}const E=.35-p*d/2,T=e.getAttribute("x"),w=e.getAttribute("y");m.forEach((g,b)=>{g.setAttribute("x",T),g.setAttribute("y",w),g.setAttribute("dy",`${E+b*d}em`)})}}function at(t,n,s){let e=n[0].radius-K(n[0],t);for(let i=1;i<n.length;++i){const r=n[i].radius-K(n[i],t);r<=e&&(e=r)}for(let i=0;i<s.length;++i){const r=K(s[i],t)-s[i].radius;r<=e&&(e=r)}return e}function jt(t,n,s){const e=[];for(const a of t)e.push({x:a.x,y:a.y}),e.push({x:a.x+a.radius/2,y:a.y}),e.push({x:a.x-a.radius/2,y:a.y}),e.push({x:a.x,y:a.y+a.radius/2}),e.push({x:a.x,y:a.y-a.radius/2});let i=e[0],r=at(e[0],t,n);for(let a=1;a<e.length;++a){const p=at(e[a],t,n);p>=r&&(i=e[a],r=p)}const o=zt(a=>-1*at({x:a[0],y:a[1]},t,n),[i.x,i.y],{maxIterations:500,minErrorDelta:1e-10}).x,l={x:s?0:o[0],y:o[1]};let h=!0;for(const a of t)if(K(l,a)>a.radius){h=!1;break}for(const a of n)if(K(l,a)<a.radius){h=!1;break}if(h)return l;if(t.length==1)return{x:t[0].x,y:t[0].y};const u={};return st(t,u),u.arcs.length===0?{x:0,y:-1e3,disjoint:!0}:u.arcs.length==1?{x:u.arcs[0].circle.x,y:u.arcs[0].circle.y}:n.length?jt(t,[]):Et(u.arcs.map(a=>a.p1))}function ke(t){const n={},s=Object.keys(t);for(const e of s)n[e]=[];for(let e=0;e<s.length;e++){const i=s[e],r=t[i];for(let o=e+1;o<s.length;++o){const l=s[o],h=t[l],u=K(r,h);u+h.radius<=r.radius+1e-10?n[l].push(i):u+r.radius<=h.radius+1e-10&&n[i].push(l)}}return n}function Lt(t,n,s){const e={},i=ke(t);for(let r=0;r<n.length;++r){const o=n[r].sets,l={},h={};for(let d=0;d<o.length;++d){l[o[d]]=!0;const m=i[o[d]];for(let y=0;y<m.length;++y)h[m[y]]=!0}const u=[],a=[];for(let d in t)d in l?u.push(t[d]):d in h||a.push(t[d]);const p=jt(u,a,s);e[o]=p,p.disjoint&&n[r].size>0&&console.log("WARNING: area "+o+" not represented on screen")}return e}function Ie(t,n,s){const e=[];return e.push(`
1
+ import{ax as Wt,s as Kt,g as Ht,t as Yt,q as Xt,a as Zt,b as Qt,_ as S,L as St,Q as Jt,k as rt,af as $t,a2 as te,a3 as ee,a4 as ne,d as se,A as ie,N as re,O as oe}from"./mermaid.core-B1vpXQvD.js";import"./index-Bp8EjOaI.js";const It=(t,n)=>Wt(t,"a",-n),_t=1e-10;function st(t,n){const s=le(t),e=s.filter(l=>ae(l,t));let i=0,r=0;const o=[];if(e.length>1){const l=Et(e);for(let u=0;u<e.length;++u){const a=e[u];a.angle=Math.atan2(a.x-l.x,a.y-l.y)}e.sort((u,a)=>a.angle-u.angle);let h=e[e.length-1];for(let u=0;u<e.length;++u){const a=e[u];r+=(h.x+a.x)*(a.y-h.y);const p={x:(a.x+h.x)/2,y:(a.y+h.y)/2};let d=null;for(let m=0;m<a.parentIndex.length;++m)if(h.parentIndex.includes(a.parentIndex[m])){const y=t[a.parentIndex[m]],M=Math.atan2(a.x-y.x,a.y-y.y),E=Math.atan2(h.x-y.x,h.y-y.y);let T=E-M;T<0&&(T+=2*Math.PI);const w=E-T/2;let g=K(p,{x:y.x+y.radius*Math.sin(w),y:y.y+y.radius*Math.cos(w)});g>y.radius*2&&(g=y.radius*2),(d==null||d.width>g)&&(d={circle:y,width:g,p1:a,p2:h,large:g>y.radius,sweep:!0})}d!=null&&(o.push(d),i+=lt(d.circle.radius,d.width),h=a)}}else{let l=t[0];for(let u=1;u<t.length;++u)t[u].radius<l.radius&&(l=t[u]);let h=!1;for(let u=0;u<t.length;++u)if(K(t[u],l)>Math.abs(l.radius-t[u].radius)){h=!0;break}h?i=r=0:(i=l.radius*l.radius*Math.PI,o.push({circle:l,p1:{x:l.x,y:l.y+l.radius},p2:{x:l.x-_t,y:l.y+l.radius},width:l.radius*2,large:!0,sweep:!0}))}return r/=2,n&&(n.area=i+r,n.arcArea=i,n.polygonArea=r,n.arcs=o,n.innerPoints=e,n.intersectionPoints=s),i+r}function ae(t,n){return n.every(s=>K(t,s)<s.radius+_t)}function le(t){const n=[];for(let s=0;s<t.length;++s)for(let e=s+1;e<t.length;++e){const i=Tt(t[s],t[e]);for(const r of i)r.parentIndex=[s,e],n.push(r)}return n}function lt(t,n){return t*t*Math.acos(1-n/t)-(t-n)*Math.sqrt(n*(2*t-n))}function K(t,n){return Math.sqrt((t.x-n.x)*(t.x-n.x)+(t.y-n.y)*(t.y-n.y))}function xt(t,n,s){if(s>=t+n)return 0;if(s<=Math.abs(t-n))return Math.PI*Math.min(t,n)*Math.min(t,n);const e=t-(s*s-n*n+t*t)/(2*s),i=n-(s*s-t*t+n*n)/(2*s);return lt(t,e)+lt(n,i)}function Tt(t,n){const s=K(t,n),e=t.radius,i=n.radius;if(s>=e+i||s<=Math.abs(e-i))return[];const r=(e*e-i*i+s*s)/(2*s),o=Math.sqrt(e*e-r*r),l=t.x+r*(n.x-t.x)/s,h=t.y+r*(n.y-t.y)/s,u=-(n.y-t.y)*(o/s),a=-(n.x-t.x)*(o/s);return[{x:l+u,y:h-a},{x:l-u,y:h+a}]}function Et(t){const n={x:0,y:0};for(const s of t)n.x+=s.x,n.y+=s.y;return n.x/=t.length,n.y/=t.length,n}function ce(t,n,s,e){e=e||{};const i=e.maxIterations||100,r=e.tolerance||1e-10,o=t(n),l=t(s);let h=s-n;if(o*l>0)throw"Initial bisect points must have opposite signs";if(o===0)return n;if(l===0)return s;for(let u=0;u<i;++u){h/=2;const a=n+h,p=t(a);if(p*o>=0&&(n=a),Math.abs(h)<r||p===0)return a}return n+h}function ct(t){const n=new Array(t);for(let s=0;s<t;++s)n[s]=0;return n}function Mt(t,n){return ct(t).map(()=>ct(n))}function tt(t,n){let s=0;for(let e=0;e<t.length;++e)s+=t[e]*n[e];return s}function ut(t){return Math.sqrt(tt(t,t))}function ht(t,n,s){for(let e=0;e<n.length;++e)t[e]=n[e]*s}function Q(t,n,s,e,i){for(let r=0;r<t.length;++r)t[r]=n*s[r]+e*i[r]}function zt(t,n,s){s=s||{};const e=s.maxIterations||n.length*200,i=s.nonZeroDelta||1.05,r=s.zeroDelta||.001,o=s.minErrorDelta||1e-6,l=s.minErrorDelta||1e-5,h=s.rho!==void 0?s.rho:1,u=s.chi!==void 0?s.chi:2,a=s.psi!==void 0?s.psi:-.5,p=s.sigma!==void 0?s.sigma:.5;let d;const m=n.length,y=new Array(m+1);y[0]=n,y[0].fx=t(n),y[0].id=0;for(let v=0;v<m;++v){const c=n.slice();c[v]=c[v]?c[v]*i:r,y[v+1]=c,y[v+1].fx=t(c),y[v+1].id=v+1}function M(v){for(let c=0;c<v.length;c++)y[m][c]=v[c];y[m].fx=v.fx}const E=(v,c)=>v.fx-c.fx,T=n.slice(),w=n.slice(),g=n.slice(),b=n.slice();for(let v=0;v<e;++v){if(y.sort(E),s.history){const x=y.map(f=>{const N=f.slice();return N.fx=f.fx,N.id=f.id,N});x.sort((f,N)=>f.id-N.id),s.history.push({x:y[0].slice(),fx:y[0].fx,simplex:x})}d=0;for(let x=0;x<m;++x)d=Math.max(d,Math.abs(y[0][x]-y[1][x]));if(Math.abs(y[0].fx-y[m].fx)<o&&d<l)break;for(let x=0;x<m;++x){T[x]=0;for(let f=0;f<m;++f)T[x]+=y[f][x];T[x]/=m}const c=y[m];if(Q(w,1+h,T,-h,c),w.fx=t(w),w.fx<y[0].fx)Q(b,1+u,T,-u,c),b.fx=t(b),b.fx<w.fx?M(b):M(w);else if(w.fx>=y[m-1].fx){let x=!1;if(w.fx>c.fx?(Q(g,1+a,T,-a,c),g.fx=t(g),g.fx<c.fx?M(g):x=!0):(Q(g,1-a*h,T,a*h,c),g.fx=t(g),g.fx<w.fx?M(g):x=!0),x){if(p>=1)break;for(let f=1;f<y.length;++f)Q(y[f],1-p,y[0],p,y[f]),y[f].fx=t(y[f])}}else M(w)}return y.sort(E),{fx:y[0].fx,x:y[0]}}function ue(t,n,s,e,i,r,o){const l=s.fx,h=tt(s.fxprime,n);let u=l,a=l,p=h,d=0;i=i||1,r=r||1e-6,o=o||.1;function m(y,M,E){for(let T=0;T<16;++T)if(i=(y+M)/2,Q(e.x,1,s.x,i,n),u=e.fx=t(e.x,e.fxprime),p=tt(e.fxprime,n),u>l+r*i*h||u>=E)M=i;else{if(Math.abs(p)<=-o*h)return i;p*(M-y)>=0&&(M=y),y=i,E=u}return 0}for(let y=0;y<10;++y){if(Q(e.x,1,s.x,i,n),u=e.fx=t(e.x,e.fxprime),p=tt(e.fxprime,n),u>l+r*i*h||y&&u>=a)return m(d,i,a);if(Math.abs(p)<=-o*h)return i;if(p>=0)return m(i,d,u);a=u,d=i,i*=2}return i}function he(t,n,s){let e={x:n.slice(),fx:0,fxprime:n.slice()},i={x:n.slice(),fx:0,fxprime:n.slice()};const r=n.slice();let o,l,h=1,u;s=s||{},u=s.maxIterations||n.length*20,e.fx=t(e.x,e.fxprime),o=e.fxprime.slice(),ht(o,e.fxprime,-1);for(let a=0;a<u;++a){if(h=ue(t,o,e,i,h),s.history&&s.history.push({x:e.x.slice(),fx:e.fx,fxprime:e.fxprime.slice(),alpha:h}),!h)ht(o,e.fxprime,-1);else{Q(r,1,i.fxprime,-1,e.fxprime);const p=tt(e.fxprime,e.fxprime),d=Math.max(0,tt(r,i.fxprime)/p);Q(o,d,o,-1,i.fxprime),l=e,e=i,i=l}if(ut(e.fxprime)<=1e-5)break}return s.history&&s.history.push({x:e.x.slice(),fx:e.fx,fxprime:e.fxprime.slice(),alpha:h}),e}function At(t,n={}){n.maxIterations=n.maxIterations||500;const s=n.initialLayout||xe,e=n.lossFunction||et,i=fe(t,n),r=s(i,n),o=Object.keys(r),l=[];for(const a of o)l.push(r[a].x),l.push(r[a].y);const u=zt(a=>{const p={};for(let d=0;d<o.length;++d){const m=o[d];p[m]={x:a[2*d],y:a[2*d+1],radius:r[m].radius}}return e(p,i)},l,n).x;for(let a=0;a<o.length;++a){const p=o[a];r[p].x=u[2*a],r[p].y=u[2*a+1]}return r}const Rt=1e-10;function ft(t,n,s){return Math.min(t,n)*Math.min(t,n)*Math.PI<=s+Rt?Math.abs(t-n):ce(e=>xt(t,n,e)-s,0,t+n)}function fe(t,n={}){const s=n.distinct,e=t.map(l=>Object.assign({},l));function i(l){return l.join(";")}if(s){const l=new Map;for(const h of e)for(let u=0;u<h.sets.length;u++){const a=String(h.sets[u]);l.set(a,h.size+(l.get(a)||0));for(let p=u+1;p<h.sets.length;p++){const d=String(h.sets[p]),m=`${a};${d}`,y=`${d};${a}`;l.set(m,h.size+(l.get(m)||0)),l.set(y,h.size+(l.get(y)||0))}}for(const h of e)h.sets.length<3&&(h.size=l.get(i(h.sets)))}const r=[],o=new Set;for(const l of e)if(l.sets.length===1)r.push(l.sets[0]);else if(l.sets.length===2){const h=l.sets[0],u=l.sets[1];o.add(i(l.sets)),o.add(i([u,h]))}r.sort((l,h)=>l===h?0:l<h?-1:1);for(let l=0;l<r.length;++l){const h=r[l];for(let u=l+1;u<r.length;++u){const a=r[u];o.has(i([h,a]))||e.push({sets:[h,a],size:0})}}return e}function de(t,n,s){const e=Mt(n.length,n.length),i=Mt(n.length,n.length);return t.filter(r=>r.sets.length===2).forEach(r=>{const o=s[r.sets[0]],l=s[r.sets[1]],h=Math.sqrt(n[o].size/Math.PI),u=Math.sqrt(n[l].size/Math.PI),a=ft(h,u,r.size);e[o][l]=e[l][o]=a;let p=0;r.size+1e-10>=Math.min(n[o].size,n[l].size)?p=1:r.size<=1e-10&&(p=-1),i[o][l]=i[l][o]=p}),{distances:e,constraints:i}}function ge(t,n,s,e){for(let r=0;r<n.length;++r)n[r]=0;let i=0;for(let r=0;r<s.length;++r){const o=t[2*r],l=t[2*r+1];for(let h=r+1;h<s.length;++h){const u=t[2*h],a=t[2*h+1],p=s[r][h],d=e[r][h],m=(u-o)*(u-o)+(a-l)*(a-l),y=Math.sqrt(m),M=m-p*p;d>0&&y<=p||d<0&&y>=p||(i+=2*M*M,n[2*r]+=4*M*(o-u),n[2*r+1]+=4*M*(l-a),n[2*h]+=4*M*(u-o),n[2*h+1]+=4*M*(a-l))}}return i}function xe(t,n={}){let s=pe(t,n);const e=n.lossFunction||et;if(t.length>=8){const i=ye(t,n),r=e(i,t),o=e(s,t);r+1e-8<o&&(s=i)}return s}function ye(t,n={}){const s=n.restarts||10,e=[],i={};for(const d of t)d.sets.length===1&&(i[d.sets[0]]=e.length,e.push(d));let{distances:r,constraints:o}=de(t,e,i);const l=ut(r.map(ut))/r.length;r=r.map(d=>d.map(m=>m/l));const h=(d,m)=>ge(d,m,r,o);let u=null;for(let d=0;d<s;++d){const m=ct(r.length*2).map(Math.random),y=he(h,m,n);(!u||y.fx<u.fx)&&(u=y)}const a=u.x,p={};for(let d=0;d<e.length;++d){const m=e[d];p[m.sets[0]]={x:a[2*d]*l,y:a[2*d+1]*l,radius:Math.sqrt(m.size/Math.PI)}}if(n.history)for(const d of n.history)ht(d.x,l);return p}function pe(t,n){const s=n&&n.lossFunction?n.lossFunction:et,e={},i={};for(const p of t)if(p.sets.length===1){const d=p.sets[0];e[d]={x:1e10,y:1e10,rowid:e.length,size:p.size,radius:Math.sqrt(p.size/Math.PI)},i[d]=[]}t=t.filter(p=>p.sets.length===2);for(const p of t){let d=p.weight!=null?p.weight:1;const m=p.sets[0],y=p.sets[1];p.size+Rt>=Math.min(e[m].size,e[y].size)&&(d=0),i[m].push({set:y,size:p.size,weight:d}),i[y].push({set:m,size:p.size,weight:d})}const r=[];Object.keys(i).forEach(p=>{let d=0;for(let m=0;m<i[p].length;++m)d+=i[p][m].size*i[p][m].weight;r.push({set:p,size:d})});function o(p,d){return d.size-p.size}r.sort(o);const l={};function h(p){return p.set in l}function u(p,d){e[d].x=p.x,e[d].y=p.y,l[d]=!0}u({x:0,y:0},r[0].set);for(let p=1;p<r.length;++p){const d=r[p].set,m=i[d].filter(h),y=e[d];if(m.sort(o),m.length===0)throw"ERROR: missing pairwise overlap information";const M=[];for(var a=0;a<m.length;++a){const w=e[m[a].set],g=ft(y.radius,w.radius,m[a].size);M.push({x:w.x+g,y:w.y}),M.push({x:w.x-g,y:w.y}),M.push({y:w.y+g,x:w.x}),M.push({y:w.y-g,x:w.x});for(let b=a+1;b<m.length;++b){const v=e[m[b].set],c=ft(y.radius,v.radius,m[b].size),x=Tt({x:w.x,y:w.y,radius:g},{x:v.x,y:v.y,radius:c});M.push(...x)}}let E=1e50,T=M[0];for(const w of M){e[d].x=w.x,e[d].y=w.y;const g=s(e,t);g<E&&(E=g,T=w)}u(T,d)}return e}function et(t,n){let s=0;for(const e of n){if(e.sets.length===1)continue;let i;if(e.sets.length===2){const o=t[e.sets[0]],l=t[e.sets[1]];i=xt(o.radius,l.radius,K(o,l))}else i=st(e.sets.map(o=>t[o]));const r=e.weight!=null?e.weight:1;s+=r*(i-e.size)*(i-e.size)}return s}function Ct(t,n){let s=0;for(const e of n){if(e.sets.length===1)continue;let i;if(e.sets.length===2){const l=t[e.sets[0]],h=t[e.sets[1]];i=xt(l.radius,h.radius,K(l,h))}else i=st(e.sets.map(l=>t[l]));const r=e.weight!=null?e.weight:1,o=Math.log((i+1)/(e.size+1));s+=r*o*o}return s}function me(t,n,s){if(s==null?t.sort((i,r)=>r.radius-i.radius):t.sort(s),t.length>0){const i=t[0].x,r=t[0].y;for(const o of t)o.x-=i,o.y-=r}if(t.length===2&&K(t[0],t[1])<Math.abs(t[1].radius-t[0].radius)&&(t[1].x=t[0].x+t[0].radius-t[1].radius-1e-10,t[1].y=t[0].y),t.length>1){const i=Math.atan2(t[1].x,t[1].y)-n,r=Math.cos(i),o=Math.sin(i);for(const l of t){const h=l.x,u=l.y;l.x=r*h-o*u,l.y=o*h+r*u}}if(t.length>2){let i=Math.atan2(t[2].x,t[2].y)-n;for(;i<0;)i+=2*Math.PI;for(;i>2*Math.PI;)i-=2*Math.PI;if(i>Math.PI){const r=t[1].y/(1e-10+t[1].x);for(const o of t){var e=(o.x+r*o.y)/(1+r*r);o.x=2*e-o.x,o.y=2*e*r-o.y}}}}function be(t){t.forEach(i=>{i.parent=i});function n(i){return i.parent!==i&&(i.parent=n(i.parent)),i.parent}function s(i,r){const o=n(i),l=n(r);o.parent=l}for(let i=0;i<t.length;++i)for(let r=i+1;r<t.length;++r){const o=t[i].radius+t[r].radius;K(t[i],t[r])+1e-10<o&&s(t[r],t[i])}const e=new Map;for(let i=0;i<t.length;++i){const r=n(t[i]).parent.setid;e.has(r)||e.set(r,[]),e.get(r).push(t[i])}return t.forEach(i=>{delete i.parent}),Array.from(e.values())}function dt(t){const n=s=>{const e=t.reduce((r,o)=>Math.max(r,o[s]+o.radius),Number.NEGATIVE_INFINITY),i=t.reduce((r,o)=>Math.min(r,o[s]-o.radius),Number.POSITIVE_INFINITY);return{max:e,min:i}};return{xRange:n("x"),yRange:n("y")}}function Dt(t,n,s){n==null&&(n=Math.PI/2);let e=Ft(t).map(u=>Object.assign({},u));const i=be(e);for(const u of i){me(u,n,s);const a=dt(u);u.size=(a.xRange.max-a.xRange.min)*(a.yRange.max-a.yRange.min),u.bounds=a}i.sort((u,a)=>a.size-u.size),e=i[0];let r=e.bounds;const o=(r.xRange.max-r.xRange.min)/50;function l(u,a,p){if(!u)return;const d=u.bounds;let m,y;if(a)m=r.xRange.max-d.xRange.min+o;else{m=r.xRange.max-d.xRange.max;const M=(d.xRange.max-d.xRange.min)/2-(r.xRange.max-r.xRange.min)/2;M<0&&(m+=M)}if(p)y=r.yRange.max-d.yRange.min+o;else{y=r.yRange.max-d.yRange.max;const M=(d.yRange.max-d.yRange.min)/2-(r.yRange.max-r.yRange.min)/2;M<0&&(y+=M)}for(const M of u)M.x+=m,M.y+=y,e.push(M)}let h=1;for(;h<i.length;)l(i[h],!0,!1),l(i[h+1],!1,!0),l(i[h+2],!0,!0),h+=3,r=dt(e);return Ot(e)}function Nt(t,n,s,e,i){const r=Ft(t);n-=2*e,s-=2*e;const{xRange:o,yRange:l}=dt(r);if(o.max===o.min||l.max===l.min)return console.log("not scaling solution: zero size detected"),t;let h,u;if(i){const m=Math.sqrt(i/Math.PI)*2;h=n/m,u=s/m}else h=n/(o.max-o.min),u=s/(l.max-l.min);const a=Math.min(u,h),p=(n-(o.max-o.min)*a)/2,d=(s-(l.max-l.min)*a)/2;return Ot(r.map(m=>({radius:a*m.radius,x:e+p+(m.x-o.min)*a,y:e+d+(m.y-l.min)*a,setid:m.setid})))}function Ot(t){const n={};for(const s of t)n[s.setid]=s;return n}function Ft(t){return Object.keys(t).map(s=>Object.assign(t[s],{setid:s}))}function ve(t={}){let n=!1,s=600,e=350,i=15,r=1e3,o=Math.PI/2,l=!0,h=null,u=!0,a=!0,p=null,d=null,m=!1,y=null,M=t&&t.symmetricalTextCentre?t.symmetricalTextCentre:!1,E={},T=t&&t.colourScheme?t.colourScheme:t&&t.colorScheme?t.colorScheme:["#1f77b4","#ff7f0e","#2ca02c","#d62728","#9467bd","#8c564b","#e377c2","#7f7f7f","#bcbd22","#17becf"],w=0,g=function(x){if(x in E)return E[x];var f=E[x]=T[w];return w+=1,w>=T.length&&(w=0),f},b=At,v=et;function c(x){let f=x.datum();const N=new Set;f.forEach(k=>{k.size==0&&k.sets.length==1&&N.add(k.sets[0])}),f=f.filter(k=>!k.sets.some(C=>N.has(C)));let I={},D={};if(f.length>0){let k=b(f,{lossFunction:v,distinct:m});l&&(k=Dt(k,o,d)),I=Nt(k,s,e,i,h),D=Lt(I,f,M)}const X={};f.forEach(k=>{k.label&&(X[k.sets]=k.label)});function G(k){if(k.sets in X)return X[k.sets];if(k.sets.length==1)return""+k.sets[0]}x.selectAll("svg").data([I]).enter().append("svg");const B=x.select("svg");n?B.attr("viewBox",`0 0 ${s} ${e}`):B.attr("width",s).attr("height",e);const V={};let z=!1;B.selectAll(".venn-area path").each(function(k){const C=this.getAttribute("d");k.sets.length==1&&C&&!m&&(z=!0,V[k.sets[0]]=Me(C))});function q(k){return C=>{const H=k.sets.map(J=>{let W=V[J],Y=I[J];return W||(W={x:s/2,y:e/2,radius:1}),Y||(Y={x:s/2,y:e/2,radius:1}),{x:W.x*(1-C)+Y.x*C,y:W.y*(1-C)+Y.y*C,radius:W.radius*(1-C)+Y.radius*C}});return wt(H,y)}}const R=B.selectAll(".venn-area").data(f,k=>k.sets),O=R.enter().append("g").attr("class",k=>`venn-area venn-${k.sets.length==1?"circle":"intersection"}${k.colour||k.color?" venn-coloured":""}`).attr("data-venn-sets",k=>k.sets.join("_")),j=O.append("path"),L=O.append("text").attr("class","label").text(k=>G(k)).attr("text-anchor","middle").attr("dy",".35em").attr("x",s/2).attr("y",e/2);a&&(j.style("fill-opacity","0").filter(k=>k.sets.length==1).style("fill",k=>k.colour?k.colour:k.color?k.color:g(k.sets)).style("fill-opacity",".25"),L.style("fill",k=>k.colour||k.color?"#FFF":t.textFill?t.textFill:k.sets.length==1?g(k.sets):"#444"));function P(k){return typeof k.transition=="function"?k.transition("venn").duration(r):k}let _=x;z&&typeof _.transition=="function"?(_=P(x),_.selectAll("path").attrTween("d",q)):_.selectAll("path").attr("d",k=>wt(k.sets.map(C=>I[C])),y);const F=_.selectAll("text").filter(k=>k.sets in D).text(k=>G(k)).attr("x",k=>Math.floor(D[k.sets].x)).attr("y",k=>Math.floor(D[k.sets].y));u&&(z?"on"in F?F.on("end",ot(I,G)):F.each("end",ot(I,G)):F.each(ot(I,G)));const A=P(R.exit()).remove();typeof R.transition=="function"&&A.selectAll("path").attrTween("d",q);const Z=A.selectAll("text").attr("x",s/2).attr("y",e/2);return p!==null&&(L.style("font-size","0px"),F.style("font-size",p),Z.style("font-size","0px")),{circles:I,textCentres:D,nodes:R,enter:O,update:_,exit:A}}return c.wrap=function(x){return arguments.length?(u=x,c):u},c.useViewBox=function(){return n=!0,c},c.width=function(x){return arguments.length?(s=x,c):s},c.height=function(x){return arguments.length?(e=x,c):e},c.padding=function(x){return arguments.length?(i=x,c):i},c.distinct=function(x){return arguments.length?(m=x,c):m},c.colours=function(x){return arguments.length?(g=x,c):g},c.colors=function(x){return arguments.length?(g=x,c):g},c.fontSize=function(x){return arguments.length?(p=x,c):p},c.round=function(x){return arguments.length?(y=x,c):y},c.duration=function(x){return arguments.length?(r=x,c):r},c.layoutFunction=function(x){return arguments.length?(b=x,c):b},c.normalize=function(x){return arguments.length?(l=x,c):l},c.scaleToFit=function(x){return arguments.length?(h=x,c):h},c.styled=function(x){return arguments.length?(a=x,c):a},c.orientation=function(x){return arguments.length?(o=x,c):o},c.orientationOrder=function(x){return arguments.length?(d=x,c):d},c.lossFunction=function(x){return arguments.length?(v=x==="default"?et:x==="logRatio"?Ct:x,c):v},c}function ot(t,n){return function(s){const e=this,i=t[s.sets[0]].radius||50,r=n(s)||"",o=r.split(/\s+/).reverse(),h=(r.length+o.length)/3;let u=o.pop(),a=[u],p=0;const d=1.1;e.textContent=null;const m=[];function y(g){const b=e.ownerDocument.createElementNS(e.namespaceURI,"tspan");return b.textContent=g,m.push(b),e.append(b),b}let M=y(u);for(;u=o.pop(),!!u;){a.push(u);const g=a.join(" ");M.textContent=g,g.length>h&&M.getComputedTextLength()>i&&(a.pop(),M.textContent=a.join(" "),a=[u],M=y(u),p++)}const E=.35-p*d/2,T=e.getAttribute("x"),w=e.getAttribute("y");m.forEach((g,b)=>{g.setAttribute("x",T),g.setAttribute("y",w),g.setAttribute("dy",`${E+b*d}em`)})}}function at(t,n,s){let e=n[0].radius-K(n[0],t);for(let i=1;i<n.length;++i){const r=n[i].radius-K(n[i],t);r<=e&&(e=r)}for(let i=0;i<s.length;++i){const r=K(s[i],t)-s[i].radius;r<=e&&(e=r)}return e}function jt(t,n,s){const e=[];for(const a of t)e.push({x:a.x,y:a.y}),e.push({x:a.x+a.radius/2,y:a.y}),e.push({x:a.x-a.radius/2,y:a.y}),e.push({x:a.x,y:a.y+a.radius/2}),e.push({x:a.x,y:a.y-a.radius/2});let i=e[0],r=at(e[0],t,n);for(let a=1;a<e.length;++a){const p=at(e[a],t,n);p>=r&&(i=e[a],r=p)}const o=zt(a=>-1*at({x:a[0],y:a[1]},t,n),[i.x,i.y],{maxIterations:500,minErrorDelta:1e-10}).x,l={x:s?0:o[0],y:o[1]};let h=!0;for(const a of t)if(K(l,a)>a.radius){h=!1;break}for(const a of n)if(K(l,a)<a.radius){h=!1;break}if(h)return l;if(t.length==1)return{x:t[0].x,y:t[0].y};const u={};return st(t,u),u.arcs.length===0?{x:0,y:-1e3,disjoint:!0}:u.arcs.length==1?{x:u.arcs[0].circle.x,y:u.arcs[0].circle.y}:n.length?jt(t,[]):Et(u.arcs.map(a=>a.p1))}function ke(t){const n={},s=Object.keys(t);for(const e of s)n[e]=[];for(let e=0;e<s.length;e++){const i=s[e],r=t[i];for(let o=e+1;o<s.length;++o){const l=s[o],h=t[l],u=K(r,h);u+h.radius<=r.radius+1e-10?n[l].push(i):u+r.radius<=h.radius+1e-10&&n[i].push(l)}}return n}function Lt(t,n,s){const e={},i=ke(t);for(let r=0;r<n.length;++r){const o=n[r].sets,l={},h={};for(let d=0;d<o.length;++d){l[o[d]]=!0;const m=i[o[d]];for(let y=0;y<m.length;++y)h[m[y]]=!0}const u=[],a=[];for(let d in t)d in l?u.push(t[d]):d in h||a.push(t[d]);const p=jt(u,a,s);e[o]=p,p.disjoint&&n[r].size>0&&console.log("WARNING: area "+o+" not represented on screen")}return e}function Ie(t,n,s){const e=[];return e.push(`
2
2
  M`,t,n),e.push(`
3
3
  m`,-s,0),e.push(`
4
4
  a`,s,s,0,1,0,s*2,0),e.push(`
@@ -1,4 +1,4 @@
1
- import{p as Lt}from"./chunk-JWPE2WC7-CkLRmEro.js";import{s as zt,g as Tt,t as At,q as Xt,a as Et,b as Yt,_ as y,R as It,L as Bt,N as K,l as et,Q as Ft,d as Rt,A as Ot,c as V}from"./mermaid.core-C888eQE1.js";import{p as Wt}from"./cynefin-OW5HDTMX-98M_mPg9.js";import"./index-DGq8BOVF.js";var G=y((a,o)=>{const e=a<=1?a*100:a;if(e<0||e>100)throw new Error(`${o} must be between 0-1 (decimal) or 0-100 (percentage). Received: ${a}`);return e},"toPercent"),E=y((a,o,e)=>({x:G(o,`${e} evolution`),y:G(a,`${e} visibility`)}),"toCoordinates"),tt=y(a=>{if(a){if(a==="+<>")return"bidirectional";if(a==="+<")return"backward";if(a==="+>")return"forward"}},"getFlowFromPort"),Dt=y(a=>{if(!(a!=null&&a.startsWith("+")))return{};const o=/^\+'([^']*)'/.exec(a),e=o==null?void 0:o[1];return a.includes("<>")?{flow:"bidirectional",label:e}:a.includes("<")?{flow:"backward",label:e}:a.includes(">")?{flow:"forward",label:e}:{label:e}},"extractFlowFromArrow"),Gt=y((a,o)=>{if(Lt(a,o),a.size&&o.setSize(a.size.width,a.size.height),a.evolution){const e=a.evolution.stages.map(r=>r.secondName?`${r.name.trim()} / ${r.secondName.trim()}`:r.name.trim()),p=a.evolution.stages.filter(r=>r.boundary!==void 0).map(r=>r.boundary);o.updateAxes({stages:e,stageBoundaries:p})}if(a.anchors.forEach(e=>{const p=E(e.visibility,e.evolution,`Anchor "${e.name}"`);o.addNode(e.name,e.name,p.x,p.y,"anchor")}),a.components.forEach(e=>{var v;const p=E(e.visibility,e.evolution,`Component "${e.name}"`),r=e.label?(e.label.negX?-1:1)*e.label.offsetX:void 0,d=e.label?(e.label.negY?-1:1)*e.label.offsetY:void 0,m=(v=e.decorator)==null?void 0:v.strategy;o.addNode(e.name,e.name,p.x,p.y,"component",r,d,e.inertia,m)}),a.notes.forEach(e=>{const p=E(e.visibility,e.evolution,`Note "${e.text}"`);o.addNote(e.text,p.x,p.y)}),a.pipelines.forEach(e=>{const p=o.getNode(e.parent);if(!p||typeof p.y!="number")throw new Error(`Pipeline "${e.parent}" must reference an existing component with coordinates.`);const r=p.y;o.startPipeline(e.parent),e.components.forEach(d=>{const m=`${e.parent}_${d.name}`,v=d.label?(d.label.negX?-1:1)*d.label.offsetX:void 0,g=d.label?(d.label.negY?-1:1)*d.label.offsetY:void 0,z=G(d.evolution,`Pipeline component "${d.name}" evolution`);o.addNode(m,d.name,z,r,"pipeline-component",v,g),o.addPipelineComponent(e.parent,m)})}),a.links.forEach(e=>{const p=!!e.arrow&&(e.arrow.includes("-.->")||e.arrow.includes(".-."));let r=tt(e.fromPort)??tt(e.toPort);const{flow:d,label:m}=Dt(e.arrow);!r&&d&&(r=d);const v=e.linkLabel,g=m??v;o.addLink(o.resolveNodeId(e.from),o.resolveNodeId(e.to),p,g,r)}),a.evolves.forEach(e=>{const p=o.getNode(e.component);if((p==null?void 0:p.y)!==void 0){const r=G(e.target,`Evolve target for "${e.component}"`);o.addTrend(e.component,r,p.y)}}),a.annotations.length>0){const e=a.annotations[0],p=E(e.x,e.y,"Annotations box");o.setAnnotationsBox(p.x,p.y)}a.annotation.forEach(e=>{const p=E(e.x,e.y,`Annotation ${e.number}`);o.addAnnotation(e.number,[{x:p.x,y:p.y}],e.text)}),a.accelerators.forEach(e=>{const p=E(e.x,e.y,`Accelerator "${e.name}"`);o.addAccelerator(e.name,p.x,p.y)}),a.deaccelerators.forEach(e=>{const p=E(e.x,e.y,`Deaccelerator "${e.name}"`);o.addDeaccelerator(e.name,p.x,p.y)})},"populateDb"),at={parser:{yy:void 0},parse:y(async a=>{var p;const o=await Wt("wardley",a);et.debug(o);const e=(p=at.parser)==null?void 0:p.yy;if(!e||typeof e.addNode!="function")throw new Error("parser.parser?.yy was not a WardleyDB. This is due to a bug within Mermaid, please report this issue at https://github.com/mermaid-js/mermaid/issues.");Gt(o,e)},"parse")},I,qt=(I=class{constructor(){this.nodes=new Map,this.links=[],this.trends=new Map,this.pipelines=new Map,this.annotations=[],this.notes=[],this.accelerators=[],this.deaccelerators=[],this.axes={}}addNode(o){const e=this.nodes.get(o.id)??{id:o.id,label:o.label},p={...e,...o,className:o.className??e.className,labelOffsetX:o.labelOffsetX??e.labelOffsetX,labelOffsetY:o.labelOffsetY??e.labelOffsetY};this.nodes.set(o.id,p)}addLink(o){this.links.push(o)}addTrend(o){this.trends.set(o.nodeId,o)}startPipeline(o){this.pipelines.set(o,{nodeId:o,componentIds:[]});const e=this.nodes.get(o);e&&(e.isPipelineParent=!0)}addPipelineComponent(o,e){const p=this.pipelines.get(o);p&&p.componentIds.push(e);const r=this.nodes.get(e);r&&(r.inPipeline=!0)}addAnnotation(o){this.annotations.push(o)}addNote(o){this.notes.push(o)}addAccelerator(o){this.accelerators.push(o)}addDeaccelerator(o){this.deaccelerators.push(o)}setAnnotationsBox(o,e){this.annotationsBox={x:o,y:e}}setAxes(o){this.axes={...this.axes,...o}}setSize(o,e){this.size={width:o,height:e}}getNode(o){return this.nodes.get(o)}resolveNodeId(o){if(this.nodes.has(o))return o;for(const[e,p]of this.nodes)if(p.label===o)return e;return o}build(){const o=[];for(const e of this.nodes.values()){if(typeof e.x!="number"||typeof e.y!="number")throw new Error(`Node "${e.label}" is missing coordinates`);o.push(e)}return{nodes:o,links:[...this.links],trends:[...this.trends.values()],pipelines:[...this.pipelines.values()],annotations:[...this.annotations],notes:[...this.notes],accelerators:[...this.accelerators],deaccelerators:[...this.deaccelerators],annotationsBox:this.annotationsBox,axes:{...this.axes},size:this.size}}clear(){this.nodes.clear(),this.links=[],this.trends.clear(),this.pipelines.clear(),this.annotations=[],this.notes=[],this.accelerators=[],this.deaccelerators=[],this.annotationsBox=void 0,this.axes={},this.size=void 0}},y(I,"WardleyBuilder"),I),b=new qt;function rt(){return V()["wardley-beta"]}y(rt,"getConfig");function ot(a,o,e,p,r,d,m,v,g){b.addNode({id:a,label:o,x:e,y:p,className:r,labelOffsetX:d,labelOffsetY:m,inertia:v,sourceStrategy:g})}y(ot,"addNode");function st(a,o,e=!1,p,r){b.addLink({source:a,target:o,dashed:e,label:p,flow:r})}y(st,"addLink");function nt(a,o,e){b.addTrend({nodeId:a,targetX:o,targetY:e})}y(nt,"addTrend");function it(a,o,e){b.addAnnotation({number:a,coordinates:o,text:e})}y(it,"addAnnotation");function dt(a,o,e){b.addNote({text:a,x:o,y:e})}y(dt,"addNote");function lt(a,o,e){b.addAccelerator({name:a,x:o,y:e})}y(lt,"addAccelerator");function ct(a,o,e){b.addDeaccelerator({name:a,x:o,y:e})}y(ct,"addDeaccelerator");function pt(a,o){b.setAnnotationsBox(a,o)}y(pt,"setAnnotationsBox");function ht(a,o){b.setSize(a,o)}y(ht,"setSize");function xt(a){b.startPipeline(a)}y(xt,"startPipeline");function ft(a,o){b.addPipelineComponent(a,o)}y(ft,"addPipelineComponent");function gt(a){b.setAxes(a)}y(gt,"updateAxes");function ut(a){return b.getNode(a)}y(ut,"getNode");function yt(a){return b.resolveNodeId(a)}y(yt,"resolveNodeId");function mt(){return b.build()}y(mt,"getWardleyData");function wt(){b.clear(),Ot()}y(wt,"clear");var Ht={getConfig:rt,addNode:ot,addLink:st,addTrend:nt,addAnnotation:it,addNote:dt,addAccelerator:lt,addDeaccelerator:ct,setAnnotationsBox:pt,setSize:ht,startPipeline:xt,addPipelineComponent:ft,updateAxes:gt,getNode:ut,resolveNodeId:yt,getWardleyData:mt,clear:wt,setAccTitle:Yt,getAccTitle:Et,setDiagramTitle:Xt,getDiagramTitle:At,getAccDescription:Tt,setAccDescription:zt},jt=["Genesis","Custom Built","Product","Commodity"],Vt=y(()=>{var o,e,p,r,d,m,v,g,z,M,k,N;const{themeVariables:a}=V();return{backgroundColor:((o=a.wardley)==null?void 0:o.backgroundColor)??a.background??"#fff",axisColor:((e=a.wardley)==null?void 0:e.axisColor)??"#000",axisTextColor:((p=a.wardley)==null?void 0:p.axisTextColor)??a.primaryTextColor??"#222",gridColor:((r=a.wardley)==null?void 0:r.gridColor)??"rgba(100, 100, 100, 0.2)",componentFill:((d=a.wardley)==null?void 0:d.componentFill)??"#fff",componentStroke:((m=a.wardley)==null?void 0:m.componentStroke)??"#000",componentLabelColor:((v=a.wardley)==null?void 0:v.componentLabelColor)??a.primaryTextColor??"#222",linkStroke:((g=a.wardley)==null?void 0:g.linkStroke)??"#000",evolutionStroke:((z=a.wardley)==null?void 0:z.evolutionStroke)??"#dc3545",annotationStroke:((M=a.wardley)==null?void 0:M.annotationStroke)??"#000",annotationTextColor:((k=a.wardley)==null?void 0:k.annotationTextColor)??a.primaryTextColor??"#222",annotationFill:((N=a.wardley)==null?void 0:N.annotationFill)??a.background??"#fff"}},"getTheme"),_t=y(()=>{const a=V()["wardley-beta"];return{width:(a==null?void 0:a.width)??900,height:(a==null?void 0:a.height)??600,padding:(a==null?void 0:a.padding)??48,nodeRadius:(a==null?void 0:a.nodeRadius)??6,nodeLabelOffset:(a==null?void 0:a.nodeLabelOffset)??8,axisFontSize:(a==null?void 0:a.axisFontSize)??12,labelFontSize:(a==null?void 0:a.labelFontSize)??10,showGrid:(a==null?void 0:a.showGrid)??!1,useMaxWidth:(a==null?void 0:a.useMaxWidth)??!0}},"getConfigValues"),Zt=y((a,o,e,p)=>{var U,J;et.debug(`Rendering Wardley map
1
+ import{p as Lt}from"./chunk-JWPE2WC7-CnvQdH0o.js";import{s as zt,g as Tt,t as At,q as Xt,a as Et,b as Yt,_ as y,R as It,L as Bt,N as K,l as et,Q as Ft,d as Rt,A as Ot,c as V}from"./mermaid.core-B1vpXQvD.js";import{p as Wt}from"./cynefin-OW5HDTMX-Ba9Ve3LO.js";import"./index-Bp8EjOaI.js";var G=y((a,o)=>{const e=a<=1?a*100:a;if(e<0||e>100)throw new Error(`${o} must be between 0-1 (decimal) or 0-100 (percentage). Received: ${a}`);return e},"toPercent"),E=y((a,o,e)=>({x:G(o,`${e} evolution`),y:G(a,`${e} visibility`)}),"toCoordinates"),tt=y(a=>{if(a){if(a==="+<>")return"bidirectional";if(a==="+<")return"backward";if(a==="+>")return"forward"}},"getFlowFromPort"),Dt=y(a=>{if(!(a!=null&&a.startsWith("+")))return{};const o=/^\+'([^']*)'/.exec(a),e=o==null?void 0:o[1];return a.includes("<>")?{flow:"bidirectional",label:e}:a.includes("<")?{flow:"backward",label:e}:a.includes(">")?{flow:"forward",label:e}:{label:e}},"extractFlowFromArrow"),Gt=y((a,o)=>{if(Lt(a,o),a.size&&o.setSize(a.size.width,a.size.height),a.evolution){const e=a.evolution.stages.map(r=>r.secondName?`${r.name.trim()} / ${r.secondName.trim()}`:r.name.trim()),p=a.evolution.stages.filter(r=>r.boundary!==void 0).map(r=>r.boundary);o.updateAxes({stages:e,stageBoundaries:p})}if(a.anchors.forEach(e=>{const p=E(e.visibility,e.evolution,`Anchor "${e.name}"`);o.addNode(e.name,e.name,p.x,p.y,"anchor")}),a.components.forEach(e=>{var v;const p=E(e.visibility,e.evolution,`Component "${e.name}"`),r=e.label?(e.label.negX?-1:1)*e.label.offsetX:void 0,d=e.label?(e.label.negY?-1:1)*e.label.offsetY:void 0,m=(v=e.decorator)==null?void 0:v.strategy;o.addNode(e.name,e.name,p.x,p.y,"component",r,d,e.inertia,m)}),a.notes.forEach(e=>{const p=E(e.visibility,e.evolution,`Note "${e.text}"`);o.addNote(e.text,p.x,p.y)}),a.pipelines.forEach(e=>{const p=o.getNode(e.parent);if(!p||typeof p.y!="number")throw new Error(`Pipeline "${e.parent}" must reference an existing component with coordinates.`);const r=p.y;o.startPipeline(e.parent),e.components.forEach(d=>{const m=`${e.parent}_${d.name}`,v=d.label?(d.label.negX?-1:1)*d.label.offsetX:void 0,g=d.label?(d.label.negY?-1:1)*d.label.offsetY:void 0,z=G(d.evolution,`Pipeline component "${d.name}" evolution`);o.addNode(m,d.name,z,r,"pipeline-component",v,g),o.addPipelineComponent(e.parent,m)})}),a.links.forEach(e=>{const p=!!e.arrow&&(e.arrow.includes("-.->")||e.arrow.includes(".-."));let r=tt(e.fromPort)??tt(e.toPort);const{flow:d,label:m}=Dt(e.arrow);!r&&d&&(r=d);const v=e.linkLabel,g=m??v;o.addLink(o.resolveNodeId(e.from),o.resolveNodeId(e.to),p,g,r)}),a.evolves.forEach(e=>{const p=o.getNode(e.component);if((p==null?void 0:p.y)!==void 0){const r=G(e.target,`Evolve target for "${e.component}"`);o.addTrend(e.component,r,p.y)}}),a.annotations.length>0){const e=a.annotations[0],p=E(e.x,e.y,"Annotations box");o.setAnnotationsBox(p.x,p.y)}a.annotation.forEach(e=>{const p=E(e.x,e.y,`Annotation ${e.number}`);o.addAnnotation(e.number,[{x:p.x,y:p.y}],e.text)}),a.accelerators.forEach(e=>{const p=E(e.x,e.y,`Accelerator "${e.name}"`);o.addAccelerator(e.name,p.x,p.y)}),a.deaccelerators.forEach(e=>{const p=E(e.x,e.y,`Deaccelerator "${e.name}"`);o.addDeaccelerator(e.name,p.x,p.y)})},"populateDb"),at={parser:{yy:void 0},parse:y(async a=>{var p;const o=await Wt("wardley",a);et.debug(o);const e=(p=at.parser)==null?void 0:p.yy;if(!e||typeof e.addNode!="function")throw new Error("parser.parser?.yy was not a WardleyDB. This is due to a bug within Mermaid, please report this issue at https://github.com/mermaid-js/mermaid/issues.");Gt(o,e)},"parse")},I,qt=(I=class{constructor(){this.nodes=new Map,this.links=[],this.trends=new Map,this.pipelines=new Map,this.annotations=[],this.notes=[],this.accelerators=[],this.deaccelerators=[],this.axes={}}addNode(o){const e=this.nodes.get(o.id)??{id:o.id,label:o.label},p={...e,...o,className:o.className??e.className,labelOffsetX:o.labelOffsetX??e.labelOffsetX,labelOffsetY:o.labelOffsetY??e.labelOffsetY};this.nodes.set(o.id,p)}addLink(o){this.links.push(o)}addTrend(o){this.trends.set(o.nodeId,o)}startPipeline(o){this.pipelines.set(o,{nodeId:o,componentIds:[]});const e=this.nodes.get(o);e&&(e.isPipelineParent=!0)}addPipelineComponent(o,e){const p=this.pipelines.get(o);p&&p.componentIds.push(e);const r=this.nodes.get(e);r&&(r.inPipeline=!0)}addAnnotation(o){this.annotations.push(o)}addNote(o){this.notes.push(o)}addAccelerator(o){this.accelerators.push(o)}addDeaccelerator(o){this.deaccelerators.push(o)}setAnnotationsBox(o,e){this.annotationsBox={x:o,y:e}}setAxes(o){this.axes={...this.axes,...o}}setSize(o,e){this.size={width:o,height:e}}getNode(o){return this.nodes.get(o)}resolveNodeId(o){if(this.nodes.has(o))return o;for(const[e,p]of this.nodes)if(p.label===o)return e;return o}build(){const o=[];for(const e of this.nodes.values()){if(typeof e.x!="number"||typeof e.y!="number")throw new Error(`Node "${e.label}" is missing coordinates`);o.push(e)}return{nodes:o,links:[...this.links],trends:[...this.trends.values()],pipelines:[...this.pipelines.values()],annotations:[...this.annotations],notes:[...this.notes],accelerators:[...this.accelerators],deaccelerators:[...this.deaccelerators],annotationsBox:this.annotationsBox,axes:{...this.axes},size:this.size}}clear(){this.nodes.clear(),this.links=[],this.trends.clear(),this.pipelines.clear(),this.annotations=[],this.notes=[],this.accelerators=[],this.deaccelerators=[],this.annotationsBox=void 0,this.axes={},this.size=void 0}},y(I,"WardleyBuilder"),I),b=new qt;function rt(){return V()["wardley-beta"]}y(rt,"getConfig");function ot(a,o,e,p,r,d,m,v,g){b.addNode({id:a,label:o,x:e,y:p,className:r,labelOffsetX:d,labelOffsetY:m,inertia:v,sourceStrategy:g})}y(ot,"addNode");function st(a,o,e=!1,p,r){b.addLink({source:a,target:o,dashed:e,label:p,flow:r})}y(st,"addLink");function nt(a,o,e){b.addTrend({nodeId:a,targetX:o,targetY:e})}y(nt,"addTrend");function it(a,o,e){b.addAnnotation({number:a,coordinates:o,text:e})}y(it,"addAnnotation");function dt(a,o,e){b.addNote({text:a,x:o,y:e})}y(dt,"addNote");function lt(a,o,e){b.addAccelerator({name:a,x:o,y:e})}y(lt,"addAccelerator");function ct(a,o,e){b.addDeaccelerator({name:a,x:o,y:e})}y(ct,"addDeaccelerator");function pt(a,o){b.setAnnotationsBox(a,o)}y(pt,"setAnnotationsBox");function ht(a,o){b.setSize(a,o)}y(ht,"setSize");function xt(a){b.startPipeline(a)}y(xt,"startPipeline");function ft(a,o){b.addPipelineComponent(a,o)}y(ft,"addPipelineComponent");function gt(a){b.setAxes(a)}y(gt,"updateAxes");function ut(a){return b.getNode(a)}y(ut,"getNode");function yt(a){return b.resolveNodeId(a)}y(yt,"resolveNodeId");function mt(){return b.build()}y(mt,"getWardleyData");function wt(){b.clear(),Ot()}y(wt,"clear");var Ht={getConfig:rt,addNode:ot,addLink:st,addTrend:nt,addAnnotation:it,addNote:dt,addAccelerator:lt,addDeaccelerator:ct,setAnnotationsBox:pt,setSize:ht,startPipeline:xt,addPipelineComponent:ft,updateAxes:gt,getNode:ut,resolveNodeId:yt,getWardleyData:mt,clear:wt,setAccTitle:Yt,getAccTitle:Et,setDiagramTitle:Xt,getDiagramTitle:At,getAccDescription:Tt,setAccDescription:zt},jt=["Genesis","Custom Built","Product","Commodity"],Vt=y(()=>{var o,e,p,r,d,m,v,g,z,M,k,N;const{themeVariables:a}=V();return{backgroundColor:((o=a.wardley)==null?void 0:o.backgroundColor)??a.background??"#fff",axisColor:((e=a.wardley)==null?void 0:e.axisColor)??"#000",axisTextColor:((p=a.wardley)==null?void 0:p.axisTextColor)??a.primaryTextColor??"#222",gridColor:((r=a.wardley)==null?void 0:r.gridColor)??"rgba(100, 100, 100, 0.2)",componentFill:((d=a.wardley)==null?void 0:d.componentFill)??"#fff",componentStroke:((m=a.wardley)==null?void 0:m.componentStroke)??"#000",componentLabelColor:((v=a.wardley)==null?void 0:v.componentLabelColor)??a.primaryTextColor??"#222",linkStroke:((g=a.wardley)==null?void 0:g.linkStroke)??"#000",evolutionStroke:((z=a.wardley)==null?void 0:z.evolutionStroke)??"#dc3545",annotationStroke:((M=a.wardley)==null?void 0:M.annotationStroke)??"#000",annotationTextColor:((k=a.wardley)==null?void 0:k.annotationTextColor)??a.primaryTextColor??"#222",annotationFill:((N=a.wardley)==null?void 0:N.annotationFill)??a.background??"#fff"}},"getTheme"),_t=y(()=>{const a=V()["wardley-beta"];return{width:(a==null?void 0:a.width)??900,height:(a==null?void 0:a.height)??600,padding:(a==null?void 0:a.padding)??48,nodeRadius:(a==null?void 0:a.nodeRadius)??6,nodeLabelOffset:(a==null?void 0:a.nodeLabelOffset)??8,axisFontSize:(a==null?void 0:a.axisFontSize)??12,labelFontSize:(a==null?void 0:a.labelFontSize)??10,showGrid:(a==null?void 0:a.showGrid)??!1,useMaxWidth:(a==null?void 0:a.useMaxWidth)??!0}},"getConfigValues"),Zt=y((a,o,e,p)=>{var U,J;et.debug(`Rendering Wardley map
2
2
  `+a);const r=_t(),d=Vt(),m=r.nodeRadius*1.6,v=p.db,g=v.getWardleyData(),z=v.getDiagramTitle(),M=((U=g.size)==null?void 0:U.width)??r.width,k=((J=g.size)==null?void 0:J.height)??r.height,N=Ft(o);N.selectAll("*").remove(),Rt(N,k,M,r.useMaxWidth),N.attr("viewBox",`0 0 ${M} ${k}`);const P=N.append("g").attr("class","wardley-map"),q=N.append("defs");q.append("marker").attr("id",`arrow-${o}`).attr("viewBox","0 0 10 10").attr("refX",9).attr("refY",5).attr("markerWidth",6).attr("markerHeight",6).attr("orient","auto-start-reverse").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").attr("fill",d.evolutionStroke).attr("stroke","none"),q.append("marker").attr("id",`link-arrow-end-${o}`).attr("viewBox","0 0 10 10").attr("refX",9).attr("refY",5).attr("markerWidth",5).attr("markerHeight",5).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").attr("fill",d.linkStroke).attr("stroke","none"),q.append("marker").attr("id",`link-arrow-start-${o}`).attr("viewBox","0 0 10 10").attr("refX",1).attr("refY",5).attr("markerWidth",5).attr("markerHeight",5).attr("orient","auto").append("path").attr("d","M 10 0 L 0 5 L 10 10 z").attr("fill",d.linkStroke).attr("stroke","none"),P.append("rect").attr("class","wardley-background").attr("width",M).attr("height",k).attr("fill",d.backgroundColor);const B=M-r.padding*2,F=k-r.padding*2;z&&P.append("text").attr("class","wardley-title").attr("x",M/2).attr("y",r.padding/2).attr("fill",d.axisTextColor).attr("font-size",r.axisFontSize*1.05).attr("font-weight","bold").attr("text-anchor","middle").attr("dominant-baseline","middle").text(z);const T=y(t=>r.padding+t/100*B,"projectX"),A=y(t=>k-r.padding-t/100*F,"projectY"),O=P.append("g").attr("class","wardley-axes");O.append("line").attr("x1",r.padding).attr("x2",M-r.padding).attr("y1",k-r.padding).attr("y2",k-r.padding).attr("stroke",d.axisColor).attr("stroke-width",1),O.append("line").attr("x1",r.padding).attr("x2",r.padding).attr("y1",r.padding).attr("y2",k-r.padding).attr("stroke",d.axisColor).attr("stroke-width",1);const kt=g.axes.xLabel??"Evolution",bt=g.axes.yLabel??"Visibility";O.append("text").attr("class","wardley-axis-label wardley-axis-label-x").attr("x",r.padding+B/2).attr("y",k-r.padding/4).attr("fill",d.axisTextColor).attr("font-size",r.axisFontSize).attr("font-weight","bold").attr("text-anchor","middle").text(kt),O.append("text").attr("class","wardley-axis-label wardley-axis-label-y").attr("x",r.padding/3).attr("y",r.padding+F/2).attr("fill",d.axisTextColor).attr("font-size",r.axisFontSize).attr("font-weight","bold").attr("text-anchor","middle").attr("transform",`rotate(-90 ${r.padding/3} ${r.padding+F/2})`).text(bt);const R=g.axes.stages&&g.axes.stages.length>0?g.axes.stages:jt;if(R.length>0){const t=P.append("g").attr("class","wardley-stages"),n=g.axes.stageBoundaries,s=[];if(n&&n.length===R.length){let i=0;n.forEach(h=>{s.push({start:i,end:h}),i=h})}else{const i=1/R.length;R.forEach((h,l)=>{s.push({start:l*i,end:(l+1)*i})})}R.forEach((i,h)=>{const l=s[h],x=r.padding+l.start*B,f=r.padding+l.end*B,u=(x+f)/2;h>0&&t.append("line").attr("x1",x).attr("x2",x).attr("y1",r.padding).attr("y2",k-r.padding).attr("stroke","#000").attr("stroke-width",1).attr("stroke-dasharray","5 5").attr("opacity",.8),t.append("text").attr("class","wardley-stage-label").attr("x",u).attr("y",k-r.padding/1.5).attr("fill",d.axisTextColor).attr("font-size",r.axisFontSize-2).attr("text-anchor","middle").text(i)})}if(r.showGrid){const t=P.append("g").attr("class","wardley-grid");for(let n=1;n<4;n++){const s=n/4,i=r.padding+B*s;t.append("line").attr("x1",i).attr("x2",i).attr("y1",r.padding).attr("y2",k-r.padding).attr("stroke",d.gridColor).attr("stroke-dasharray","2 6"),t.append("line").attr("x1",r.padding).attr("x2",M-r.padding).attr("y1",k-r.padding-F*s).attr("y2",k-r.padding-F*s).attr("stroke",d.gridColor).attr("stroke-dasharray","2 6")}}const c=new Map;if(g.nodes.forEach(t=>{c.set(t.id,{x:T(t.x),y:A(t.y),node:t})}),g.pipelines.length>0){const t=P.append("g").attr("class","wardley-pipelines"),n=P.append("g").attr("class","wardley-pipeline-links");g.pipelines.forEach(s=>{if(s.componentIds.length===0)return;const i=s.componentIds.map(f=>({id:f,pos:c.get(f),node:g.nodes.find(u=>u.id===f)})).filter(f=>f.pos&&f.node).sort((f,u)=>f.node.x-u.node.x);for(let f=0;f<i.length-1;f++){const u=i[f],w=i[f+1];n.append("line").attr("class","wardley-pipeline-evolution-link").attr("x1",u.pos.x).attr("y1",u.pos.y).attr("x2",w.pos.x).attr("y2",w.pos.y).attr("stroke",d.linkStroke).attr("stroke-width",1).attr("stroke-dasharray","4 4")}let h=1/0,l=-1/0,x=0;if(s.componentIds.forEach(f=>{const u=c.get(f);u&&(h=Math.min(h,u.x),l=Math.max(l,u.x),x=u.y)}),h!==1/0&&l!==-1/0){const u=r.nodeRadius*4,w=x-u/2,S=c.get(s.nodeId);if(S){const L=(h+l)/2;S.x=L,S.y=w-m/6}t.append("rect").attr("class","wardley-pipeline-box").attr("x",h-15).attr("y",w).attr("width",l-h+30).attr("height",u).attr("fill","none").attr("stroke",d.axisColor).attr("stroke-width",1.5).attr("rx",4).attr("ry",4)}})}const _=P.append("g").attr("class","wardley-links"),Z=new Map;g.pipelines.forEach(t=>{Z.set(t.nodeId,new Set(t.componentIds))});const Q=g.links.filter(t=>{if(!c.has(t.source)||!c.has(t.target))return!1;const n=Z.get(t.target);return!(n!=null&&n.has(t.source))});_.selectAll("line").data(Q).enter().append("line").attr("class",t=>`wardley-link${t.dashed?" wardley-link--dashed":""}`).attr("x1",t=>{const n=c.get(t.source),s=c.get(t.target),h=g.nodes.find(u=>u.id===t.source).isPipelineParent?m/Math.sqrt(2):r.nodeRadius,l=s.x-n.x,x=s.y-n.y,f=Math.sqrt(l*l+x*x);return n.x+l/f*h}).attr("y1",t=>{const n=c.get(t.source),s=c.get(t.target),h=g.nodes.find(u=>u.id===t.source).isPipelineParent?m/Math.sqrt(2):r.nodeRadius,l=s.x-n.x,x=s.y-n.y,f=Math.sqrt(l*l+x*x);return n.y+x/f*h}).attr("x2",t=>{const n=c.get(t.source),s=c.get(t.target),h=g.nodes.find(u=>u.id===t.target).isPipelineParent?m/Math.sqrt(2):r.nodeRadius,l=n.x-s.x,x=n.y-s.y,f=Math.sqrt(l*l+x*x);return s.x+l/f*h}).attr("y2",t=>{const n=c.get(t.source),s=c.get(t.target),h=g.nodes.find(u=>u.id===t.target).isPipelineParent?m/Math.sqrt(2):r.nodeRadius,l=n.x-s.x,x=n.y-s.y,f=Math.sqrt(l*l+x*x);return s.y+x/f*h}).attr("stroke",d.linkStroke).attr("stroke-width",1).attr("stroke-dasharray",t=>t.dashed?"6 6":null).attr("marker-end",t=>t.flow==="forward"||t.flow==="bidirectional"?`url(#link-arrow-end-${o})`:null).attr("marker-start",t=>t.flow==="backward"||t.flow==="bidirectional"?`url(#link-arrow-start-${o})`:null),_.selectAll("text").data(Q.filter(t=>t.label)).enter().append("text").attr("class","wardley-link-label").attr("x",t=>{const n=c.get(t.source),s=c.get(t.target),i=(n.x+s.x)/2,h=s.y-n.y,l=s.x-n.x,x=Math.sqrt(l*l+h*h),f=8,u=h/x;return i+u*f}).attr("y",t=>{const n=c.get(t.source),s=c.get(t.target),i=(n.y+s.y)/2,h=s.x-n.x,l=s.y-n.y,x=Math.sqrt(h*h+l*l),f=8,u=-h/x;return i+u*f}).attr("fill",d.axisTextColor).attr("font-size",r.labelFontSize).attr("text-anchor","middle").attr("dominant-baseline","middle").attr("transform",t=>{const n=c.get(t.source),s=c.get(t.target),i=(n.x+s.x)/2,h=(n.y+s.y)/2,l=s.x-n.x,x=s.y-n.y,f=Math.sqrt(l*l+x*x),u=8,w=x/f,S=-l/f,L=i+w*u,W=h+S*u;let Y=Math.atan2(x,l)*180/Math.PI;return(Y>90||Y<-90)&&(Y+=180),`rotate(${Y} ${L} ${W})`}).text(t=>t.label);const $t=P.append("g").attr("class","wardley-trends"),vt=g.trends.map(t=>{const n=c.get(t.nodeId);if(!n)return null;const s=T(t.targetX),i=A(t.targetY),h=s-n.x,l=i-n.y,x=Math.sqrt(h*h+l*l),f=r.nodeRadius+2,u=x>f?s-h/x*f:s,w=x>f?i-l/x*f:i;return{origin:n,targetX:s,targetY:i,adjustedX2:u,adjustedY2:w}}).filter(t=>t!==null);$t.selectAll("line").data(vt).enter().append("line").attr("class","wardley-trend").attr("x1",t=>t.origin.x).attr("y1",t=>t.origin.y).attr("x2",t=>t.adjustedX2).attr("y2",t=>t.adjustedY2).attr("stroke",d.evolutionStroke).attr("stroke-width",1).attr("stroke-dasharray","4 4").attr("marker-end",`url(#arrow-${o})`);const C=P.append("g").attr("class","wardley-nodes").selectAll("g").data(g.nodes).enter().append("g").attr("class",t=>["wardley-node",t.className?`wardley-node--${t.className}`:""].filter(Boolean).join(" "));C.filter(t=>t.sourceStrategy==="outsource").append("circle").attr("class","wardley-outsource-overlay").attr("cx",t=>c.get(t.id).x).attr("cy",t=>c.get(t.id).y).attr("r",r.nodeRadius*2).attr("fill","#666").attr("stroke",d.componentStroke).attr("stroke-width",1),C.filter(t=>t.sourceStrategy==="buy").append("circle").attr("class","wardley-buy-overlay").attr("cx",t=>c.get(t.id).x).attr("cy",t=>c.get(t.id).y).attr("r",r.nodeRadius*2).attr("fill","#ccc").attr("stroke",d.componentStroke).attr("stroke-width",1),C.filter(t=>t.sourceStrategy==="build").append("circle").attr("class","wardley-build-overlay").attr("cx",t=>c.get(t.id).x).attr("cy",t=>c.get(t.id).y).attr("r",r.nodeRadius*2).attr("fill","#eee").attr("stroke","#000").attr("stroke-width",1);const X=C.filter(t=>t.sourceStrategy==="market");X.append("circle").attr("class","wardley-market-overlay").attr("cx",t=>c.get(t.id).x).attr("cy",t=>c.get(t.id).y).attr("r",r.nodeRadius*2).attr("fill","white").attr("stroke",d.componentStroke).attr("stroke-width",1),C.filter(t=>!t.isPipelineParent&&t.sourceStrategy!=="market"&&t.className!=="anchor").append("circle").attr("cx",t=>c.get(t.id).x).attr("cy",t=>c.get(t.id).y).attr("r",r.nodeRadius).attr("fill",d.componentFill).attr("stroke",d.componentStroke).attr("stroke-width",1);const H=r.nodeRadius*.7,$=r.nodeRadius*1.2;if(X.append("line").attr("class","wardley-market-line").attr("x1",t=>c.get(t.id).x).attr("y1",t=>c.get(t.id).y-$).attr("x2",t=>c.get(t.id).x-$*Math.cos(Math.PI/6)).attr("y2",t=>c.get(t.id).y+$*Math.sin(Math.PI/6)).attr("stroke",d.componentStroke).attr("stroke-width",1),X.append("line").attr("class","wardley-market-line").attr("x1",t=>c.get(t.id).x-$*Math.cos(Math.PI/6)).attr("y1",t=>c.get(t.id).y+$*Math.sin(Math.PI/6)).attr("x2",t=>c.get(t.id).x+$*Math.cos(Math.PI/6)).attr("y2",t=>c.get(t.id).y+$*Math.sin(Math.PI/6)).attr("stroke",d.componentStroke).attr("stroke-width",1),X.append("line").attr("class","wardley-market-line").attr("x1",t=>c.get(t.id).x+$*Math.cos(Math.PI/6)).attr("y1",t=>c.get(t.id).y+$*Math.sin(Math.PI/6)).attr("x2",t=>c.get(t.id).x).attr("y2",t=>c.get(t.id).y-$).attr("stroke",d.componentStroke).attr("stroke-width",1),X.append("circle").attr("class","wardley-market-dot").attr("cx",t=>c.get(t.id).x).attr("cy",t=>c.get(t.id).y-$).attr("r",H).attr("fill","white").attr("stroke",d.componentStroke).attr("stroke-width",2),X.append("circle").attr("class","wardley-market-dot").attr("cx",t=>c.get(t.id).x-$*Math.cos(Math.PI/6)).attr("cy",t=>c.get(t.id).y+$*Math.sin(Math.PI/6)).attr("r",H).attr("fill","white").attr("stroke",d.componentStroke).attr("stroke-width",2),X.append("circle").attr("class","wardley-market-dot").attr("cx",t=>c.get(t.id).x+$*Math.cos(Math.PI/6)).attr("cy",t=>c.get(t.id).y+$*Math.sin(Math.PI/6)).attr("r",H).attr("fill","white").attr("stroke",d.componentStroke).attr("stroke-width",2),C.filter(t=>t.isPipelineParent===!0).append("rect").attr("x",t=>c.get(t.id).x-m/2).attr("y",t=>c.get(t.id).y-m/2).attr("width",m).attr("height",m).attr("fill",d.componentFill).attr("stroke",d.componentStroke).attr("stroke-width",1),C.filter(t=>t.inertia===!0).append("line").attr("class","wardley-inertia").attr("x1",t=>{const n=c.get(t.id);let s=t.isPipelineParent?m/2+15:r.nodeRadius+15;return t.sourceStrategy&&(s+=r.nodeRadius+10),n.x+s}).attr("y1",t=>{const n=c.get(t.id),s=t.isPipelineParent?m:r.nodeRadius*2;return n.y-s/2}).attr("x2",t=>{const n=c.get(t.id);let s=t.isPipelineParent?m/2+15:r.nodeRadius+15;return t.sourceStrategy&&(s+=r.nodeRadius+10),n.x+s}).attr("y2",t=>{const n=c.get(t.id),s=t.isPipelineParent?m:r.nodeRadius*2;return n.y+s/2}).attr("stroke",d.componentStroke).attr("stroke-width",6),C.append("text").attr("x",t=>{const n=c.get(t.id);if(t.className==="anchor")return t.labelOffsetX!==void 0?n.x+t.labelOffsetX:n.x;let s=r.nodeLabelOffset;t.sourceStrategy&&t.labelOffsetX===void 0&&(s+=10);const i=t.labelOffsetX??s;return n.x+i}).attr("y",t=>{const n=c.get(t.id);if(t.className==="anchor")return t.labelOffsetY!==void 0?n.y+t.labelOffsetY:n.y-3;let s=-r.nodeLabelOffset;t.sourceStrategy&&t.labelOffsetY===void 0&&(s-=10);const i=t.labelOffsetY??s;return n.y+i}).attr("class","wardley-node-label").attr("fill",t=>t.className==="evolved"?d.evolutionStroke:t.className==="anchor"?"#000":d.componentLabelColor).attr("font-size",r.labelFontSize).attr("font-weight",t=>t.className==="anchor"?"bold":"normal").attr("text-anchor",t=>t.className==="anchor"?"middle":"start").attr("dominant-baseline",t=>t.className==="anchor"?"middle":"auto").text(t=>t.label),g.annotations.length>0){const t=P.append("g").attr("class","wardley-annotations");if(g.annotations.forEach(n=>{const s=n.coordinates.map(i=>({x:T(i.x),y:A(i.y)}));if(s.length>1)for(let i=0;i<s.length-1;i++)t.append("line").attr("class","wardley-annotation-line").attr("x1",s[i].x).attr("y1",s[i].y).attr("x2",s[i+1].x).attr("y2",s[i+1].y).attr("stroke",d.axisColor).attr("stroke-width",1.5).attr("stroke-dasharray","4 4");s.forEach(i=>{const h=t.append("g").attr("class","wardley-annotation");h.append("circle").attr("cx",i.x).attr("cy",i.y).attr("r",10).attr("fill","white").attr("stroke",d.axisColor).attr("stroke-width",1.5),h.append("text").attr("x",i.x).attr("y",i.y).attr("text-anchor","middle").attr("dominant-baseline","central").attr("font-size",10).attr("fill",d.axisTextColor).attr("font-weight","bold").text(n.number)})}),g.annotationsBox){let n=T(g.annotationsBox.x),s=A(g.annotationsBox.y);const i=10,h=16,l=11,x=t.append("g").attr("class","wardley-annotations-box"),f=[...g.annotations].filter(w=>w.text).sort((w,S)=>w.number-S.number),u=[];if(f.forEach((w,S)=>{const L=x.append("text").attr("x",n+i).attr("y",s+i+(S+1)*h).attr("font-size",l).attr("fill",d.axisTextColor).attr("text-anchor","start").attr("dominant-baseline","middle").text(`${w.number}. ${w.text}`);u.push(L)}),u.length>0){let w=0,S=0;u.forEach(j=>{const D=j.node(),Nt=D.getComputedTextLength();w=Math.max(w,Nt);const Ct=D.getBBox();S=Math.max(S,Ct.height)});const L=w+i*2+105,W=f.length*h+i*2+S/2,Y=r.padding,Pt=M-r.padding-L,St=r.padding,Mt=k-r.padding-W;n=Math.max(Y,Math.min(n,Pt)),s=Math.max(St,Math.min(s,Mt)),u.forEach((j,D)=>{j.attr("x",n+i).attr("y",s+i+(D+1)*h)}),x.insert("rect","text").attr("x",n).attr("y",s).attr("width",L).attr("height",W).attr("fill","white").attr("stroke",d.axisColor).attr("stroke-width",1.5).attr("rx",4).attr("ry",4)}}}if(g.notes.length>0){const t=P.append("g").attr("class","wardley-notes");g.notes.forEach(n=>{const s=T(n.x),i=A(n.y);t.append("text").attr("x",s).attr("y",i).attr("text-anchor","start").attr("font-size",11).attr("fill",d.axisTextColor).attr("font-weight","bold").text(n.text)})}if(g.accelerators.length>0){const t=P.append("g").attr("class","wardley-accelerators");g.accelerators.forEach(n=>{const s=T(n.x),i=A(n.y),h=60,l=30,x=20,f=`
3
3
  M ${s} ${i-l/2}
4
4
  L ${s+h-x} ${i-l/2}
@@ -1,4 +1,4 @@
1
- import{s as pi,g as mi,t as $t,q as yi,a as bi,b as Ai,_ as n,l as Ut,Q as wi,d as Ci,A as Si,L as Tt,j as Ri,N as qt,O as _i,R as ki,S as Ti}from"./mermaid.core-C888eQE1.js";import{b as Wt,l as Xt,a as Nt}from"./index-DGq8BOVF.js";var St=(function(){var e=n(function(V,r,g,u){for(g=g||{},u=V.length;u--;g[V[u]]=r);return g},"o"),t=[1,10,12,14,16,18,19,21,23],i=[2,6],s=[1,3],a=[1,5],h=[1,6],l=[1,7],y=[1,5,10,12,14,16,18,19,21,23,36,37,38],d=[1,25],p=[1,26],_=[1,28],k=[1,29],P=[1,30],F=[1,31],W=[1,32],v=[1,33],B=[1,34],b=[1,35],T=[1,36],c=[1,37],I=[1,43],O=[1,42],X=[1,47],N=[1,50],S=[1,10,12,14,16,18,19,21,23,36,37,38],H=[1,10,12,14,16,18,19,21,23,24,26,28,29,36,37,38],A=[1,10,12,14,16,18,19,21,23,24,26,28,29,36,37,38,42,43,44,45,46,47,48,49,50,51],w=[1,65],M=[26,28],R={trace:n(function(){},"trace"),yy:{},symbols_:{error:2,start:3,eol:4,XYCHART:5,chartConfig:6,document:7,CHART_ORIENTATION:8,statement:9,title:10,text:11,X_AXIS:12,parseXAxis:13,Y_AXIS:14,parseYAxis:15,LINE:16,plotData:17,BAR:18,acc_title:19,acc_title_value:20,acc_descr:21,acc_descr_value:22,acc_descr_multiline_value:23,SQUARE_BRACES_START:24,dataPoints:25,SQUARE_BRACES_END:26,dataPoint:27,COMMA:28,NUMBER_WITH_DECIMAL:29,STR:30,xAxisData:31,bandData:32,ARROW_DELIMITER:33,commaSeparatedTexts:34,yAxisData:35,NEWLINE:36,SEMI:37,EOF:38,alphaNum:39,MD_STR:40,alphaNumToken:41,AMP:42,NUM:43,ALPHA:44,PLUS:45,EQUALS:46,MULT:47,DOT:48,BRKT:49,MINUS:50,UNDERSCORE:51,$accept:0,$end:1},terminals_:{2:"error",5:"XYCHART",8:"CHART_ORIENTATION",10:"title",12:"X_AXIS",14:"Y_AXIS",16:"LINE",18:"BAR",19:"acc_title",20:"acc_title_value",21:"acc_descr",22:"acc_descr_value",23:"acc_descr_multiline_value",24:"SQUARE_BRACES_START",26:"SQUARE_BRACES_END",28:"COMMA",29:"NUMBER_WITH_DECIMAL",30:"STR",33:"ARROW_DELIMITER",36:"NEWLINE",37:"SEMI",38:"EOF",40:"MD_STR",42:"AMP",43:"NUM",44:"ALPHA",45:"PLUS",46:"EQUALS",47:"MULT",48:"DOT",49:"BRKT",50:"MINUS",51:"UNDERSCORE"},productions_:[0,[3,2],[3,3],[3,2],[3,1],[6,1],[7,0],[7,2],[9,2],[9,2],[9,2],[9,2],[9,2],[9,3],[9,2],[9,3],[9,2],[9,2],[9,1],[17,3],[25,3],[25,1],[27,2],[27,1],[13,1],[13,2],[13,1],[31,1],[31,3],[32,3],[34,3],[34,1],[15,1],[15,2],[15,1],[35,3],[4,1],[4,1],[4,1],[11,1],[11,1],[11,1],[39,1],[39,2],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1]],performAction:n(function(r,g,u,x,C,o,lt){var f=o.length-1;switch(C){case 5:x.setOrientation(o[f]);break;case 9:x.setDiagramTitle(o[f].text.trim());break;case 12:x.setLineData({text:"",type:"text"},o[f]);break;case 13:x.setLineData(o[f-1],o[f]);break;case 14:x.setBarData({text:"",type:"text"},o[f]);break;case 15:x.setBarData(o[f-1],o[f]);break;case 16:this.$=o[f].trim(),x.setAccTitle(this.$);break;case 17:case 18:this.$=o[f].trim(),x.setAccDescription(this.$);break;case 19:this.$=o[f-1];break;case 20:case 30:this.$=[o[f-2],...o[f]];break;case 21:case 31:this.$=[o[f]];break;case 22:this.$={value:Number(o[f-1]),label:o[f]};break;case 23:this.$={value:Number(o[f]),label:""};break;case 24:x.setXAxisTitle(o[f]);break;case 25:x.setXAxisTitle(o[f-1]);break;case 26:x.setXAxisTitle({type:"text",text:""});break;case 27:x.setXAxisBand(o[f]);break;case 28:x.setXAxisRangeData(Number(o[f-2]),Number(o[f]));break;case 29:this.$=o[f-1];break;case 32:x.setYAxisTitle(o[f]);break;case 33:x.setYAxisTitle(o[f-1]);break;case 34:x.setYAxisTitle({type:"text",text:""});break;case 35:x.setYAxisRangeData(Number(o[f-2]),Number(o[f]));break;case 39:this.$={text:o[f],type:"text"};break;case 40:this.$={text:o[f],type:"text"};break;case 41:this.$={text:o[f],type:"markdown"};break;case 42:this.$=o[f];break;case 43:this.$=o[f-1]+""+o[f];break}},"anonymous"),table:[e(t,i,{3:1,4:2,7:4,5:s,36:a,37:h,38:l}),{1:[3]},e(t,i,{4:2,7:4,3:8,5:s,36:a,37:h,38:l}),e(t,i,{4:2,7:4,6:9,3:10,5:s,8:[1,11],36:a,37:h,38:l}),{1:[2,4],9:12,10:[1,13],12:[1,14],14:[1,15],16:[1,16],18:[1,17],19:[1,18],21:[1,19],23:[1,20]},e(y,[2,36]),e(y,[2,37]),e(y,[2,38]),{1:[2,1]},e(t,i,{4:2,7:4,3:21,5:s,36:a,37:h,38:l}),{1:[2,3]},e(y,[2,5]),e(t,[2,7],{4:22,36:a,37:h,38:l}),{11:23,30:d,39:24,40:p,41:27,42:_,43:k,44:P,45:F,46:W,47:v,48:B,49:b,50:T,51:c},{11:39,13:38,24:I,29:O,30:d,31:40,32:41,39:24,40:p,41:27,42:_,43:k,44:P,45:F,46:W,47:v,48:B,49:b,50:T,51:c},{11:45,15:44,29:X,30:d,35:46,39:24,40:p,41:27,42:_,43:k,44:P,45:F,46:W,47:v,48:B,49:b,50:T,51:c},{11:49,17:48,24:N,30:d,39:24,40:p,41:27,42:_,43:k,44:P,45:F,46:W,47:v,48:B,49:b,50:T,51:c},{11:52,17:51,24:N,30:d,39:24,40:p,41:27,42:_,43:k,44:P,45:F,46:W,47:v,48:B,49:b,50:T,51:c},{20:[1,53]},{22:[1,54]},e(S,[2,18]),{1:[2,2]},e(S,[2,8]),e(S,[2,9]),e(H,[2,39],{41:55,42:_,43:k,44:P,45:F,46:W,47:v,48:B,49:b,50:T,51:c}),e(H,[2,40]),e(H,[2,41]),e(A,[2,42]),e(A,[2,44]),e(A,[2,45]),e(A,[2,46]),e(A,[2,47]),e(A,[2,48]),e(A,[2,49]),e(A,[2,50]),e(A,[2,51]),e(A,[2,52]),e(A,[2,53]),e(S,[2,10]),e(S,[2,24],{32:41,31:56,24:I,29:O}),e(S,[2,26]),e(S,[2,27]),{33:[1,57]},{11:59,30:d,34:58,39:24,40:p,41:27,42:_,43:k,44:P,45:F,46:W,47:v,48:B,49:b,50:T,51:c},e(S,[2,11]),e(S,[2,32],{35:60,29:X}),e(S,[2,34]),{33:[1,61]},e(S,[2,12]),{17:62,24:N},{25:63,27:64,29:w},e(S,[2,14]),{17:66,24:N},e(S,[2,16]),e(S,[2,17]),e(A,[2,43]),e(S,[2,25]),{29:[1,67]},{26:[1,68]},{26:[2,31],28:[1,69]},e(S,[2,33]),{29:[1,70]},e(S,[2,13]),{26:[1,71]},{26:[2,21],28:[1,72]},e(M,[2,23],{30:[1,73]}),e(S,[2,15]),e(S,[2,28]),e(S,[2,29]),{11:59,30:d,34:74,39:24,40:p,41:27,42:_,43:k,44:P,45:F,46:W,47:v,48:B,49:b,50:T,51:c},e(S,[2,35]),e(S,[2,19]),{25:75,27:64,29:w},e(M,[2,22]),{26:[2,30]},{26:[2,20]}],defaultActions:{8:[2,1],10:[2,3],21:[2,2],74:[2,30],75:[2,20]},parseError:n(function(r,g){if(g.recoverable)this.trace(r);else{var u=new Error(r);throw u.hash=g,u}},"parseError"),parse:n(function(r){var g=this,u=[0],x=[],C=[null],o=[],lt=this.table,f="",xt=0,Bt=0,ui=2,Ot=1,xi=o.slice.call(arguments,1),D=Object.create(this.lexer),$={yy:{}};for(var bt in this.yy)Object.prototype.hasOwnProperty.call(this.yy,bt)&&($.yy[bt]=this.yy[bt]);D.setInput(r,$.yy),$.yy.lexer=D,$.yy.parser=this,typeof D.yylloc>"u"&&(D.yylloc={});var At=D.yylloc;o.push(At);var di=D.options&&D.options.ranges;typeof $.yy.parseError=="function"?this.parseError=$.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function fi(E){u.length=u.length-2*E,C.length=C.length-E,o.length=o.length-E}n(fi,"popStack");function Vt(){var E;return E=x.pop()||D.lex()||Ot,typeof E!="number"&&(E instanceof Array&&(x=E,E=x.pop()),E=g.symbols_[E]||E),E}n(Vt,"lex");for(var L,U,z,wt,j={},dt,Y,Ft,ft;;){if(U=u[u.length-1],this.defaultActions[U]?z=this.defaultActions[U]:((L===null||typeof L>"u")&&(L=Vt()),z=lt[U]&&lt[U][L]),typeof z>"u"||!z.length||!z[0]){var Ct="";ft=[];for(dt in lt[U])this.terminals_[dt]&&dt>ui&&ft.push("'"+this.terminals_[dt]+"'");D.showPosition?Ct="Parse error on line "+(xt+1)+`:
1
+ import{s as pi,g as mi,t as $t,q as yi,a as bi,b as Ai,_ as n,l as Ut,Q as wi,d as Ci,A as Si,L as Tt,j as Ri,N as qt,O as _i,R as ki,S as Ti}from"./mermaid.core-B1vpXQvD.js";import{b as Wt,l as Xt,a as Nt}from"./index-Bp8EjOaI.js";var St=(function(){var e=n(function(V,r,g,u){for(g=g||{},u=V.length;u--;g[V[u]]=r);return g},"o"),t=[1,10,12,14,16,18,19,21,23],i=[2,6],s=[1,3],a=[1,5],h=[1,6],l=[1,7],y=[1,5,10,12,14,16,18,19,21,23,36,37,38],d=[1,25],p=[1,26],_=[1,28],k=[1,29],P=[1,30],F=[1,31],W=[1,32],v=[1,33],B=[1,34],b=[1,35],T=[1,36],c=[1,37],I=[1,43],O=[1,42],X=[1,47],N=[1,50],S=[1,10,12,14,16,18,19,21,23,36,37,38],H=[1,10,12,14,16,18,19,21,23,24,26,28,29,36,37,38],A=[1,10,12,14,16,18,19,21,23,24,26,28,29,36,37,38,42,43,44,45,46,47,48,49,50,51],w=[1,65],M=[26,28],R={trace:n(function(){},"trace"),yy:{},symbols_:{error:2,start:3,eol:4,XYCHART:5,chartConfig:6,document:7,CHART_ORIENTATION:8,statement:9,title:10,text:11,X_AXIS:12,parseXAxis:13,Y_AXIS:14,parseYAxis:15,LINE:16,plotData:17,BAR:18,acc_title:19,acc_title_value:20,acc_descr:21,acc_descr_value:22,acc_descr_multiline_value:23,SQUARE_BRACES_START:24,dataPoints:25,SQUARE_BRACES_END:26,dataPoint:27,COMMA:28,NUMBER_WITH_DECIMAL:29,STR:30,xAxisData:31,bandData:32,ARROW_DELIMITER:33,commaSeparatedTexts:34,yAxisData:35,NEWLINE:36,SEMI:37,EOF:38,alphaNum:39,MD_STR:40,alphaNumToken:41,AMP:42,NUM:43,ALPHA:44,PLUS:45,EQUALS:46,MULT:47,DOT:48,BRKT:49,MINUS:50,UNDERSCORE:51,$accept:0,$end:1},terminals_:{2:"error",5:"XYCHART",8:"CHART_ORIENTATION",10:"title",12:"X_AXIS",14:"Y_AXIS",16:"LINE",18:"BAR",19:"acc_title",20:"acc_title_value",21:"acc_descr",22:"acc_descr_value",23:"acc_descr_multiline_value",24:"SQUARE_BRACES_START",26:"SQUARE_BRACES_END",28:"COMMA",29:"NUMBER_WITH_DECIMAL",30:"STR",33:"ARROW_DELIMITER",36:"NEWLINE",37:"SEMI",38:"EOF",40:"MD_STR",42:"AMP",43:"NUM",44:"ALPHA",45:"PLUS",46:"EQUALS",47:"MULT",48:"DOT",49:"BRKT",50:"MINUS",51:"UNDERSCORE"},productions_:[0,[3,2],[3,3],[3,2],[3,1],[6,1],[7,0],[7,2],[9,2],[9,2],[9,2],[9,2],[9,2],[9,3],[9,2],[9,3],[9,2],[9,2],[9,1],[17,3],[25,3],[25,1],[27,2],[27,1],[13,1],[13,2],[13,1],[31,1],[31,3],[32,3],[34,3],[34,1],[15,1],[15,2],[15,1],[35,3],[4,1],[4,1],[4,1],[11,1],[11,1],[11,1],[39,1],[39,2],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1]],performAction:n(function(r,g,u,x,C,o,lt){var f=o.length-1;switch(C){case 5:x.setOrientation(o[f]);break;case 9:x.setDiagramTitle(o[f].text.trim());break;case 12:x.setLineData({text:"",type:"text"},o[f]);break;case 13:x.setLineData(o[f-1],o[f]);break;case 14:x.setBarData({text:"",type:"text"},o[f]);break;case 15:x.setBarData(o[f-1],o[f]);break;case 16:this.$=o[f].trim(),x.setAccTitle(this.$);break;case 17:case 18:this.$=o[f].trim(),x.setAccDescription(this.$);break;case 19:this.$=o[f-1];break;case 20:case 30:this.$=[o[f-2],...o[f]];break;case 21:case 31:this.$=[o[f]];break;case 22:this.$={value:Number(o[f-1]),label:o[f]};break;case 23:this.$={value:Number(o[f]),label:""};break;case 24:x.setXAxisTitle(o[f]);break;case 25:x.setXAxisTitle(o[f-1]);break;case 26:x.setXAxisTitle({type:"text",text:""});break;case 27:x.setXAxisBand(o[f]);break;case 28:x.setXAxisRangeData(Number(o[f-2]),Number(o[f]));break;case 29:this.$=o[f-1];break;case 32:x.setYAxisTitle(o[f]);break;case 33:x.setYAxisTitle(o[f-1]);break;case 34:x.setYAxisTitle({type:"text",text:""});break;case 35:x.setYAxisRangeData(Number(o[f-2]),Number(o[f]));break;case 39:this.$={text:o[f],type:"text"};break;case 40:this.$={text:o[f],type:"text"};break;case 41:this.$={text:o[f],type:"markdown"};break;case 42:this.$=o[f];break;case 43:this.$=o[f-1]+""+o[f];break}},"anonymous"),table:[e(t,i,{3:1,4:2,7:4,5:s,36:a,37:h,38:l}),{1:[3]},e(t,i,{4:2,7:4,3:8,5:s,36:a,37:h,38:l}),e(t,i,{4:2,7:4,6:9,3:10,5:s,8:[1,11],36:a,37:h,38:l}),{1:[2,4],9:12,10:[1,13],12:[1,14],14:[1,15],16:[1,16],18:[1,17],19:[1,18],21:[1,19],23:[1,20]},e(y,[2,36]),e(y,[2,37]),e(y,[2,38]),{1:[2,1]},e(t,i,{4:2,7:4,3:21,5:s,36:a,37:h,38:l}),{1:[2,3]},e(y,[2,5]),e(t,[2,7],{4:22,36:a,37:h,38:l}),{11:23,30:d,39:24,40:p,41:27,42:_,43:k,44:P,45:F,46:W,47:v,48:B,49:b,50:T,51:c},{11:39,13:38,24:I,29:O,30:d,31:40,32:41,39:24,40:p,41:27,42:_,43:k,44:P,45:F,46:W,47:v,48:B,49:b,50:T,51:c},{11:45,15:44,29:X,30:d,35:46,39:24,40:p,41:27,42:_,43:k,44:P,45:F,46:W,47:v,48:B,49:b,50:T,51:c},{11:49,17:48,24:N,30:d,39:24,40:p,41:27,42:_,43:k,44:P,45:F,46:W,47:v,48:B,49:b,50:T,51:c},{11:52,17:51,24:N,30:d,39:24,40:p,41:27,42:_,43:k,44:P,45:F,46:W,47:v,48:B,49:b,50:T,51:c},{20:[1,53]},{22:[1,54]},e(S,[2,18]),{1:[2,2]},e(S,[2,8]),e(S,[2,9]),e(H,[2,39],{41:55,42:_,43:k,44:P,45:F,46:W,47:v,48:B,49:b,50:T,51:c}),e(H,[2,40]),e(H,[2,41]),e(A,[2,42]),e(A,[2,44]),e(A,[2,45]),e(A,[2,46]),e(A,[2,47]),e(A,[2,48]),e(A,[2,49]),e(A,[2,50]),e(A,[2,51]),e(A,[2,52]),e(A,[2,53]),e(S,[2,10]),e(S,[2,24],{32:41,31:56,24:I,29:O}),e(S,[2,26]),e(S,[2,27]),{33:[1,57]},{11:59,30:d,34:58,39:24,40:p,41:27,42:_,43:k,44:P,45:F,46:W,47:v,48:B,49:b,50:T,51:c},e(S,[2,11]),e(S,[2,32],{35:60,29:X}),e(S,[2,34]),{33:[1,61]},e(S,[2,12]),{17:62,24:N},{25:63,27:64,29:w},e(S,[2,14]),{17:66,24:N},e(S,[2,16]),e(S,[2,17]),e(A,[2,43]),e(S,[2,25]),{29:[1,67]},{26:[1,68]},{26:[2,31],28:[1,69]},e(S,[2,33]),{29:[1,70]},e(S,[2,13]),{26:[1,71]},{26:[2,21],28:[1,72]},e(M,[2,23],{30:[1,73]}),e(S,[2,15]),e(S,[2,28]),e(S,[2,29]),{11:59,30:d,34:74,39:24,40:p,41:27,42:_,43:k,44:P,45:F,46:W,47:v,48:B,49:b,50:T,51:c},e(S,[2,35]),e(S,[2,19]),{25:75,27:64,29:w},e(M,[2,22]),{26:[2,30]},{26:[2,20]}],defaultActions:{8:[2,1],10:[2,3],21:[2,2],74:[2,30],75:[2,20]},parseError:n(function(r,g){if(g.recoverable)this.trace(r);else{var u=new Error(r);throw u.hash=g,u}},"parseError"),parse:n(function(r){var g=this,u=[0],x=[],C=[null],o=[],lt=this.table,f="",xt=0,Bt=0,ui=2,Ot=1,xi=o.slice.call(arguments,1),D=Object.create(this.lexer),$={yy:{}};for(var bt in this.yy)Object.prototype.hasOwnProperty.call(this.yy,bt)&&($.yy[bt]=this.yy[bt]);D.setInput(r,$.yy),$.yy.lexer=D,$.yy.parser=this,typeof D.yylloc>"u"&&(D.yylloc={});var At=D.yylloc;o.push(At);var di=D.options&&D.options.ranges;typeof $.yy.parseError=="function"?this.parseError=$.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function fi(E){u.length=u.length-2*E,C.length=C.length-E,o.length=o.length-E}n(fi,"popStack");function Vt(){var E;return E=x.pop()||D.lex()||Ot,typeof E!="number"&&(E instanceof Array&&(x=E,E=x.pop()),E=g.symbols_[E]||E),E}n(Vt,"lex");for(var L,U,z,wt,j={},dt,Y,Ft,ft;;){if(U=u[u.length-1],this.defaultActions[U]?z=this.defaultActions[U]:((L===null||typeof L>"u")&&(L=Vt()),z=lt[U]&&lt[U][L]),typeof z>"u"||!z.length||!z[0]){var Ct="";ft=[];for(dt in lt[U])this.terminals_[dt]&&dt>ui&&ft.push("'"+this.terminals_[dt]+"'");D.showPosition?Ct="Parse error on line "+(xt+1)+`:
2
2
  `+D.showPosition()+`
3
3
  Expecting `+ft.join(", ")+", got '"+(this.terminals_[L]||L)+"'":Ct="Parse error on line "+(xt+1)+": Unexpected "+(L==Ot?"end of input":"'"+(this.terminals_[L]||L)+"'"),this.parseError(Ct,{text:D.match,token:this.terminals_[L]||L,line:D.yylineno,loc:At,expected:ft})}if(z[0]instanceof Array&&z.length>1)throw new Error("Parse Error: multiple actions possible at state: "+U+", token: "+L);switch(z[0]){case 1:u.push(L),C.push(D.yytext),o.push(D.yylloc),u.push(z[1]),L=null,Bt=D.yyleng,f=D.yytext,xt=D.yylineno,At=D.yylloc;break;case 2:if(Y=this.productions_[z[1]][1],j.$=C[C.length-Y],j._$={first_line:o[o.length-(Y||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(Y||1)].first_column,last_column:o[o.length-1].last_column},di&&(j._$.range=[o[o.length-(Y||1)].range[0],o[o.length-1].range[1]]),wt=this.performAction.apply(j,[f,Bt,xt,$.yy,z[1],C,o].concat(xi)),typeof wt<"u")return wt;Y&&(u=u.slice(0,-1*Y*2),C=C.slice(0,-1*Y),o=o.slice(0,-1*Y)),u.push(this.productions_[z[1]][0]),C.push(j.$),o.push(j._$),Ft=lt[u[u.length-2]][u[u.length-1]],u.push(Ft);break;case 3:return!0}}return!0},"parse")},rt=(function(){var V={EOF:1,parseError:n(function(g,u){if(this.yy.parser)this.yy.parser.parseError(g,u);else throw new Error(g)},"parseError"),setInput:n(function(r,g){return this.yy=g||this.yy||{},this._input=r,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:n(function(){var r=this._input[0];this.yytext+=r,this.yyleng++,this.offset++,this.match+=r,this.matched+=r;var g=r.match(/(?:\r\n?|\n).*/g);return g?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),r},"input"),unput:n(function(r){var g=r.length,u=r.split(/(?:\r\n?|\n)/g);this._input=r+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-g),this.offset-=g;var x=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),u.length-1&&(this.yylineno-=u.length-1);var C=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:u?(u.length===x.length?this.yylloc.first_column:0)+x[x.length-u.length].length-u[0].length:this.yylloc.first_column-g},this.options.ranges&&(this.yylloc.range=[C[0],C[0]+this.yyleng-g]),this.yyleng=this.yytext.length,this},"unput"),more:n(function(){return this._more=!0,this},"more"),reject:n(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
4
4
  `+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:n(function(r){this.unput(this.match.slice(r))},"less"),pastInput:n(function(){var r=this.matched.substr(0,this.matched.length-this.match.length);return(r.length>20?"...":"")+r.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:n(function(){var r=this.match;return r.length<20&&(r+=this._input.substr(0,20-r.length)),(r.substr(0,20)+(r.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:n(function(){var r=this.pastInput(),g=new Array(r.length+1).join("-");return r+this.upcomingInput()+`