mirror of
https://github.com/crazywhalecc/static-php-cli.git
synced 2026-07-20 23:35:37 +08:00
157 lines
59 KiB
JavaScript
157 lines
59 KiB
JavaScript
|
|
import{g as Xe}from"./chunk-5VM5RSS4.D8JH7qlT.js";import{g as Qe}from"./chunk-XXDRQBXY.Cwm78DH8.js";import{s as Ze}from"./chunk-VR4S4FIN.V_t2sjuN.js";import{_ as k,b6 as Je,X as Me,l as Z,c as g1,v as $e,x as et,y as re,b as tt,s as st,o as it,a as rt,g as at,p as nt,k as ut,Y as ot,Z as lt,bp as ct,r as se,d as ie,a5 as ht,q as dt,b9 as pt,t as ft}from"./mermaid.core.TSSz6aZW.js";import{f as gt}from"./chunk-32BRIVSS.DTslVixY.js";import{c as bt}from"./channel.DVCQ8-ym.js";var At="flowchart-",G1,kt=(G1=class{constructor(){this.vertexCounter=0,this.config=g1(),this.diagramId="",this.vertices=new Map,this.edges=[],this.classes=new Map,this.subGraphs=[],this.subGraphLookup=new Map,this.tooltips=new Map,this.subCount=0,this.firstGraphFlag=!0,this.secCount=-1,this.posCrossRef=[],this.funs=[],this.setAccTitle=tt,this.setAccDescription=st,this.setDiagramTitle=it,this.getAccTitle=rt,this.getAccDescription=at,this.getDiagramTitle=nt,this.funs.push(this.setupToolTips.bind(this)),this.addVertex=this.addVertex.bind(this),this.firstGraph=this.firstGraph.bind(this),this.setDirection=this.setDirection.bind(this),this.addSubGraph=this.addSubGraph.bind(this),this.addLink=this.addLink.bind(this),this.setLink=this.setLink.bind(this),this.updateLink=this.updateLink.bind(this),this.addClass=this.addClass.bind(this),this.setClass=this.setClass.bind(this),this.destructLink=this.destructLink.bind(this),this.setClickEvent=this.setClickEvent.bind(this),this.setTooltip=this.setTooltip.bind(this),this.updateLinkInterpolate=this.updateLinkInterpolate.bind(this),this.setClickFun=this.setClickFun.bind(this),this.bindFunctions=this.bindFunctions.bind(this),this.lex={firstGraph:this.firstGraph.bind(this)},this.clear(),this.setGen("gen-2")}sanitizeText(i){return ut.sanitizeText(i,this.config)}sanitizeNodeLabelType(i){switch(i){case"markdown":case"string":case"text":return i;default:return"markdown"}}setDiagramId(i){this.diagramId=i}lookUpDomId(i){for(const r of this.vertices.values())if(r.id===i)return this.diagramId?`${this.diagramId}-${r.domId}`:r.domId;return this.diagramId?`${this.diagramId}-${i}`:i}addVertex(i,r,a,n,l,p,c={},g){if(!i||i.trim().length===0)return;let u;if(g!==void 0){let m;g.includes(`
|
||
|
|
`)?m=g+`
|
||
|
|
`:m=`{
|
||
|
|
`+g+`
|
||
|
|
}`,u=ot(m,{schema:lt})}const A=this.edges.find(m=>m.id===i);if(A){const m=u;m?.animate!==void 0&&(A.animate=m.animate),m?.animation!==void 0&&(A.animation=m.animation),m?.curve!==void 0&&(A.interpolate=m.curve);return}let v,b=this.vertices.get(i);if(b===void 0&&(r===void 0&&a===void 0&&n!==void 0&&n!==null&&Z.warn(`Style applied to unknown node "${i}". This may indicate a typo. The node will be created automatically.`),b={id:i,labelType:"text",domId:At+i+"-"+this.vertexCounter,styles:[],classes:[]},this.vertices.set(i,b)),this.vertexCounter++,r!==void 0?(this.config=g1(),v=this.sanitizeText(r.text.trim()),b.labelType=r.type,v.startsWith('"')&&v.endsWith('"')&&(v=v.substring(1,v.length-1)),b.text=v):b.text===void 0&&(b.text=i),a!==void 0&&(b.type=a),n?.forEach(m=>{b.styles.push(m)}),l?.forEach(m=>{b.classes.push(m)}),p!==void 0&&(b.dir=p),b.props===void 0?b.props=c:c!==void 0&&Object.assign(b.props,c),u!==void 0){if(u.shape){if(u.shape!==u.shape.toLowerCase()||u.shape.includes("_"))throw new Error(`No such shape: ${u.shape}. Shape names should be lowercase.`);if(!ct(u.shape))throw new Error(`No such shape: ${u.shape}.`);b.type=u?.shape}u?.label&&(b.text=u?.label,b.labelType=this.sanitizeNodeLabelType(u?.labelType)),u?.icon&&(b.icon=u?.icon,!u.label?.trim()&&b.text===i&&(b.text="")),u?.form&&(b.form=u?.form),u?.pos&&(b.pos=u?.pos),u?.img&&(b.img=u?.img,!u.label?.trim()&&b.text===i&&(b.text="")),u?.constraint&&(b.constraint=u.constraint),u.w&&(b.assetWidth=Number(u.w)),u.h&&(b.assetHeight=Number(u.h))}}addSingleLink(i,r,a,n){const c={start:i,end:r,type:void 0,text:"",labelType:"text",classes:[],isUserDefinedId:!1,interpolate:this.edges.defaultInterpolate};Z.info("abc78 Got edge...",c);const g=a.text;if(g!==void 0&&(c.text=this.sanitizeText(g.text.trim()),c.text.startsWith('"')&&c.text.endsWith('"')&&(c.text=c.text.substring(1,c.text.length-1)),c.labelType=this.sanitizeNodeLabelType(g.type)),a!==void 0&&(c.type=a.type,c.stroke=a.stroke,c.length=a.length>10?10:a.length),n&&!this.edges.some(u=>u.id===n))c.id=n,c.isUserDefinedId=!0;else{const u=this.edges.filter(A=>A.start===c.start&&A.end===c.end);u.length===0?c.id=se(c.start,c.end,{counter:0,prefix:"L"}):c.id=se(c.start,c.end,{counter:u.length+1,prefix:"L"})}if(this.edges.length<(this.config.maxEdges??500))Z.info("Pushing edge..."),this.edges.push(c);else throw new Error(`Edge limit exceeded. ${this.edges.length} edges found, but the limit is ${this.config.maxEdges}.
|
||
|
|
|
||
|
|
Initialize mermaid with maxEdges set to a higher number to allow more edges.
|
||
|
|
You cannot set this config via configuration inside the diagram as it is a secure config.
|
||
|
|
You have to call mermaid.initialize.`)}isLinkData(i){return i!==null&&typeof i=="object"&&"id"in i&&typeof i.id=="string"}addLink(i,r,a){const n=this.isLinkData(a)?a.id.replace("@",""):void 0;Z.info("addLink",i,r,n);for(const l of i)for(const p of r){const c=l===i[i.length-1],g=p===r[0];c&&g?this.addSingleLink(l,p,a,n):this.addSingleLink(l,p,a,void 0)}}updateLinkInterpolate(i,r){i.forEach(a=>{a==="default"?this.edges.defaultInterpolate=r:this.edges[a].interpolate=r})}updateLink(i,r){i.forEach(a=>{if(typeof a=="number"&&a>=this.edges.length)throw new Error(`The index ${a} for linkStyle is out of bounds. Valid indices for linkStyle are between 0 and ${this.edges.length-1}. (Help: Ensure that the index is within the range of existing edges.)`);a==="default"?this.edges.defaultStyle=r:(this.edges[a].style=r,(this.edges[a]?.style?.length??0)>0&&!this.edges[a]?.style?.some(n=>n?.startsWith("fill"))&&this.edges[a]?.style?.push("fill:none"))})}addClass(i,r){const a=r.join().replace(/\\,/g,"§§§").replace(/,/g,";").replace(/§§§/g,",").split(";");i.split(",").forEach(n=>{let l=this.classes.get(n);l===void 0&&(l={id:n,styles:[],textStyles:[]},this.classes.set(n,l)),a?.forEach(p=>{if(/color/.exec(p)){const c=p.replace("fill","bgFill");l.textStyles.push(c)}l.styles.push(p)})})}setDirection(i){this.direction=i.trim(),/.*</.exec(this.direction)&&(this.direction="RL"),/.*\^/.exec(this.direction)&&(this.direction="BT"),/.*>/.exec(this.direction)&&(this.direction="LR"),/.*v/.exec(this.direction)&&(this.direction="TB"),this.direction==="TD"&&(this.direction="TB")}setClass(i,r){for(const a of i.split(",")){const n=this.vertices.get(a);n&&n.classes.push(r);const l=this.edges.find(c=>c.id===a);l&&l.classes.push(r);const p=this.subGraphLookup.get(a);p&&p.classes.push(r)}}setTooltip(i,r){if(r!==void 0){r=this.sanitizeText(r);for(const a of i.split(","))this.tooltips.set(this.version==="gen-1"?this.lookUpDomId(a):a,r)}}setClickFun(i,r,a){if(g1().securityLevel!=="loose"||r===void 0)return;let n=[];if(typeof a=="string"){n=a.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let p=0;p<n.length;p++){let c=n[p].trim();c.startsWith('"')&&c.endsWith('"')&&(c=c.substr(1,c.length-2)),n[p]=c}}n.length===0&&n.push(i);const l=this.vertices.get(i);l&&(l.haveCallback=!0,this.funs.push(()=>{const p=this.lookUpDomId(i),c=document.querySelector(`[id="${p}"]`);c!==null&&c.addEventListener("click",()=>{re.runFunc(r,...n)},!1)}))}setLink(i,r,a){i.split(",").forEach(n=>{const l=this.vertices.get(n);l!==void 0&&(l.link=re.formatUrl(r,this.config),l.linkTarget=a)}),this.setClass(i,"clickable")}getTooltip(i){return this.tooltips.get(i)}setClickEvent(i,r,a){i.split(",").forEach(n=>{this.setClickFun(n,r,a)}),this.setClass(i,"clickable")}bindFunctions(i){this.funs.forEach(r=>{r(i)})}getDirection(){return this.direction?.trim()}getVertices(){return this.vertices}getEdges(){return this.edges}getClasses(){return this.classes}setupToolTips(i){const r=gt();ie(i).select("svg").selectAll("g.node").on("mouseover",l=>{const p=ie(l.currentTarget),c=p.attr("title");if(c===null)return;const g=l.currentTarget?.getBoundingClientRect();r.transition().duration(200).style("opacity",".9"),r.text(p.attr("title")).style("left",window.scrollX+g.left+(g.right-g.left)/2+"px").style("top",window.scrollY+g.bottom+"px"),r.html(ht.sanitize(c)),p.classed("hover",!0)}).on("mouseout",l=>{r.transition().duration(500).style("opacity",0),ie(l.currentTarget).classed("hover",!1)})}clear(i="gen-2"){this.vertices=new Map,this.classes=new Map,this.edges=[],this.funs=[this.setupToolTips.bind(this)],this.diagramId="",this.subGraphs=[],this.subGraphLookup=new Map,this.subCount=0,this.tooltips=new Map,this.firstGraphFlag=!0,this.version=i,this.config=g1(),dt()}setGen(i){this.version=i||"gen-2"}defaultStyle(){return"fill:#ffa;stroke: #f66; stroke-width: 3px; stroke-dasharray: 5, 5;fill:#ffa;stroke: #666;"}addSubGraph(i,r,a){let n=i.text.trim(),l=a.text;i===a&&/\s/.exec(a.text)&&(n=void 0);const c=k(S=>{const B={boolean:{},number:{},string:{}},b1=[];let A1;return{nodeList:S.filter(function(K){const h1=typeof K;return
|
||
|
|
`+U.showPosition()+`
|
||
|
|
Expecting `+X1.join(", ")+", got '"+(this.terminals_[Y]||Y)+"'":te="Parse error on line "+(L+1)+": Unexpected "+(Y==Ge?"end of input":"'"+(this.terminals_[Y]||Y)+"'"),this.parseError(te,{text:U.match,token:this.terminals_[Y]||Y,line:U.yylineno,loc:$1,expected:X1})}if(Q[0]instanceof Array&&Q.length>1)throw new Error("Parse Error: multiple actions possible at state: "+D1+", token: "+Y);switch(Q[0]){case 1:f.push(Y),F.push(U.yytext),e.push(U.yylloc),f.push(Q[1]),Y=null,Ne=U.yyleng,t=U.yytext,L=U.yylineno,$1=U.yylloc;break;case 2:if(c1=this.productions_[Q[1]][1],N1.$=F[F.length-c1],N1._$={first_line:e[e.length-(c1||1)].first_line,last_line:e[e.length-1].last_line,first_column:e[e.length-(c1||1)].first_column,last_column:e[e.length-1].last_column},qe&&(N1._$.range=[e[e.length-(c1||1)].range[0],e[e.length-1].range[1]]),ee=this.performAction.apply(N1,[t,Ne,L,m1.yy,Q[1],F,e].concat(Ye)),typeof ee<"u")return ee;c1&&(f=f.slice(0,-1*c1*2),F=F.slice(0,-1*c1),e=e.slice(0,-1*c1)),f.push(this.productions_[Q[1]][0]),F.push(N1.$),e.push(N1._$),Oe=O1[f[f.length-2]][f[f.length-1]],f.push(Oe);break;case 3:return!0}}return!0},"parse")},je=(function(){var f1={EOF:1,parseError:k(function(d,f){if(this.yy.parser)this.yy.parser.parseError(d,f);else throw new Error(d)},"parseError"),setInput:k(function(h,d){return this.yy=d||this.yy||{},this._input=h,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:k(function(){var h=this._input[0];this.yytext+=h,this.yyleng++,this.offset++,this.match+=h,this.matched+=h;var d=h.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),h},"input"),unput:k(function(h){var d=h.length,f=h.split(/(?:\r\n?|\n)/g);this._input=h+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-d),this.offset-=d;var o=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),f.length-1&&(this.yylineno-=f.length-1);var F=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:f?(f.length===o.length?this.yylloc.first_column:0)+o[o.length-f.length].length-f[0].length:this.yylloc.first_column-d},this.options.ranges&&(this.yylloc.range=[F[0],F[0]+this.yyleng-d]),this.yyleng=this.yytext.length,this},"unput"),more:k(function(){return this._more=!0,this},"more"),reject:k(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).
|
||
|
|
`+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:k(function(h){this.unput(this.match.slice(h))},"less"),pastInput:k(function(){var h=this.matched.substr(0,this.matched.length-this.match.length);return(h.length>20?"...":"")+h.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:k(function(){var h=this.match;return h.length<20&&(h+=this._input.substr(0,20-h.length)),(h.substr(0,20)+(h.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:k(function(){var h=this.pastInput(),d=new Array(h.length+1).join("-");return h+this.upcomingInput()+`
|
||
|
|
`+d+"^"},"showPosition"),test_match:k(function(h,d){var f,o,F;if(this.options.backtrack_lexer&&(F={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(F.yylloc.range=this.yylloc.range.slice(0))),o=h[0].match(/(?:\r\n?|\n).*/g),o&&(this.yylineno+=o.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:o?o[o.length-1].length-o[o.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+h[0].length},this.yytext+=h[0],this.match+=h[0],this.matches=h,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(h[0].length),this.matched+=h[0],f=this.performAction.call(this,this.yy,this,d,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),f)return f;if(this._backtrack){for(var e in F)this[e]=F[e];return!1}return!1},"test_match"),next:k(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var h,d,f,o;this._more||(this.yytext="",this.match="");for(var F=this._currentRules(),e=0;e<F.length;e++)if(f=this._input.match(this.rules[F[e]]),f&&(!d||f[0].length>d[0].length)){if(d=f,o=e,this.options.backtrack_lexer){if(h=this.test_match(f,F[e]),h!==!1)return h;if(this._backtrack){d=!1;continue}else return!1}else if(!this.options.flex)break}return d?(h=this.test_match(d,F[o]),h!==!1?h:!1):this._input===""?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text.
|
||
|
|
`+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:k(function(){var d=this.next();return d||this.lex()},"lex"),begin:k(function(d){this.conditionStack.push(d)},"begin"),popState:k(function(){var d=this.conditionStack.length-1;return d>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:k(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},"_currentRules"),topState:k(function(d){return d=this.conditionStack.length-1-Math.abs(d||0),d>=0?this.conditionStack[d]:"INITIAL"},"topState"),pushState:k(function(d){this.begin(d)},"pushState"),stateStackSize:k(function(){return this.conditionStack.length},"stateStackSize"),options:{},performAction:k(function(d,f,o,F){switch(o){case 0:return this.begin("acc_title"),34;case 1:return this.popState(),"acc_title_value";case 2:return this.begin("acc_descr"),36;case 3:return this.popState(),"acc_descr_value";case 4:this.begin("acc_descr_multiline");break;case 5:this.popState();break;case 6:return"acc_descr_multiline_value";case 7:return this.pushState("shapeData"),f.yytext="",40;case 8:return this.pushState("shapeDataStr"),40;case 9:return this.popState(),40;case 10:const e=/\n\s*/g;return f.yytext=f.yytext.replace(e,"<br/>"),40;case 11:return 40;case 12:this.popState();break;case 13:this.begin("callbackname");break;case 14:this.popState();break;case 15:this.popState(),this.begin("callbackargs");break;case 16:return 95;case 17:this.popState();break;case 18:return 96;case 19:return"MD_STR";case 20:this.popState();break;case 21:this.begin("md_string");break;case 22:return"STR";case 23:this.popState();break;case 24:this.pushState("string");break;case 25:return 84;case 26:return 102;case 27:return 85;case 28:return 104;case 29:return 86;case 30:return 87;case 31:return 97;case 32:this.begin("click");break;case 33:this.popState();break;case 34:return 88;case 35:return d.lex.firstGraph()&&this.begin("dir"),12;case 36:return d.lex.firstGraph()&&this.begin("dir"),12;case 37:return d.lex.firstGraph()&&this.begin("dir"),12;case 38:return d.lex.firstGraph()&&this.begin("dir"),12;case 39:return 27;case 40:return 32;case 41:return 98;case 42:return 98;case 43:return 98;case 44:return 98;case 45:return this.popState(),13;case 46:return this.popState(),14;case 47:return this.popState(),14;case 48:return this.popState(),14;case 49:return this.popState(),14;case 50:return this.popState(),14;case 51:return this.popState(),14;case 52:return this.popState(),14;case 53:return this.popState(),14;case 54:return this.popState(),14;case 55:return this.popState(),14;case 56:return 121;case 57:return 122;case 58:return 123;case 59:return 124;case 60:return 125;case 61:return 78;case 62:return 105;case 63:return 111;case 64:return 46;case 65:return 60;case 66:return 44;case 67:return 8;case 68:return 106;case 69:return 115;case 70:return this.popState(),77;case 71:return this.pushState("edgeText"),75;case 72:return 119;case 73:return this.popState(),77;case 74:return this.pushState("thickEdgeText"),75;case 75:return 119;case 76:return this.popState(),77;case 77:return this.pushState("dottedEdgeText"),75;case 78:return 119;case 79:return 77;case 80:return this.popState(),53;case 81:return"TEXT";case 82:return this.pushState("ellipseText"),52;case 83:return this.popState(),55;case 84:return this.pushState("text"),54;case 85:return this.popState(),57;case 86:return this.pushState("text"),56;case 87:return 58;case 88:return this.pushState("text"),67;case 89:return this.popState(),64;case 90:return this.pushState("text"),63;case 91:return this.popState(),49;case 92:return this.pushState("text"),48;case 93:return this.popState(),69;case 94:return this.popState(),71;case 95:return 117;case 96:return this.pushState("trapText"),68;case 97:return this.pushState("trapText"),70;case 98:return 118;case 99:return 67;case 100:return 90;case 101:return"SEP";case 102:return 89;case 103:return 115;case 104:return 111;case 105:return 44;cas
|
||
|
|
`);return Ue.parse(i)};var Ct=ze,Tt=k((s,i)=>{const r=bt,a=r(s,"r"),n=r(s,"g"),l=r(s,"b");return ft(a,n,l,i)},"fade"),St=k(s=>`.label {
|
||
|
|
font-family: ${s.fontFamily};
|
||
|
|
color: ${s.nodeTextColor||s.textColor};
|
||
|
|
}
|
||
|
|
.cluster-label text {
|
||
|
|
fill: ${s.titleColor};
|
||
|
|
}
|
||
|
|
.cluster-label span {
|
||
|
|
color: ${s.titleColor};
|
||
|
|
}
|
||
|
|
.cluster-label span p {
|
||
|
|
background-color: transparent;
|
||
|
|
}
|
||
|
|
|
||
|
|
.label text,span {
|
||
|
|
fill: ${s.nodeTextColor||s.textColor};
|
||
|
|
color: ${s.nodeTextColor||s.textColor};
|
||
|
|
}
|
||
|
|
|
||
|
|
.node rect,
|
||
|
|
.node circle,
|
||
|
|
.node ellipse,
|
||
|
|
.node polygon,
|
||
|
|
.node path {
|
||
|
|
fill: ${s.mainBkg};
|
||
|
|
stroke: ${s.nodeBorder};
|
||
|
|
stroke-width: ${s.strokeWidth??1}px;
|
||
|
|
}
|
||
|
|
.rough-node .label text , .node .label text, .image-shape .label, .icon-shape .label {
|
||
|
|
text-anchor: middle;
|
||
|
|
}
|
||
|
|
|
||
|
|
.node .katex path {
|
||
|
|
fill: #000;
|
||
|
|
stroke: #000;
|
||
|
|
stroke-width: 1px;
|
||
|
|
}
|
||
|
|
|
||
|
|
.rough-node .label,.node .label, .image-shape .label, .icon-shape .label {
|
||
|
|
text-align: center;
|
||
|
|
}
|
||
|
|
.node.clickable {
|
||
|
|
cursor: pointer;
|
||
|
|
}
|
||
|
|
|
||
|
|
|
||
|
|
.root .anchor path {
|
||
|
|
fill: ${s.lineColor} !important;
|
||
|
|
stroke-width: 0;
|
||
|
|
stroke: ${s.lineColor};
|
||
|
|
}
|
||
|
|
|
||
|
|
.arrowheadPath {
|
||
|
|
fill: ${s.arrowheadColor};
|
||
|
|
}
|
||
|
|
|
||
|
|
.edgePath .path {
|
||
|
|
stroke: ${s.lineColor};
|
||
|
|
stroke-width: ${s.strokeWidth??2}px;
|
||
|
|
}
|
||
|
|
|
||
|
|
.flowchart-link {
|
||
|
|
stroke: ${s.lineColor};
|
||
|
|
fill: none;
|
||
|
|
}
|
||
|
|
|
||
|
|
.edgeLabel {
|
||
|
|
background-color: ${s.edgeLabelBackground};
|
||
|
|
p {
|
||
|
|
background-color: ${s.edgeLabelBackground};
|
||
|
|
}
|
||
|
|
rect {
|
||
|
|
opacity: 0.5;
|
||
|
|
background-color: ${s.edgeLabelBackground};
|
||
|
|
fill: ${s.edgeLabelBackground};
|
||
|
|
}
|
||
|
|
text-align: center;
|
||
|
|
}
|
||
|
|
|
||
|
|
/* For html labels only */
|
||
|
|
.labelBkg {
|
||
|
|
background-color: ${Tt(s.edgeLabelBackground,.5)};
|
||
|
|
// background-color:
|
||
|
|
}
|
||
|
|
|
||
|
|
.cluster rect {
|
||
|
|
fill: ${s.clusterBkg};
|
||
|
|
stroke: ${s.clusterBorder};
|
||
|
|
stroke-width: 1px;
|
||
|
|
}
|
||
|
|
|
||
|
|
.cluster text {
|
||
|
|
fill: ${s.titleColor};
|
||
|
|
}
|
||
|
|
|
||
|
|
.cluster span {
|
||
|
|
color: ${s.titleColor};
|
||
|
|
}
|
||
|
|
/* .cluster div {
|
||
|
|
color: ${s.titleColor};
|
||
|
|
} */
|
||
|
|
|
||
|
|
div.mermaidTooltip {
|
||
|
|
position: absolute;
|
||
|
|
text-align: center;
|
||
|
|
max-width: 200px;
|
||
|
|
padding: 2px;
|
||
|
|
font-family: ${s.fontFamily};
|
||
|
|
font-size: 12px;
|
||
|
|
background: ${s.tertiaryColor};
|
||
|
|
border: 1px solid ${s.border2};
|
||
|
|
border-radius: 2px;
|
||
|
|
pointer-events: none;
|
||
|
|
z-index: 100;
|
||
|
|
}
|
||
|
|
|
||
|
|
.flowchartTitleText {
|
||
|
|
text-anchor: middle;
|
||
|
|
font-size: 18px;
|
||
|
|
fill: ${s.textColor};
|
||
|
|
}
|
||
|
|
|
||
|
|
rect.text {
|
||
|
|
fill: none;
|
||
|
|
stroke-width: 0;
|
||
|
|
}
|
||
|
|
|
||
|
|
.icon-shape, .image-shape {
|
||
|
|
background-color: ${s.edgeLabelBackground};
|
||
|
|
p {
|
||
|
|
background-color: ${s.edgeLabelBackground};
|
||
|
|
padding: 2px;
|
||
|
|
}
|
||
|
|
.label rect {
|
||
|
|
opacity: 0.5;
|
||
|
|
background-color: ${s.edgeLabelBackground};
|
||
|
|
fill: ${s.edgeLabelBackground};
|
||
|
|
}
|
||
|
|
text-align: center;
|
||
|
|
}
|
||
|
|
${Xe()}
|
||
|
|
`,"getStyles"),yt=St,We=k(({defaultLayout:s,styles:i=yt}={})=>({parser:Ct,get db(){return new kt},renderer:Et,styles:i,init:k(r=>{r.flowchart||(r.flowchart={});const a=Je().layout??s??r.layout;a&&Me({layout:a}),r.flowchart.arrowMarkerAbsolute=r.arrowMarkerAbsolute,Me({flowchart:{arrowMarkerAbsolute:r.arrowMarkerAbsolute}})},"init")}),"createFlowDiagram"),xt=We();const It=Object.freeze(Object.defineProperty({__proto__:null,createFlowDiagram:We,diagram:xt},Symbol.toStringTag,{value:"Module"}));export{We as c,It as f,yt as s};
|