openwork-server 0.18.71 → 0.18.73
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.
- package/dist/opencode-plugin-deps-1.18.33.tgz +0 -0
- package/dist/opencode-plugins/agent-instruction-compose.js +0 -24
- package/dist/opencode-plugins/approval-loopback-fetch.js +0 -9
- package/dist/opencode-plugins/browser-tool-args.js +47 -0
- package/dist/opencode-plugins/computer-listing-files.js +0 -19
- package/dist/opencode-plugins/drive-file-tools.js +0 -4
- package/dist/opencode-plugins/gmail-attachment-fulfillment.js +0 -14
- package/dist/opencode-plugins/managed-policy-client.js +0 -2
- package/dist/opencode-plugins/opencode-stop-fence-client.js +0 -1
- package/dist/opencode-plugins/openwork-agent-permissions-v2.js +91 -7
- package/dist/opencode-plugins/openwork-agent-questions.js +2 -10
- package/dist/opencode-plugins/openwork-capabilities-knowledge.js +2 -2
- package/dist/opencode-plugins/openwork-chrome-devtools.js +73 -10
- package/dist/opencode-plugins/openwork-cloud-skills-v2.js +34 -49
- package/dist/opencode-plugins/openwork-codemode-discovery-v2.js +0 -7
- package/dist/opencode-plugins/openwork-computer-use.js +4 -4
- package/dist/opencode-plugins/openwork-context-v2.js +116 -22
- package/dist/opencode-plugins/openwork-extensions-preview-steering.js +0 -16
- package/dist/opencode-plugins/openwork-extensions-preview.js +1 -1
- package/dist/opencode-plugins/openwork-office-attachments.js +1401 -10
- package/dist/opencode-plugins/openwork-private-values-v2.js +38262 -0
- package/dist/opencode-plugins/openwork-private-values.js +38173 -0
- package/dist/opencode-plugins/openwork-provider-adapters.js +0 -11
- package/dist/opencode-plugins/openwork-session-groups.js +0 -13
- package/dist/opencode-plugins/openwork-spreadsheets.js +1401 -10
- package/dist/opencode-plugins/openwork-ui-bridge.js +1 -6
- package/dist/opencode-plugins/private-values-filter.js +150 -0
- package/dist/opencode-plugins/private-values-terminal.js +28 -0
- package/dist/opencode-plugins/private-values-tool.js +52 -0
- package/dist/opencode-plugins/provider-safe-tool-schema.js +0 -10
- package/dist/opencode-plugins/session-read-detail.js +0 -36
- package/dist/opencode-plugins/workspace-file-destinations.js +0 -5
- package/dist/openwork-server.mjs +6044 -2988
- package/package.json +1 -1
- package/web/assets/{abnfDiagram-VCTEODGH-DlWncS8i.js → abnfDiagram-VCTEODGH-CT7h6RSR.js} +1 -1
- package/web/assets/app-BinIaXyk.css +32 -0
- package/web/assets/{app-DSUHKGsm.js → app-DDsVI393.js} +480 -472
- package/web/assets/{arc-BtZC6wuw.js → arc-DrdxwkS1.js} +1 -1
- package/web/assets/{architectureDiagram-5GKGNRK7-DTbl4Rnl.js → architectureDiagram-5GKGNRK7-BHmeLgIo.js} +1 -1
- package/web/assets/{artifact-code-view-Ck4sjscy.js → artifact-code-view-BGAA8-Ej.js} +1 -1
- package/web/assets/artifact-office-preview-CCkdmKIT.js +6 -0
- package/web/assets/artifact-spreadsheet-editor-CMs_-Fs-.js +4 -0
- package/web/assets/{artifact-text-editor-DjSmnNjJ.js → artifact-text-editor-TtuV8SdE.js} +1 -1
- package/web/assets/{blockDiagram-OSKFZWR5-DAYSy6DL.js → blockDiagram-OSKFZWR5-CQ3xUn93.js} +1 -1
- package/web/assets/{c4Diagram-7LVT6UL2-CjyvESYl.js → c4Diagram-7LVT6UL2-s1wM6Iib.js} +1 -1
- package/web/assets/channel-DUquWRxW.js +1 -0
- package/web/assets/{chunk-2Q5K7J3B-CcMgFZAV.js → chunk-2Q5K7J3B-BZGXkEN4.js} +1 -1
- package/web/assets/{chunk-5VM5RSS4-D4c8XRGl.js → chunk-5VM5RSS4-C0tCaGEn.js} +1 -1
- package/web/assets/{chunk-F27PBJKO-BnyyjaCS.js → chunk-F27PBJKO-CGT4AvxR.js} +1 -1
- package/web/assets/{chunk-HLEWEB6X-JXz7B5zc.js → chunk-HLEWEB6X-BUm0nTzw.js} +1 -1
- package/web/assets/{chunk-JWPE2WC7-CYcnmDz7.js → chunk-JWPE2WC7-BrmOFhXE.js} +1 -1
- package/web/assets/{chunk-POPQ4Y6H-2llTUUN7.js → chunk-POPQ4Y6H-D0Red1rH.js} +1 -1
- package/web/assets/{chunk-SVP7TREG-BnWFSOpJ.js → chunk-SVP7TREG-BOfUyMpo.js} +1 -1
- package/web/assets/{chunk-XXDRQBXY-XqHzbo0u.js → chunk-XXDRQBXY-DdDJLBr5.js} +1 -1
- package/web/assets/{chunk-ZLD2IHE6-Dz_IjbQJ.js → chunk-ZLD2IHE6-CtgRsQI9.js} +1 -1
- package/web/assets/classDiagram-CYGNFDIV-D5L4nTet.js +1 -0
- package/web/assets/classDiagram-v2-TLXNO2FR-D5L4nTet.js +1 -0
- package/web/assets/{cose-bilkent-JH36ORCC--bD81EP5.js → cose-bilkent-JH36ORCC-C2GkVjI-.js} +1 -1
- package/web/assets/{cynefin-OW5HDTMX-tTD-HcrI.js → cynefin-OW5HDTMX-290exk3b.js} +1 -1
- package/web/assets/{cynefinDiagram-5FMLGOSQ-CMslIrwy.js → cynefinDiagram-5FMLGOSQ-Bn4pzfGg.js} +1 -1
- package/web/assets/{dagre-OS7QT2EB-B__oM1cx.js → dagre-OS7QT2EB-pvGtPuBl.js} +1 -1
- package/web/assets/{diagram-S7CK7UJ4-D2ghWE6t.js → diagram-S7CK7UJ4-CWs5HWfs.js} +1 -1
- package/web/assets/{diagram-UQ7AKVKN-BanDxdhW.js → diagram-UQ7AKVKN-DAtsBm-A.js} +1 -1
- package/web/assets/{diagram-VSXAHHWV-DGvbp0xT.js → diagram-VSXAHHWV-B0Z-KH-p.js} +1 -1
- package/web/assets/{diagram-VX7I27RA-CThCeJli.js → diagram-VX7I27RA-Bz5GVlm5.js} +1 -1
- package/web/assets/{diagram-Z3DM3KII-CAt65CmM.js → diagram-Z3DM3KII-BhwH3kbC.js} +1 -1
- package/web/assets/{ebnfDiagram-PWID7BFC-Cp5nPs03.js → ebnfDiagram-PWID7BFC-CIEcjysp.js} +1 -1
- package/web/assets/{erDiagram-2YWLMYGG-HLBdDnlf.js → erDiagram-2YWLMYGG-BrdXGtuT.js} +1 -1
- package/web/assets/{flowDiagram-T62WH6J4-CELW8hlc.js → flowDiagram-T62WH6J4-DskTn8O1.js} +1 -1
- package/web/assets/{ganttDiagram-EL5Y4UJY-C7R0OzTb.js → ganttDiagram-EL5Y4UJY-OCmeEDkw.js} +1 -1
- package/web/assets/{gitGraphDiagram-WWUBYQGX-qBuuQIor.js → gitGraphDiagram-WWUBYQGX-BuhI6DQ1.js} +1 -1
- package/web/assets/{infoDiagram-FKFFQAWI-iEzBkgjk.js → infoDiagram-FKFFQAWI-C3k38hJ_.js} +1 -1
- package/web/assets/{ishikawaDiagram-5VMMS53U-DrK4XY4T.js → ishikawaDiagram-5VMMS53U-C6Hpxc9K.js} +1 -1
- package/web/assets/{journeyDiagram-EYS64GPL-CGd8HUPB.js → journeyDiagram-EYS64GPL-C7KcOJMH.js} +1 -1
- package/web/assets/{kanban-definition-UXKFOSKX-DQmiyxel.js → kanban-definition-UXKFOSKX-ZcMziysx.js} +1 -1
- package/web/assets/{layout-DLjmmpHK.js → layout-DzriRV2A.js} +1 -1
- package/web/assets/{linear-DHJPnkfR.js → linear-DL_T580R.js} +1 -1
- package/web/assets/{mermaid.core-PQNy-dHT.js → mermaid.core-C4R8NQRz.js} +6 -6
- package/web/assets/{mindmap-definition-THT77NOG-B5jNdC9x.js → mindmap-definition-THT77NOG-n6izCCQf.js} +1 -1
- package/web/assets/{pegDiagram-XKGWAZYB-wbhF-roR.js → pegDiagram-XKGWAZYB-BADF-j9h.js} +1 -1
- package/web/assets/{pieDiagram-E7YTZNPT-2HAV5f46.js → pieDiagram-E7YTZNPT-BtdHIRbI.js} +1 -1
- package/web/assets/{quadrantDiagram-AXDQQJYC-CLDLYWPn.js → quadrantDiagram-AXDQQJYC-DhbkPfnT.js} +1 -1
- package/web/assets/{railroadDiagram-O6MQD6OU-Be5VkSOo.js → railroadDiagram-O6MQD6OU-BlyQ_Gry.js} +1 -1
- package/web/assets/{requirementDiagram-IS5BZ75X-qBk4BaLm.js → requirementDiagram-IS5BZ75X-BzIoUxA6.js} +1 -1
- package/web/assets/{sankeyDiagram-P5KCCOFB-a-kGn14g.js → sankeyDiagram-P5KCCOFB-qPG2gCyL.js} +1 -1
- package/web/assets/{sequenceDiagram-WJ2MYXX4-B19t616Z.js → sequenceDiagram-WJ2MYXX4-Bx12LmjC.js} +1 -1
- package/web/assets/{sizeCapture-INFHLROL-CGM0ZmNa.js → sizeCapture-INFHLROL-CvyuDIwF.js} +1 -1
- package/web/assets/{stateDiagram-XQSTLZYL-CQYuKN4p.js → stateDiagram-XQSTLZYL-DU9RhZb1.js} +1 -1
- package/web/assets/stateDiagram-v2-IH3M54BS-iZjygJwL.js +1 -0
- package/web/assets/{swimlanes-V6O3JKXN-CvzknNlU.js → swimlanes-V6O3JKXN-CTXpVjqj.js} +1 -1
- package/web/assets/swimlanesDiagram-JKAHXJPX-GfrjbmAb.js +8 -0
- package/web/assets/{timeline-definition-24CTP7MA-BhF3gzcl.js → timeline-definition-24CTP7MA-U_izIFdJ.js} +1 -1
- package/web/assets/{vennDiagram-4TSXK5OY-6DNrrc2_.js → vennDiagram-4TSXK5OY-DWquLtuy.js} +1 -1
- package/web/assets/{wardleyDiagram-VM6X3IG4-DO0onK3t.js → wardleyDiagram-VM6X3IG4-CH8aTVHX.js} +1 -1
- package/web/assets/{workspace-file-tree-BCpC4HYD.js → workspace-file-tree-CmGwayaP.js} +1 -1
- package/web/assets/xlsx-workbook-DcK1GLDS.js +9 -0
- package/web/assets/{xychartDiagram-S5SC5T6Z-44sg_69l.js → xychartDiagram-S5SC5T6Z-r1FFIWA_.js} +1 -1
- package/web/index.html +2 -2
- package/web/assets/app-CfKQPy_C.css +0 -32
- package/web/assets/artifact-spreadsheet-editor-O5R5Qt-8.js +0 -11
- package/web/assets/channel-OiorT9Re.js +0 -1
- package/web/assets/classDiagram-CYGNFDIV-CLY7M0C9.js +0 -1
- package/web/assets/classDiagram-v2-TLXNO2FR-CLY7M0C9.js +0 -1
- package/web/assets/stateDiagram-v2-IH3M54BS-CVq-yI8K.js +0 -1
- package/web/assets/swimlanesDiagram-JKAHXJPX-YWNRXT7V.js +0 -8
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import{c as r,s as e}from"./flowDiagram-T62WH6J4-DskTn8O1.js";import{_ as a}from"./mermaid.core-C4R8NQRz.js";import"./chunk-5VM5RSS4-C0tCaGEn.js";import"./chunk-XXDRQBXY-DdDJLBr5.js";import"./chunk-POPQ4Y6H-D0Red1rH.js";import"./chunk-F27PBJKO-CGT4AvxR.js";import"./app-DDsVI393.js";import"./channel-DUquWRxW.js";var o=a(t=>`${e(t)}
|
|
2
|
+
.swimlane.cluster rect {
|
|
3
|
+
stroke: ${t.clusterBorder} !important;
|
|
4
|
+
}
|
|
5
|
+
[data-look="neo"].cluster rect {
|
|
6
|
+
filter: none;
|
|
7
|
+
}
|
|
8
|
+
`,"getStyles"),s=o,n=r({defaultLayout:"swimlane",styles:s});export{n as diagram};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{_ as o,A as pt,ab as Rt,ac as Ct,ad as Wt,c as gt,l as E,G as Pt,a2 as Bt,ae as ft,j as U,v as Vt,af as Ft,r as zt}from"./mermaid.core-
|
|
1
|
+
import{_ as o,A as pt,ab as Rt,ac as Ct,ad as Wt,c as gt,l as E,G as Pt,a2 as Bt,ae as ft,j as U,v as Vt,af as Ft,r as zt}from"./mermaid.core-C4R8NQRz.js";import{d as ot}from"./arc-DrdxwkS1.js";import"./app-DDsVI393.js";var tt=(function(){var e=o(function(k,s,d,l){for(d=d||{},l=k.length;l--;d[k[l]]=s);return d},"o"),t=[6,11,13,14,15,17,19,20,23,24],n=[1,12],i=[1,13],r=[1,14],h=[1,15],c=[1,16],a=[1,19],f=[1,20],g={trace:o(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:o(function(s,d,l,p,x,u,S){var v=u.length-1;switch(x){case 1:return u[v-1];case 3:p.setDirection("LR");break;case 4:p.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:p.getCommonDb().setDiagramTitle(u[v].substr(6)),this.$=u[v].substr(6);break;case 12:this.$=u[v].trim(),p.getCommonDb().setAccTitle(this.$);break;case 13:case 14:this.$=u[v].trim(),p.getCommonDb().setAccDescription(this.$);break;case 15:p.addSection(u[v].substr(8)),this.$=u[v].substr(8);break;case 18:p.addTask(u[v],0,""),this.$=u[v];break;case 19:p.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:n,15:i,17:r,19:h,20:c,21:17,22:18,23:a,24:f},e(t,[2,10],{1:[2,1]}),e(t,[2,6]),{12:21,14:n,15:i,17:r,19:h,20:c,21:17,22:18,23:a,24:f},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:o(function(s,d){if(d.recoverable)this.trace(s);else{var l=new Error(s);throw l.hash=d,l}},"parseError"),parse:o(function(s){var d=this,l=[0],p=[],x=[null],u=[],S=this.table,v="",I=0,R=0,W=2,O=1,L=u.slice.call(arguments,1),w=Object.create(this.lexer),H={yy:{}};for(var V in this.yy)Object.prototype.hasOwnProperty.call(this.yy,V)&&(H.yy[V]=this.yy[V]);w.setInput(s,H.yy),H.yy.lexer=w,H.yy.parser=this,typeof w.yylloc>"u"&&(w.yylloc={});var F=w.yylloc;u.push(F);var K=w.options&&w.options.ranges;typeof H.yy.parseError=="function"?this.parseError=H.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function N(A){l.length=l.length-2*A,x.length=x.length-A,u.length=u.length-A}o(N,"popStack");function b(){var A;return A=p.pop()||w.lex()||O,typeof A!="number"&&(A instanceof Array&&(p=A,A=p.pop()),A=d.symbols_[A]||A),A}o(b,"lex");for(var _,$,T,P,C={},G,B,X,Z;;){if($=l[l.length-1],this.defaultActions[$]?T=this.defaultActions[$]:((_===null||typeof _>"u")&&(_=b()),T=S[$]&&S[$][_]),typeof T>"u"||!T.length||!T[0]){var Y="";Z=[];for(G in S[$])this.terminals_[G]&&G>W&&Z.push("'"+this.terminals_[G]+"'");w.showPosition?Y="Parse error on line "+(I+1)+`:
|
|
2
2
|
`+w.showPosition()+`
|
|
3
3
|
Expecting `+Z.join(", ")+", got '"+(this.terminals_[_]||_)+"'":Y="Parse error on line "+(I+1)+": Unexpected "+(_==O?"end of input":"'"+(this.terminals_[_]||_)+"'"),this.parseError(Y,{text:w.match,token:this.terminals_[_]||_,line:w.yylineno,loc:F,expected:Z})}if(T[0]instanceof Array&&T.length>1)throw new Error("Parse Error: multiple actions possible at state: "+$+", token: "+_);switch(T[0]){case 1:l.push(_),x.push(w.yytext),u.push(w.yylloc),l.push(T[1]),_=null,R=w.yyleng,v=w.yytext,I=w.yylineno,F=w.yylloc;break;case 2:if(B=this.productions_[T[1]][1],C.$=x[x.length-B],C._$={first_line:u[u.length-(B||1)].first_line,last_line:u[u.length-1].last_line,first_column:u[u.length-(B||1)].first_column,last_column:u[u.length-1].last_column},K&&(C._$.range=[u[u.length-(B||1)].range[0],u[u.length-1].range[1]]),P=this.performAction.apply(C,[v,R,I,H.yy,T[1],x,u].concat(L)),typeof P<"u")return P;B&&(l=l.slice(0,-1*B*2),x=x.slice(0,-1*B),u=u.slice(0,-1*B)),l.push(this.productions_[T[1]][0]),x.push(C.$),u.push(C._$),X=S[l[l.length-2]][l[l.length-1]],l.push(X);break;case 3:return!0}}return!0},"parse")},m=(function(){var k={EOF:1,parseError:o(function(d,l){if(this.yy.parser)this.yy.parser.parseError(d,l);else throw new Error(d)},"parseError"),setInput:o(function(s,d){return this.yy=d||this.yy||{},this._input=s,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:o(function(){var s=this._input[0];this.yytext+=s,this.yyleng++,this.offset++,this.match+=s,this.matched+=s;var d=s.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),s},"input"),unput:o(function(s){var d=s.length,l=s.split(/(?:\r\n?|\n)/g);this._input=s+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-d),this.offset-=d;var p=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),l.length-1&&(this.yylineno-=l.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:l?(l.length===p.length?this.yylloc.first_column:0)+p[p.length-l.length].length-l[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:o(function(){return this._more=!0,this},"more"),reject:o(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:o(function(s){this.unput(this.match.slice(s))},"less"),pastInput:o(function(){var s=this.matched.substr(0,this.matched.length-this.match.length);return(s.length>20?"...":"")+s.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:o(function(){var s=this.match;return s.length<20&&(s+=this._input.substr(0,20-s.length)),(s.substr(0,20)+(s.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:o(function(){var s=this.pastInput(),d=new Array(s.length+1).join("-");return s+this.upcomingInput()+`
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{b1 as Wt,s as Kt,g as Ht,q as Yt,p as Xt,a as Zt,b as Jt,_ as w,A as wt,G as Qt,j as ot,am as $t,ab as te,ac as ee,ad as ne,d as se,r as ie,D as oe,E as re}from"./mermaid.core-PQNy-dHT.js";import"./app-DSUHKGsm.js";const kt=(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,o=0;const r=[];if(e.length>1){const l=Tt(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 f=e[e.length-1];for(let u=0;u<e.length;++u){const a=e[u];o+=(f.x+a.x)*(a.y-f.y);const y={x:(a.x+f.x)/2,y:(a.y+f.y)/2};let h=null;for(let b=0;b<a.parentIndex.length;++b)if(f.parentIndex.includes(a.parentIndex[b])){const p=t[a.parentIndex[b]],M=Math.atan2(a.x-p.x,a.y-p.y),T=Math.atan2(f.x-p.x,f.y-p.y);let _=T-M;_<0&&(_+=2*Math.PI);const S=T-_/2;let g=q(y,{x:p.x+p.radius*Math.sin(S),y:p.y+p.radius*Math.cos(S)});g>p.radius*2&&(g=p.radius*2),(h==null||h.width>g)&&(h={circle:p,width:g,p1:a,p2:f,large:g>p.radius,sweep:!0})}h!=null&&(r.push(h),i+=lt(h.circle.radius,h.width),f=a)}}else{let l=t[0];for(let u=1;u<t.length;++u)t[u].radius<l.radius&&(l=t[u]);let f=!1;for(let u=0;u<t.length;++u)if(q(t[u],l)>Math.abs(l.radius-t[u].radius)){f=!0;break}f?i=o=0:(i=l.radius*l.radius*Math.PI,r.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 o/=2,n&&(n.area=i+o,n.arcArea=i,n.polygonArea=o,n.arcs=r,n.innerPoints=e,n.intersectionPoints=s),i+o}function ae(t,n){return n.every(s=>q(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=Et(t[s],t[e]);for(const o of i)o.parentIndex=[s,e],n.push(o)}return n}function lt(t,n){return t*t*Math.acos(1-n/t)-(t-n)*Math.sqrt(n*(2*t-n))}function q(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 Et(t,n){const s=q(t,n),e=t.radius,i=n.radius;if(s>=e+i||s<=Math.abs(e-i))return[];const o=(e*e-i*i+s*s)/(2*s),r=Math.sqrt(e*e-o*o),l=t.x+o*(n.x-t.x)/s,f=t.y+o*(n.y-t.y)/s,u=-(n.y-t.y)*(r/s),a=-(n.x-t.x)*(r/s);return[{x:l+u,y:f-a},{x:l-u,y:f+a}]}function Tt(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,o=e.tolerance||1e-10,r=t(n),l=t(s);let f=s-n;if(r*l>0)throw"Initial bisect points must have opposite signs";if(r===0)return n;if(l===0)return s;for(let u=0;u<i;++u){f/=2;const a=n+f,y=t(a);if(y*r>=0&&(n=a),Math.abs(f)<o||y===0)return a}return n+f}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 $(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($(t,t))}function ft(t,n,s){for(let e=0;e<n.length;++e)t[e]=n[e]*s}function J(t,n,s,e,i){for(let o=0;o<t.length;++o)t[o]=n*s[o]+e*i[o]}function zt(t,n,s){s=s||{};const e=s.maxIterations||n.length*200,i=s.nonZeroDelta||1.05,o=s.zeroDelta||.001,r=s.minErrorDelta||1e-6,l=s.minErrorDelta||1e-5,f=s.rho!==void 0?s.rho:1,u=s.chi!==void 0?s.chi:2,a=s.psi!==void 0?s.psi:-.5,y=s.sigma!==void 0?s.sigma:.5;let h;const b=n.length,p=new Array(b+1);p[0]=n,p[0].fx=t(n),p[0].id=0;for(let v=0;v<b;++v){const c=n.slice();c[v]=c[v]?c[v]*i:o,p[v+1]=c,p[v+1].fx=t(c),p[v+1].id=v+1}function M(v){for(let c=0;c<v.length;c++)p[b][c]=v[c];p[b].fx=v.fx}const T=(v,c)=>v.fx-c.fx,_=n.slice(),S=n.slice(),g=n.slice(),m=n.slice();for(let v=0;v<e;++v){if(p.sort(T),s.history){const x=p.map(d=>{const D=d.slice();return D.fx=d.fx,D.id=d.id,D});x.sort((d,D)=>d.id-D.id),s.history.push({x:p[0].slice(),fx:p[0].fx,simplex:x})}h=0;for(let x=0;x<b;++x)h=Math.max(h,Math.abs(p[0][x]-p[1][x]));if(Math.abs(p[0].fx-p[b].fx)<r&&h<l)break;for(let x=0;x<b;++x){_[x]=0;for(let d=0;d<b;++d)_[x]+=p[d][x];_[x]/=b}const c=p[b];if(J(S,1+f,_,-f,c),S.fx=t(S),S.fx<p[0].fx)J(m,1+u,_,-u,c),m.fx=t(m),m.fx<S.fx?M(m):M(S);else if(S.fx>=p[b-1].fx){let x=!1;if(S.fx>c.fx?(J(g,1+a,_,-a,c),g.fx=t(g),g.fx<c.fx?M(g):x=!0):(J(g,1-a*f,_,a*f,c),g.fx=t(g),g.fx<S.fx?M(g):x=!0),x){if(y>=1)break;for(let d=1;d<p.length;++d)J(p[d],1-y,p[0],y,p[d]),p[d].fx=t(p[d])}}else M(S)}return p.sort(T),{fx:p[0].fx,x:p[0]}}function ue(t,n,s,e,i,o,r){const l=s.fx,f=$(s.fxprime,n);let u=l,a=l,y=f,h=0;i=i||1,o=o||1e-6,r=r||.1;function b(p,M,T){for(let _=0;_<16;++_)if(i=(p+M)/2,J(e.x,1,s.x,i,n),u=e.fx=t(e.x,e.fxprime),y=$(e.fxprime,n),u>l+o*i*f||u>=T)M=i;else{if(Math.abs(y)<=-r*f)return i;y*(M-p)>=0&&(M=p),p=i,T=u}return 0}for(let p=0;p<10;++p){if(J(e.x,1,s.x,i,n),u=e.fx=t(e.x,e.fxprime),y=$(e.fxprime,n),u>l+o*i*f||p&&u>=a)return b(h,i,a);if(Math.abs(y)<=-r*f)return i;if(y>=0)return b(i,h,u);a=u,h=i,i*=2}return i}function fe(t,n,s){let e={x:n.slice(),fx:0,fxprime:n.slice()},i={x:n.slice(),fx:0,fxprime:n.slice()};const o=n.slice();let r,l,f=1,u;s=s||{},u=s.maxIterations||n.length*20,e.fx=t(e.x,e.fxprime),r=e.fxprime.slice(),ft(r,e.fxprime,-1);for(let a=0;a<u;++a){if(f=ue(t,r,e,i,f),s.history&&s.history.push({x:e.x.slice(),fx:e.fx,fxprime:e.fxprime.slice(),alpha:f}),!f)ft(r,e.fxprime,-1);else{J(o,1,i.fxprime,-1,e.fxprime);const y=$(e.fxprime,e.fxprime),h=Math.max(0,$(o,i.fxprime)/y);J(r,h,r,-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:f}),e}function At(t,n={}){n.maxIterations=n.maxIterations||500;const s=n.initialLayout||xe,e=n.lossFunction||tt,i=he(t,n),o=s(i,n),r=Object.keys(o),l=[];for(const a of r)l.push(o[a].x),l.push(o[a].y);const u=zt(a=>{const y={};for(let h=0;h<r.length;++h){const b=r[h];y[b]={x:a[2*h],y:a[2*h+1],radius:o[b].radius}}return e(y,i)},l,n).x;for(let a=0;a<r.length;++a){const y=r[a];o[y].x=u[2*a],o[y].y=u[2*a+1]}return o}const Rt=1e-10;function ht(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 he(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 f of e)for(let u=0;u<f.sets.length;u++){const a=String(f.sets[u]);l.set(a,f.size+(l.get(a)||0));for(let y=u+1;y<f.sets.length;y++){const h=String(f.sets[y]),b=`${a};${h}`,p=`${h};${a}`;l.set(b,f.size+(l.get(b)||0)),l.set(p,f.size+(l.get(p)||0))}}for(const f of e)f.sets.length<3&&(f.size=l.get(i(f.sets)))}const o=[],r=new Set;for(const l of e)if(l.sets.length===1)o.push(l.sets[0]);else if(l.sets.length===2){const f=l.sets[0],u=l.sets[1];r.add(i(l.sets)),r.add(i([u,f]))}o.sort((l,f)=>l===f?0:l<f?-1:1);for(let l=0;l<o.length;++l){const f=o[l];for(let u=l+1;u<o.length;++u){const a=o[u];r.has(i([f,a]))||e.push({sets:[f,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(o=>o.sets.length===2).forEach(o=>{const r=s[o.sets[0]],l=s[o.sets[1]],f=Math.sqrt(n[r].size/Math.PI),u=Math.sqrt(n[l].size/Math.PI),a=ht(f,u,o.size);e[r][l]=e[l][r]=a;let y=0;o.size+1e-10>=Math.min(n[r].size,n[l].size)?y=1:o.size<=1e-10&&(y=-1),i[r][l]=i[l][r]=y}),{distances:e,constraints:i}}function ge(t,n,s,e){for(let o=0;o<n.length;++o)n[o]=0;let i=0;for(let o=0;o<s.length;++o){const r=t[2*o],l=t[2*o+1];for(let f=o+1;f<s.length;++f){const u=t[2*f],a=t[2*f+1],y=s[o][f],h=e[o][f],b=(u-r)*(u-r)+(a-l)*(a-l),p=Math.sqrt(b),M=b-y*y;h>0&&p<=y||h<0&&p>=y||(i+=2*M*M,n[2*o]+=4*M*(r-u),n[2*o+1]+=4*M*(l-a),n[2*f]+=4*M*(u-r),n[2*f+1]+=4*M*(a-l))}}return i}function xe(t,n={}){let s=pe(t,n);const e=n.lossFunction||tt;if(t.length>=8){const i=ye(t,n),o=e(i,t),r=e(s,t);o+1e-8<r&&(s=i)}return s}function ye(t,n={}){const s=n.restarts||10,e=[],i={};for(const h of t)h.sets.length===1&&(i[h.sets[0]]=e.length,e.push(h));let{distances:o,constraints:r}=de(t,e,i);const l=ut(o.map(ut))/o.length;o=o.map(h=>h.map(b=>b/l));const f=(h,b)=>ge(h,b,o,r);let u=null;for(let h=0;h<s;++h){const b=ct(o.length*2).map(Math.random),p=fe(f,b,n);(!u||p.fx<u.fx)&&(u=p)}const a=u.x,y={};for(let h=0;h<e.length;++h){const b=e[h];y[b.sets[0]]={x:a[2*h]*l,y:a[2*h+1]*l,radius:Math.sqrt(b.size/Math.PI)}}if(n.history)for(const h of n.history)ft(h.x,l);return y}function pe(t,n){const s=n&&n.lossFunction?n.lossFunction:tt,e={},i={};for(const y of t)if(y.sets.length===1){const h=y.sets[0];e[h]={x:1e10,y:1e10,rowid:e.length,size:y.size,radius:Math.sqrt(y.size/Math.PI)},i[h]=[]}t=t.filter(y=>y.sets.length===2);for(const y of t){let h=y.weight!=null?y.weight:1;const b=y.sets[0],p=y.sets[1];y.size+Rt>=Math.min(e[b].size,e[p].size)&&(h=0),i[b].push({set:p,size:y.size,weight:h}),i[p].push({set:b,size:y.size,weight:h})}const o=[];Object.keys(i).forEach(y=>{let h=0;for(let b=0;b<i[y].length;++b)h+=i[y][b].size*i[y][b].weight;o.push({set:y,size:h})});function r(y,h){return h.size-y.size}o.sort(r);const l={};function f(y){return y.set in l}function u(y,h){e[h].x=y.x,e[h].y=y.y,l[h]=!0}u({x:0,y:0},o[0].set);for(let y=1;y<o.length;++y){const h=o[y].set,b=i[h].filter(f),p=e[h];if(b.sort(r),b.length===0)throw"ERROR: missing pairwise overlap information";const M=[];for(var a=0;a<b.length;++a){const S=e[b[a].set],g=ht(p.radius,S.radius,b[a].size);M.push({x:S.x+g,y:S.y}),M.push({x:S.x-g,y:S.y}),M.push({y:S.y+g,x:S.x}),M.push({y:S.y-g,x:S.x});for(let m=a+1;m<b.length;++m){const v=e[b[m].set],c=ht(p.radius,v.radius,b[m].size),x=Et({x:S.x,y:S.y,radius:g},{x:v.x,y:v.y,radius:c});M.push(...x)}}let T=1e50,_=M[0];for(const S of M){e[h].x=S.x,e[h].y=S.y;const g=s(e,t);g<T&&(T=g,_=S)}u(_,h)}return e}function tt(t,n){let s=0;for(const e of n){if(e.sets.length===1)continue;let i;if(e.sets.length===2){const r=t[e.sets[0]],l=t[e.sets[1]];i=xt(r.radius,l.radius,q(r,l))}else i=st(e.sets.map(r=>t[r]));const o=e.weight!=null?e.weight:1;s+=o*(i-e.size)*(i-e.size)}return s}function Dt(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]],f=t[e.sets[1]];i=xt(l.radius,f.radius,q(l,f))}else i=st(e.sets.map(l=>t[l]));const o=e.weight!=null?e.weight:1,r=Math.log((i+1)/(e.size+1));s+=o*r*r}return s}function me(t,n,s){if(s==null?t.sort((i,o)=>o.radius-i.radius):t.sort(s),t.length>0){const i=t[0].x,o=t[0].y;for(const r of t)r.x-=i,r.y-=o}if(t.length===2&&q(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,o=Math.cos(i),r=Math.sin(i);for(const l of t){const f=l.x,u=l.y;l.x=o*f-r*u,l.y=r*f+o*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 o=t[1].y/(1e-10+t[1].x);for(const r of t){var e=(r.x+o*r.y)/(1+o*o);r.x=2*e-r.x,r.y=2*e*o-r.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,o){const r=n(i),l=n(o);r.parent=l}for(let i=0;i<t.length;++i)for(let o=i+1;o<t.length;++o){const r=t[i].radius+t[o].radius;q(t[i],t[o])+1e-10<r&&s(t[o],t[i])}const e=new Map;for(let i=0;i<t.length;++i){const o=n(t[i]).parent.setid;e.has(o)||e.set(o,[]),e.get(o).push(t[i])}return t.forEach(i=>{delete i.parent}),Array.from(e.values())}function dt(t){const n=s=>{const e=t.reduce((o,r)=>Math.max(o,r[s]+r.radius),Number.NEGATIVE_INFINITY),i=t.reduce((o,r)=>Math.min(o,r[s]-r.radius),Number.POSITIVE_INFINITY);return{max:e,min:i}};return{xRange:n("x"),yRange:n("y")}}function Ct(t,n,s){n==null&&(n=Math.PI/2);let e=jt(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 o=e.bounds;const r=(o.xRange.max-o.xRange.min)/50;function l(u,a,y){if(!u)return;const h=u.bounds;let b,p;if(a)b=o.xRange.max-h.xRange.min+r;else{b=o.xRange.max-h.xRange.max;const M=(h.xRange.max-h.xRange.min)/2-(o.xRange.max-o.xRange.min)/2;M<0&&(b+=M)}if(y)p=o.yRange.max-h.yRange.min+r;else{p=o.yRange.max-h.yRange.max;const M=(h.yRange.max-h.yRange.min)/2-(o.yRange.max-o.yRange.min)/2;M<0&&(p+=M)}for(const M of u)M.x+=b,M.y+=p,e.push(M)}let f=1;for(;f<i.length;)l(i[f],!0,!1),l(i[f+1],!1,!0),l(i[f+2],!0,!0),f+=3,o=dt(e);return Ot(e)}function Nt(t,n,s,e,i){const o=jt(t);n-=2*e,s-=2*e;const{xRange:r,yRange:l}=dt(o);if(r.max===r.min||l.max===l.min)return console.log("not scaling solution: zero size detected"),t;let f,u;if(i){const b=Math.sqrt(i/Math.PI)*2;f=n/b,u=s/b}else f=n/(r.max-r.min),u=s/(l.max-l.min);const a=Math.min(u,f),y=(n-(r.max-r.min)*a)/2,h=(s-(l.max-l.min)*a)/2;return Ot(o.map(b=>({radius:a*b.radius,x:e+y+(b.x-r.min)*a,y:e+h+(b.y-l.min)*a,setid:b.setid})))}function Ot(t){const n={};for(const s of t)n[s.setid]=s;return n}function jt(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,o=1e3,r=Math.PI/2,l=!0,f=null,u=!0,a=!0,y=null,h=null,b=!1,p=null,M=t&&t.symmetricalTextCentre?t.symmetricalTextCentre:!1,T={},_=t&&t.colourScheme?t.colourScheme:t&&t.colorScheme?t.colorScheme:["#1f77b4","#ff7f0e","#2ca02c","#d62728","#9467bd","#8c564b","#e377c2","#7f7f7f","#bcbd22","#17becf"],S=0,g=function(x){if(x in T)return T[x];var d=T[x]=_[S];return S+=1,S>=_.length&&(S=0),d},m=At,v=tt;function c(x){let d=x.datum();const D=new Set;d.forEach(k=>{k.size==0&&k.sets.length==1&&D.add(k.sets[0])}),d=d.filter(k=>!k.sets.some(j=>D.has(j)));let I={},C={};if(d.length>0){let k=m(d,{lossFunction:v,distinct:b});l&&(k=Ct(k,r,h)),I=Nt(k,s,e,i,f),C=Lt(I,d,M)}const U={};d.forEach(k=>{k.label&&(U[k.sets]=k.label)});function V(k){if(k.sets in U)return U[k.sets];if(k.sets.length==1)return""+k.sets[0]}x.selectAll("svg").data([I]).enter().append("svg");const O=x.select("svg");n?O.attr("viewBox",`0 0 ${s} ${e}`):O.attr("width",s).attr("height",e);const R={};let E=!1;O.selectAll(".venn-area path").each(function(k){const j=this.getAttribute("d");k.sets.length==1&&j&&!b&&(E=!0,R[k.sets[0]]=Me(j))});function A(k){return j=>{const H=k.sets.map(et=>{let Y=R[et],Z=I[et];return Y||(Y={x:s/2,y:e/2,radius:1}),Z||(Z={x:s/2,y:e/2,radius:1}),{x:Y.x*(1-j)+Z.x*j,y:Y.y*(1-j)+Z.y*j,radius:Y.radius*(1-j)+Z.radius*j}});return St(H,p)}}const G=O.selectAll(".venn-area").data(d,k=>k.sets),P=G.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("_")),B=P.append("path"),L=P.append("text").attr("class","label").text(k=>V(k)).attr("text-anchor","middle").attr("dy",".35em").attr("x",s/2).attr("y",e/2);a&&(B.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 K(k){return typeof k.transition=="function"?k.transition("venn").duration(o):k}let z=x;E&&typeof z.transition=="function"?(z=K(x),z.selectAll("path").attrTween("d",A)):z.selectAll("path").attr("d",k=>St(k.sets.map(j=>I[j])),p);const N=z.selectAll("text").filter(k=>k.sets in C).text(k=>V(k)).attr("x",k=>Math.floor(C[k.sets].x)).attr("y",k=>Math.floor(C[k.sets].y));u&&(E?"on"in N?N.on("end",rt(I,V)):N.each("end",rt(I,V)):N.each(rt(I,V)));const F=K(G.exit()).remove();typeof G.transition=="function"&&F.selectAll("path").attrTween("d",A);const X=F.selectAll("text").attr("x",s/2).attr("y",e/2);return y!==null&&(L.style("font-size","0px"),N.style("font-size",y),X.style("font-size","0px")),{circles:I,textCentres:C,nodes:G,enter:P,update:z,exit:F}}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?(b=x,c):b},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?(y=x,c):y},c.round=function(x){return arguments.length?(p=x,c):p},c.duration=function(x){return arguments.length?(o=x,c):o},c.layoutFunction=function(x){return arguments.length?(m=x,c):m},c.normalize=function(x){return arguments.length?(l=x,c):l},c.scaleToFit=function(x){return arguments.length?(f=x,c):f},c.styled=function(x){return arguments.length?(a=x,c):a},c.orientation=function(x){return arguments.length?(r=x,c):r},c.orientationOrder=function(x){return arguments.length?(h=x,c):h},c.lossFunction=function(x){return arguments.length?(v=x==="default"?tt:x==="logRatio"?Dt:x,c):v},c}function rt(t,n){return function(s){const e=this,i=t[s.sets[0]].radius||50,o=n(s)||"",r=o.split(/\s+/).reverse(),f=(o.length+r.length)/3;let u=r.pop(),a=[u],y=0;const h=1.1;e.textContent=null;const b=[];function p(g){const m=e.ownerDocument.createElementNS(e.namespaceURI,"tspan");return m.textContent=g,b.push(m),e.append(m),m}let M=p(u);for(;u=r.pop(),!!u;){a.push(u);const g=a.join(" ");M.textContent=g,g.length>f&&M.getComputedTextLength()>i&&(a.pop(),M.textContent=a.join(" "),a=[u],M=p(u),y++)}const T=.35-y*h/2,_=e.getAttribute("x"),S=e.getAttribute("y");b.forEach((g,m)=>{g.setAttribute("x",_),g.setAttribute("y",S),g.setAttribute("dy",`${T+m*h}em`)})}}function at(t,n,s){let e=n[0].radius-q(n[0],t);for(let i=1;i<n.length;++i){const o=n[i].radius-q(n[i],t);o<=e&&(e=o)}for(let i=0;i<s.length;++i){const o=q(s[i],t)-s[i].radius;o<=e&&(e=o)}return e}function Ft(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],o=at(e[0],t,n);for(let a=1;a<e.length;++a){const y=at(e[a],t,n);y>=o&&(i=e[a],o=y)}const r=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:r[0],y:r[1]};let f=!0;for(const a of t)if(q(l,a)>a.radius){f=!1;break}for(const a of n)if(q(l,a)<a.radius){f=!1;break}if(f)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?Ft(t,[]):Tt(u.arcs.map(a=>a.p1))}function Ie(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],o=t[i];for(let r=e+1;r<s.length;++r){const l=s[r],f=t[l],u=q(o,f);u+f.radius<=o.radius+1e-10?n[l].push(i):u+o.radius<=f.radius+1e-10&&n[i].push(l)}}return n}function Lt(t,n,s){const e={},i=Ie(t);for(let o=0;o<n.length;++o){const r=n[o].sets,l={},f={};for(let h=0;h<r.length;++h){l[r[h]]=!0;const b=i[r[h]];for(let p=0;p<b.length;++p)f[b[p]]=!0}const u=[],a=[];for(let h in t)h in l?u.push(t[h]):h in f||a.push(t[h]);const y=Ft(u,a,s);e[r]=y,y.disjoint&&n[o].size>0&&console.log("WARNING: area "+r+" not represented on screen")}return e}function ke(t,n,s){const e=[];return e.push(`
|
|
1
|
+
import{b1 as Wt,s as Kt,g as Ht,q as Yt,p as Xt,a as Zt,b as Jt,_ as w,A as wt,G as Qt,j as ot,am as $t,ab as te,ac as ee,ad as ne,d as se,r as ie,D as oe,E as re}from"./mermaid.core-C4R8NQRz.js";import"./app-DDsVI393.js";const kt=(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,o=0;const r=[];if(e.length>1){const l=Tt(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 f=e[e.length-1];for(let u=0;u<e.length;++u){const a=e[u];o+=(f.x+a.x)*(a.y-f.y);const y={x:(a.x+f.x)/2,y:(a.y+f.y)/2};let h=null;for(let b=0;b<a.parentIndex.length;++b)if(f.parentIndex.includes(a.parentIndex[b])){const p=t[a.parentIndex[b]],M=Math.atan2(a.x-p.x,a.y-p.y),T=Math.atan2(f.x-p.x,f.y-p.y);let _=T-M;_<0&&(_+=2*Math.PI);const S=T-_/2;let g=q(y,{x:p.x+p.radius*Math.sin(S),y:p.y+p.radius*Math.cos(S)});g>p.radius*2&&(g=p.radius*2),(h==null||h.width>g)&&(h={circle:p,width:g,p1:a,p2:f,large:g>p.radius,sweep:!0})}h!=null&&(r.push(h),i+=lt(h.circle.radius,h.width),f=a)}}else{let l=t[0];for(let u=1;u<t.length;++u)t[u].radius<l.radius&&(l=t[u]);let f=!1;for(let u=0;u<t.length;++u)if(q(t[u],l)>Math.abs(l.radius-t[u].radius)){f=!0;break}f?i=o=0:(i=l.radius*l.radius*Math.PI,r.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 o/=2,n&&(n.area=i+o,n.arcArea=i,n.polygonArea=o,n.arcs=r,n.innerPoints=e,n.intersectionPoints=s),i+o}function ae(t,n){return n.every(s=>q(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=Et(t[s],t[e]);for(const o of i)o.parentIndex=[s,e],n.push(o)}return n}function lt(t,n){return t*t*Math.acos(1-n/t)-(t-n)*Math.sqrt(n*(2*t-n))}function q(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 Et(t,n){const s=q(t,n),e=t.radius,i=n.radius;if(s>=e+i||s<=Math.abs(e-i))return[];const o=(e*e-i*i+s*s)/(2*s),r=Math.sqrt(e*e-o*o),l=t.x+o*(n.x-t.x)/s,f=t.y+o*(n.y-t.y)/s,u=-(n.y-t.y)*(r/s),a=-(n.x-t.x)*(r/s);return[{x:l+u,y:f-a},{x:l-u,y:f+a}]}function Tt(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,o=e.tolerance||1e-10,r=t(n),l=t(s);let f=s-n;if(r*l>0)throw"Initial bisect points must have opposite signs";if(r===0)return n;if(l===0)return s;for(let u=0;u<i;++u){f/=2;const a=n+f,y=t(a);if(y*r>=0&&(n=a),Math.abs(f)<o||y===0)return a}return n+f}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 $(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($(t,t))}function ft(t,n,s){for(let e=0;e<n.length;++e)t[e]=n[e]*s}function J(t,n,s,e,i){for(let o=0;o<t.length;++o)t[o]=n*s[o]+e*i[o]}function zt(t,n,s){s=s||{};const e=s.maxIterations||n.length*200,i=s.nonZeroDelta||1.05,o=s.zeroDelta||.001,r=s.minErrorDelta||1e-6,l=s.minErrorDelta||1e-5,f=s.rho!==void 0?s.rho:1,u=s.chi!==void 0?s.chi:2,a=s.psi!==void 0?s.psi:-.5,y=s.sigma!==void 0?s.sigma:.5;let h;const b=n.length,p=new Array(b+1);p[0]=n,p[0].fx=t(n),p[0].id=0;for(let v=0;v<b;++v){const c=n.slice();c[v]=c[v]?c[v]*i:o,p[v+1]=c,p[v+1].fx=t(c),p[v+1].id=v+1}function M(v){for(let c=0;c<v.length;c++)p[b][c]=v[c];p[b].fx=v.fx}const T=(v,c)=>v.fx-c.fx,_=n.slice(),S=n.slice(),g=n.slice(),m=n.slice();for(let v=0;v<e;++v){if(p.sort(T),s.history){const x=p.map(d=>{const D=d.slice();return D.fx=d.fx,D.id=d.id,D});x.sort((d,D)=>d.id-D.id),s.history.push({x:p[0].slice(),fx:p[0].fx,simplex:x})}h=0;for(let x=0;x<b;++x)h=Math.max(h,Math.abs(p[0][x]-p[1][x]));if(Math.abs(p[0].fx-p[b].fx)<r&&h<l)break;for(let x=0;x<b;++x){_[x]=0;for(let d=0;d<b;++d)_[x]+=p[d][x];_[x]/=b}const c=p[b];if(J(S,1+f,_,-f,c),S.fx=t(S),S.fx<p[0].fx)J(m,1+u,_,-u,c),m.fx=t(m),m.fx<S.fx?M(m):M(S);else if(S.fx>=p[b-1].fx){let x=!1;if(S.fx>c.fx?(J(g,1+a,_,-a,c),g.fx=t(g),g.fx<c.fx?M(g):x=!0):(J(g,1-a*f,_,a*f,c),g.fx=t(g),g.fx<S.fx?M(g):x=!0),x){if(y>=1)break;for(let d=1;d<p.length;++d)J(p[d],1-y,p[0],y,p[d]),p[d].fx=t(p[d])}}else M(S)}return p.sort(T),{fx:p[0].fx,x:p[0]}}function ue(t,n,s,e,i,o,r){const l=s.fx,f=$(s.fxprime,n);let u=l,a=l,y=f,h=0;i=i||1,o=o||1e-6,r=r||.1;function b(p,M,T){for(let _=0;_<16;++_)if(i=(p+M)/2,J(e.x,1,s.x,i,n),u=e.fx=t(e.x,e.fxprime),y=$(e.fxprime,n),u>l+o*i*f||u>=T)M=i;else{if(Math.abs(y)<=-r*f)return i;y*(M-p)>=0&&(M=p),p=i,T=u}return 0}for(let p=0;p<10;++p){if(J(e.x,1,s.x,i,n),u=e.fx=t(e.x,e.fxprime),y=$(e.fxprime,n),u>l+o*i*f||p&&u>=a)return b(h,i,a);if(Math.abs(y)<=-r*f)return i;if(y>=0)return b(i,h,u);a=u,h=i,i*=2}return i}function fe(t,n,s){let e={x:n.slice(),fx:0,fxprime:n.slice()},i={x:n.slice(),fx:0,fxprime:n.slice()};const o=n.slice();let r,l,f=1,u;s=s||{},u=s.maxIterations||n.length*20,e.fx=t(e.x,e.fxprime),r=e.fxprime.slice(),ft(r,e.fxprime,-1);for(let a=0;a<u;++a){if(f=ue(t,r,e,i,f),s.history&&s.history.push({x:e.x.slice(),fx:e.fx,fxprime:e.fxprime.slice(),alpha:f}),!f)ft(r,e.fxprime,-1);else{J(o,1,i.fxprime,-1,e.fxprime);const y=$(e.fxprime,e.fxprime),h=Math.max(0,$(o,i.fxprime)/y);J(r,h,r,-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:f}),e}function At(t,n={}){n.maxIterations=n.maxIterations||500;const s=n.initialLayout||xe,e=n.lossFunction||tt,i=he(t,n),o=s(i,n),r=Object.keys(o),l=[];for(const a of r)l.push(o[a].x),l.push(o[a].y);const u=zt(a=>{const y={};for(let h=0;h<r.length;++h){const b=r[h];y[b]={x:a[2*h],y:a[2*h+1],radius:o[b].radius}}return e(y,i)},l,n).x;for(let a=0;a<r.length;++a){const y=r[a];o[y].x=u[2*a],o[y].y=u[2*a+1]}return o}const Rt=1e-10;function ht(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 he(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 f of e)for(let u=0;u<f.sets.length;u++){const a=String(f.sets[u]);l.set(a,f.size+(l.get(a)||0));for(let y=u+1;y<f.sets.length;y++){const h=String(f.sets[y]),b=`${a};${h}`,p=`${h};${a}`;l.set(b,f.size+(l.get(b)||0)),l.set(p,f.size+(l.get(p)||0))}}for(const f of e)f.sets.length<3&&(f.size=l.get(i(f.sets)))}const o=[],r=new Set;for(const l of e)if(l.sets.length===1)o.push(l.sets[0]);else if(l.sets.length===2){const f=l.sets[0],u=l.sets[1];r.add(i(l.sets)),r.add(i([u,f]))}o.sort((l,f)=>l===f?0:l<f?-1:1);for(let l=0;l<o.length;++l){const f=o[l];for(let u=l+1;u<o.length;++u){const a=o[u];r.has(i([f,a]))||e.push({sets:[f,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(o=>o.sets.length===2).forEach(o=>{const r=s[o.sets[0]],l=s[o.sets[1]],f=Math.sqrt(n[r].size/Math.PI),u=Math.sqrt(n[l].size/Math.PI),a=ht(f,u,o.size);e[r][l]=e[l][r]=a;let y=0;o.size+1e-10>=Math.min(n[r].size,n[l].size)?y=1:o.size<=1e-10&&(y=-1),i[r][l]=i[l][r]=y}),{distances:e,constraints:i}}function ge(t,n,s,e){for(let o=0;o<n.length;++o)n[o]=0;let i=0;for(let o=0;o<s.length;++o){const r=t[2*o],l=t[2*o+1];for(let f=o+1;f<s.length;++f){const u=t[2*f],a=t[2*f+1],y=s[o][f],h=e[o][f],b=(u-r)*(u-r)+(a-l)*(a-l),p=Math.sqrt(b),M=b-y*y;h>0&&p<=y||h<0&&p>=y||(i+=2*M*M,n[2*o]+=4*M*(r-u),n[2*o+1]+=4*M*(l-a),n[2*f]+=4*M*(u-r),n[2*f+1]+=4*M*(a-l))}}return i}function xe(t,n={}){let s=pe(t,n);const e=n.lossFunction||tt;if(t.length>=8){const i=ye(t,n),o=e(i,t),r=e(s,t);o+1e-8<r&&(s=i)}return s}function ye(t,n={}){const s=n.restarts||10,e=[],i={};for(const h of t)h.sets.length===1&&(i[h.sets[0]]=e.length,e.push(h));let{distances:o,constraints:r}=de(t,e,i);const l=ut(o.map(ut))/o.length;o=o.map(h=>h.map(b=>b/l));const f=(h,b)=>ge(h,b,o,r);let u=null;for(let h=0;h<s;++h){const b=ct(o.length*2).map(Math.random),p=fe(f,b,n);(!u||p.fx<u.fx)&&(u=p)}const a=u.x,y={};for(let h=0;h<e.length;++h){const b=e[h];y[b.sets[0]]={x:a[2*h]*l,y:a[2*h+1]*l,radius:Math.sqrt(b.size/Math.PI)}}if(n.history)for(const h of n.history)ft(h.x,l);return y}function pe(t,n){const s=n&&n.lossFunction?n.lossFunction:tt,e={},i={};for(const y of t)if(y.sets.length===1){const h=y.sets[0];e[h]={x:1e10,y:1e10,rowid:e.length,size:y.size,radius:Math.sqrt(y.size/Math.PI)},i[h]=[]}t=t.filter(y=>y.sets.length===2);for(const y of t){let h=y.weight!=null?y.weight:1;const b=y.sets[0],p=y.sets[1];y.size+Rt>=Math.min(e[b].size,e[p].size)&&(h=0),i[b].push({set:p,size:y.size,weight:h}),i[p].push({set:b,size:y.size,weight:h})}const o=[];Object.keys(i).forEach(y=>{let h=0;for(let b=0;b<i[y].length;++b)h+=i[y][b].size*i[y][b].weight;o.push({set:y,size:h})});function r(y,h){return h.size-y.size}o.sort(r);const l={};function f(y){return y.set in l}function u(y,h){e[h].x=y.x,e[h].y=y.y,l[h]=!0}u({x:0,y:0},o[0].set);for(let y=1;y<o.length;++y){const h=o[y].set,b=i[h].filter(f),p=e[h];if(b.sort(r),b.length===0)throw"ERROR: missing pairwise overlap information";const M=[];for(var a=0;a<b.length;++a){const S=e[b[a].set],g=ht(p.radius,S.radius,b[a].size);M.push({x:S.x+g,y:S.y}),M.push({x:S.x-g,y:S.y}),M.push({y:S.y+g,x:S.x}),M.push({y:S.y-g,x:S.x});for(let m=a+1;m<b.length;++m){const v=e[b[m].set],c=ht(p.radius,v.radius,b[m].size),x=Et({x:S.x,y:S.y,radius:g},{x:v.x,y:v.y,radius:c});M.push(...x)}}let T=1e50,_=M[0];for(const S of M){e[h].x=S.x,e[h].y=S.y;const g=s(e,t);g<T&&(T=g,_=S)}u(_,h)}return e}function tt(t,n){let s=0;for(const e of n){if(e.sets.length===1)continue;let i;if(e.sets.length===2){const r=t[e.sets[0]],l=t[e.sets[1]];i=xt(r.radius,l.radius,q(r,l))}else i=st(e.sets.map(r=>t[r]));const o=e.weight!=null?e.weight:1;s+=o*(i-e.size)*(i-e.size)}return s}function Dt(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]],f=t[e.sets[1]];i=xt(l.radius,f.radius,q(l,f))}else i=st(e.sets.map(l=>t[l]));const o=e.weight!=null?e.weight:1,r=Math.log((i+1)/(e.size+1));s+=o*r*r}return s}function me(t,n,s){if(s==null?t.sort((i,o)=>o.radius-i.radius):t.sort(s),t.length>0){const i=t[0].x,o=t[0].y;for(const r of t)r.x-=i,r.y-=o}if(t.length===2&&q(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,o=Math.cos(i),r=Math.sin(i);for(const l of t){const f=l.x,u=l.y;l.x=o*f-r*u,l.y=r*f+o*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 o=t[1].y/(1e-10+t[1].x);for(const r of t){var e=(r.x+o*r.y)/(1+o*o);r.x=2*e-r.x,r.y=2*e*o-r.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,o){const r=n(i),l=n(o);r.parent=l}for(let i=0;i<t.length;++i)for(let o=i+1;o<t.length;++o){const r=t[i].radius+t[o].radius;q(t[i],t[o])+1e-10<r&&s(t[o],t[i])}const e=new Map;for(let i=0;i<t.length;++i){const o=n(t[i]).parent.setid;e.has(o)||e.set(o,[]),e.get(o).push(t[i])}return t.forEach(i=>{delete i.parent}),Array.from(e.values())}function dt(t){const n=s=>{const e=t.reduce((o,r)=>Math.max(o,r[s]+r.radius),Number.NEGATIVE_INFINITY),i=t.reduce((o,r)=>Math.min(o,r[s]-r.radius),Number.POSITIVE_INFINITY);return{max:e,min:i}};return{xRange:n("x"),yRange:n("y")}}function Ct(t,n,s){n==null&&(n=Math.PI/2);let e=jt(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 o=e.bounds;const r=(o.xRange.max-o.xRange.min)/50;function l(u,a,y){if(!u)return;const h=u.bounds;let b,p;if(a)b=o.xRange.max-h.xRange.min+r;else{b=o.xRange.max-h.xRange.max;const M=(h.xRange.max-h.xRange.min)/2-(o.xRange.max-o.xRange.min)/2;M<0&&(b+=M)}if(y)p=o.yRange.max-h.yRange.min+r;else{p=o.yRange.max-h.yRange.max;const M=(h.yRange.max-h.yRange.min)/2-(o.yRange.max-o.yRange.min)/2;M<0&&(p+=M)}for(const M of u)M.x+=b,M.y+=p,e.push(M)}let f=1;for(;f<i.length;)l(i[f],!0,!1),l(i[f+1],!1,!0),l(i[f+2],!0,!0),f+=3,o=dt(e);return Ot(e)}function Nt(t,n,s,e,i){const o=jt(t);n-=2*e,s-=2*e;const{xRange:r,yRange:l}=dt(o);if(r.max===r.min||l.max===l.min)return console.log("not scaling solution: zero size detected"),t;let f,u;if(i){const b=Math.sqrt(i/Math.PI)*2;f=n/b,u=s/b}else f=n/(r.max-r.min),u=s/(l.max-l.min);const a=Math.min(u,f),y=(n-(r.max-r.min)*a)/2,h=(s-(l.max-l.min)*a)/2;return Ot(o.map(b=>({radius:a*b.radius,x:e+y+(b.x-r.min)*a,y:e+h+(b.y-l.min)*a,setid:b.setid})))}function Ot(t){const n={};for(const s of t)n[s.setid]=s;return n}function jt(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,o=1e3,r=Math.PI/2,l=!0,f=null,u=!0,a=!0,y=null,h=null,b=!1,p=null,M=t&&t.symmetricalTextCentre?t.symmetricalTextCentre:!1,T={},_=t&&t.colourScheme?t.colourScheme:t&&t.colorScheme?t.colorScheme:["#1f77b4","#ff7f0e","#2ca02c","#d62728","#9467bd","#8c564b","#e377c2","#7f7f7f","#bcbd22","#17becf"],S=0,g=function(x){if(x in T)return T[x];var d=T[x]=_[S];return S+=1,S>=_.length&&(S=0),d},m=At,v=tt;function c(x){let d=x.datum();const D=new Set;d.forEach(k=>{k.size==0&&k.sets.length==1&&D.add(k.sets[0])}),d=d.filter(k=>!k.sets.some(j=>D.has(j)));let I={},C={};if(d.length>0){let k=m(d,{lossFunction:v,distinct:b});l&&(k=Ct(k,r,h)),I=Nt(k,s,e,i,f),C=Lt(I,d,M)}const U={};d.forEach(k=>{k.label&&(U[k.sets]=k.label)});function V(k){if(k.sets in U)return U[k.sets];if(k.sets.length==1)return""+k.sets[0]}x.selectAll("svg").data([I]).enter().append("svg");const O=x.select("svg");n?O.attr("viewBox",`0 0 ${s} ${e}`):O.attr("width",s).attr("height",e);const R={};let E=!1;O.selectAll(".venn-area path").each(function(k){const j=this.getAttribute("d");k.sets.length==1&&j&&!b&&(E=!0,R[k.sets[0]]=Me(j))});function A(k){return j=>{const H=k.sets.map(et=>{let Y=R[et],Z=I[et];return Y||(Y={x:s/2,y:e/2,radius:1}),Z||(Z={x:s/2,y:e/2,radius:1}),{x:Y.x*(1-j)+Z.x*j,y:Y.y*(1-j)+Z.y*j,radius:Y.radius*(1-j)+Z.radius*j}});return St(H,p)}}const G=O.selectAll(".venn-area").data(d,k=>k.sets),P=G.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("_")),B=P.append("path"),L=P.append("text").attr("class","label").text(k=>V(k)).attr("text-anchor","middle").attr("dy",".35em").attr("x",s/2).attr("y",e/2);a&&(B.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 K(k){return typeof k.transition=="function"?k.transition("venn").duration(o):k}let z=x;E&&typeof z.transition=="function"?(z=K(x),z.selectAll("path").attrTween("d",A)):z.selectAll("path").attr("d",k=>St(k.sets.map(j=>I[j])),p);const N=z.selectAll("text").filter(k=>k.sets in C).text(k=>V(k)).attr("x",k=>Math.floor(C[k.sets].x)).attr("y",k=>Math.floor(C[k.sets].y));u&&(E?"on"in N?N.on("end",rt(I,V)):N.each("end",rt(I,V)):N.each(rt(I,V)));const F=K(G.exit()).remove();typeof G.transition=="function"&&F.selectAll("path").attrTween("d",A);const X=F.selectAll("text").attr("x",s/2).attr("y",e/2);return y!==null&&(L.style("font-size","0px"),N.style("font-size",y),X.style("font-size","0px")),{circles:I,textCentres:C,nodes:G,enter:P,update:z,exit:F}}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?(b=x,c):b},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?(y=x,c):y},c.round=function(x){return arguments.length?(p=x,c):p},c.duration=function(x){return arguments.length?(o=x,c):o},c.layoutFunction=function(x){return arguments.length?(m=x,c):m},c.normalize=function(x){return arguments.length?(l=x,c):l},c.scaleToFit=function(x){return arguments.length?(f=x,c):f},c.styled=function(x){return arguments.length?(a=x,c):a},c.orientation=function(x){return arguments.length?(r=x,c):r},c.orientationOrder=function(x){return arguments.length?(h=x,c):h},c.lossFunction=function(x){return arguments.length?(v=x==="default"?tt:x==="logRatio"?Dt:x,c):v},c}function rt(t,n){return function(s){const e=this,i=t[s.sets[0]].radius||50,o=n(s)||"",r=o.split(/\s+/).reverse(),f=(o.length+r.length)/3;let u=r.pop(),a=[u],y=0;const h=1.1;e.textContent=null;const b=[];function p(g){const m=e.ownerDocument.createElementNS(e.namespaceURI,"tspan");return m.textContent=g,b.push(m),e.append(m),m}let M=p(u);for(;u=r.pop(),!!u;){a.push(u);const g=a.join(" ");M.textContent=g,g.length>f&&M.getComputedTextLength()>i&&(a.pop(),M.textContent=a.join(" "),a=[u],M=p(u),y++)}const T=.35-y*h/2,_=e.getAttribute("x"),S=e.getAttribute("y");b.forEach((g,m)=>{g.setAttribute("x",_),g.setAttribute("y",S),g.setAttribute("dy",`${T+m*h}em`)})}}function at(t,n,s){let e=n[0].radius-q(n[0],t);for(let i=1;i<n.length;++i){const o=n[i].radius-q(n[i],t);o<=e&&(e=o)}for(let i=0;i<s.length;++i){const o=q(s[i],t)-s[i].radius;o<=e&&(e=o)}return e}function Ft(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],o=at(e[0],t,n);for(let a=1;a<e.length;++a){const y=at(e[a],t,n);y>=o&&(i=e[a],o=y)}const r=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:r[0],y:r[1]};let f=!0;for(const a of t)if(q(l,a)>a.radius){f=!1;break}for(const a of n)if(q(l,a)<a.radius){f=!1;break}if(f)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?Ft(t,[]):Tt(u.arcs.map(a=>a.p1))}function Ie(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],o=t[i];for(let r=e+1;r<s.length;++r){const l=s[r],f=t[l],u=q(o,f);u+f.radius<=o.radius+1e-10?n[l].push(i):u+o.radius<=f.radius+1e-10&&n[i].push(l)}}return n}function Lt(t,n,s){const e={},i=Ie(t);for(let o=0;o<n.length;++o){const r=n[o].sets,l={},f={};for(let h=0;h<r.length;++h){l[r[h]]=!0;const b=i[r[h]];for(let p=0;p<b.length;++p)f[b[p]]=!0}const u=[],a=[];for(let h in t)h in l?u.push(t[h]):h in f||a.push(t[h]);const y=Ft(u,a,s);e[r]=y,y.disjoint&&n[o].size>0&&console.log("WARNING: area "+r+" not represented on screen")}return e}function ke(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(`
|
package/web/assets/{wardleyDiagram-VM6X3IG4-DO0onK3t.js → wardleyDiagram-VM6X3IG4-CH8aTVHX.js}
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{p as St}from"./chunk-JWPE2WC7-
|
|
1
|
+
import{p as St}from"./chunk-JWPE2WC7-BrmOFhXE.js";import{s as Mt,g as Nt,q as zt,p as Lt,a as Tt,b as At,_ as u,X as Xt,A as Et,D as U,l as K,G as Yt,d as It,r as Bt,c as j}from"./mermaid.core-C4R8NQRz.js";import{p as Ft}from"./cynefin-OW5HDTMX-290exk3b.js";import"./app-DDsVI393.js";var D=u((e,n)=>{const r=e<=1?e*100:e;if(r<0||r>100)throw new Error(`${n} must be between 0-1 (decimal) or 0-100 (percentage). Received: ${e}`);return r},"toPercent"),A=u((e,n,r)=>({x:D(n,`${r} evolution`),y:D(e,`${r} visibility`)}),"toCoordinates"),J=u(e=>{if(e){if(e==="+<>")return"bidirectional";if(e==="+<")return"backward";if(e==="+>")return"forward"}},"getFlowFromPort"),Rt=u(e=>{if(!e?.startsWith("+"))return{};const r=/^\+'([^']*)'/.exec(e)?.[1];return e.includes("<>")?{flow:"bidirectional",label:r}:e.includes("<")?{flow:"backward",label:r}:e.includes(">")?{flow:"forward",label:r}:{label:r}},"extractFlowFromArrow"),Ot=u((e,n)=>{if(St(e,n),e.size&&n.setSize(e.size.width,e.size.height),e.evolution){const r=e.evolution.stages.map(a=>a.secondName?`${a.name.trim()} / ${a.secondName.trim()}`:a.name.trim()),x=e.evolution.stages.filter(a=>a.boundary!==void 0).map(a=>a.boundary);n.updateAxes({stages:r,stageBoundaries:x})}if(e.anchors.forEach(r=>{const x=A(r.visibility,r.evolution,`Anchor "${r.name}"`);n.addNode(r.name,r.name,x.x,x.y,"anchor")}),e.components.forEach(r=>{const x=A(r.visibility,r.evolution,`Component "${r.name}"`),a=r.label?(r.label.negX?-1:1)*r.label.offsetX:void 0,d=r.label?(r.label.negY?-1:1)*r.label.offsetY:void 0,w=r.decorator?.strategy;n.addNode(r.name,r.name,x.x,x.y,"component",a,d,r.inertia,w)}),e.notes.forEach(r=>{const x=A(r.visibility,r.evolution,`Note "${r.text}"`);n.addNote(r.text,x.x,x.y)}),e.pipelines.forEach(r=>{const x=n.getNode(r.parent);if(!x||typeof x.y!="number")throw new Error(`Pipeline "${r.parent}" must reference an existing component with coordinates.`);const a=x.y;n.startPipeline(r.parent),r.components.forEach(d=>{const w=`${r.parent}_${d.name}`,C=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,F=D(d.evolution,`Pipeline component "${d.name}" evolution`);n.addNode(w,d.name,F,a,"pipeline-component",C,g),n.addPipelineComponent(r.parent,w)})}),e.links.forEach(r=>{const x=!!r.arrow&&(r.arrow.includes("-.->")||r.arrow.includes(".-."));let a=J(r.fromPort)??J(r.toPort);const{flow:d,label:w}=Rt(r.arrow);!a&&d&&(a=d);const C=r.linkLabel,g=w??C;n.addLink(n.resolveNodeId(r.from),n.resolveNodeId(r.to),x,g,a)}),e.evolves.forEach(r=>{const x=n.getNode(r.component);if(x?.y!==void 0){const a=D(r.target,`Evolve target for "${r.component}"`);n.addTrend(r.component,a,x.y)}}),e.annotations.length>0){const r=e.annotations[0],x=A(r.x,r.y,"Annotations box");n.setAnnotationsBox(x.x,x.y)}e.annotation.forEach(r=>{const x=A(r.x,r.y,`Annotation ${r.number}`);n.addAnnotation(r.number,[{x:x.x,y:x.y}],r.text)}),e.accelerators.forEach(r=>{const x=A(r.x,r.y,`Accelerator "${r.name}"`);n.addAccelerator(r.name,x.x,x.y)}),e.deaccelerators.forEach(r=>{const x=A(r.x,r.y,`Deaccelerator "${r.name}"`);n.addDeaccelerator(r.name,x.x,x.y)})},"populateDb"),Q={parser:{yy:void 0},parse:u(async e=>{const n=await Ft("wardley",e);K.debug(n);const r=Q.parser?.yy;if(!r||typeof r.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.");Ot(n,r)},"parse")},Wt=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={}}static{u(this,"WardleyBuilder")}addNode(e){const n=this.nodes.get(e.id)??{id:e.id,label:e.label},r={...n,...e,className:e.className??n.className,labelOffsetX:e.labelOffsetX??n.labelOffsetX,labelOffsetY:e.labelOffsetY??n.labelOffsetY};this.nodes.set(e.id,r)}addLink(e){this.links.push(e)}addTrend(e){this.trends.set(e.nodeId,e)}startPipeline(e){this.pipelines.set(e,{nodeId:e,componentIds:[]});const n=this.nodes.get(e);n&&(n.isPipelineParent=!0)}addPipelineComponent(e,n){const r=this.pipelines.get(e);r&&r.componentIds.push(n);const x=this.nodes.get(n);x&&(x.inPipeline=!0)}addAnnotation(e){this.annotations.push(e)}addNote(e){this.notes.push(e)}addAccelerator(e){this.accelerators.push(e)}addDeaccelerator(e){this.deaccelerators.push(e)}setAnnotationsBox(e,n){this.annotationsBox={x:e,y:n}}setAxes(e){this.axes={...this.axes,...e}}setSize(e,n){this.size={width:e,height:n}}getNode(e){return this.nodes.get(e)}resolveNodeId(e){if(this.nodes.has(e))return e;for(const[n,r]of this.nodes)if(r.label===e)return n;return e}build(){const e=[];for(const n of this.nodes.values()){if(typeof n.x!="number"||typeof n.y!="number")throw new Error(`Node "${n.label}" is missing coordinates`);e.push(n)}return{nodes:e,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}},k=new Wt;function tt(){return j()["wardley-beta"]}u(tt,"getConfig");function et(e,n,r,x,a,d,w,C,g){k.addNode({id:e,label:n,x:r,y:x,className:a,labelOffsetX:d,labelOffsetY:w,inertia:C,sourceStrategy:g})}u(et,"addNode");function at(e,n,r=!1,x,a){k.addLink({source:e,target:n,dashed:r,label:x,flow:a})}u(at,"addLink");function rt(e,n,r){k.addTrend({nodeId:e,targetX:n,targetY:r})}u(rt,"addTrend");function ot(e,n,r){k.addAnnotation({number:e,coordinates:n,text:r})}u(ot,"addAnnotation");function nt(e,n,r){k.addNote({text:e,x:n,y:r})}u(nt,"addNote");function st(e,n,r){k.addAccelerator({name:e,x:n,y:r})}u(st,"addAccelerator");function it(e,n,r){k.addDeaccelerator({name:e,x:n,y:r})}u(it,"addDeaccelerator");function dt(e,n){k.setAnnotationsBox(e,n)}u(dt,"setAnnotationsBox");function lt(e,n){k.setSize(e,n)}u(lt,"setSize");function ct(e){k.startPipeline(e)}u(ct,"startPipeline");function pt(e,n){k.addPipelineComponent(e,n)}u(pt,"addPipelineComponent");function ft(e){k.setAxes(e)}u(ft,"updateAxes");function ht(e){return k.getNode(e)}u(ht,"getNode");function xt(e){return k.resolveNodeId(e)}u(xt,"resolveNodeId");function gt(){return k.build()}u(gt,"getWardleyData");function yt(){k.clear(),Bt()}u(yt,"clear");var Dt={getConfig:tt,addNode:et,addLink:at,addTrend:rt,addAnnotation:ot,addNote:nt,addAccelerator:st,addDeaccelerator:it,setAnnotationsBox:dt,setSize:lt,startPipeline:ct,addPipelineComponent:pt,updateAxes:ft,getNode:ht,resolveNodeId:xt,getWardleyData:gt,clear:yt,setAccTitle:At,getAccTitle:Tt,setDiagramTitle:Lt,getDiagramTitle:zt,getAccDescription:Nt,setAccDescription:Mt},Gt=["Genesis","Custom Built","Product","Commodity"],qt=u(()=>{const{themeVariables:e}=j();return{backgroundColor:e.wardley?.backgroundColor??e.background??"#fff",axisColor:e.wardley?.axisColor??"#000",axisTextColor:e.wardley?.axisTextColor??e.primaryTextColor??"#222",gridColor:e.wardley?.gridColor??"rgba(100, 100, 100, 0.2)",componentFill:e.wardley?.componentFill??"#fff",componentStroke:e.wardley?.componentStroke??"#000",componentLabelColor:e.wardley?.componentLabelColor??e.primaryTextColor??"#222",linkStroke:e.wardley?.linkStroke??"#000",evolutionStroke:e.wardley?.evolutionStroke??"#dc3545",annotationStroke:e.wardley?.annotationStroke??"#000",annotationTextColor:e.wardley?.annotationTextColor??e.primaryTextColor??"#222",annotationFill:e.wardley?.annotationFill??e.background??"#fff"}},"getTheme"),Ht=u(()=>{const e=j()["wardley-beta"];return{width:e?.width??900,height:e?.height??600,padding:e?.padding??48,nodeRadius:e?.nodeRadius??6,nodeLabelOffset:e?.nodeLabelOffset??8,axisFontSize:e?.axisFontSize??12,labelFontSize:e?.labelFontSize??10,showGrid:e?.showGrid??!1,useMaxWidth:e?.useMaxWidth??!0}},"getConfigValues"),jt=u((e,n,r,x)=>{K.debug(`Rendering Wardley map
|
|
2
2
|
`+e);const a=Ht(),d=qt(),w=a.nodeRadius*1.6,C=x.db,g=C.getWardleyData(),F=C.getDiagramTitle(),S=g.size?.width??a.width,b=g.size?.height??a.height,E=Yt(n);E.selectAll("*").remove(),It(E,b,S,a.useMaxWidth),E.attr("viewBox",`0 0 ${S} ${b}`);const v=E.append("g").attr("class","wardley-map"),G=E.append("defs");G.append("marker").attr("id",`arrow-${n}`).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"),G.append("marker").attr("id",`link-arrow-end-${n}`).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"),G.append("marker").attr("id",`link-arrow-start-${n}`).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"),v.append("rect").attr("class","wardley-background").attr("width",S).attr("height",b).attr("fill",d.backgroundColor);const Y=S-a.padding*2,I=b-a.padding*2;F&&v.append("text").attr("class","wardley-title").attr("x",S/2).attr("y",a.padding/2).attr("fill",d.axisTextColor).attr("font-size",a.axisFontSize*1.05).attr("font-weight","bold").attr("text-anchor","middle").attr("dominant-baseline","middle").text(F);const z=u(t=>a.padding+t/100*Y,"projectX"),L=u(t=>b-a.padding-t/100*I,"projectY"),R=v.append("g").attr("class","wardley-axes");R.append("line").attr("x1",a.padding).attr("x2",S-a.padding).attr("y1",b-a.padding).attr("y2",b-a.padding).attr("stroke",d.axisColor).attr("stroke-width",1),R.append("line").attr("x1",a.padding).attr("x2",a.padding).attr("y1",a.padding).attr("y2",b-a.padding).attr("stroke",d.axisColor).attr("stroke-width",1);const ut=g.axes.xLabel??"Evolution",wt=g.axes.yLabel??"Visibility";R.append("text").attr("class","wardley-axis-label wardley-axis-label-x").attr("x",a.padding+Y/2).attr("y",b-a.padding/4).attr("fill",d.axisTextColor).attr("font-size",a.axisFontSize).attr("font-weight","bold").attr("text-anchor","middle").text(ut),R.append("text").attr("class","wardley-axis-label wardley-axis-label-y").attr("x",a.padding/3).attr("y",a.padding+I/2).attr("fill",d.axisTextColor).attr("font-size",a.axisFontSize).attr("font-weight","bold").attr("text-anchor","middle").attr("transform",`rotate(-90 ${a.padding/3} ${a.padding+I/2})`).text(wt);const B=g.axes.stages&&g.axes.stages.length>0?g.axes.stages:Gt;if(B.length>0){const t=v.append("g").attr("class","wardley-stages"),s=g.axes.stageBoundaries,o=[];if(s&&s.length===B.length){let i=0;s.forEach(p=>{o.push({start:i,end:p}),i=p})}else{const i=1/B.length;B.forEach((p,l)=>{o.push({start:l*i,end:(l+1)*i})})}B.forEach((i,p)=>{const l=o[p],f=a.padding+l.start*Y,h=a.padding+l.end*Y,y=(f+h)/2;p>0&&t.append("line").attr("x1",f).attr("x2",f).attr("y1",a.padding).attr("y2",b-a.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",y).attr("y",b-a.padding/1.5).attr("fill",d.axisTextColor).attr("font-size",a.axisFontSize-2).attr("text-anchor","middle").text(i)})}if(a.showGrid){const t=v.append("g").attr("class","wardley-grid");for(let s=1;s<4;s++){const o=s/4,i=a.padding+Y*o;t.append("line").attr("x1",i).attr("x2",i).attr("y1",a.padding).attr("y2",b-a.padding).attr("stroke",d.gridColor).attr("stroke-dasharray","2 6"),t.append("line").attr("x1",a.padding).attr("x2",S-a.padding).attr("y1",b-a.padding-I*o).attr("y2",b-a.padding-I*o).attr("stroke",d.gridColor).attr("stroke-dasharray","2 6")}}const c=new Map;if(g.nodes.forEach(t=>{c.set(t.id,{x:z(t.x),y:L(t.y),node:t})}),g.pipelines.length>0){const t=v.append("g").attr("class","wardley-pipelines"),s=v.append("g").attr("class","wardley-pipeline-links");g.pipelines.forEach(o=>{if(o.componentIds.length===0)return;const i=o.componentIds.map(h=>({id:h,pos:c.get(h),node:g.nodes.find(y=>y.id===h)})).filter(h=>h.pos&&h.node).sort((h,y)=>h.node.x-y.node.x);for(let h=0;h<i.length-1;h++){const y=i[h],m=i[h+1];s.append("line").attr("class","wardley-pipeline-evolution-link").attr("x1",y.pos.x).attr("y1",y.pos.y).attr("x2",m.pos.x).attr("y2",m.pos.y).attr("stroke",d.linkStroke).attr("stroke-width",1).attr("stroke-dasharray","4 4")}let p=1/0,l=-1/0,f=0;if(o.componentIds.forEach(h=>{const y=c.get(h);y&&(p=Math.min(p,y.x),l=Math.max(l,y.x),f=y.y)}),p!==1/0&&l!==-1/0){const y=a.nodeRadius*4,m=f-y/2,P=c.get(o.nodeId);if(P){const N=(p+l)/2;P.x=N,P.y=m-w/6}t.append("rect").attr("class","wardley-pipeline-box").attr("x",p-15).attr("y",m).attr("width",l-p+30).attr("height",y).attr("fill","none").attr("stroke",d.axisColor).attr("stroke-width",1.5).attr("rx",4).attr("ry",4)}})}const V=v.append("g").attr("class","wardley-links"),_=new Map;g.pipelines.forEach(t=>{_.set(t.nodeId,new Set(t.componentIds))});const Z=g.links.filter(t=>!(!c.has(t.source)||!c.has(t.target)||_.get(t.target)?.has(t.source)));V.selectAll("line").data(Z).enter().append("line").attr("class",t=>`wardley-link${t.dashed?" wardley-link--dashed":""}`).attr("x1",t=>{const s=c.get(t.source),o=c.get(t.target),p=g.nodes.find(y=>y.id===t.source).isPipelineParent?w/Math.sqrt(2):a.nodeRadius,l=o.x-s.x,f=o.y-s.y,h=Math.sqrt(l*l+f*f);return s.x+l/h*p}).attr("y1",t=>{const s=c.get(t.source),o=c.get(t.target),p=g.nodes.find(y=>y.id===t.source).isPipelineParent?w/Math.sqrt(2):a.nodeRadius,l=o.x-s.x,f=o.y-s.y,h=Math.sqrt(l*l+f*f);return s.y+f/h*p}).attr("x2",t=>{const s=c.get(t.source),o=c.get(t.target),p=g.nodes.find(y=>y.id===t.target).isPipelineParent?w/Math.sqrt(2):a.nodeRadius,l=s.x-o.x,f=s.y-o.y,h=Math.sqrt(l*l+f*f);return o.x+l/h*p}).attr("y2",t=>{const s=c.get(t.source),o=c.get(t.target),p=g.nodes.find(y=>y.id===t.target).isPipelineParent?w/Math.sqrt(2):a.nodeRadius,l=s.x-o.x,f=s.y-o.y,h=Math.sqrt(l*l+f*f);return o.y+f/h*p}).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-${n})`:null).attr("marker-start",t=>t.flow==="backward"||t.flow==="bidirectional"?`url(#link-arrow-start-${n})`:null),V.selectAll("text").data(Z.filter(t=>t.label)).enter().append("text").attr("class","wardley-link-label").attr("x",t=>{const s=c.get(t.source),o=c.get(t.target),i=(s.x+o.x)/2,p=o.y-s.y,l=o.x-s.x,f=Math.sqrt(l*l+p*p),h=8,y=p/f;return i+y*h}).attr("y",t=>{const s=c.get(t.source),o=c.get(t.target),i=(s.y+o.y)/2,p=o.x-s.x,l=o.y-s.y,f=Math.sqrt(p*p+l*l),h=8,y=-p/f;return i+y*h}).attr("fill",d.axisTextColor).attr("font-size",a.labelFontSize).attr("text-anchor","middle").attr("dominant-baseline","middle").attr("transform",t=>{const s=c.get(t.source),o=c.get(t.target),i=(s.x+o.x)/2,p=(s.y+o.y)/2,l=o.x-s.x,f=o.y-s.y,h=Math.sqrt(l*l+f*f),y=8,m=f/h,P=-l/h,N=i+m*y,O=p+P*y;let X=Math.atan2(f,l)*180/Math.PI;return(X>90||X<-90)&&(X+=180),`rotate(${X} ${N} ${O})`}).text(t=>t.label);const mt=v.append("g").attr("class","wardley-trends"),kt=g.trends.map(t=>{const s=c.get(t.nodeId);if(!s)return null;const o=z(t.targetX),i=L(t.targetY),p=o-s.x,l=i-s.y,f=Math.sqrt(p*p+l*l),h=a.nodeRadius+2,y=f>h?o-p/f*h:o,m=f>h?i-l/f*h:i;return{origin:s,targetX:o,targetY:i,adjustedX2:y,adjustedY2:m}}).filter(t=>t!==null);mt.selectAll("line").data(kt).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-${n})`);const M=v.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(" "));M.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",a.nodeRadius*2).attr("fill","#666").attr("stroke",d.componentStroke).attr("stroke-width",1),M.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",a.nodeRadius*2).attr("fill","#ccc").attr("stroke",d.componentStroke).attr("stroke-width",1),M.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",a.nodeRadius*2).attr("fill","#eee").attr("stroke","#000").attr("stroke-width",1);const T=M.filter(t=>t.sourceStrategy==="market");T.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",a.nodeRadius*2).attr("fill","white").attr("stroke",d.componentStroke).attr("stroke-width",1),M.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",a.nodeRadius).attr("fill",d.componentFill).attr("stroke",d.componentStroke).attr("stroke-width",1);const q=a.nodeRadius*.7,$=a.nodeRadius*1.2;if(T.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),T.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),T.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),T.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",q).attr("fill","white").attr("stroke",d.componentStroke).attr("stroke-width",2),T.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",q).attr("fill","white").attr("stroke",d.componentStroke).attr("stroke-width",2),T.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",q).attr("fill","white").attr("stroke",d.componentStroke).attr("stroke-width",2),M.filter(t=>t.isPipelineParent===!0).append("rect").attr("x",t=>c.get(t.id).x-w/2).attr("y",t=>c.get(t.id).y-w/2).attr("width",w).attr("height",w).attr("fill",d.componentFill).attr("stroke",d.componentStroke).attr("stroke-width",1),M.filter(t=>t.inertia===!0).append("line").attr("class","wardley-inertia").attr("x1",t=>{const s=c.get(t.id);let o=t.isPipelineParent?w/2+15:a.nodeRadius+15;return t.sourceStrategy&&(o+=a.nodeRadius+10),s.x+o}).attr("y1",t=>{const s=c.get(t.id),o=t.isPipelineParent?w:a.nodeRadius*2;return s.y-o/2}).attr("x2",t=>{const s=c.get(t.id);let o=t.isPipelineParent?w/2+15:a.nodeRadius+15;return t.sourceStrategy&&(o+=a.nodeRadius+10),s.x+o}).attr("y2",t=>{const s=c.get(t.id),o=t.isPipelineParent?w:a.nodeRadius*2;return s.y+o/2}).attr("stroke",d.componentStroke).attr("stroke-width",6),M.append("text").attr("x",t=>{const s=c.get(t.id);if(t.className==="anchor")return t.labelOffsetX!==void 0?s.x+t.labelOffsetX:s.x;let o=a.nodeLabelOffset;t.sourceStrategy&&t.labelOffsetX===void 0&&(o+=10);const i=t.labelOffsetX??o;return s.x+i}).attr("y",t=>{const s=c.get(t.id);if(t.className==="anchor")return t.labelOffsetY!==void 0?s.y+t.labelOffsetY:s.y-3;let o=-a.nodeLabelOffset;t.sourceStrategy&&t.labelOffsetY===void 0&&(o-=10);const i=t.labelOffsetY??o;return s.y+i}).attr("class","wardley-node-label").attr("fill",t=>t.className==="evolved"?d.evolutionStroke:t.className==="anchor"?"#000":d.componentLabelColor).attr("font-size",a.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=v.append("g").attr("class","wardley-annotations");if(g.annotations.forEach(s=>{const o=s.coordinates.map(i=>({x:z(i.x),y:L(i.y)}));if(o.length>1)for(let i=0;i<o.length-1;i++)t.append("line").attr("class","wardley-annotation-line").attr("x1",o[i].x).attr("y1",o[i].y).attr("x2",o[i+1].x).attr("y2",o[i+1].y).attr("stroke",d.axisColor).attr("stroke-width",1.5).attr("stroke-dasharray","4 4");o.forEach(i=>{const p=t.append("g").attr("class","wardley-annotation");p.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),p.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(s.number)})}),g.annotationsBox){let s=z(g.annotationsBox.x),o=L(g.annotationsBox.y);const i=10,p=16,l=11,f=t.append("g").attr("class","wardley-annotations-box"),h=[...g.annotations].filter(m=>m.text).sort((m,P)=>m.number-P.number),y=[];if(h.forEach((m,P)=>{const N=f.append("text").attr("x",s+i).attr("y",o+i+(P+1)*p).attr("font-size",l).attr("fill",d.axisTextColor).attr("text-anchor","start").attr("dominant-baseline","middle").text(`${m.number}. ${m.text}`);y.push(N)}),y.length>0){let m=0,P=0;y.forEach(H=>{const W=H.node(),Pt=W.getComputedTextLength();m=Math.max(m,Pt);const Ct=W.getBBox();P=Math.max(P,Ct.height)});const N=m+i*2+105,O=h.length*p+i*2+P/2,X=a.padding,bt=S-a.padding-N,$t=a.padding,vt=b-a.padding-O;s=Math.max(X,Math.min(s,bt)),o=Math.max($t,Math.min(o,vt)),y.forEach((H,W)=>{H.attr("x",s+i).attr("y",o+i+(W+1)*p)}),f.insert("rect","text").attr("x",s).attr("y",o).attr("width",N).attr("height",O).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=v.append("g").attr("class","wardley-notes");g.notes.forEach(s=>{const o=z(s.x),i=L(s.y);t.append("text").attr("x",o).attr("y",i).attr("text-anchor","start").attr("font-size",11).attr("fill",d.axisTextColor).attr("font-weight","bold").text(s.text)})}if(g.accelerators.length>0){const t=v.append("g").attr("class","wardley-accelerators");g.accelerators.forEach(s=>{const o=z(s.x),i=L(s.y),p=60,l=30,f=20,h=`
|
|
3
3
|
M ${o} ${i-l/2}
|
|
4
4
|
L ${o+p-f} ${i-l/2}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{r as U,j as oe,
|
|
1
|
+
import{r as U,j as oe,e as Ul,u as Kl,I as Wl,h as Gl,S as Yl,i as Xl,B as Ql,R as Jl,c as Zl}from"./app-DDsVI393.js";const cr="file-tree-container",vo="data-file-tree-style",yo="data-file-tree-unsafe-css",ea="data-file-tree-scrollbar-measure",bo="data-file-tree-scrollbar-gutter-measured",ta="--trees-scrollbar-gutter-measured",Vn="header",Yt="context-menu",na="context-menu-trigger",Io=typeof window>"u"?U.useEffect:U.useLayoutEffect;function ra(e,t,n){const r=e!=null?oe.jsx("div",{slot:Vn,children:e}):null,o=t!=null&&n!=null?oe.jsx("div",{slot:Yt,children:t(n.item,n.context)}):null;return r==null&&o==null?null:oe.jsxs(oe.Fragment,{children:[r,o]})}function oa(e,t){return typeof window>"u"&&t!=null?oe.jsxs(oe.Fragment,{children:[oe.jsx("template",{shadowrootmode:"open",dangerouslySetInnerHTML:{__html:t.shadowHtml}}),e]}):oe.jsx(oe.Fragment,{children:e})}function ia(e){const t=e.shadowRoot;return t?.querySelector("[data-file-tree-id]")instanceof HTMLElement||t?.querySelector("[data-file-tree-id]")instanceof SVGElement?!0:e.querySelector('template[shadowrootmode="open"]')instanceof HTMLTemplateElement}function sa(e,t,n,r,o){const i={...e??{}};if(t!=null&&delete i.header,n){const s=e?.contextMenu,l=s?.onClose,a=s?.onOpen;i.contextMenu={...s??{},enabled:!0,onClose:()=>{l?.(),r()},onOpen:(d,h)=>{o(d,h),a?.(d,h)}},delete i.contextMenu.render}return i.header!=null||i.contextMenu!=null?i:void 0}function la({header:e,id:t,model:n,preloadedData:r,renderContextMenu:o,...i}){const[s,l]=U.useState(null),[a,d]=U.useState(null),h=U.useRef(n.getComposition()),f=U.useRef(n);f.current!==n&&(f.current=n,h.current=n.getComposition());const c=o!=null,m=U.useCallback(()=>{l(null)},[]),p=U.useCallback((S,E)=>{l({context:E,item:S})},[]),g=h.current,v=U.useMemo(()=>sa(g,e,c,m,p),[g,m,p,c,e]),w=U.useCallback(S=>{d(S)},[]);U.useEffect(()=>{c||l(null)},[c]),Io(()=>{n.setComposition(v)},[v,n]),Io(()=>{if(a!=null)return r!=null&&ia(a)?n.hydrate({fileTreeContainer:a}):n.render({fileTreeContainer:a}),()=>{n.unmount(),n.setComposition(g)}},[g,a,n,r]);const x=oa(ra(e,o,s),r),b=t??r?.id,I={"--trees-item-height":`${String(n.getItemHeight())}px`,"--trees-density-override":n.getDensityFactor(),...i.style};return oe.jsx(cr,{...i,id:b,ref:w,style:I,suppressHydrationWarning:r!=null,children:x})}const zi=`<svg data-icon-sprite aria-hidden="true" width="0" height="0">
|
|
2
2
|
<symbol id="file-tree-icon-chevron" viewBox="0 0 16 16">
|
|
3
3
|
<path d="M12.4697 5.46973C12.7626 5.17684 13.2374 5.17684 13.5303 5.46973C13.8232 5.76262 13.8232 6.23738 13.5303 6.53028L8.53028 11.5303C8.23738 11.8232 7.76262 11.8232 7.46973 11.5303L2.46973 6.53028C2.17684 6.23738 2.17684 5.76262 2.46973 5.46973C2.76262 5.17684 3.23738 5.17684 3.53028 5.46973L8 9.93946L12.4697 5.46973Z" fill="currentcolor"/>
|
|
4
4
|
</symbol>
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import{T as Ut,f as q,Q as Z}from"./app-DDsVI393.js";const v=new Set(["input","option","optgroup","select","button","datalist","textarea"]),m=new Set(["p"]),tt=new Set(["thead","tbody"]),et=new Set(["dd","dt"]),nt=new Set(["rt","rp"]),At=new Map([["tr",new Set(["tr","th","td"])],["th",new Set(["th"])],["td",new Set(["thead","th","td"])],["body",new Set(["head","link","script"])],["li",new Set(["li"])],["p",m],["h1",m],["h2",m],["h3",m],["h4",m],["h5",m],["h6",m],["select",v],["input",v],["output",v],["button",v],["datalist",v],["textarea",v],["option",new Set(["option"])],["optgroup",new Set(["optgroup","option"])],["dd",et],["dt",et],["address",m],["article",m],["aside",m],["blockquote",m],["details",m],["div",m],["dl",m],["fieldset",m],["figcaption",m],["figure",m],["footer",m],["form",m],["header",m],["hr",m],["main",m],["nav",m],["ol",m],["pre",m],["section",m],["table",m],["ul",m],["rt",nt],["rp",nt],["tbody",tt],["tfoot",tt]]),Nt=new Set(["area","base","basefont","br","col","command","embed","frame","hr","img","input","isindex","keygen","link","meta","param","source","track","wbr"]),st=new Set(["math","svg"]),ot=new Set(["mi","mo","mn","ms","mtext","annotation-xml","foreignobject","desc","title"]),Pt=/\s|\//;class Ot{constructor(t,n={}){var s,o,r,i,a;this.options=n,this.startIndex=0,this.endIndex=0,this.openTagStart=0,this.tagname="",this.attribname="",this.attribvalue="",this.attribs=null,this.stack=[],this.foreignContext=[],this.buffers=[],this.bufferOffset=0,this.writeIndex=0,this.ended=!1,this.cbs=t??{},this.lowerCaseTagNames=(s=n.lowerCaseTags)!==null&&s!==void 0?s:!n.xmlMode,this.lowerCaseAttributeNames=(o=n.lowerCaseAttributeNames)!==null&&o!==void 0?o:!n.xmlMode,this.tokenizer=new((r=n.Tokenizer)!==null&&r!==void 0?r:Ut)(this.options,this),(a=(i=this.cbs).onparserinit)===null||a===void 0||a.call(i,this)}ontext(t,n){var s,o;const r=this.getSlice(t,n);this.endIndex=n-1,(o=(s=this.cbs).ontext)===null||o===void 0||o.call(s,r),this.startIndex=n}ontextentity(t){var n,s;const o=this.tokenizer.getSectionStart();this.endIndex=o-1,(s=(n=this.cbs).ontext)===null||s===void 0||s.call(n,q(t)),this.startIndex=o}isVoidElement(t){return!this.options.xmlMode&&Nt.has(t)}onopentagname(t,n){this.endIndex=n;let s=this.getSlice(t,n);this.lowerCaseTagNames&&(s=s.toLowerCase()),this.emitOpenTag(s)}emitOpenTag(t){var n,s,o,r;this.openTagStart=this.startIndex,this.tagname=t;const i=!this.options.xmlMode&&At.get(t);if(i)for(;this.stack.length>0&&i.has(this.stack[this.stack.length-1]);){const a=this.stack.pop();(s=(n=this.cbs).onclosetag)===null||s===void 0||s.call(n,a,!0)}this.isVoidElement(t)||(this.stack.push(t),st.has(t)?this.foreignContext.push(!0):ot.has(t)&&this.foreignContext.push(!1)),(r=(o=this.cbs).onopentagname)===null||r===void 0||r.call(o,t),this.cbs.onopentag&&(this.attribs={})}endOpenTag(t){var n,s;this.startIndex=this.openTagStart,this.attribs&&((s=(n=this.cbs).onopentag)===null||s===void 0||s.call(n,this.tagname,this.attribs,t),this.attribs=null),this.cbs.onclosetag&&this.isVoidElement(this.tagname)&&this.cbs.onclosetag(this.tagname,!0),this.tagname=""}onopentagend(t){this.endIndex=t,this.endOpenTag(!1),this.startIndex=t+1}onclosetag(t,n){var s,o,r,i,a,l;this.endIndex=n;let u=this.getSlice(t,n);if(this.lowerCaseTagNames&&(u=u.toLowerCase()),(st.has(u)||ot.has(u))&&this.foreignContext.pop(),this.isVoidElement(u))!this.options.xmlMode&&u==="br"&&((o=(s=this.cbs).onopentagname)===null||o===void 0||o.call(s,"br"),(i=(r=this.cbs).onopentag)===null||i===void 0||i.call(r,"br",{},!0),(l=(a=this.cbs).onclosetag)===null||l===void 0||l.call(a,"br",!1));else{const f=this.stack.lastIndexOf(u);if(f!==-1)if(this.cbs.onclosetag){let c=this.stack.length-f;for(;c--;)this.cbs.onclosetag(this.stack.pop(),c!==0)}else this.stack.length=f;else!this.options.xmlMode&&u==="p"&&(this.emitOpenTag("p"),this.closeCurrentTag(!0))}this.startIndex=n+1}onselfclosingtag(t){this.endIndex=t,this.options.xmlMode||this.options.recognizeSelfClosing||this.foreignContext[this.foreignContext.length-1]?(this.closeCurrentTag(!1),this.startIndex=t+1):this.onopentagend(t)}closeCurrentTag(t){var n,s;const o=this.tagname;this.endOpenTag(t),this.stack[this.stack.length-1]===o&&((s=(n=this.cbs).onclosetag)===null||s===void 0||s.call(n,o,!t),this.stack.pop())}onattribname(t,n){this.startIndex=t;const s=this.getSlice(t,n);this.attribname=this.lowerCaseAttributeNames?s.toLowerCase():s}onattribdata(t,n){this.attribvalue+=this.getSlice(t,n)}onattribentity(t){this.attribvalue+=q(t)}onattribend(t,n){var s,o;this.endIndex=n,(o=(s=this.cbs).onattribute)===null||o===void 0||o.call(s,this.attribname,this.attribvalue,t===Z.Double?'"':t===Z.Single?"'":t===Z.NoValue?void 0:null),this.attribs&&!Object.prototype.hasOwnProperty.call(this.attribs,this.attribname)&&(this.attribs[this.attribname]=this.attribvalue),this.attribvalue=""}getInstructionName(t){const n=t.search(Pt);let s=n<0?t:t.substr(0,n);return this.lowerCaseTagNames&&(s=s.toLowerCase()),s}ondeclaration(t,n){this.endIndex=n;const s=this.getSlice(t,n);if(this.cbs.onprocessinginstruction){const o=this.getInstructionName(s);this.cbs.onprocessinginstruction(`!${o}`,`!${s}`)}this.startIndex=n+1}onprocessinginstruction(t,n){this.endIndex=n;const s=this.getSlice(t,n);if(this.cbs.onprocessinginstruction){const o=this.getInstructionName(s);this.cbs.onprocessinginstruction(`?${o}`,`?${s}`)}this.startIndex=n+1}oncomment(t,n,s){var o,r,i,a;this.endIndex=n,(r=(o=this.cbs).oncomment)===null||r===void 0||r.call(o,this.getSlice(t,n-s)),(a=(i=this.cbs).oncommentend)===null||a===void 0||a.call(i),this.startIndex=n+1}oncdata(t,n,s){var o,r,i,a,l,u,f,c,h,g;this.endIndex=n;const E=this.getSlice(t,n-s);this.options.xmlMode||this.options.recognizeCDATA?((r=(o=this.cbs).oncdatastart)===null||r===void 0||r.call(o),(a=(i=this.cbs).ontext)===null||a===void 0||a.call(i,E),(u=(l=this.cbs).oncdataend)===null||u===void 0||u.call(l)):((c=(f=this.cbs).oncomment)===null||c===void 0||c.call(f,`[CDATA[${E}]]`),(g=(h=this.cbs).oncommentend)===null||g===void 0||g.call(h)),this.startIndex=n+1}onend(){var t,n;if(this.cbs.onclosetag){this.endIndex=this.startIndex;for(let s=this.stack.length;s>0;this.cbs.onclosetag(this.stack[--s],!0));}(n=(t=this.cbs).onend)===null||n===void 0||n.call(t)}reset(){var t,n,s,o;(n=(t=this.cbs).onreset)===null||n===void 0||n.call(t),this.tokenizer.reset(),this.tagname="",this.attribname="",this.attribs=null,this.stack.length=0,this.startIndex=0,this.endIndex=0,(o=(s=this.cbs).onparserinit)===null||o===void 0||o.call(s,this),this.buffers.length=0,this.bufferOffset=0,this.writeIndex=0,this.ended=!1}parseComplete(t){this.reset(),this.end(t)}getSlice(t,n){for(;t-this.bufferOffset>=this.buffers[0].length;)this.shiftBuffer();let s=this.buffers[0].slice(t-this.bufferOffset,n-this.bufferOffset);for(;n-this.bufferOffset>this.buffers[0].length;)this.shiftBuffer(),s+=this.buffers[0].slice(0,n-this.bufferOffset);return s}shiftBuffer(){this.bufferOffset+=this.buffers[0].length,this.writeIndex--,this.buffers.shift()}write(t){var n,s;if(this.ended){(s=(n=this.cbs).onerror)===null||s===void 0||s.call(n,new Error(".write() after done!"));return}this.buffers.push(t),this.tokenizer.running&&(this.tokenizer.write(t),this.writeIndex++)}end(t){var n,s;if(this.ended){(s=(n=this.cbs).onerror)===null||s===void 0||s.call(n,new Error(".end() after done!"));return}t&&this.write(t),this.ended=!0,this.tokenizer.end()}pause(){this.tokenizer.pause()}resume(){for(this.tokenizer.resume();this.tokenizer.running&&this.writeIndex<this.buffers.length;)this.tokenizer.write(this.buffers[this.writeIndex++]);this.ended&&this.tokenizer.end()}parseChunk(t){this.write(t)}done(t){this.end(t)}}const dt=67324752,gt=33639248,pt=101010256,Dt=1,Xt=8,Ft=64,Y=0,wt=8,Zt=12*1024*1024,P=128,bt=10*1024*1024,R=2*1024*1024,xt=100;class I extends Error{}const Et=new TextEncoder,zt=new TextDecoder("utf-8");function y(e){return Et.encode(e)}function G(e){return zt.decode(e)}function St(e){return Et.encode(e).byteLength}function L(e){return new DataView(e.buffer,e.byteOffset,e.byteLength)}function _t(e){const t=e.reduce((o,r)=>o+r.byteLength,0),n=new Uint8Array(t);let s=0;for(const o of e)n.set(o,s),s+=o.byteLength;return n}async function It(e,t,n){const s=e.getReader(),o=[];let r=0;try{for(;;){const{done:i,value:a}=await s.read();if(i)break;if(r+=a.byteLength,r>t)throw await s.cancel(),new I(`ZIP entry ${n} inflated beyond its declared size.`);o.push(a)}}finally{s.releaseLock()}return _t(o)}function Tt(e){const t=new Uint8Array(e.byteLength);return t.set(e),new ReadableStream({start(n){n.enqueue(t),n.close()}})}async function Vt(e,t,n){const s=Tt(e).pipeThrough(new DecompressionStream("deflate-raw"));return await It(s,t,n)}async function Bt(e){const t=Tt(e).pipeThrough(new CompressionStream("deflate-raw"));return await It(t,R+1024,"(deflate)")}function jt(e){const t=L(e),n=Math.max(0,e.byteLength-65535-22);for(let s=e.byteLength-22;s>=n;s-=1){if(s<0||t.getUint32(s,!0)!==pt)continue;const o=t.getUint16(s+20,!0);if(s+22+o===e.byteLength)return s}throw new Error("ZIP end-of-central-directory not found.")}function yt(e,t){if((e&Dt)!==0)throw new Error(`ZIP entry ${t} is encrypted.`);if((e&Ft)!==0)throw new Error(`ZIP entry ${t} uses strong encryption.`)}function rt(e,t,n){return t===n?!0:(e&Xt)!==0&&t===0}function Ht(e){if(e.byteLength>Zt)throw new I("ZIP input exceeds compressed byte limit.");const t=L(e),n=jt(e),s=t.getUint16(n+4,!0),o=t.getUint16(n+6,!0),r=t.getUint16(n+8,!0),i=t.getUint16(n+10,!0),a=t.getUint32(n+12,!0),l=t.getUint32(n+16,!0),u=l+a;if(s!==0||o!==0||r!==i)throw new Error("Multi-disk ZIP archives are not supported.");if(i===65535||a===4294967295||l===4294967295)throw new Error("ZIP64 archives are not supported.");if(i>P)throw new I(`ZIP entry count ${i} exceeds limit ${P}.`);if(l+a>e.byteLength)throw new Error("ZIP central directory is out of bounds.");if(u>n)throw new Error("ZIP central directory overlaps the end-of-central-directory record.");const f=[];let c=l,h=0;for(let g=0;g<i;g+=1){if(c+46>u||t.getUint32(c,!0)!==gt)throw new Error("Invalid ZIP central directory entry.");const E=t.getUint16(c+8,!0),S=t.getUint16(c+10,!0),w=t.getUint32(c+20,!0),b=t.getUint32(c+24,!0),x=t.getUint16(c+28,!0),T=t.getUint16(c+30,!0),_=t.getUint16(c+32,!0),p=t.getUint32(c+42,!0);if(w===4294967295||b===4294967295||p===4294967295)throw new Error("ZIP64 archives are not supported.");if(c+46+x+T+_>u)throw new Error("ZIP central directory entry is out of bounds.");const d=G(e.subarray(c+46,c+46+x));if(yt(E,d),S!==Y&&S!==wt)throw new Error(`ZIP entry ${d} uses unsupported compression method ${S}.`);if(b>R)throw new I(`ZIP entry ${d} exceeds per-entry uncompressed limit.`);if(b>0&&w===0)throw new Error(`ZIP entry ${d} has an invalid compression ratio.`);if(w>0&&b/w>xt)throw new I(`ZIP entry ${d} exceeds compression ratio limit.`);if(h+=b,h>bt)throw new I("ZIP archive exceeds total uncompressed limit.");f.push({name:d,flags:E,method:S,compressedSize:w,uncompressedSize:b,localOffset:p}),c+=46+x+T+_}if(c!==u)throw new Error("ZIP central directory size does not match its entries.");return f}async function Wt(e,t){const n=L(e),s=t.localOffset;if(s+30>e.byteLength||n.getUint32(s,!0)!==dt)throw new Error(`Invalid local ZIP header for ${t.name}.`);const o=n.getUint16(s+6,!0),r=n.getUint16(s+8,!0),i=n.getUint32(s+18,!0),a=n.getUint32(s+22,!0),l=n.getUint16(s+26,!0),u=n.getUint16(s+28,!0);if(yt(o,t.name),r!==t.method)throw new Error(`ZIP method mismatch for ${t.name}.`);if(!rt(o,i,t.compressedSize)||!rt(o,a,t.uncompressedSize))throw new Error(`ZIP size mismatch for ${t.name}.`);if(s+30+l+u>e.byteLength)throw new Error(`ZIP local header for ${t.name} is out of bounds.`);if(G(e.subarray(s+30,s+30+l))!==t.name)throw new Error(`ZIP local header name mismatch for ${t.name}.`);const c=s+30+l+u;if(c+t.compressedSize>e.byteLength)throw new Error(`ZIP data for ${t.name} is out of bounds.`);const h=e.subarray(c,c+t.compressedSize),g=t.method===Y?h.slice():await Vt(h,t.uncompressedSize,t.name);if(g.byteLength!==t.uncompressedSize)throw new Error(`ZIP uncompressed size mismatch for ${t.name}.`);return g}function Yt(e){const t=new Map;for(const n of e)t.set(n.name,n);return t}async function M(e,t,n){const s=t.get(n);if(!s)return null;const o=G(await Wt(e,s));return Ct(o),o}let N=null;function Gt(e){if(!N){N=new Uint32Array(256);for(let n=0;n<256;n+=1){let s=n;for(let o=0;o<8;o+=1)s=s&1?3988292384^s>>>1:s>>>1;N[n]=s>>>0}}let t=4294967295;for(const n of e)t=N[(t^n)&255]^t>>>8;return(t^4294967295)>>>0}async function Kt(e){if(e.length>P)throw new I(`ZIP entry count ${e.length} exceeds limit ${P}.`);const t=[],n=[];let s=0,o=0;for(const l of e){if(l.data.byteLength>R)throw new I(`ZIP entry ${l.name} exceeds per-entry uncompressed limit.`);if(o+=l.data.byteLength,o>bt)throw new I("ZIP archive exceeds total uncompressed limit.");const u=await Bt(l.data),f=u.byteLength<l.data.byteLength&&l.data.byteLength/Math.max(1,u.byteLength)<=xt,c=f?u:l.data,h=f?wt:Y,g=y(l.name),E=Gt(l.data),S=new Uint8Array(30),w=L(S);w.setUint32(0,dt,!0),w.setUint16(4,20,!0),w.setUint16(6,0,!0),w.setUint16(8,h,!0),w.setUint32(14,E,!0),w.setUint32(18,c.byteLength,!0),w.setUint32(22,l.data.byteLength,!0),w.setUint16(26,g.byteLength,!0),t.push(S,g,c);const b=new Uint8Array(46),x=L(b);x.setUint32(0,gt,!0),x.setUint16(4,20,!0),x.setUint16(6,20,!0),x.setUint16(8,0,!0),x.setUint16(10,h,!0),x.setUint32(16,E,!0),x.setUint32(20,c.byteLength,!0),x.setUint32(24,l.data.byteLength,!0),x.setUint16(28,g.byteLength,!0),x.setUint32(42,s,!0),n.push(b,g),s+=S.byteLength+g.byteLength+c.byteLength}const r=n.reduce((l,u)=>l+u.byteLength,0),i=new Uint8Array(22),a=L(i);return a.setUint32(0,pt,!0),a.setUint16(8,e.length,!0),a.setUint16(10,e.length,!0),a.setUint32(12,r,!0),a.setUint32(16,s,!0),_t([...t,...n,i])}function Ct(e){if(St(e)>R)throw new I("Office XML exceeds the parser input limit.");const t=e.toLowerCase();if(t.includes("<!doctype")||t.includes("<!entity"))throw new Error("Office XML DTD and entity declarations are not supported.")}function it(e){const t=e.lastIndexOf(":");return(t===-1?e:e.slice(t+1)).toLowerCase()}function D(e,t){Ct(e);let n="",s=0;const o=t||" ";return new Ot({onopentag(i){s>0?s+=1:it(i)==="script"||it(i)==="style"?(n+=o,s=1):n+=t},ontext(i){s===0&&(n+=i)},onclosetag(){s>0?(s-=1,s===0&&(n+=o)):n+=t}},{decodeEntities:!0,xmlMode:!0}).end(e),n}function Qt(e){return D(`<openwork-value>${e}</openwork-value>`,"")}function $t(e){return D(e," ").replace(/\s+/g," ").trim()}function K(e){return`(?:[A-Za-z_][\\w.-]*:)?${e}`}function Q(e){const t={},n=/([\w:.-]+)\s*=\s*(?:"([^"]*)"|'([^']*)')/g;let s;for(;s=n.exec(e);){const o=s[1],r=s[2]??s[3]??"";t[o]=Qt(r)}return t}function U(e,t){const n=K(t),s=new RegExp(`<${n}\\b([^>]*)>([\\s\\S]*?)<\\/${n}>`,"g"),o=[];let r;for(;r=s.exec(e);)o.push({attributes:Q(r[1]),inner:r[2]});return o}function $(e,t){const n=K(t),s=new RegExp(`<${n}\\b([^>]*)\\/?\\s*>`,"g"),o=[];let r;for(;r=s.exec(e);)o.push(Q(r[1]));return o}function Jt(e,t){const n=U(e,t)[0];if(n)return D(n.inner,"").trim()}function z(e,t){const n=K(t),s=new RegExp(`<${n}\\b([^>]*?)(\\/>|>([\\s\\S]*?)<\\/${n}>)`,"g"),o=[];let r;for(;r=s.exec(e);)o.push({attributes:Q(r[1]),inner:r[3]??""});return o}function B(e){return e.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/[\u0000-\u0008\u000b\u000c\u000e-\u001f]/g,"")}function at(...e){const t=[];for(const n of e.join("/").split("/"))!n||n==="."||(n===".."?t.pop():t.push(n));return t.join("/")}function qt(e,t){const n=new Map;if(!e)return n;for(const s of $(e,"Relationship")){const o=s.Id,r=s.Target;!o||!r||s.TargetMode==="External"||/^[a-z][a-z0-9+.-]*:/i.test(r)||n.set(o,r.startsWith("/")?at(r.slice(1)):at(t,r))}return n}const te=64,ee=2e5,ne=25e4,lt=32,ct=5e4,j=1048576,H=16384,ut=31,ht=32767,mt=Date.UTC(1899,11,30),se=Date.UTC(1904,0,1),V=864e5;function O(e){let t=e,n="";for(;t>0;){const s=(t-1)%26;n=String.fromCharCode(65+s)+n,t=Math.floor((t-1)/26)}return n}function oe(e){let t=0;for(const n of e.toUpperCase()){const s=n.charCodeAt(0);if(s<65||s>90)return 0;t=t*26+(s-64)}return t}function W(e){const t=/^\$?([A-Za-z]{1,3})\$?(\d{1,7})$/.exec(e.trim());if(!t)return null;const n=oe(t[1]),s=Number.parseInt(t[2],10);return n<1||n>H||s<1||s>j?null:{row:s,column:n}}function kt(e){const t=e.trim(),[n,s=n]=t.split(":"),o=W(n),r=W(s);return!o||!r?null:{firstRow:Math.min(o.row,r.row),lastRow:Math.max(o.row,r.row),firstColumn:Math.min(o.column,r.column),lastColumn:Math.max(o.column,r.column)}}function re(e,t){const n=qt(t,"xl"),s=$(e,"sheet"),o=s.slice(0,te).map((r,i)=>{const a=r["r:id"]??r.id??"",l=a&&n.has(a)?n.get(a)??"":`xl/worksheets/sheet${i+1}.xml`;return{position:i+1,name:r.name??`Sheet${i+1}`,sheetId:r.sheetId??String(i+1),relationshipId:a,path:l,hidden:r.state==="hidden"||r.state==="veryHidden"}});return{sheets:o,omittedSheets:s.length-o.length}}const ie=/<(?:[A-Za-z_][\w.-]*:)?rPh\b(?:[^>]*\/>|[^>]*>[\s\S]*?<\/(?:[A-Za-z_][\w.-]*:)?rPh\s*>)/g;function vt(e){const t=e.replace(ie,"");return U(t,"t").map(s=>D(s.inner,"")).join("").trim()||$t(t)}function ae(e){if(!e)return[];const t=[];for(const n of U(e,"si")){if(t.length>=ee)break;t.push(vt(n.inner))}return t}function le(e){switch(e){case"0":return"General";case"1":return"0";case"2":return"0.00";case"3":return"#,##0";case"4":return"#,##0.00";case"9":return"0%";case"10":return"0.00%";case"11":return"0.00E+00";case"14":return"mm-dd-yy";case"15":return"d-mmm-yy";case"16":return"d-mmm";case"17":return"mmm-yy";case"18":return"h:mm AM/PM";case"19":return"h:mm:ss AM/PM";case"20":return"h:mm";case"21":return"h:mm:ss";case"22":return"m/d/yy h:mm";case"27":case"28":case"29":case"30":case"31":case"36":case"50":case"51":case"52":case"53":case"54":case"57":case"58":return"yyyy-mm-dd";case"32":case"33":case"34":case"35":case"55":case"56":return"h:mm:ss";case"45":return"mm:ss";case"46":return"[h]:mm:ss";case"47":return"mmss.0";case"49":return"@";default:return""}}function ce(e){if(!e)return[];const t=new Map;for(const s of $(e,"numFmt"))s.numFmtId&&s.formatCode&&t.set(s.numFmtId,s.formatCode);const n=U(e,"cellXfs")[0]?.inner??"";return $(n,"xf").map(s=>{const o=s.numFmtId??"0";return t.get(o)??le(o)})}const ue=/\[(?:h+|m+|s+)\]/i;function Lt(e){return!!e&&ue.test(e.replace(/"[^"]*"/g,""))}function he(e){if(!Number.isFinite(e)||e<0)return null;const t=Math.round(e*86400);return`${Math.floor(t/3600)}:${C(Math.floor(t%3600/60))}:${C(t%60)}`}function me(e){if(!e||e==="General"||e==="@"||Lt(e))return!1;const t=e.replace(/"[^"]*"/g,"").replace(/\[[^\]]*\]/g,"").replace(/\\./g,"").replace(/[Ee][+-]/g,"");return/[ymdhs]/i.test(t)}function C(e,t=2){return String(e).padStart(t,"0")}function fe(e,t=!1){if(!Number.isFinite(e)||e<0||e>2958465)return null;const n=t?se:e<60?mt+V:mt,s=Math.round(e*V),o=new Date(n+s);if(Number.isNaN(o.getTime()))return null;const r=`${C(o.getUTCHours())}:${C(o.getUTCMinutes())}:${C(o.getUTCSeconds())}`;if(e<1&&!t)return r;const i=`${o.getUTCFullYear()}-${C(o.getUTCMonth()+1)}-${C(o.getUTCDate())}`;return s%V===0?i:`${i} ${r}`}function de(e){return e==="s"?"shared_string":e==="inlineStr"?"inline_string":e==="str"?"formula_string":e==="b"?"boolean":e==="e"?"error":e==="d"?"date":e||"number"}function ge(e,t,n,s,o,r){if(e==="inlineStr")return vt(n)||void 0;if(e==="s"&&t!==void 0){const i=Number.parseInt(t,10);return Number.isInteger(i)?s[i]:void 0}return e==="b"&&t!==void 0?t==="1"?"TRUE":"FALSE":(e===""||e==="n")&&t!==void 0&&Lt(o)?he(Number(t))??t:(e===""||e==="n")&&t!==void 0&&me(o)?fe(Number(t),r)??t:t}function pe(e,t,n,s,o){const r=$(e,"dimension")[0]?.ref??"",i=[];for(const h of $(e,"mergeCell"))h.ref&&i.push(h.ref);const a=U(e,"sheetData")[0]?.inner??e,l=[];let u=0,f=0,c=0;for(const h of z(a,"row")){const g=Number.parseInt(h.attributes.r??"",10),E=Number.isInteger(g)&&g>0?g:c+1;c=E;let S=0;for(const w of z(h.inner,"c")){const b=w.attributes,x=w.inner,T=b.r?W(b.r):null,_=T?.column??S+1,p=T?.row??E;S=_;const d=z(x,"f")[0],k=Jt(x,"v"),X=b.t??"";if(d&&(f+=1),k===void 0&&!d&&X!=="inlineStr")continue;if(l.length>=o){u+=1;continue}const A=b.s,F=A!==void 0?n[Number.parseInt(A,10)]:void 0,J=ge(X,k,x,t,F,s),Mt=d?$t(d.inner):"";l.push({reference:`${O(_)}${p}`,row:p,column:_,type:de(X),...A!==void 0?{styleIndex:A}:{},...F?{numberFormat:F}:{},...d?{formula:Mt}:{},...d?.attributes.t?{formulaType:d.attributes.t}:{},...d?.attributes.ref?{formulaRef:d.attributes.ref}:{},...k!==void 0?{rawValue:k}:{},...J!==void 0?{displayedValue:J}:{}})}}return{dimension:r,mergedRanges:i,cells:l,omittedCells:u,formulaCount:f}}function we(e,t){const n=e.length===0&&t?kt(t):null;if(n)return n;if(e.length===0)return{firstRow:0,lastRow:0,firstColumn:0,lastColumn:0};let s=Number.POSITIVE_INFINITY,o=0,r=Number.POSITIVE_INFINITY,i=0;for(const a of e)s=Math.min(s,a.row),o=Math.max(o,a.row),r=Math.min(r,a.column),i=Math.max(i,a.column);return{firstRow:s,lastRow:o,firstColumn:r,lastColumn:i}}async function Ue(e){const t=Yt(Ht(e)),n=await M(e,t,"xl/workbook.xml");if(!n)throw new Error("XLSX workbook.xml was not found.");const s=ae(await M(e,t,"xl/sharedStrings.xml")),o=ce(await M(e,t,"xl/styles.xml")),{sheets:r,omittedSheets:i}=re(n,await M(e,t,"xl/_rels/workbook.xml.rels"));if(r.length===0)throw new Error("XLSX workbook contained no sheets.");const a=$(n,"workbookPr").some(l=>l.date1904==="1"||l.date1904==="true");return{sheets:r,omittedSheets:i,sharedStringCount:s.length,styleCount:o.length,date1904:a,async readSheet(l,u={}){const f=l.path.startsWith("xl/worksheets/")&&l.path.endsWith(".xml")?l.path:"",c=f?await M(e,t,f):null;if(!c)throw new Error(`Worksheet XML for "${l.name}" was not found or was outside xl/worksheets.`);const h=pe(c,s,o,a,u.cellLimit??ne);return{info:l,...h,...we(h.cells,h.dimension)}}}}const be="│";function xe(e,t,n){if(!e)return"";const o=(t&&e.formula?`=${e.formula}`:e.displayedValue??e.rawValue??(e.formula?`=${e.formula}`:"")).replace(/\s*\r?\n\s*/g," ").replaceAll("|",be);return o.length>n?`${o.slice(0,n-1)}…`:o}function Ae(e,t={}){const n=t.range?kt(t.range):null;if(t.range&&!n)throw new Error(`Range "${t.range}" is not a valid A1-style range such as A1:D20.`);const s=Math.max(1,t.maxRows??100),o=Math.max(1,t.maxColumns??40),r=Math.max(8,t.maxCellChars??120),i=t.formulas??!1,a=Math.max(t.startRow??1,n?.firstRow??1),l=n?.lastRow??Number.POSITIVE_INFINITY,u=n?.firstColumn??1,f=n?.lastColumn??Number.POSITIVE_INFINITY,c=new Map,h=new Set;for(const p of e.cells){if(p.column<u||p.column>f||p.row<(n?.firstRow??1)||p.row>l)continue;h.add(p.column);let d=c.get(p.row);d||(d=new Map,c.set(p.row,d)),d.set(p.column,p)}const g=[...h].sort((p,d)=>p-d),E=g.slice(0,o),S=g.length-E.length,w=[...c.keys()].filter(p=>p>=a).sort((p,d)=>p-d),b=w.slice(0,s),x=w.length>b.length?w[b.length]:null,T=E.map(O),_=[];if(b.length===0)_.push("(no cells in this range)");else{_.push(`| # | ${T.join(" | ")} |`),_.push(`|---|${T.map(()=>"---").join("|")}|`);for(const p of b){const d=c.get(p);_.push(`| ${p} | ${E.map(k=>xe(d?.get(k),i,r)).join(" | ")} |`)}}return{text:_.join(`
|
|
2
|
+
`),renderedRows:b.length,nextStartRow:x,columns:T,truncatedColumns:S}}function Ne(e,t=8,n=3){const s=new Map;for(const o of e.cells){if(!o.numberFormat||o.numberFormat==="General")continue;const r=s.get(o.numberFormat)??[];r.length<n&&r.push(o.reference),s.set(o.numberFormat,r)}return[...s.entries()].slice(0,t).map(([o,r])=>`${JSON.stringify(o)} (${r.join(", ")})`)}function Pe(e,t=20){return e.cells.filter(n=>n.formula).slice(0,t).map(n=>{const s=n.displayedValue??n.rawValue;return`${n.reference}: =${n.formula}${s!==void 0?` → ${s}`:""}`})}const Ee=25e4;function Oe(e,t={}){if(e.cells.length===0)return[[""]];const n=t.maxCells??Ee;if(e.lastRow*e.lastColumn>n)throw new Error(`This sheet spans ${e.lastRow} rows by ${e.lastColumn} columns, which is too large to show as an editable grid.`);const s=Array.from({length:e.lastRow},()=>Array.from({length:e.lastColumn},()=>""));for(const o of e.cells)s[o.row-1][o.column-1]=t.formulas&&o.formula?`=${o.formula}`:o.displayedValue??o.rawValue??(o.formula?`=${o.formula}`:"");return s}const Se=/^-?(?:0|[1-9]\d*)(?:\.\d+)?(?:[eE][+-]?\d+)?$/,ft=8192,_e=/\b(DDE|WEBSERVICE|FILTERXML|RTD|CALL|REGISTER(?:\.ID)?|EXEC|SQL\.REQUEST|IMPORT(?:DATA|XML|HTML|FEED|RANGE)|IMAGE)\s*\(/i,Ie=/\[[^\]]*\][^!'"(),;+\-*/^&=<>\[\]{}]*!|'[^']*\[[^\]]*\][^']*'!/u,Te=/'[^']*(?::\/\/|\\\\)[^']*'!/;function Rt(e){return typeof e=="object"&&e!==null&&typeof e.formula=="string"}function ye(e){const t=e.trim().replace(/^=/,"");if(!t)return"is empty";if(t.length>ft)return`is longer than ${ft} characters`;if(t.includes("|"))return"contains a DDE-style external command reference";const n=_e.exec(t);return n?`uses ${n[1].toUpperCase()}, which reaches outside the workbook when it recalculates`:Ie.test(t)?"references another workbook":Te.test(t)?"references a remote or network path":null}function Ce(e,t){const n=ye(e.formula);if(n)throw new Error(`Formula in ${t} ${n}; only calculations inside the workbook are written. Write the value instead.`);return e.formula.trim().replace(/^=/,"")}function De(e){if(e==="")return null;if(e==="TRUE")return!0;if(e==="FALSE")return!1;if(Se.test(e)){const t=Number(e);if(Number.isFinite(t))return t}return e}function $e(e,t,n){let o=(e??"").replace(/[\u0000-\u001f\u007f[\]:*?/\\]/g," ").replace(/\s+/g," ").replace(/^'+|'+$/g,"").trim().slice(0,ut).trim()||`Sheet${t}`,r=2;for(;n.has(o.toLowerCase())||o.toLowerCase()==="history";)o=`${o.slice(0,ut-String(r).length-1)}-${r}`,r+=1;return n.add(o.toLowerCase()),o}function ke(e,t,n){const s=n>0?` s="${n}"`:"";if(t===null||t==="")return"";if(typeof t=="number")return Number.isFinite(t)?`<c r="${e}"${s}><v>${t}</v></c>`:`<c r="${e}" t="e"${s}><v>#NUM!</v></c>`;if(typeof t=="boolean")return`<c r="${e}" t="b"${s}><v>${t?1:0}</v></c>`;if(Rt(t))return`<c r="${e}"${s}><f>${B(Ce(t,e))}</f></c>`;if(t.length>ht)throw new Error(`Cell ${e} holds ${t.length} characters of text; Excel allows ${ht}. Shorten it or split it across cells.`);const o=/^\s|\s$|\n/.test(t)?' xml:space="preserve"':"";return`<c r="${e}" t="inlineStr"${s}><is><t${o}>${B(t)}</t></is></c>`}function ve(e){return e===null?0:Rt(e)?12:String(e).split(`
|
|
3
|
+
`).reduce((t,n)=>Math.max(t,n.length),0)}function Le(e){const t=e.rows,n=t.reduce((f,c)=>Math.max(f,c.length),0);if(t.length>j)throw new Error(`Sheet "${e.name??""}" has ${t.length} rows; Excel allows ${j}.`);if(n>H)throw new Error(`Sheet "${e.name??""}" has ${n} columns; Excel allows ${H}.`);const s=e.header??!0,o=Array.from({length:n},()=>0),r=[];t.forEach((f,c)=>{const h=[];f.forEach((g,E)=>{o[E]=Math.max(o[E],ve(g));const S=ke(`${O(E+1)}${c+1}`,g,s&&c===0?1:0);S&&h.push(S)}),h.length&&r.push(`<row r="${c+1}">${h.join("")}</row>`)});const i=t.length&&n?`A1:${O(n)}${t.length}`:"A1",a=n?`<cols>${o.map((f,c)=>`<col min="${c+1}" max="${c+1}" width="${Math.min(60,Math.max(8,f+2))}" customWidth="1"/>`).join("")}</cols>`:"",l=`<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
|
4
|
+
<worksheet xmlns="http://schemas.openxmlformats.org/spreadsheetml/2006/main" xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships"><dimension ref="${i}"/><sheetViews><sheetView workbookViewId="0"${s&&t.length>1?'><pane ySplit="1" topLeftCell="A2" activePane="bottomLeft" state="frozen"/></sheetView>':"/>"}</sheetViews><sheetFormatPr defaultRowHeight="15"/>${a}<sheetData>${r.join("")}</sheetData><pageMargins left="0.7" right="0.7" top="0.75" bottom="0.75" header="0.3" footer="0.3"/></worksheet>`,u=St(l);if(u>R)throw new Error(`Sheet ${JSON.stringify(e.name??"")} would be ${u} bytes of worksheet XML; the limit is ${R} bytes (roughly 30,000 text cells). Split the rows across sheets or files, shorten cell text, or write a CSV instead.`);return{xml:l,rows:t.length,columns:n}}const Re=`<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
|
5
|
+
<styleSheet xmlns="http://schemas.openxmlformats.org/spreadsheetml/2006/main"><fonts count="2"><font><sz val="11"/><name val="Calibri"/></font><font><b/><sz val="11"/><name val="Calibri"/></font></fonts><fills count="2"><fill><patternFill patternType="none"/></fill><fill><patternFill patternType="gray125"/></fill></fills><borders count="1"><border><left/><right/><top/><bottom/><diagonal/></border></borders><cellStyleXfs count="1"><xf numFmtId="0" fontId="0" fillId="0" borderId="0"/></cellStyleXfs><cellXfs count="2"><xf numFmtId="0" fontId="0" fillId="0" borderId="0" xfId="0"/><xf numFmtId="0" fontId="1" fillId="0" borderId="0" xfId="0" applyFont="1"/></cellXfs><cellStyles count="1"><cellStyle name="Normal" xfId="0" builtinId="0"/></cellStyles></styleSheet>`;async function Xe(e){if(e.length===0)throw new Error("A workbook needs at least one sheet.");if(e.length>lt)throw new Error(`A workbook may contain at most ${lt} sheets.`);const t=e.reduce((i,a)=>i+a.rows.reduce((l,u)=>l+u.length,0),0);if(t>ct)throw new Error(`Workbook has ${t} cells; spreadsheet_write accepts at most ${ct}. Split the data across files or write a CSV.`);const n=new Set,s=e.map((i,a)=>({...i,name:$e(i.name,a+1,n)})),o=s.map(i=>Le(i)),r=[{name:"[Content_Types].xml",data:y(`<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
|
6
|
+
<Types xmlns="http://schemas.openxmlformats.org/package/2006/content-types"><Default Extension="rels" ContentType="application/vnd.openxmlformats-package.relationships+xml"/><Default Extension="xml" ContentType="application/xml"/><Override PartName="/xl/workbook.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml"/><Override PartName="/xl/styles.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml"/>${s.map((i,a)=>`<Override PartName="/xl/worksheets/sheet${a+1}.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml"/>`).join("")}</Types>`)},{name:"_rels/.rels",data:y(`<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
|
7
|
+
<Relationships xmlns="http://schemas.openxmlformats.org/package/2006/relationships"><Relationship Id="rId1" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument" Target="xl/workbook.xml"/></Relationships>`)},{name:"xl/workbook.xml",data:y(`<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
|
8
|
+
<workbook xmlns="http://schemas.openxmlformats.org/spreadsheetml/2006/main" xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships"><bookViews><workbookView/></bookViews><sheets>${s.map((i,a)=>`<sheet name="${B(i.name)}" sheetId="${a+1}" r:id="rId${a+1}"/>`).join("")}</sheets><calcPr fullCalcOnLoad="1"/></workbook>`)},{name:"xl/_rels/workbook.xml.rels",data:y(`<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
|
9
|
+
<Relationships xmlns="http://schemas.openxmlformats.org/package/2006/relationships">${s.map((i,a)=>`<Relationship Id="rId${a+1}" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/worksheet" Target="worksheets/sheet${a+1}.xml"/>`).join("")}<Relationship Id="rId${s.length+1}" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles" Target="styles.xml"/></Relationships>`)},{name:"xl/styles.xml",data:y(Re)},...o.map((i,a)=>({name:`xl/worksheets/sheet${a+1}.xml`,data:y(i.xml)}))];return{bytes:await Kt(r),sheets:s.map((i,a)=>({name:i.name,rows:o[a].rows,columns:o[a].columns}))}}export{I as O,Ot as P,qt as a,Ct as b,De as c,Wt as d,Ae as e,Pe as f,O as g,Ht as l,Ne as n,Ue as o,M as r,Oe as s,G as u,Xe as w,$t as x,Yt as z};
|
package/web/assets/{xychartDiagram-S5SC5T6Z-44sg_69l.js → xychartDiagram-S5SC5T6Z-r1FFIWA_.js}
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{s as ai,g as oi,q as It,p as ri,a as hi,b as li,_ as a,l as Bt,G as ci,d as gi,r as ui,A as mt,i as di,D as zt,E as xi,X as fi,aB as pi,a8 as vt}from"./mermaid.core-
|
|
1
|
+
import{s as ai,g as oi,q as It,p as ri,a as hi,b as li,_ as a,l as Bt,G as ci,d as gi,r as ui,A as mt,i as di,D as zt,E as xi,X as fi,aB as pi,a8 as vt}from"./mermaid.core-C4R8NQRz.js";import{i as mi}from"./init-Gi6I4Gst.js";import{o as yi}from"./ordinal-Cboi1Yqb.js";import{l as Lt}from"./linear-DL_T580R.js";import"./app-DDsVI393.js";import"./defaultLocale-DX6XiGOO.js";function bi(t,i,e){t=+t,i=+i,e=(n=arguments.length)<2?(i=t,t=0,1):n<3?1:+e;for(var s=-1,n=Math.max(0,Math.ceil((i-t)/e))|0,h=new Array(n);++s<n;)h[s]=t+s*e;return h}function ut(){var t=yi().unknown(void 0),i=t.domain,e=t.range,s=0,n=1,h,l,d=!1,x=0,C=0,k=.5;delete t.unknown;function R(){var b=i().length,E=n<s,v=E?n:s,L=E?s:n;h=(L-v)/Math.max(1,b-x+C*2),d&&(h=Math.floor(h)),v+=(L-v-h*(b-x))*k,l=h*(1-x),d&&(v=Math.round(v),l=Math.round(l));var M=bi(b).map(function(m){return v+h*m});return e(E?M.reverse():M)}return t.domain=function(b){return arguments.length?(i(b),R()):i()},t.range=function(b){return arguments.length?([s,n]=b,s=+s,n=+n,R()):[s,n]},t.rangeRound=function(b){return[s,n]=b,s=+s,n=+n,d=!0,R()},t.bandwidth=function(){return l},t.step=function(){return h},t.round=function(b){return arguments.length?(d=!!b,R()):d},t.padding=function(b){return arguments.length?(x=Math.min(1,C=+b),R()):x},t.paddingInner=function(b){return arguments.length?(x=Math.min(1,b),R()):x},t.paddingOuter=function(b){return arguments.length?(C=+b,R()):C},t.align=function(b){return arguments.length?(k=Math.max(0,Math.min(1,b)),R()):k},t.copy=function(){return ut(i(),[s,n]).round(d).paddingInner(x).paddingOuter(C).align(k)},mi.apply(R(),arguments)}var dt=(function(){var t=a(function(W,r,g,u){for(g=g||{},u=W.length;u--;g[W[u]]=r);return g},"o"),i=[1,10,12,14,16,18,19,21,23],e=[2,6],s=[1,3],n=[1,5],h=[1,6],l=[1,7],d=[1,5,10,12,14,16,18,19,21,23,36,37,38],x=[1,25],C=[1,26],k=[1,28],R=[1,29],b=[1,30],E=[1,31],v=[1,32],L=[1,33],M=[1,34],m=[1,35],D=[1,36],c=[1,37],z=[1,43],F=[1,42],X=[1,47],N=[1,50],_=[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],w=[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],A=[1,65],O=[26,28],T={trace:a(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:a(function(r,g,u,f,S,o,Z){var p=o.length-1;switch(S){case 5:f.setOrientation(o[p]);break;case 9:f.setDiagramTitle(o[p].text.trim());break;case 12:f.setLineData({text:"",type:"text"},o[p]);break;case 13:f.setLineData(o[p-1],o[p]);break;case 14:f.setBarData({text:"",type:"text"},o[p]);break;case 15:f.setBarData(o[p-1],o[p]);break;case 16:this.$=o[p].trim(),f.setAccTitle(this.$);break;case 17:case 18:this.$=o[p].trim(),f.setAccDescription(this.$);break;case 19:this.$=o[p-1];break;case 20:case 30:this.$=[o[p-2],...o[p]];break;case 21:case 31:this.$=[o[p]];break;case 22:this.$={value:Number(o[p-1]),label:o[p]};break;case 23:this.$={value:Number(o[p]),label:""};break;case 24:f.setXAxisTitle(o[p]);break;case 25:f.setXAxisTitle(o[p-1]);break;case 26:f.setXAxisTitle({type:"text",text:""});break;case 27:f.setXAxisBand(o[p]);break;case 28:f.setXAxisRangeData(Number(o[p-2]),Number(o[p]));break;case 29:this.$=o[p-1];break;case 32:f.setYAxisTitle(o[p]);break;case 33:f.setYAxisTitle(o[p-1]);break;case 34:f.setYAxisTitle({type:"text",text:""});break;case 35:f.setYAxisRangeData(Number(o[p-2]),Number(o[p]));break;case 39:this.$={text:o[p],type:"text"};break;case 40:this.$={text:o[p],type:"text"};break;case 41:this.$={text:o[p],type:"markdown"};break;case 42:this.$=o[p];break;case 43:this.$=o[p-1]+""+o[p];break}},"anonymous"),table:[t(i,e,{3:1,4:2,7:4,5:s,36:n,37:h,38:l}),{1:[3]},t(i,e,{4:2,7:4,3:8,5:s,36:n,37:h,38:l}),t(i,e,{4:2,7:4,6:9,3:10,5:s,8:[1,11],36:n,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]},t(d,[2,36]),t(d,[2,37]),t(d,[2,38]),{1:[2,1]},t(i,e,{4:2,7:4,3:21,5:s,36:n,37:h,38:l}),{1:[2,3]},t(d,[2,5]),t(i,[2,7],{4:22,36:n,37:h,38:l}),{11:23,30:x,39:24,40:C,41:27,42:k,43:R,44:b,45:E,46:v,47:L,48:M,49:m,50:D,51:c},{11:39,13:38,24:z,29:F,30:x,31:40,32:41,39:24,40:C,41:27,42:k,43:R,44:b,45:E,46:v,47:L,48:M,49:m,50:D,51:c},{11:45,15:44,29:X,30:x,35:46,39:24,40:C,41:27,42:k,43:R,44:b,45:E,46:v,47:L,48:M,49:m,50:D,51:c},{11:49,17:48,24:N,30:x,39:24,40:C,41:27,42:k,43:R,44:b,45:E,46:v,47:L,48:M,49:m,50:D,51:c},{11:52,17:51,24:N,30:x,39:24,40:C,41:27,42:k,43:R,44:b,45:E,46:v,47:L,48:M,49:m,50:D,51:c},{20:[1,53]},{22:[1,54]},t(_,[2,18]),{1:[2,2]},t(_,[2,8]),t(_,[2,9]),t(H,[2,39],{41:55,42:k,43:R,44:b,45:E,46:v,47:L,48:M,49:m,50:D,51:c}),t(H,[2,40]),t(H,[2,41]),t(w,[2,42]),t(w,[2,44]),t(w,[2,45]),t(w,[2,46]),t(w,[2,47]),t(w,[2,48]),t(w,[2,49]),t(w,[2,50]),t(w,[2,51]),t(w,[2,52]),t(w,[2,53]),t(_,[2,10]),t(_,[2,24],{32:41,31:56,24:z,29:F}),t(_,[2,26]),t(_,[2,27]),{33:[1,57]},{11:59,30:x,34:58,39:24,40:C,41:27,42:k,43:R,44:b,45:E,46:v,47:L,48:M,49:m,50:D,51:c},t(_,[2,11]),t(_,[2,32],{35:60,29:X}),t(_,[2,34]),{33:[1,61]},t(_,[2,12]),{17:62,24:N},{25:63,27:64,29:A},t(_,[2,14]),{17:66,24:N},t(_,[2,16]),t(_,[2,17]),t(w,[2,43]),t(_,[2,25]),{29:[1,67]},{26:[1,68]},{26:[2,31],28:[1,69]},t(_,[2,33]),{29:[1,70]},t(_,[2,13]),{26:[1,71]},{26:[2,21],28:[1,72]},t(O,[2,23],{30:[1,73]}),t(_,[2,15]),t(_,[2,28]),t(_,[2,29]),{11:59,30:x,34:74,39:24,40:C,41:27,42:k,43:R,44:b,45:E,46:v,47:L,48:M,49:m,50:D,51:c},t(_,[2,35]),t(_,[2,19]),{25:75,27:64,29:A},t(O,[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:a(function(r,g){if(g.recoverable)this.trace(r);else{var u=new Error(r);throw u.hash=g,u}},"parseError"),parse:a(function(r){var g=this,u=[0],f=[],S=[null],o=[],Z=this.table,p="",et=0,kt=0,ii=2,Tt=1,ei=o.slice.call(arguments,1),P=Object.create(this.lexer),$={yy:{}};for(var ht in this.yy)Object.prototype.hasOwnProperty.call(this.yy,ht)&&($.yy[ht]=this.yy[ht]);P.setInput(r,$.yy),$.yy.lexer=P,$.yy.parser=this,typeof P.yylloc>"u"&&(P.yylloc={});var lt=P.yylloc;o.push(lt);var si=P.options&&P.options.ranges;typeof $.yy.parseError=="function"?this.parseError=$.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function ni(B){u.length=u.length-2*B,S.length=S.length-B,o.length=o.length-B}a(ni,"popStack");function Dt(){var B;return B=f.pop()||P.lex()||Tt,typeof B!="number"&&(B instanceof Array&&(f=B,B=f.pop()),B=g.symbols_[B]||B),B}a(Dt,"lex");for(var I,U,V,ct,j={},st,Y,Pt,nt;;){if(U=u[u.length-1],this.defaultActions[U]?V=this.defaultActions[U]:((I===null||typeof I>"u")&&(I=Dt()),V=Z[U]&&Z[U][I]),typeof V>"u"||!V.length||!V[0]){var gt="";nt=[];for(st in Z[U])this.terminals_[st]&&st>ii&&nt.push("'"+this.terminals_[st]+"'");P.showPosition?gt="Parse error on line "+(et+1)+`:
|
|
2
2
|
`+P.showPosition()+`
|
|
3
3
|
Expecting `+nt.join(", ")+", got '"+(this.terminals_[I]||I)+"'":gt="Parse error on line "+(et+1)+": Unexpected "+(I==Tt?"end of input":"'"+(this.terminals_[I]||I)+"'"),this.parseError(gt,{text:P.match,token:this.terminals_[I]||I,line:P.yylineno,loc:lt,expected:nt})}if(V[0]instanceof Array&&V.length>1)throw new Error("Parse Error: multiple actions possible at state: "+U+", token: "+I);switch(V[0]){case 1:u.push(I),S.push(P.yytext),o.push(P.yylloc),u.push(V[1]),I=null,kt=P.yyleng,p=P.yytext,et=P.yylineno,lt=P.yylloc;break;case 2:if(Y=this.productions_[V[1]][1],j.$=S[S.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},si&&(j._$.range=[o[o.length-(Y||1)].range[0],o[o.length-1].range[1]]),ct=this.performAction.apply(j,[p,kt,et,$.yy,V[1],S,o].concat(ei)),typeof ct<"u")return ct;Y&&(u=u.slice(0,-1*Y*2),S=S.slice(0,-1*Y),o=o.slice(0,-1*Y)),u.push(this.productions_[V[1]][0]),S.push(j.$),o.push(j._$),Pt=Z[u[u.length-2]][u[u.length-1]],u.push(Pt);break;case 3:return!0}}return!0},"parse")},K=(function(){var W={EOF:1,parseError:a(function(g,u){if(this.yy.parser)this.yy.parser.parseError(g,u);else throw new Error(g)},"parseError"),setInput:a(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:a(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:a(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 f=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 S=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===f.length?this.yylloc.first_column:0)+f[f.length-u.length].length-u[0].length:this.yylloc.first_column-g},this.options.ranges&&(this.yylloc.range=[S[0],S[0]+this.yyleng-g]),this.yyleng=this.yytext.length,this},"unput"),more:a(function(){return this._more=!0,this},"more"),reject:a(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:a(function(r){this.unput(this.match.slice(r))},"less"),pastInput:a(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:a(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:a(function(){var r=this.pastInput(),g=new Array(r.length+1).join("-");return r+this.upcomingInput()+`
|
package/web/index.html
CHANGED
|
@@ -102,8 +102,8 @@
|
|
|
102
102
|
} catch (e) {}
|
|
103
103
|
})();
|
|
104
104
|
</script>
|
|
105
|
-
<script type="module" crossorigin src="/assets/app-
|
|
106
|
-
<link rel="stylesheet" crossorigin href="/assets/app-
|
|
105
|
+
<script type="module" crossorigin src="/assets/app-DDsVI393.js"></script>
|
|
106
|
+
<link rel="stylesheet" crossorigin href="/assets/app-BinIaXyk.css">
|
|
107
107
|
</head>
|
|
108
108
|
<body class="bg-dls-surface text-dls-text mac:bg-transparent">
|
|
109
109
|
<div id="root">
|