@ui-ddy-process/design 1.6.25 → 1.6.27

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.
@@ -272,7 +272,7 @@
272
272
  <input type="text" spellcheck="false" />
273
273
  </div>
274
274
  <div class="djs-search-results" />
275
- </div>`,r0.RESULT_HTML='<div class="djs-search-result"></div>',r0.RESULT_PRIMARY_HTML='<div class="djs-search-result-primary"></div>',r0.RESULT_SECONDARY_HTML='<p class="djs-search-result-secondary"></p>';const Gb={__depends__:[bo,No,Ce],searchPad:["type",r0]};function X1(e,t,n,A){this._elementRegistry=e,this._canvas=n,this._search=A,t.registerProvider(this)}X1.$inject=["elementRegistry","searchPad","canvas","search"],X1.prototype.find=function(e){var t=this._canvas.getRootElements(),n=this._elementRegistry.filter(function(A){return!f0(A)&&!t.includes(A)});return this._search(n.map(A=>({element:A,label:fe(A),id:A.id})),e,{keys:["label","id"]}).map(Hb)};function Hb(e){const{item:{element:t},tokens:n}=e;return{element:t,primaryTokens:n.label,secondaryTokens:n.id}}const Pb={__depends__:[Gb,Jp],__init__:["bpmnSearch"],bpmnSearch:["type",X1]},Jb="M44.7648 11.3263L36.9892 2.64074C36.0451 1.58628 34.5651 0.988708 33.1904 0.988708H5.98667C3.22688 0.988708 0.989624 3.34892 0.989624 6.26039V55.0235C0.989624 57.9349 3.22688 60.2952 5.98667 60.2952H40.966C43.7257 60.2952 45.963 57.9349 45.963 55.0235V14.9459C45.963 13.5998 45.6407 12.3048 44.7648 11.3263Z",jb="M1.03845 48.1347C1.03845 49.3511 1.07295 50.758 1.38342 52.064C1.69949 53.3938 2.32428 54.7154 3.56383 55.6428C6.02533 57.4841 10.1161 58.7685 14.8212 59.6067C19.5772 60.4538 25.1388 60.8738 30.6831 60.8738C36.2276 60.8738 41.7891 60.4538 46.545 59.6067C51.2504 58.7687 55.3412 57.4842 57.8028 55.6429C59.0424 54.7156 59.6673 53.3938 59.9834 52.064C60.2938 50.7579 60.3285 49.351 60.3285 48.1344V13.8415C60.3285 12.6249 60.2938 11.218 59.9834 9.91171C59.6673 8.58194 59.0423 7.2602 57.8027 6.33294C55.341 4.49168 51.2503 3.20723 46.545 2.36914C41.7891 1.522 36.2276 1.10204 30.6831 1.10205C25.1388 1.10206 19.5772 1.52206 14.8213 2.36923C10.1162 3.20734 6.02543 4.49183 3.5639 6.33314C2.32433 7.26038 1.69951 8.58206 1.38343 9.91181C1.07295 11.2179 1.03845 12.6247 1.03845 13.8411V48.1347Z",Vb={width:36,height:50},Lb={width:50,height:50};function tu(e,t,n){return c2("path",{d:e,strokeWidth:2,transform:`translate(${t.x}, ${t.y})`,...n})}const Lt=5;function sa(e,t){this._styles=t,e.registerProvider(this)}sa.$inject=["outline","styles"],sa.prototype.getOutline=function(e){const t=this._styles.cls("djs-outline",["no-fill"]);var n;if(!f0(e))return f(e,"bpmn:Gateway")?(n=c2("rect"),N(n.style,{"transform-box":"fill-box",transform:"rotate(45deg)","transform-origin":"center"}),N2(n,N({x:2,y:2,rx:4,width:e.width-4,height:e.height-4},t))):a0(e,["bpmn:Task","bpmn:SubProcess","bpmn:Group","bpmn:CallActivity"])?(n=c2("rect"),N2(n,N({x:-Lt,y:-Lt,rx:14,width:e.width+Lt*2,height:e.height+Lt*2},t))):f(e,"bpmn:EndEvent")?(n=c2("circle"),N2(n,N({cx:e.width/2,cy:e.height/2,r:e.width/2+Lt+1},t))):f(e,"bpmn:Event")?(n=c2("circle"),N2(n,N({cx:e.width/2,cy:e.height/2,r:e.width/2+Lt},t))):f(e,"bpmn:DataObjectReference")&&nu(e,"bpmn:DataObjectReference")?n=tu(Jb,{x:-6,y:-6},t):f(e,"bpmn:DataStoreReference")&&nu(e,"bpmn:DataStoreReference")&&(n=tu(jb,{x:-6,y:-6},t)),n},sa.prototype.updateOutline=function(e,t){if(!f0(e))return a0(e,["bpmn:SubProcess","bpmn:Group"])?(N2(t,{width:e.width+Lt*2,height:e.height+Lt*2}),!0):!!a0(e,["bpmn:Event","bpmn:Gateway","bpmn:DataStoreReference","bpmn:DataObjectReference"])};function nu(e,t){var n;return t==="bpmn:DataObjectReference"?n=Vb:t==="bpmn:DataStoreReference"&&(n=Lb),e.width===n.width&&e.height===n.height}const Wb={__depends__:[Fd],__init__:["outlineProvider"],outlineProvider:["type",sa]};var _b='<?xml version="1.0" encoding="UTF-8"?><bpmn:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" targetNamespace="http://bpmn.io/schema/bpmn" id="Definitions_1"><bpmn:process id="Process_1" isExecutable="false"><bpmn:startEvent id="StartEvent_1"/></bpmn:process><bpmndi:BPMNDiagram id="BPMNDiagram_1"><bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="Process_1"><bpmndi:BPMNShape id="_BPMNShape_StartEvent_2" bpmnElement="StartEvent_1"><dc:Bounds height="36.0" width="36.0" x="173.0" y="102.0"/></bpmndi:BPMNShape></bpmndi:BPMNPlane></bpmndi:BPMNDiagram></bpmn:definitions>';function Ie(e){HA.call(this,e)}W(Ie,HA),Ie.Viewer=et,Ie.NavigatedViewer=_A,Ie.prototype.createDiagram=function(){return this.importXML(_b)},Ie.prototype._interactionModules=[Og,Hc,jc],Ie.prototype._modelingModules=[_D,As,uy,ly,Sy,Es,Jy,Xv,qE,xr,$v,nx,Qx,wx,mx,yx,Tx,L3,jx,eb,lb,gb,md,Tb,Pb,Wb],Ie.prototype._modules=[].concat(et.prototype._modules,Ie.prototype._interactionModules,Ie.prototype._modelingModules);function K1(e,t,n,A,i,o,r,a,c){this._palette=e,this._create=t,this._elementFactory=n,this._spaceTool=A,this._lassoTool=i,this._handTool=o,this._globalConnect=r,this._translate=a,this._bpmnFactory=c,e.registerProvider(this)}K1.$inject=["palette","create","elementFactory","spaceTool","lassoTool","handTool","globalConnect","translate","bpmnFactory"],K1.prototype.getPaletteEntries=function(e){const t={},n=this._create,A=this._elementFactory,i=this._spaceTool,o=this._lassoTool,r=this._handTool,a=this._globalConnect,c=this._translate,l=this._bpmnFactory;function B(d,u,h,D,y){function C(I){const x=A.createShape(N({type:d},y));n.start(I,x)}const m=d.replace(/^bpmn:/,"");return{group:u,className:h,title:D||c("Create {type}",{type:m}),action:{dragstart:C,click:C}}}function g(d){const u=A.createShape({type:"bpmn:SubProcess",x:0,y:0,isExpanded:!0}),h=A.createShape({type:"bpmn:StartEvent",x:40,y:82,parent:u});n.start(d,[u,h],{hints:{autoSelect:[h]}})}function p(d){n.start(d,A.createParticipantShape())}function E(d){const u=l.create("bpmn:Task",{name:"抄送任务",customType:"抄送任务","flowable:customType":"flowable抄送任务"}),h=A.createShape({type:"bpmn:Task",businessObject:u});h.di.isExpanded=!0,n.start(d,h)}return N(t,{"hand-tool":{group:"tools",className:"bpmn-icon-hand-tool",title:c("Activate the hand tool"),action:{click:function(d){r.activateHand(d)}}},"lasso-tool":{group:"tools",className:"bpmn-icon-lasso-tool",title:c("Activate the lasso tool"),action:{click:function(d){o.activateSelection(d)}}},"space-tool":{group:"tools",className:"bpmn-icon-space-tool",title:c("Activate the create/remove space tool"),action:{click:function(d){i.activateSelection(d)}}},"global-connect-tool":{group:"tools",className:"bpmn-icon-connection-multi",title:c("Activate the global connect tool"),action:{click:function(d){a.toggle(d)}}},"tool-separator":{group:"tools",separator:!0},"create.start-event":B("bpmn:StartEvent","event","bpmn-icon-start-event-none",c("Create StartEvent")),"create.intermediate-event":B("bpmn:IntermediateThrowEvent","event","bpmn-icon-intermediate-event-none",c("Create Intermediate/Boundary Event")),"create.end-event":B("bpmn:EndEvent","event","bpmn-icon-end-event-none",c("Create EndEvent")),"create.exclusive-gateway":B("bpmn:ExclusiveGateway","gateway","bpmn-icon-gateway-xor",c("Create Exclusive Gateway")),"create.inclusive-gateway":B("bpmn:InclusiveGateway","gateway","bpmn-icon-gateway-or",c("Create Inclusive Gateway")),"create.parallel-gateway":B("bpmn:ParallelGateway","gateway","bpmn-icon-gateway-parallel",c("Create Parallel Gateway")),"create.UserTask":B("bpmn:UserTask","activity","bpmn-icon-user-task",c("Create UserTask")),"create.subprocess-expanded":{group:"activity",className:"bpmn-icon-subprocess-expanded",title:c("Create expanded SubProcess"),action:{dragstart:g,click:g}},"create.participant-expanded":{group:"collaboration",className:"bpmn-icon-participant",title:c("Create Pool/Participant"),action:{dragstart:p,click:p}},"create.cc-task":{group:"model",className:"bpmn-icon-task CC-task",title:c("抄送任务"),action:{dragstart:E,click:E}}}),t};function Z1(e,t,n,A,i,o,r,a,c,l,B,g){e=e||{},A.registerProvider(this),this._contextPad=A,this._modeling=i,this._elementFactory=o,this._connect=r,this._create=a,this._popupMenu=c,this._canvas=l,this._rules=B,this._translate=g,e.autoPlace!==!1&&(this._autoPlace=t.get("autoPlace",!1)),n.on("create.end",250,function(p){const E=p.context,d=E.shape;if(!(!Wn(p)||!A.isOpen(d))){var u=A.getEntries(d);u.replace&&u.replace.action.click(p,d)}})}Z1.$inject=["config.contextPad","injector","eventBus","contextPad","modeling","elementFactory","connect","create","popupMenu","canvas","rules","translate"],Z1.prototype.getContextPadEntries=function(e){const t=this._contextPad,n=this._modeling,A=this._elementFactory,i=this._connect,o=this._create,r=this._popupMenu,a=this._canvas,c=this._rules,l=this._autoPlace,B=this._translate,g={};if(e.type==="label")return g;const p=e.businessObject;function E(m,I){i.start(m,I)}function d(){n.removeElements([e])}function u(m){const x=a.getContainer(),v=x.querySelector(".djs-context-pad"),F=x.getBoundingClientRect(),z=v.getBoundingClientRect(),R=z.top-F.top;return{x:z.left-F.left,y:R+z.height+5}}function h(m,I,x,v){typeof x!="string"&&(v=x,x=B("Append {type}",{type:m.replace(/^bpmn:/,"")}));function F(R,k){const T=A.createShape(N({type:m},v));o.start(R,T,{source:k})}return{group:"model",className:I,title:x,action:{dragstart:F,click:l?function(R,k){const T=A.createShape(N({type:m},v));l.append(k,T)}:F}}}function D(m){return function(I,x){n.splitLane(x,m),t.open(x,!0)}}if(a0(p,["bpmn:Lane","bpmn:Participant"])&&E0(p)){const m=it(e);N(g,{"lane-insert-above":{group:"lane-insert-above",className:"bpmn-icon-lane-insert-above",title:B("Add Lane above"),action:{click:function(I,x){n.addLane(x,"top")}}}}),m.length<2&&(e.height>=120&&N(g,{"lane-divide-two":{group:"lane-divide",className:"bpmn-icon-lane-divide-two",title:B("Divide into two Lanes"),action:{click:D(2)}}}),e.height>=180&&N(g,{"lane-divide-three":{group:"lane-divide",className:"bpmn-icon-lane-divide-three",title:B("Divide into three Lanes"),action:{click:D(3)}}})),N(g,{"lane-insert-below":{group:"lane-insert-below",className:"bpmn-icon-lane-insert-below",title:B("Add Lane below"),action:{click:function(I,x){n.addLane(x,"bottom")}}}})}if(f(p,"bpmn:FlowNode"))if(f(p,"bpmn:EventBasedGateway")){var y="0d9a60fe0131dff70d665020f5b0cdee";N(g,{"append.receive-task":h("bpmn:ReceiveTask","bpmn-icon-receive-task"),"append.message-intermediate-event":h("bpmn:IntermediateCatchEvent","bpmn-icon-intermediate-event-catch-message",B("Append MessageIntermediateCatchEvent"),{eventDefinitionType:"bpmn:MessageEventDefinition"}),"append.timer-intermediate-event":h("bpmn:IntermediateCatchEvent","bpmn-icon-intermediate-event-catch-timer",B("Append TimerIntermediateCatchEvent"),{eventDefinitionType:"bpmn:TimerEventDefinition"}),"append.condition-intermediate-event":h("bpmn:IntermediateCatchEvent","bpmn-icon-intermediate-event-catch-condition",B("Append ConditionIntermediateCatchEvent"),{eventDefinitionType:"bpmn:ConditionalEventDefinition"}),"append.signal-intermediate-event":h("bpmn:IntermediateCatchEvent","bpmn-icon-intermediate-event-catch-signal",B("Append SignalIntermediateCatchEvent"),{eventDefinitionType:"bpmn:SignalEventDefinition"})}),y.trim()}else Au(p,"bpmn:BoundaryEvent","bpmn:CompensateEventDefinition")?N(g,{"append.compensation-activity":h("bpmn:Task","bpmn-icon-task",B("Append compensation activity"),{isForCompensation:!0})}):!f(p,"bpmn:EndEvent")&&!p.isForCompensation&&!Au(p,"bpmn:IntermediateThrowEvent","bpmn:LinkEventDefinition")&&!h2(p)&&N(g,{"append.end-event":h("bpmn:EndEvent","bpmn-icon-end-event-none",B("Append EndEvent")),"append.gateway":h("bpmn:ExclusiveGateway","bpmn-icon-gateway-none",B("Append Gateway")),"append.user-task":h("bpmn:UserTask","bpmn-icon-user-task",B("Append UserTask")),"append.intermediate-event":h("bpmn:IntermediateThrowEvent","bpmn-icon-intermediate-event-none",B("Append Intermediate/Boundary Event")),"append.timer-intermediate-event":h("bpmn:IntermediateCatchEvent","bpmn-icon-intermediate-event-catch-timer",B("Append TimerIntermediateCatchEvent"),{eventDefinitionType:"bpmn:TimerEventDefinition"})});r.isEmpty(e,"bpmn-replace")||N(g,{replace:{group:"edit",className:"bpmn-icon-screw-wrench",title:B("Change type"),action:{click:function(m,I){var x=N(u(),{cursor:{x:m.x,y:m.y}});r.open(I,"bpmn-replace",x)}}}}),a0(p,["bpmn:FlowNode","bpmn:InteractionNode","bpmn:DataObjectReference","bpmn:DataStoreReference"])&&N(g,{"append.text-annotation":h("bpmn:TextAnnotation","bpmn-icon-text-annotation",B("Append TextAnnotation")),connect:{group:"connect",className:"bpmn-icon-connection-multi",title:B("Connect using "+(p.isForCompensation?"":"Sequence/MessageFlow or ")+"Association"),action:{click:E,dragstart:E}}}),a0(p,["bpmn:DataObjectReference","bpmn:DataStoreReference"])&&N(g,{connect:{group:"connect",className:"bpmn-icon-connection-multi",title:B("Connect using DataInputAssociation"),action:{click:E,dragstart:E}}});let C=c.allowed("elements.delete",{elements:[e]});return n0(C)&&(C=C[0]===e),C&&N(g,{delete:{group:"edit",className:"bpmn-icon-trash",title:B("Remove"),action:{click:d}}}),g};function Au(e,t,n){const A=e.$instanceOf(t);let i=!1;const o=e.eventDefinitions||[];return U(o,function(r){r.$type===n&&(i=!0)}),A&&i}function Ob(e,t){if(e.ownerDocument!==t.ownerDocument)try{return t.ownerDocument.importNode(e,!0)}catch{}return e}function la(e,t){return t.appendChild(Ob(e,t))}function Ni(e,t){return la(t,e),e}var q1=2,iu={"alignment-baseline":1,"baseline-shift":1,clip:1,"clip-path":1,"clip-rule":1,color:1,"color-interpolation":1,"color-interpolation-filters":1,"color-profile":1,"color-rendering":1,cursor:1,direction:1,display:1,"dominant-baseline":1,"enable-background":1,fill:1,"fill-opacity":1,"fill-rule":1,filter:1,"flood-color":1,"flood-opacity":1,font:1,"font-family":1,"font-size":q1,"font-size-adjust":1,"font-stretch":1,"font-style":1,"font-variant":1,"font-weight":1,"glyph-orientation-horizontal":1,"glyph-orientation-vertical":1,"image-rendering":1,kerning:1,"letter-spacing":1,"lighting-color":1,marker:1,"marker-end":1,"marker-mid":1,"marker-start":1,mask:1,opacity:1,overflow:1,"pointer-events":1,"shape-rendering":1,"stop-color":1,"stop-opacity":1,stroke:1,"stroke-dasharray":1,"stroke-dashoffset":1,"stroke-linecap":1,"stroke-linejoin":1,"stroke-miterlimit":1,"stroke-opacity":1,"stroke-width":q1,"text-anchor":1,"text-decoration":1,"text-rendering":1,"unicode-bidi":1,visibility:1,"word-spacing":1,"writing-mode":1};function Xb(e,t){return iu[t]?e.style[t]:e.getAttributeNS(null,t)}function ou(e,t,n){var A=t.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),i=iu[A];i?(i===q1&&typeof n=="number"&&(n=String(n)+"px"),e.style[A]=n):e.setAttributeNS(null,t,n)}function Kb(e,t){var n=Object.keys(t),A,i;for(A=0,i;i=n[A];A++)ou(e,i,t[i])}function He(e,t,n){if(typeof t=="string")if(n!==void 0)ou(e,t,n);else return Xb(e,t);else Kb(e,t);return e}const Zb=Object.prototype.toString;function $1(e){return new Wt(e)}function Wt(e){if(!e||!e.nodeType)throw new Error("A DOM element reference is required");this.el=e,this.list=e.classList}Wt.prototype.add=function(e){return this.list.add(e),this},Wt.prototype.remove=function(e){return Zb.call(e)=="[object RegExp]"?this.removeMatching(e):(this.list.remove(e),this)},Wt.prototype.removeMatching=function(e){const t=this.array();for(let n=0;n<t.length;n++)e.test(t[n])&&this.remove(t[n]);return this},Wt.prototype.toggle=function(e,t){return typeof t<"u"?t!==this.list.toggle(e,t)&&this.list.toggle(e):this.list.toggle(e),this},Wt.prototype.array=function(){return Array.from(this.list)},Wt.prototype.has=Wt.prototype.contains=function(e){return this.list.contains(e)};function qb(e){for(var t;t=e.firstChild;)e.removeChild(t);return e}function $b(e){return e.cloneNode(!0)}var el={svg:"http://www.w3.org/2000/svg"},ru='<svg xmlns="'+el.svg+'"';function au(e){var t=!1;e.substring(0,4)==="<svg"?e.indexOf(el.svg)===-1&&(e=ru+e.substring(4)):(e=ru+">"+e+"</svg>",t=!0);var n=eY(e);if(!t)return n;for(var A=document.createDocumentFragment(),i=n.firstChild;i.firstChild;)A.appendChild(i.firstChild);return A}function eY(e){var t;return t=new DOMParser,t.async=!1,t.parseFromString(e,"text/xml")}function _t(e,t){var n;return e=e.trim(),e.charAt(0)==="<"?(n=au(e).firstChild,n=document.importNode(n,!0)):n=document.createElementNS(el.svg,e),n}var cu=/([&<>]{1})/g,tY=/([&<>\n\r"]{1})/g,nY={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"'"};function tl(e,t){function n(A,i){return nY[i]||i}return e.replace(t,n)}function su(e,t){var n,A,i,o,r;switch(e.nodeType){case 3:t.push(tl(e.textContent,cu));break;case 1:if(t.push("<",e.tagName),e.hasAttributes())for(i=e.attributes,n=0,A=i.length;n<A;++n)o=i.item(n),t.push(" ",o.name,'="',tl(o.value,tY),'"');if(e.hasChildNodes()){for(t.push(">"),r=e.childNodes,n=0,A=r.length;n<A;++n)su(r.item(n),t);t.push("</",e.tagName,">")}else t.push("/>");break;case 8:t.push("<!--",tl(e.nodeValue,cu),"-->");break;case 4:t.push("<![CDATA[",e.nodeValue,"]]>");break;default:throw new Error("unable to handle node "+e.nodeType)}return t}function AY(e,t){var n=au(t);if(qb(e),!!t){oY(n)||(n=n.documentElement);for(var A=aY(n.childNodes),i=0;i<A.length;i++)la(A[i],e)}}function iY(e){for(var t=e.firstChild,n=[];t;)su(t,n),t=t.nextSibling;return n.join("")}function oY(e){return e.nodeName==="#document-fragment"}function rY(e,t){if(t!==void 0){try{AY(e,t)}catch(n){throw new Error("error parsing SVG: "+n.message)}return e}else return iY(e)}function aY(e){return Array.prototype.slice.call(e)}function lu(e){var t=e.parentNode;return t&&t.removeChild(e),e}const cY=1500,sY=2,lY="#52B415",BY="#ffc800",gY="#cc0000";class Bu extends be{constructor(t,n){super(t,cY),this.bpmnRenderer=n}canRender(t){return!t.labelTarget}drawShape(t,n){console.error("进来了???",t,n);const A=this.bpmnRenderer.drawShape(t,n),i=this.getSuitabilityScore(n),o=P(n);if(console.error(i,"suitabilityScore 评分得分"),o.$attrs.customType==="抄送任务"){var a=`
275
+ </div>`,r0.RESULT_HTML='<div class="djs-search-result"></div>',r0.RESULT_PRIMARY_HTML='<div class="djs-search-result-primary"></div>',r0.RESULT_SECONDARY_HTML='<p class="djs-search-result-secondary"></p>';const Gb={__depends__:[bo,No,Ce],searchPad:["type",r0]};function X1(e,t,n,A){this._elementRegistry=e,this._canvas=n,this._search=A,t.registerProvider(this)}X1.$inject=["elementRegistry","searchPad","canvas","search"],X1.prototype.find=function(e){var t=this._canvas.getRootElements(),n=this._elementRegistry.filter(function(A){return!f0(A)&&!t.includes(A)});return this._search(n.map(A=>({element:A,label:fe(A),id:A.id})),e,{keys:["label","id"]}).map(Hb)};function Hb(e){const{item:{element:t},tokens:n}=e;return{element:t,primaryTokens:n.label,secondaryTokens:n.id}}const Pb={__depends__:[Gb,Jp],__init__:["bpmnSearch"],bpmnSearch:["type",X1]},Jb="M44.7648 11.3263L36.9892 2.64074C36.0451 1.58628 34.5651 0.988708 33.1904 0.988708H5.98667C3.22688 0.988708 0.989624 3.34892 0.989624 6.26039V55.0235C0.989624 57.9349 3.22688 60.2952 5.98667 60.2952H40.966C43.7257 60.2952 45.963 57.9349 45.963 55.0235V14.9459C45.963 13.5998 45.6407 12.3048 44.7648 11.3263Z",jb="M1.03845 48.1347C1.03845 49.3511 1.07295 50.758 1.38342 52.064C1.69949 53.3938 2.32428 54.7154 3.56383 55.6428C6.02533 57.4841 10.1161 58.7685 14.8212 59.6067C19.5772 60.4538 25.1388 60.8738 30.6831 60.8738C36.2276 60.8738 41.7891 60.4538 46.545 59.6067C51.2504 58.7687 55.3412 57.4842 57.8028 55.6429C59.0424 54.7156 59.6673 53.3938 59.9834 52.064C60.2938 50.7579 60.3285 49.351 60.3285 48.1344V13.8415C60.3285 12.6249 60.2938 11.218 59.9834 9.91171C59.6673 8.58194 59.0423 7.2602 57.8027 6.33294C55.341 4.49168 51.2503 3.20723 46.545 2.36914C41.7891 1.522 36.2276 1.10204 30.6831 1.10205C25.1388 1.10206 19.5772 1.52206 14.8213 2.36923C10.1162 3.20734 6.02543 4.49183 3.5639 6.33314C2.32433 7.26038 1.69951 8.58206 1.38343 9.91181C1.07295 11.2179 1.03845 12.6247 1.03845 13.8411V48.1347Z",Vb={width:36,height:50},Lb={width:50,height:50};function tu(e,t,n){return c2("path",{d:e,strokeWidth:2,transform:`translate(${t.x}, ${t.y})`,...n})}const Lt=5;function sa(e,t){this._styles=t,e.registerProvider(this)}sa.$inject=["outline","styles"],sa.prototype.getOutline=function(e){const t=this._styles.cls("djs-outline",["no-fill"]);var n;if(!f0(e))return f(e,"bpmn:Gateway")?(n=c2("rect"),N(n.style,{"transform-box":"fill-box",transform:"rotate(45deg)","transform-origin":"center"}),N2(n,N({x:2,y:2,rx:4,width:e.width-4,height:e.height-4},t))):a0(e,["bpmn:Task","bpmn:SubProcess","bpmn:Group","bpmn:CallActivity"])?(n=c2("rect"),N2(n,N({x:-Lt,y:-Lt,rx:14,width:e.width+Lt*2,height:e.height+Lt*2},t))):f(e,"bpmn:EndEvent")?(n=c2("circle"),N2(n,N({cx:e.width/2,cy:e.height/2,r:e.width/2+Lt+1},t))):f(e,"bpmn:Event")?(n=c2("circle"),N2(n,N({cx:e.width/2,cy:e.height/2,r:e.width/2+Lt},t))):f(e,"bpmn:DataObjectReference")&&nu(e,"bpmn:DataObjectReference")?n=tu(Jb,{x:-6,y:-6},t):f(e,"bpmn:DataStoreReference")&&nu(e,"bpmn:DataStoreReference")&&(n=tu(jb,{x:-6,y:-6},t)),n},sa.prototype.updateOutline=function(e,t){if(!f0(e))return a0(e,["bpmn:SubProcess","bpmn:Group"])?(N2(t,{width:e.width+Lt*2,height:e.height+Lt*2}),!0):!!a0(e,["bpmn:Event","bpmn:Gateway","bpmn:DataStoreReference","bpmn:DataObjectReference"])};function nu(e,t){var n;return t==="bpmn:DataObjectReference"?n=Vb:t==="bpmn:DataStoreReference"&&(n=Lb),e.width===n.width&&e.height===n.height}const Wb={__depends__:[Fd],__init__:["outlineProvider"],outlineProvider:["type",sa]};var _b='<?xml version="1.0" encoding="UTF-8"?><bpmn:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" targetNamespace="http://bpmn.io/schema/bpmn" id="Definitions_1"><bpmn:process id="Process_1" isExecutable="false"><bpmn:startEvent id="StartEvent_1"/></bpmn:process><bpmndi:BPMNDiagram id="BPMNDiagram_1"><bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="Process_1"><bpmndi:BPMNShape id="_BPMNShape_StartEvent_2" bpmnElement="StartEvent_1"><dc:Bounds height="36.0" width="36.0" x="173.0" y="102.0"/></bpmndi:BPMNShape></bpmndi:BPMNPlane></bpmndi:BPMNDiagram></bpmn:definitions>';function Ie(e){HA.call(this,e)}W(Ie,HA),Ie.Viewer=et,Ie.NavigatedViewer=_A,Ie.prototype.createDiagram=function(){return this.importXML(_b)},Ie.prototype._interactionModules=[Og,Hc,jc],Ie.prototype._modelingModules=[_D,As,uy,ly,Sy,Es,Jy,Xv,qE,xr,$v,nx,Qx,wx,mx,yx,Tx,L3,jx,eb,lb,gb,md,Tb,Pb,Wb],Ie.prototype._modules=[].concat(et.prototype._modules,Ie.prototype._interactionModules,Ie.prototype._modelingModules);function K1(e,t,n,A,i,o,r,a,c){this._palette=e,this._create=t,this._elementFactory=n,this._spaceTool=A,this._lassoTool=i,this._handTool=o,this._globalConnect=r,this._translate=a,this._bpmnFactory=c,e.registerProvider(this)}K1.$inject=["palette","create","elementFactory","spaceTool","lassoTool","handTool","globalConnect","translate","bpmnFactory"],K1.prototype.getPaletteEntries=function(e){const t={},n=this._create,A=this._elementFactory,i=this._spaceTool,o=this._lassoTool,r=this._handTool,a=this._globalConnect,c=this._translate,l=this._bpmnFactory;function B(d,u,h,D,y){function C(I){const x=A.createShape(N({type:d},y));n.start(I,x)}const m=d.replace(/^bpmn:/,"");return{group:u,className:h,title:D||c("Create {type}",{type:m}),action:{dragstart:C,click:C}}}function g(d){const u=A.createShape({type:"bpmn:SubProcess",x:0,y:0,isExpanded:!0}),h=A.createShape({type:"bpmn:StartEvent",x:40,y:82,parent:u});n.start(d,[u,h],{hints:{autoSelect:[h]}})}function p(d){n.start(d,A.createParticipantShape())}function E(d){const u=l.create("bpmn:Task",{name:"抄送任务",customType:"抄送任务","flowable:customType":"flowable抄送任务"}),h=A.createShape({type:"bpmn:Task",businessObject:u});h.di.isExpanded=!0,n.start(d,h)}return N(t,{"hand-tool":{group:"tools",className:"bpmn-icon-hand-tool",title:c("Activate the hand tool"),action:{click:function(d){r.activateHand(d)}}},"lasso-tool":{group:"tools",className:"bpmn-icon-lasso-tool",title:c("Activate the lasso tool"),action:{click:function(d){o.activateSelection(d)}}},"space-tool":{group:"tools",className:"bpmn-icon-space-tool",title:c("Activate the create/remove space tool"),action:{click:function(d){i.activateSelection(d)}}},"global-connect-tool":{group:"tools",className:"bpmn-icon-connection-multi",title:c("Activate the global connect tool"),action:{click:function(d){a.toggle(d)}}},"tool-separator":{group:"tools",separator:!0},"create.start-event":B("bpmn:StartEvent","event","bpmn-icon-start-event-none",c("Create StartEvent")),"create.intermediate-event":B("bpmn:IntermediateThrowEvent","event","bpmn-icon-intermediate-event-none",c("Create Intermediate/Boundary Event")),"create.end-event":B("bpmn:EndEvent","event","bpmn-icon-end-event-none",c("Create EndEvent")),"create.exclusive-gateway":B("bpmn:ExclusiveGateway","gateway","bpmn-icon-gateway-xor",c("Create Exclusive Gateway")),"create.inclusive-gateway":B("bpmn:InclusiveGateway","gateway","bpmn-icon-gateway-or",c("Create Inclusive Gateway")),"create.parallel-gateway":B("bpmn:ParallelGateway","gateway","bpmn-icon-gateway-parallel",c("Create Parallel Gateway")),"create.UserTask":B("bpmn:UserTask","activity","bpmn-icon-user-task",c("Create UserTask")),"create.subprocess-expanded":{group:"activity",className:"bpmn-icon-subprocess-expanded",title:c("Create expanded SubProcess"),action:{dragstart:g,click:g}},"create.participant-expanded":{group:"collaboration",className:"bpmn-icon-participant",title:c("Create Pool/Participant"),action:{dragstart:p,click:p}},"create.cc-task":{group:"model",className:"bpmn-icon-task CC-task",title:c("抄送任务"),action:{dragstart:E,click:E}}}),t};function Z1(e,t,n,A,i,o,r,a,c,l,B,g){e=e||{},A.registerProvider(this),this._contextPad=A,this._modeling=i,this._elementFactory=o,this._connect=r,this._create=a,this._popupMenu=c,this._canvas=l,this._rules=B,this._translate=g,e.autoPlace!==!1&&(this._autoPlace=t.get("autoPlace",!1)),n.on("create.end",250,function(p){const E=p.context,d=E.shape;if(!(!Wn(p)||!A.isOpen(d))){var u=A.getEntries(d);u.replace&&u.replace.action.click(p,d)}})}Z1.$inject=["config.contextPad","injector","eventBus","contextPad","modeling","elementFactory","connect","create","popupMenu","canvas","rules","translate"],Z1.prototype.getContextPadEntries=function(e){const t=this._contextPad,n=this._modeling,A=this._elementFactory,i=this._connect,o=this._create,r=this._popupMenu,a=this._canvas,c=this._rules,l=this._autoPlace,B=this._translate,g={};if(e.type==="label")return g;const p=e.businessObject;function E(m,I){i.start(m,I)}function d(){n.removeElements([e])}function u(m){const x=a.getContainer(),v=x.querySelector(".djs-context-pad"),F=x.getBoundingClientRect(),z=v.getBoundingClientRect(),R=z.top-F.top;return{x:z.left-F.left,y:R+z.height+5}}function h(m,I,x,v){typeof x!="string"&&(v=x,x=B("Append {type}",{type:m.replace(/^bpmn:/,"")}));function F(R,k){const T=A.createShape(N({type:m},v));o.start(R,T,{source:k})}return{group:"model",className:I,title:x,action:{dragstart:F,click:l?function(R,k){const T=A.createShape(N({type:m},v));l.append(k,T)}:F}}}function D(m){return function(I,x){n.splitLane(x,m),t.open(x,!0)}}if(a0(p,["bpmn:Lane","bpmn:Participant"])&&E0(p)){const m=it(e);N(g,{"lane-insert-above":{group:"lane-insert-above",className:"bpmn-icon-lane-insert-above",title:B("Add Lane above"),action:{click:function(I,x){n.addLane(x,"top")}}}}),m.length<2&&(e.height>=120&&N(g,{"lane-divide-two":{group:"lane-divide",className:"bpmn-icon-lane-divide-two",title:B("Divide into two Lanes"),action:{click:D(2)}}}),e.height>=180&&N(g,{"lane-divide-three":{group:"lane-divide",className:"bpmn-icon-lane-divide-three",title:B("Divide into three Lanes"),action:{click:D(3)}}})),N(g,{"lane-insert-below":{group:"lane-insert-below",className:"bpmn-icon-lane-insert-below",title:B("Add Lane below"),action:{click:function(I,x){n.addLane(x,"bottom")}}}})}if(f(p,"bpmn:FlowNode"))if(f(p,"bpmn:EventBasedGateway")){var y="0d9a60fe0131dff70d665020f5b0cdee";N(g,{"append.receive-task":h("bpmn:ReceiveTask","bpmn-icon-receive-task"),"append.message-intermediate-event":h("bpmn:IntermediateCatchEvent","bpmn-icon-intermediate-event-catch-message",B("Append MessageIntermediateCatchEvent"),{eventDefinitionType:"bpmn:MessageEventDefinition"}),"append.timer-intermediate-event":h("bpmn:IntermediateCatchEvent","bpmn-icon-intermediate-event-catch-timer",B("Append TimerIntermediateCatchEvent"),{eventDefinitionType:"bpmn:TimerEventDefinition"}),"append.condition-intermediate-event":h("bpmn:IntermediateCatchEvent","bpmn-icon-intermediate-event-catch-condition",B("Append ConditionIntermediateCatchEvent"),{eventDefinitionType:"bpmn:ConditionalEventDefinition"}),"append.signal-intermediate-event":h("bpmn:IntermediateCatchEvent","bpmn-icon-intermediate-event-catch-signal",B("Append SignalIntermediateCatchEvent"),{eventDefinitionType:"bpmn:SignalEventDefinition"})}),y.trim()}else Au(p,"bpmn:BoundaryEvent","bpmn:CompensateEventDefinition")?N(g,{"append.compensation-activity":h("bpmn:Task","bpmn-icon-task",B("Append compensation activity"),{isForCompensation:!0})}):!f(p,"bpmn:EndEvent")&&!p.isForCompensation&&!Au(p,"bpmn:IntermediateThrowEvent","bpmn:LinkEventDefinition")&&!h2(p)&&N(g,{"append.end-event":h("bpmn:EndEvent","bpmn-icon-end-event-none",B("Append EndEvent")),"append.gateway":h("bpmn:ExclusiveGateway","bpmn-icon-gateway-none",B("Append Gateway")),"append.user-task":h("bpmn:UserTask","bpmn-icon-user-task",B("Append UserTask")),"append.intermediate-event":h("bpmn:IntermediateThrowEvent","bpmn-icon-intermediate-event-none",B("Append Intermediate/Boundary Event")),"append.timer-intermediate-event":h("bpmn:IntermediateCatchEvent","bpmn-icon-intermediate-event-catch-timer",B("Append TimerIntermediateCatchEvent"),{eventDefinitionType:"bpmn:TimerEventDefinition"})});r.isEmpty(e,"bpmn-replace")||N(g,{replace:{group:"edit",className:"bpmn-icon-screw-wrench",title:B("Change type"),action:{click:function(m,I){var x=N(u(),{cursor:{x:m.x,y:m.y}});r.open(I,"bpmn-replace",x)}}}}),a0(p,["bpmn:FlowNode","bpmn:InteractionNode","bpmn:DataObjectReference","bpmn:DataStoreReference"])&&N(g,{"append.text-annotation":h("bpmn:TextAnnotation","bpmn-icon-text-annotation",B("Append TextAnnotation")),connect:{group:"connect",className:"bpmn-icon-connection-multi",title:B("Connect using "+(p.isForCompensation?"":"Sequence/MessageFlow or ")+"Association"),action:{click:E,dragstart:E}}}),a0(p,["bpmn:DataObjectReference","bpmn:DataStoreReference"])&&N(g,{connect:{group:"connect",className:"bpmn-icon-connection-multi",title:B("Connect using DataInputAssociation"),action:{click:E,dragstart:E}}});let C=c.allowed("elements.delete",{elements:[e]});return n0(C)&&(C=C[0]===e),C&&N(g,{delete:{group:"edit",className:"bpmn-icon-trash",title:B("Remove"),action:{click:d}}}),g};function Au(e,t,n){const A=e.$instanceOf(t);let i=!1;const o=e.eventDefinitions||[];return U(o,function(r){r.$type===n&&(i=!0)}),A&&i}function Ob(e,t){if(e.ownerDocument!==t.ownerDocument)try{return t.ownerDocument.importNode(e,!0)}catch{}return e}function la(e,t){return t.appendChild(Ob(e,t))}function Ni(e,t){return la(t,e),e}var q1=2,iu={"alignment-baseline":1,"baseline-shift":1,clip:1,"clip-path":1,"clip-rule":1,color:1,"color-interpolation":1,"color-interpolation-filters":1,"color-profile":1,"color-rendering":1,cursor:1,direction:1,display:1,"dominant-baseline":1,"enable-background":1,fill:1,"fill-opacity":1,"fill-rule":1,filter:1,"flood-color":1,"flood-opacity":1,font:1,"font-family":1,"font-size":q1,"font-size-adjust":1,"font-stretch":1,"font-style":1,"font-variant":1,"font-weight":1,"glyph-orientation-horizontal":1,"glyph-orientation-vertical":1,"image-rendering":1,kerning:1,"letter-spacing":1,"lighting-color":1,marker:1,"marker-end":1,"marker-mid":1,"marker-start":1,mask:1,opacity:1,overflow:1,"pointer-events":1,"shape-rendering":1,"stop-color":1,"stop-opacity":1,stroke:1,"stroke-dasharray":1,"stroke-dashoffset":1,"stroke-linecap":1,"stroke-linejoin":1,"stroke-miterlimit":1,"stroke-opacity":1,"stroke-width":q1,"text-anchor":1,"text-decoration":1,"text-rendering":1,"unicode-bidi":1,visibility:1,"word-spacing":1,"writing-mode":1};function Xb(e,t){return iu[t]?e.style[t]:e.getAttributeNS(null,t)}function ou(e,t,n){var A=t.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),i=iu[A];i?(i===q1&&typeof n=="number"&&(n=String(n)+"px"),e.style[A]=n):e.setAttributeNS(null,t,n)}function Kb(e,t){var n=Object.keys(t),A,i;for(A=0,i;i=n[A];A++)ou(e,i,t[i])}function He(e,t,n){if(typeof t=="string")if(n!==void 0)ou(e,t,n);else return Xb(e,t);else Kb(e,t);return e}const Zb=Object.prototype.toString;function $1(e){return new Wt(e)}function Wt(e){if(!e||!e.nodeType)throw new Error("A DOM element reference is required");this.el=e,this.list=e.classList}Wt.prototype.add=function(e){return this.list.add(e),this},Wt.prototype.remove=function(e){return Zb.call(e)=="[object RegExp]"?this.removeMatching(e):(this.list.remove(e),this)},Wt.prototype.removeMatching=function(e){const t=this.array();for(let n=0;n<t.length;n++)e.test(t[n])&&this.remove(t[n]);return this},Wt.prototype.toggle=function(e,t){return typeof t<"u"?t!==this.list.toggle(e,t)&&this.list.toggle(e):this.list.toggle(e),this},Wt.prototype.array=function(){return Array.from(this.list)},Wt.prototype.has=Wt.prototype.contains=function(e){return this.list.contains(e)};function qb(e){for(var t;t=e.firstChild;)e.removeChild(t);return e}function $b(e){return e.cloneNode(!0)}var el={svg:"http://www.w3.org/2000/svg"},ru='<svg xmlns="'+el.svg+'"';function au(e){var t=!1;e.substring(0,4)==="<svg"?e.indexOf(el.svg)===-1&&(e=ru+e.substring(4)):(e=ru+">"+e+"</svg>",t=!0);var n=eY(e);if(!t)return n;for(var A=document.createDocumentFragment(),i=n.firstChild;i.firstChild;)A.appendChild(i.firstChild);return A}function eY(e){var t;return t=new DOMParser,t.async=!1,t.parseFromString(e,"text/xml")}function _t(e,t){var n;return e=e.trim(),e.charAt(0)==="<"?(n=au(e).firstChild,n=document.importNode(n,!0)):n=document.createElementNS(el.svg,e),n}var cu=/([&<>]{1})/g,tY=/([&<>\n\r"]{1})/g,nY={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"'"};function tl(e,t){function n(A,i){return nY[i]||i}return e.replace(t,n)}function su(e,t){var n,A,i,o,r;switch(e.nodeType){case 3:t.push(tl(e.textContent,cu));break;case 1:if(t.push("<",e.tagName),e.hasAttributes())for(i=e.attributes,n=0,A=i.length;n<A;++n)o=i.item(n),t.push(" ",o.name,'="',tl(o.value,tY),'"');if(e.hasChildNodes()){for(t.push(">"),r=e.childNodes,n=0,A=r.length;n<A;++n)su(r.item(n),t);t.push("</",e.tagName,">")}else t.push("/>");break;case 8:t.push("<!--",tl(e.nodeValue,cu),"-->");break;case 4:t.push("<![CDATA[",e.nodeValue,"]]>");break;default:throw new Error("unable to handle node "+e.nodeType)}return t}function AY(e,t){var n=au(t);if(qb(e),!!t){oY(n)||(n=n.documentElement);for(var A=aY(n.childNodes),i=0;i<A.length;i++)la(A[i],e)}}function iY(e){for(var t=e.firstChild,n=[];t;)su(t,n),t=t.nextSibling;return n.join("")}function oY(e){return e.nodeName==="#document-fragment"}function rY(e,t){if(t!==void 0){try{AY(e,t)}catch(n){throw new Error("error parsing SVG: "+n.message)}return e}else return iY(e)}function aY(e){return Array.prototype.slice.call(e)}function lu(e){var t=e.parentNode;return t&&t.removeChild(e),e}const cY=1500,sY=2,lY="#52B415",BY="#ffc800",gY="#cc0000";class Bu extends be{constructor(t,n){super(t,cY),this.bpmnRenderer=n}canRender(t){return!t.labelTarget}drawShape(t,n){const A=this.bpmnRenderer.drawShape(t,n),i=this.getSuitabilityScore(n),o=P(n);if(console.error(i,"suitabilityScore 评分得分"),o.$attrs.customType==="抄送任务"){var a=`
276
276
  <svg t="1766124506574" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="7318"><path d="M96 938.666667c-17.066667 0-32-14.933333-32-32 0-232.533333 187.733333-418.133333 420.266667-418.133334 83.2 0 164.266667 25.6 234.666666 72.533334 14.933333 8.533333 23.466667 27.733333 14.933334 42.666666-8.533333 14.933333-27.733333 23.466667-42.666667 14.933334-2.133333-2.133333-4.266667-2.133333-6.4-4.266667-162.133333-110.933333-384-68.266667-492.8 93.866667-42.666667 57.6-64 128-64 198.4 0 17.066667-14.933333 32-32 32z" p-id="7319"></path><path d="M484.266667 552.533333c-140.8 0-253.866667-113.066667-253.866667-253.866666S343.466667 42.666667 484.266667 42.666667s253.866667 113.066667 253.866666 253.866666c0 140.8-115.2 253.866667-253.866666 256z m0-445.866666c-104.533333 0-189.866667 85.333333-189.866667 189.866666s85.333333 189.866667 189.866667 189.866667 189.866667-85.333333 189.866666-189.866667-85.333333-189.866667-189.866666-189.866666zM763.733333 981.333333c-17.066667 0-32-14.933333-32-32v-70.4c0-29.866667 23.466667-53.333333 53.333334-53.333333 8.533333 0 19.2 2.133333 27.733333 6.4l57.6 34.133333 25.6-147.2-172.8 64 4.266667 2.133334c14.933333 8.533333 23.466667 27.733333 14.933333 42.666666-8.533333 14.933333-27.733333 23.466667-42.666667 14.933334-2.133333 0-2.133333-2.133333-4.266666-2.133334l-23.466667-12.8c-25.6-14.933333-34.133333-46.933333-19.2-72.533333 6.4-10.666667 17.066667-19.2 27.733333-23.466667l211.2-76.8c27.733333-10.666667 57.6 4.266667 68.266667 32 4.266667 8.533333 4.266667 17.066667 2.133333 27.733334L932.266667 896c-4.266667 29.866667-32 49.066667-61.866667 42.666667-6.4-2.133333-12.8-4.266667-17.066667-6.4l-53.333333-32v51.2c-4.266667 14.933333-19.2 29.866667-36.266667 29.866666z" p-id="7320"></path><path d="M765.866667 898.133333c-8.533333 0-14.933333-2.133333-21.333334-6.4-12.8-10.666667-14.933333-32-4.266666-44.8l147.2-174.933333c10.666667-12.8 32-14.933333 44.8-4.266667s14.933333 32 4.266666 44.8L789.333333 887.466667c-6.4 6.4-14.933333 10.666667-23.466666 10.666666z" p-id="7321"></path></svg>
277
277
  `,a=`
278
278
  <svg width="20px" height="20px" viewBox="0 0 20 20" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
@@ -405,4 +405,4 @@
405
405
  <path d="M1.3 3.4c.3 0 .5-.2.5-.5s-.2-.4-.5-.4c-.2 0-.4.1-.4.4 0 .3.2.5.4.5zM3 3.4c.2 0 .4-.2.4-.5s-.2-.4-.4-.4c-.3 0-.5.1-.5.4 0 .3.2.5.5.5zM4.6 3.4c.2 0 .4-.2.4-.5s-.2-.4-.4-.4c-.3 0-.5.1-.5.4 0 .3.2.5.5.5z"/>
406
406
  </svg>`,Dz=`<svg width="46" height="46" viewBox="-2 -2 9.82 9.82" xmlns="http://www.w3.org/2000/svg" fill="currentColor">
407
407
  <path d="M1.3 3.4c.3 0 .5-.2.5-.5s-.2-.4-.5-.4c-.2 0-.4.1-.4.4 0 .3.2.5.4.5zM3 3.4c.2 0 .4-.2.4-.5s-.2-.4-.4-.4c-.3 0-.5.1-.5.4 0 .3.2.5.5.5zM4.6 3.4c.2 0 .4-.2.4-.5s-.2-.4-.4-.4c-.3 0-.5.1-.5.4 0 .3.2.5.5.5z"/>
408
- </svg>`;function Zi(e,t,n,A,i){this._contextPad=e,this._popupMenu=t,this._translate=n,this._canvas=A,this._rules=i,this.register()}Zi.$inject=["contextPad","popupMenu","translate","canvas","rules"],Zi.prototype.register=function(){this._contextPad.registerProvider(this)},Zi.prototype.getContextPadEntries=function(e){const t=this._popupMenu,n=this._translate,A=this._rules,i=this._getAppendMenuPosition.bind(this);if(A.allowed("shape.append",{element:e}))return{append:{group:"model",html:`<div class="entry">${Mz}</div>`,title:n("Append element"),action:{click:function(o,r){const a=Rl(i(r),{cursor:{x:o.x,y:o.y}});t.open(r,"bpmn-append",a,{title:n("Append element"),width:300,search:!0})}}}}},Zi.prototype._getAppendMenuPosition=function(e){const A=this._canvas.getContainer().querySelector(".djs-context-pad").getBoundingClientRect();return{x:A.right+5,y:A.top}};function Sl(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}function Va(e,t){var n=Tl(e);return n&&typeof n.$instanceOf=="function"&&n.$instanceOf(t)}function yz(e,t){return iz(t,function(n){return Va(e,n)})}function Tl(e){return e&&e.businessObject||e}function Iz(e){return JQ(e)&&VQ(e,"labelTarget")}var Fz=1e3;function X2(e){this._eventBus=e}X2.$inject=["eventBus"];function vz(e,t){return function(n){return e.call(t||null,n.context,n.command,n)}}X2.prototype.on=function(e,t,n,A,i,o){if((Xi(t)||jQ(t))&&(o=i,i=A,A=n,n=t,t=null),Xi(n)&&(o=i,i=A,A=n,n=Fz),JQ(i)&&(o=i,i=!1),!Xi(A))throw new Error("handlerFn must be a function");zl(e)||(e=[e]);var r=this._eventBus;WQ(e,function(a){var c=["commandStack",a,t].filter(function(l){return l}).join(".");r.on(c,n,i?vz(A,o):A,o)})},X2.prototype.canExecute=pt("canExecute"),X2.prototype.preExecute=pt("preExecute"),X2.prototype.preExecuted=pt("preExecuted"),X2.prototype.execute=pt("execute"),X2.prototype.executed=pt("executed"),X2.prototype.postExecute=pt("postExecute"),X2.prototype.postExecuted=pt("postExecuted"),X2.prototype.revert=pt("revert"),X2.prototype.reverted=pt("reverted");function pt(e){return function(n,A,i,o,r){(Xi(n)||jQ(n))&&(r=o,o=i,i=A,A=n,n=null),this.on(n,e,A,i,o,r)}}function DA(e){X2.call(this,e),this.init()}DA.$inject=["eventBus"],Sl(DA,X2),DA.prototype.addRule=function(e,t,n){var A=this;typeof e=="string"&&(e=[e]),e.forEach(function(i){A.canExecute(i,t,function(o,r,a){return n(o)},!0)})},DA.prototype.init=function(){};function La(e){DA.call(this,e)}Sl(La,DA),La.$inject=["eventBus"],La.prototype.init=function(){this.addRule("shape.append",function(e){const t=e.element,n=Tl(t);if(Iz(t)||yz(t,["bpmn:EndEvent","bpmn:Group","bpmn:TextAnnotation","bpmn:Lane","bpmn:Participant","bpmn:DataStoreReference","bpmn:DataObjectReference"])||bz(t)||Va(t,"bpmn:IntermediateThrowEvent")&&xz(t,"bpmn:LinkEventDefinition")||Va(t,"bpmn:SubProcess")&&n.triggeredByEvent)return!1})};function xz(e,t){const n=Tl(e);return!!LQ(n.eventDefinitions||[],function(A){return Va(A,t)})}function bz(e){return e.waypoints}var kl={__init__:["appendMenuProvider","appendContextPadProvider","appendRules"],appendMenuProvider:["type",Yn],appendContextPadProvider:["type",Zi],appendRules:["type",La]};function qi(e,t,n,A,i,o){this._elementFactory=e,this._popupMenu=t,this._create=n,this._autoPlace=A,this._mouse=i,this._translate=o,this.register()}qi.$inject=["elementFactory","popupMenu","create","autoPlace","mouse","translate"],qi.prototype.register=function(){this._popupMenu.registerProvider("bpmn-create",this)},qi.prototype.getPopupMenuEntries=function(){const e={};return _Q.forEach(t=>{const{actionName:n,className:A,label:i,target:o,description:r,group:a,search:c,rank:l}=t,B=this._createEntryAction(o);e[`create-${n}`]={label:i&&this._translate(i),className:A,description:r,group:a&&{...a,name:this._translate(a.name)},search:c,rank:l,action:{click:B,dragstart:B}}}),e},qi.prototype._createEntryAction=function(e){const t=this._create,n=this._mouse,A=this._popupMenu,i=this._elementFactory;let o;return r=>(A.close(),e.type==="bpmn:Participant"?o=i.createParticipantShape(e):o=i.create("shape",e),r instanceof KeyboardEvent&&(r=n.getLastMoveEvent()),t.start(r,o))};var Wa;typeof document<"u"&&(Wa=document.createElement("div"),Wa.innerHTML=' <link/><table></table><a href="/a">a</a><input type="checkbox"/>',Wa.getElementsByTagName("link").length,Wa=void 0);function Yz(e,t){return t=t||document,t.querySelector(e)}const Uz=900;function _a(e,t,n,A,i){this._palette=e,this._translate=t,this._popupMenu=n,this._canvas=A,this._mouse=i,this.register()}_a.$inject=["palette","translate","popupMenu","canvas","mouse"],_a.prototype.register=function(){this._palette.registerProvider(Uz,this)},_a.prototype.getPaletteEntries=function(e){const t=this._translate,n=this._popupMenu,A=this._canvas,i=this._mouse,o=r=>{if(r instanceof KeyboardEvent)return r=i.getLastMoveEvent(),{x:r.x,y:r.y};const l=r&&r.target||Yz('.djs-palette [data-action="create"]'),B=l.getBoundingClientRect();return l&&{x:B.left+B.width/2+35,y:B.top+B.height/2+10}};return{create:{group:"create",html:`<div class="entry"> ${Dz}</div>`,title:t("Create element"),action:{click:function(r){const a=o(r),c=A.getRootElement();n.open(c,"bpmn-create",a,{title:t("Create element"),width:300,search:!0})}}}}};var Gl={__init__:["createMenuProvider","createPaletteProvider"],createMenuProvider:["type",qi],createPaletteProvider:["type",_a]};function Hl(e){this._injector=e,this.registerActions()}Hl.$inject=["injector"],Hl.prototype.registerActions=function(){const e=this._injector.get("editorActions",!1),t=this._injector.get("selection",!1),n=this._injector.get("contextPad",!1),A=this._injector.get("palette",!1),i=this._injector.get("popupMenu",!1),o={};t&&n&&A&&i&&A&&Rl(o,{appendElement:function(r){const a=t&&t.get();a.length==1&&!i.isEmpty(a[0],"bpmn-append")?n.triggerEntry("append","click",r):A.triggerEntry("create","click",r)}}),A&&Rl(o,{createElement:function(r){A.triggerEntry("create","click",r)}}),e&&e.register(o)};var Nz={__depends__:[kl,Gl],__init__:["createAppendEditorActions"],createAppendEditorActions:["type",Hl]},zz=["c","C"],Rz=["v","V"],Sz=["y","Y"],OQ=["z","Z"];function Un(e){return e.altKey?!1:e.ctrlKey||e.metaKey}function Et(e,t){return e=zl(e)?e:[e],e.indexOf(t.key)!==-1||e.indexOf(t.code)!==-1}function XQ(e){return e.shiftKey}function Tz(e){return Un(e)&&Et(zz,e)}function kz(e){return Un(e)&&Et(Rz,e)}function Gz(e){return Un(e)&&!XQ(e)&&Et(OQ,e)}function Hz(e){return Un(e)&&(Et(Sz,e)||Et(OQ,e)&&XQ(e))}var Pz=500;function $i(e,t){var n=this;e.on("editorActions.init",Pz,function(A){var i=A.editorActions;n.registerBindings(t,i)})}$i.$inject=["eventBus","keyboard"],$i.prototype.registerBindings=function(e,t){function n(A,i){t.isRegistered(A)&&e.addListener(i)}n("undo",function(A){var i=A.keyEvent;if(Gz(i))return t.trigger("undo"),!0}),n("redo",function(A){var i=A.keyEvent;if(Hz(i))return t.trigger("redo"),!0}),n("copy",function(A){var i=A.keyEvent;if(Tz(i))return t.trigger("copy"),!0}),n("paste",function(A){var i=A.keyEvent;if(kz(i))return t.trigger("paste"),!0}),n("stepZoom",function(A){var i=A.keyEvent;if(Et(["+","Add","="],i)&&Un(i))return t.trigger("stepZoom",{value:1}),!0}),n("stepZoom",function(A){var i=A.keyEvent;if(Et(["-","Subtract"],i)&&Un(i))return t.trigger("stepZoom",{value:-1}),!0}),n("zoom",function(A){var i=A.keyEvent;if(Et("0",i)&&Un(i))return t.trigger("zoom",{value:1}),!0}),n("removeSelection",function(A){var i=A.keyEvent;if(Et(["Backspace","Delete","Del"],i))return t.trigger("removeSelection"),!0})};function Oa(e){this._injector=e,this._keyboard=this._injector.get("keyboard",!1),this._editorActions=this._injector.get("editorActions",!1),this._keyboard&&this._injector.invoke($i,this)}Sl(Oa,$i),Oa.$inject=["injector"],Oa.prototype.registerBindings=function(){const e=this._keyboard,t=this._editorActions;$i.prototype.registerBindings.call(this,e,t);function n(A,i){t&&t.isRegistered(A)&&e&&e.addListener(i)}n("appendElement",function(A){const i=A.keyEvent;if(!(e&&e.hasModifier(i))&&e&&e.isKey(["a","A"],i))return t&&t.trigger("appendElement",i),!0}),n("createElement",function(A){const i=A.keyEvent;if(!(e&&e.hasModifier(i))&&e&&e.isKey(["n","N"],i))return t&&t.trigger("createElement",i),!0})};var Jz={__depends__:[kl,Gl],__init__:["createAppendKeyboardBindings"],createAppendKeyboardBindings:["type",Oa]},jz={__depends__:[kl,Gl,Nz,Jz]},Vz=[{label:"Start event",actionName:"replace-with-none-start",className:"bpmn-icon-start-event-none",target:{type:"bpmn:StartEvent"}},{label:"Intermediate throw event",actionName:"replace-with-none-intermediate-throwing",className:"bpmn-icon-intermediate-event-none",target:{type:"bpmn:IntermediateThrowEvent"}},{label:"End event",actionName:"replace-with-none-end",className:"bpmn-icon-end-event-none",target:{type:"bpmn:EndEvent"}},{label:"Message start event",actionName:"replace-with-message-start",className:"bpmn-icon-start-event-message",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:MessageEventDefinition"}},{label:"Timer start event",actionName:"replace-with-timer-start",className:"bpmn-icon-start-event-timer",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:TimerEventDefinition"}},{label:"Conditional start event",actionName:"replace-with-conditional-start",className:"bpmn-icon-start-event-condition",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:ConditionalEventDefinition"}},{label:"Signal start event",actionName:"replace-with-signal-start",className:"bpmn-icon-start-event-signal",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:SignalEventDefinition"}}],Lz=[{label:"Start event",actionName:"replace-with-none-start",className:"bpmn-icon-start-event-none",target:{type:"bpmn:StartEvent"}},{label:"Intermediate throw event",actionName:"replace-with-none-intermediate-throwing",className:"bpmn-icon-intermediate-event-none",target:{type:"bpmn:IntermediateThrowEvent"}},{label:"End event",actionName:"replace-with-none-end",className:"bpmn-icon-end-event-none",target:{type:"bpmn:EndEvent"}}],Wz=[{label:"Start event",actionName:"replace-with-none-start",className:"bpmn-icon-start-event-none",target:{type:"bpmn:StartEvent"}},{label:"Intermediate throw event",actionName:"replace-with-none-intermediate-throw",className:"bpmn-icon-intermediate-event-none",target:{type:"bpmn:IntermediateThrowEvent"}},{label:"End event",actionName:"replace-with-none-end",className:"bpmn-icon-end-event-none",target:{type:"bpmn:EndEvent"}},{label:"Message intermediate catch event",actionName:"replace-with-message-intermediate-catch",className:"bpmn-icon-intermediate-event-catch-message",target:{type:"bpmn:IntermediateCatchEvent",eventDefinitionType:"bpmn:MessageEventDefinition"}},{label:"Message intermediate throw event",actionName:"replace-with-message-intermediate-throw",className:"bpmn-icon-intermediate-event-throw-message",target:{type:"bpmn:IntermediateThrowEvent",eventDefinitionType:"bpmn:MessageEventDefinition"}},{label:"Timer intermediate catch event",actionName:"replace-with-timer-intermediate-catch",className:"bpmn-icon-intermediate-event-catch-timer",target:{type:"bpmn:IntermediateCatchEvent",eventDefinitionType:"bpmn:TimerEventDefinition"}},{label:"Escalation intermediate throw event",actionName:"replace-with-escalation-intermediate-throw",className:"bpmn-icon-intermediate-event-throw-escalation",target:{type:"bpmn:IntermediateThrowEvent",eventDefinitionType:"bpmn:EscalationEventDefinition"}},{label:"Conditional intermediate catch event",actionName:"replace-with-conditional-intermediate-catch",className:"bpmn-icon-intermediate-event-catch-condition",target:{type:"bpmn:IntermediateCatchEvent",eventDefinitionType:"bpmn:ConditionalEventDefinition"}},{label:"Link intermediate catch event",actionName:"replace-with-link-intermediate-catch",className:"bpmn-icon-intermediate-event-catch-link",target:{type:"bpmn:IntermediateCatchEvent",eventDefinitionType:"bpmn:LinkEventDefinition",eventDefinitionAttrs:{name:""}}},{label:"Link intermediate throw event",actionName:"replace-with-link-intermediate-throw",className:"bpmn-icon-intermediate-event-throw-link",target:{type:"bpmn:IntermediateThrowEvent",eventDefinitionType:"bpmn:LinkEventDefinition",eventDefinitionAttrs:{name:""}}},{label:"Compensation intermediate throw event",actionName:"replace-with-compensation-intermediate-throw",className:"bpmn-icon-intermediate-event-throw-compensation",target:{type:"bpmn:IntermediateThrowEvent",eventDefinitionType:"bpmn:CompensateEventDefinition"}},{label:"Signal intermediate catch event",actionName:"replace-with-signal-intermediate-catch",className:"bpmn-icon-intermediate-event-catch-signal",target:{type:"bpmn:IntermediateCatchEvent",eventDefinitionType:"bpmn:SignalEventDefinition"}},{label:"Signal intermediate throw event",actionName:"replace-with-signal-intermediate-throw",className:"bpmn-icon-intermediate-event-throw-signal",target:{type:"bpmn:IntermediateThrowEvent",eventDefinitionType:"bpmn:SignalEventDefinition"}}],_z=[{label:"Start event",actionName:"replace-with-none-start",className:"bpmn-icon-start-event-none",target:{type:"bpmn:StartEvent"}},{label:"Intermediate throw event",actionName:"replace-with-none-intermediate-throw",className:"bpmn-icon-intermediate-event-none",target:{type:"bpmn:IntermediateThrowEvent"}},{label:"End event",actionName:"replace-with-none-end",className:"bpmn-icon-end-event-none",target:{type:"bpmn:EndEvent"}},{label:"Message end event",actionName:"replace-with-message-end",className:"bpmn-icon-end-event-message",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:MessageEventDefinition"}},{label:"Escalation end event",actionName:"replace-with-escalation-end",className:"bpmn-icon-end-event-escalation",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:EscalationEventDefinition"}},{label:"Error end event",actionName:"replace-with-error-end",className:"bpmn-icon-end-event-error",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:ErrorEventDefinition"}},{label:"Cancel end event",actionName:"replace-with-cancel-end",className:"bpmn-icon-end-event-cancel",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:CancelEventDefinition"}},{label:"Compensation end event",actionName:"replace-with-compensation-end",className:"bpmn-icon-end-event-compensation",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:CompensateEventDefinition"}},{label:"Signal end event",actionName:"replace-with-signal-end",className:"bpmn-icon-end-event-signal",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:SignalEventDefinition"}},{label:"Terminate end event",actionName:"replace-with-terminate-end",className:"bpmn-icon-end-event-terminate",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:TerminateEventDefinition"}}],Oz=[{label:"Exclusive gateway",actionName:"replace-with-exclusive-gateway",className:"bpmn-icon-gateway-xor",target:{type:"bpmn:ExclusiveGateway"}},{label:"Parallel gateway",actionName:"replace-with-parallel-gateway",className:"bpmn-icon-gateway-parallel",target:{type:"bpmn:ParallelGateway"}},{label:"Inclusive gateway",actionName:"replace-with-inclusive-gateway",className:"bpmn-icon-gateway-or",target:{type:"bpmn:InclusiveGateway"}},{label:"Complex gateway",actionName:"replace-with-complex-gateway",className:"bpmn-icon-gateway-complex",target:{type:"bpmn:ComplexGateway"}},{label:"Event-based gateway",actionName:"replace-with-event-based-gateway",className:"bpmn-icon-gateway-eventbased",target:{type:"bpmn:EventBasedGateway",instantiate:!1,eventGatewayType:"Exclusive"}}],Xz=[{label:"Transaction",actionName:"replace-with-transaction",className:"bpmn-icon-transaction",target:{type:"bpmn:Transaction",isExpanded:!0}},{label:"Event sub-process",actionName:"replace-with-event-subprocess",className:"bpmn-icon-event-subprocess-expanded",target:{type:"bpmn:SubProcess",triggeredByEvent:!0,isExpanded:!0}},{label:"Ad-hoc sub-process",actionName:"replace-with-ad-hoc-subprocess",className:"bpmn-icon-subprocess-expanded",target:{type:"bpmn:AdHocSubProcess",isExpanded:!0}},{label:"Sub-process (collapsed)",actionName:"replace-with-collapsed-subprocess",className:"bpmn-icon-subprocess-collapsed",target:{type:"bpmn:SubProcess",isExpanded:!1}}],Kz=[{label:"Sub-process",actionName:"replace-with-subprocess",className:"bpmn-icon-subprocess-expanded",target:{type:"bpmn:SubProcess",isExpanded:!0}},{label:"Transaction",actionName:"replace-with-transaction",className:"bpmn-icon-transaction",target:{type:"bpmn:Transaction",isExpanded:!0}},{label:"Event sub-process",actionName:"replace-with-event-subprocess",className:"bpmn-icon-event-subprocess-expanded",target:{type:"bpmn:SubProcess",triggeredByEvent:!0,isExpanded:!0}},{label:"Ad-hoc sub-process (collapsed)",actionName:"replace-with-collapsed-ad-hoc-subprocess",className:"bpmn-icon-subprocess-collapsed",target:{type:"bpmn:AdHocSubProcess",isExpanded:!1}}],KQ=[{label:"Transaction",actionName:"replace-with-transaction",className:"bpmn-icon-transaction",target:{type:"bpmn:Transaction",isExpanded:!0}},{label:"Sub-process",actionName:"replace-with-subprocess",className:"bpmn-icon-subprocess-expanded",target:{type:"bpmn:SubProcess",isExpanded:!0}},{label:"Ad-hoc sub-process",actionName:"replace-with-ad-hoc-subprocess",className:"bpmn-icon-subprocess-expanded",target:{type:"bpmn:AdHocSubProcess",isExpanded:!0}},{label:"Event sub-process",actionName:"replace-with-event-subprocess",className:"bpmn-icon-event-subprocess-expanded",target:{type:"bpmn:SubProcess",triggeredByEvent:!0,isExpanded:!0}}],Zz=KQ,qz=[{label:"Task",actionName:"replace-with-task",className:"bpmn-icon-task",target:{type:"bpmn:Task"}},{label:"User task",actionName:"replace-with-user-task",className:"bpmn-icon-user",target:{type:"bpmn:UserTask"}},{label:"Service task",actionName:"replace-with-service-task",className:"bpmn-icon-service",target:{type:"bpmn:ServiceTask"}},{label:"Send task",actionName:"replace-with-send-task",className:"bpmn-icon-send",target:{type:"bpmn:SendTask"}},{label:"Receive task",actionName:"replace-with-receive-task",className:"bpmn-icon-receive",target:{type:"bpmn:ReceiveTask"}},{label:"Manual task",actionName:"replace-with-manual-task",className:"bpmn-icon-manual",target:{type:"bpmn:ManualTask"}},{label:"Business rule task",actionName:"replace-with-rule-task",className:"bpmn-icon-business-rule",target:{type:"bpmn:BusinessRuleTask"}},{label:"Script task",actionName:"replace-with-script-task",className:"bpmn-icon-script",target:{type:"bpmn:ScriptTask"}},{label:"Call activity",actionName:"replace-with-call-activity",className:"bpmn-icon-call-activity",target:{type:"bpmn:CallActivity"}},{label:"Sub-process (collapsed)",actionName:"replace-with-collapsed-subprocess",className:"bpmn-icon-subprocess-collapsed",target:{type:"bpmn:SubProcess",isExpanded:!1}},{label:"Sub-process (expanded)",actionName:"replace-with-expanded-subprocess",className:"bpmn-icon-subprocess-expanded",target:{type:"bpmn:SubProcess",isExpanded:!0}},{label:"Ad-hoc sub-process (collapsed)",actionName:"replace-with-collapsed-ad-hoc-subprocess",className:"bpmn-icon-subprocess-collapsed",target:{type:"bpmn:AdHocSubProcess",isExpanded:!1}},{label:"Ad-hoc sub-process (expanded)",actionName:"replace-with-ad-hoc-subprocess",className:"bpmn-icon-subprocess-expanded",target:{type:"bpmn:AdHocSubProcess",isExpanded:!0}}],$z=[{label:"Data store reference",actionName:"replace-with-data-store-reference",className:"bpmn-icon-data-store",target:{type:"bpmn:DataStoreReference"}}],eR=[{label:"Data object reference",actionName:"replace-with-data-object-reference",className:"bpmn-icon-data-object",target:{type:"bpmn:DataObjectReference"}}],tR=[{label:"Message boundary event",actionName:"replace-with-message-boundary",className:"bpmn-icon-intermediate-event-catch-message",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:MessageEventDefinition",cancelActivity:!0}},{label:"Timer boundary event",actionName:"replace-with-timer-boundary",className:"bpmn-icon-intermediate-event-catch-timer",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:TimerEventDefinition",cancelActivity:!0}},{label:"Escalation boundary event",actionName:"replace-with-escalation-boundary",className:"bpmn-icon-intermediate-event-catch-escalation",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:EscalationEventDefinition",cancelActivity:!0}},{label:"Conditional boundary event",actionName:"replace-with-conditional-boundary",className:"bpmn-icon-intermediate-event-catch-condition",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:ConditionalEventDefinition",cancelActivity:!0}},{label:"Error boundary event",actionName:"replace-with-error-boundary",className:"bpmn-icon-intermediate-event-catch-error",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:ErrorEventDefinition",cancelActivity:!0}},{label:"Cancel boundary event",actionName:"replace-with-cancel-boundary",className:"bpmn-icon-intermediate-event-catch-cancel",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:CancelEventDefinition",cancelActivity:!0}},{label:"Signal boundary event",actionName:"replace-with-signal-boundary",className:"bpmn-icon-intermediate-event-catch-signal",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:SignalEventDefinition",cancelActivity:!0}},{label:"Compensation boundary event",actionName:"replace-with-compensation-boundary",className:"bpmn-icon-intermediate-event-catch-compensation",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:CompensateEventDefinition",cancelActivity:!0}},{label:"Message boundary event (non-interrupting)",actionName:"replace-with-non-interrupting-message-boundary",className:"bpmn-icon-intermediate-event-catch-non-interrupting-message",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:MessageEventDefinition",cancelActivity:!1}},{label:"Timer boundary event (non-interrupting)",actionName:"replace-with-non-interrupting-timer-boundary",className:"bpmn-icon-intermediate-event-catch-non-interrupting-timer",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:TimerEventDefinition",cancelActivity:!1}},{label:"Escalation boundary event (non-interrupting)",actionName:"replace-with-non-interrupting-escalation-boundary",className:"bpmn-icon-intermediate-event-catch-non-interrupting-escalation",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:EscalationEventDefinition",cancelActivity:!1}},{label:"Conditional boundary event (non-interrupting)",actionName:"replace-with-non-interrupting-conditional-boundary",className:"bpmn-icon-intermediate-event-catch-non-interrupting-condition",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:ConditionalEventDefinition",cancelActivity:!1}},{label:"Signal boundary event (non-interrupting)",actionName:"replace-with-non-interrupting-signal-boundary",className:"bpmn-icon-intermediate-event-catch-non-interrupting-signal",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:SignalEventDefinition",cancelActivity:!1}}],nR=[{label:"Message start event",actionName:"replace-with-message-start",className:"bpmn-icon-start-event-message",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:MessageEventDefinition",isInterrupting:!0}},{label:"Timer start event",actionName:"replace-with-timer-start",className:"bpmn-icon-start-event-timer",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:TimerEventDefinition",isInterrupting:!0}},{label:"Conditional start event",actionName:"replace-with-conditional-start",className:"bpmn-icon-start-event-condition",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:ConditionalEventDefinition",isInterrupting:!0}},{label:"Signal start event",actionName:"replace-with-signal-start",className:"bpmn-icon-start-event-signal",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:SignalEventDefinition",isInterrupting:!0}},{label:"Error start event",actionName:"replace-with-error-start",className:"bpmn-icon-start-event-error",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:ErrorEventDefinition",isInterrupting:!0}},{label:"Escalation start event",actionName:"replace-with-escalation-start",className:"bpmn-icon-start-event-escalation",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:EscalationEventDefinition",isInterrupting:!0}},{label:"Compensation start event",actionName:"replace-with-compensation-start",className:"bpmn-icon-start-event-compensation",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:CompensateEventDefinition",isInterrupting:!0}},{label:"Message start event (non-interrupting)",actionName:"replace-with-non-interrupting-message-start",className:"bpmn-icon-start-event-non-interrupting-message",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:MessageEventDefinition",isInterrupting:!1}},{label:"Timer start event (non-interrupting)",actionName:"replace-with-non-interrupting-timer-start",className:"bpmn-icon-start-event-non-interrupting-timer",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:TimerEventDefinition",isInterrupting:!1}},{label:"Conditional start event (non-interrupting)",actionName:"replace-with-non-interrupting-conditional-start",className:"bpmn-icon-start-event-non-interrupting-condition",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:ConditionalEventDefinition",isInterrupting:!1}},{label:"Signal start event (non-interrupting)",actionName:"replace-with-non-interrupting-signal-start",className:"bpmn-icon-start-event-non-interrupting-signal",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:SignalEventDefinition",isInterrupting:!1}},{label:"Escalation start event (non-interrupting)",actionName:"replace-with-non-interrupting-escalation-start",className:"bpmn-icon-start-event-non-interrupting-escalation",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:EscalationEventDefinition",isInterrupting:!1}}],AR=[{label:"Sequence flow",actionName:"replace-with-sequence-flow",className:"bpmn-icon-connection"},{label:"Default flow",actionName:"replace-with-default-flow",className:"bpmn-icon-default-flow"},{label:"Conditional flow",actionName:"replace-with-conditional-flow",className:"bpmn-icon-conditional-flow"}],iR=[{label:"Expanded pool/participant",actionName:"replace-with-expanded-pool",className:"bpmn-icon-participant",target:{type:"bpmn:Participant",isExpanded:!0}},{label:function(e){var t="Empty pool/participant";return e.children&&e.children.length&&(t+=" (removes content)"),t},actionName:"replace-with-collapsed-pool",className:"bpmn-icon-lane",target:{type:"bpmn:Participant",isExpanded:!1}}],oR={"bpmn:MessageEventDefinition":[{label:"Message start event",actionName:"replace-with-message-start",className:"bpmn-icon-start-event-message",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:MessageEventDefinition"}},{label:"Message intermediate catch event",actionName:"replace-with-message-intermediate-catch",className:"bpmn-icon-intermediate-event-catch-message",target:{type:"bpmn:IntermediateCatchEvent",eventDefinitionType:"bpmn:MessageEventDefinition"}},{label:"Message intermediate throw event",actionName:"replace-with-message-intermediate-throw",className:"bpmn-icon-intermediate-event-throw-message",target:{type:"bpmn:IntermediateThrowEvent",eventDefinitionType:"bpmn:MessageEventDefinition"}},{label:"Message end event",actionName:"replace-with-message-end",className:"bpmn-icon-end-event-message",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:MessageEventDefinition"}}],"bpmn:TimerEventDefinition":[{label:"Timer start event",actionName:"replace-with-timer-start",className:"bpmn-icon-start-event-timer",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:TimerEventDefinition"}},{label:"Timer intermediate catch event",actionName:"replace-with-timer-intermediate-catch",className:"bpmn-icon-intermediate-event-catch-timer",target:{type:"bpmn:IntermediateCatchEvent",eventDefinitionType:"bpmn:TimerEventDefinition"}}],"bpmn:ConditionalEventDefinition":[{label:"Conditional start event",actionName:"replace-with-conditional-start",className:"bpmn-icon-start-event-condition",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:ConditionalEventDefinition"}},{label:"Conditional intermediate catch event",actionName:"replace-with-conditional-intermediate-catch",className:"bpmn-icon-intermediate-event-catch-condition",target:{type:"bpmn:IntermediateCatchEvent",eventDefinitionType:"bpmn:ConditionalEventDefinition"}}],"bpmn:SignalEventDefinition":[{label:"Signal start event",actionName:"replace-with-signal-start",className:"bpmn-icon-start-event-signal",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:SignalEventDefinition"}},{label:"Signal intermediate catch event",actionName:"replace-with-signal-intermediate-catch",className:"bpmn-icon-intermediate-event-catch-signal",target:{type:"bpmn:IntermediateCatchEvent",eventDefinitionType:"bpmn:SignalEventDefinition"}},{label:"Signal intermediate throw event",actionName:"replace-with-signal-intermediate-throw",className:"bpmn-icon-intermediate-event-throw-signal",target:{type:"bpmn:IntermediateThrowEvent",eventDefinitionType:"bpmn:SignalEventDefinition"}},{label:"Signal end event",actionName:"replace-with-signal-end",className:"bpmn-icon-end-event-signal",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:SignalEventDefinition"}}],"bpmn:ErrorEventDefinition":[{label:"Error start event",actionName:"replace-with-error-start",className:"bpmn-icon-start-event-error",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:ErrorEventDefinition"}},{label:"Error end event",actionName:"replace-with-error-end",className:"bpmn-icon-end-event-error",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:ErrorEventDefinition"}}],"bpmn:EscalationEventDefinition":[{label:"Escalation start event",actionName:"replace-with-escalation-start",className:"bpmn-icon-start-event-escalation",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:EscalationEventDefinition"}},{label:"Escalation intermediate throw event",actionName:"replace-with-escalation-intermediate-throw",className:"bpmn-icon-intermediate-event-throw-escalation",target:{type:"bpmn:IntermediateThrowEvent",eventDefinitionType:"bpmn:EscalationEventDefinition"}},{label:"Escalation end event",actionName:"replace-with-escalation-end",className:"bpmn-icon-end-event-escalation",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:EscalationEventDefinition"}}],"bpmn:CompensateEventDefinition":[{label:"Compensation start event",actionName:"replace-with-compensation-start",className:"bpmn-icon-start-event-compensation",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:CompensateEventDefinition"}},{label:"Compensation intermediate throw event",actionName:"replace-with-compensation-intermediate-throw",className:"bpmn-icon-intermediate-event-throw-compensation",target:{type:"bpmn:IntermediateThrowEvent",eventDefinitionType:"bpmn:CompensateEventDefinition"}},{label:"Compensation end event",actionName:"replace-with-compensation-end",className:"bpmn-icon-end-event-compensation",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:CompensateEventDefinition"}}]},rR=Object.freeze({__proto__:null,AD_HOC_SUBPROCESS_EXPANDED:Kz,BOUNDARY_EVENT:tR,DATA_OBJECT_REFERENCE:$z,DATA_STORE_REFERENCE:eR,END_EVENT:_z,EVENT_SUB_PROCESS:Zz,EVENT_SUB_PROCESS_START_EVENT:nR,GATEWAY:Oz,INTERMEDIATE_EVENT:Wz,PARTICIPANT:iR,SEQUENCE_FLOW:AR,START_EVENT:Vz,START_EVENT_SUB_PROCESS:Lz,SUBPROCESS_EXPANDED:Xz,TASK:qz,TRANSACTION:KQ,TYPED_EVENT:oR});Object.values(rR);const aR={name:"Flowable",uri:"http://flowable.org/bpmn",prefix:"flowable",xml:{tagAlias:"lowerCase"},associations:[],types:[{name:"Definitions",isAbstract:!0,extends:["bpmn:Definitions"],properties:[{name:"diagramRelationId",isAttr:!0,type:"String"}]},{name:"InOutBinding",superClass:["Element"],isAbstract:!0,properties:[{name:"source",isAttr:!0,type:"String"},{name:"sourceExpression",isAttr:!0,type:"String"},{name:"target",isAttr:!0,type:"String"},{name:"businessKey",isAttr:!0,type:"String"},{name:"local",isAttr:!0,type:"Boolean",default:!1},{name:"variables",isAttr:!0,type:"String"}]},{name:"In",superClass:["InOutBinding"],meta:{allowedIn:["bpmn:CallActivity"]}},{name:"Out",superClass:["InOutBinding"],meta:{allowedIn:["bpmn:CallActivity"]}},{name:"AsyncCapable",isAbstract:!0,extends:["bpmn:Activity","bpmn:Gateway","bpmn:Event"],properties:[{name:"async",isAttr:!0,type:"Boolean",default:!1},{name:"asyncBefore",isAttr:!0,type:"Boolean",default:!1},{name:"asyncAfter",isAttr:!0,type:"Boolean",default:!1},{name:"exclusive",isAttr:!0,type:"Boolean",default:!0}]},{name:"JobPriorized",isAbstract:!0,extends:["bpmn:Process","flowable:AsyncCapable"],properties:[{name:"jobPriority",isAttr:!0,type:"String"}]},{name:"SignalEventDefinition",isAbstract:!0,extends:["bpmn:SignalEventDefinition"],properties:[{name:"async",isAttr:!0,type:"Boolean",default:!1}]},{name:"ErrorEventDefinition",isAbstract:!0,extends:["bpmn:ErrorEventDefinition"],properties:[{name:"errorCodeVariable",isAttr:!0,type:"String"},{name:"errorMessageVariable",isAttr:!0,type:"String"}]},{name:"Error",isAbstract:!0,extends:["bpmn:Error"],properties:[{name:"flowable:errorMessage",isAttr:!0,type:"String"}]},{name:"PotentialStarter",superClass:["Element"],properties:[{name:"resourceAssignmentExpression",type:"bpmn:ResourceAssignmentExpression"}]},{name:"FormSupported",isAbstract:!0,extends:["bpmn:StartEvent","bpmn:UserTask"],properties:[{name:"formHandlerClass",isAttr:!0,type:"String"},{name:"formKey",isAttr:!0,type:"String"},{name:"formType",isAttr:!0,type:"String"},{name:"formReadOnly",isAttr:!0,type:"String"},{name:"indepFormKey",isAttr:!0,type:"String"},{name:"indepFormSummary",isAttr:!0,type:"String"},{name:"indepSummaryNode",isAttr:!0,type:"String"},{name:"exFormKey",isAttr:!0,type:"String"},{name:"exFormUrl",isAttr:!0,type:"String"},{name:"exAppFormUrl",isAttr:!0,type:"String"},{name:"backToRejecter",isAttr:!0,type:"String"},{name:"skipExpression",isAttr:!0,type:"String"}]},{name:"TemplateSupported",isAbstract:!0,extends:["bpmn:Process","bpmn:FlowElement"],properties:[{name:"modelerTemplate",isAttr:!0,type:"String"}]},{name:"Initiator",isAbstract:!0,extends:["bpmn:StartEvent"],properties:[{name:"initiator",isAttr:!0,type:"String"}]},{name:"ScriptTask",isAbstract:!0,extends:["bpmn:ScriptTask"],properties:[{name:"resultVariable",isAttr:!0,type:"String"},{name:"resource",isAttr:!0,type:"String"}]},{name:"Process",isAbstract:!0,extends:["bpmn:Process"],properties:[{name:"skipFirstNode",isAttr:!0,type:"Boolean"},{name:"skipWhenStartUser",isAttr:!0,type:"Boolean"},{name:"skipWhenAssignee",isAttr:!0,type:"Boolean"},{name:"rollbackNode",isAttr:!0,type:"String"},{name:"title",isAttr:!0,type:"String"},{name:"callBack",isAttr:!0,type:"String"},{name:"candidateStarterGroups",isAttr:!0,type:"String"},{name:"candidateStarterUsers",isAttr:!0,type:"String"},{name:"versionTag",isAttr:!0,type:"String"},{name:"historyTimeToLive",isAttr:!0,type:"String"},{name:"isStartableInTasklist",isAttr:!0,type:"Boolean",default:!0},{name:"executionListener",isAbstract:!0,type:"Expression"}]},{name:"EscalationEventDefinition",isAbstract:!0,extends:["bpmn:EscalationEventDefinition"],properties:[{name:"escalationCodeVariable",isAttr:!0,type:"String"}]},{name:"FormalExpression",isAbstract:!0,extends:["bpmn:FormalExpression"],properties:[{name:"resource",isAttr:!0,type:"String"}]},{name:"multiinstance_type",superClass:["Element"]},{name:"multiinstance_condition",superClass:["Element"]},{name:"Assignable",extends:["bpmn:Task","bpmn:UserTask"],properties:[{name:"flow:ccTask",isAttr:!0,type:"String"},{name:"assignee",isAttr:!0,type:"String"},{name:"candidateUsers",isAttr:!0,type:"String"},{name:"candidateGroups",isAttr:!0,type:"String"},{name:"dueDate",isAttr:!0,type:"String"},{name:"followUpDate",isAttr:!0,type:"String"},{name:"priority",isAttr:!0,type:"String"},{name:"multiinstance_condition",isAttr:!0,type:"String"},{name:"rollbackNode",isAttr:!0,type:"String"},{name:"assigneeRetain",isAttr:!0,type:"String"}]},{name:"CallActivity",extends:["bpmn:CallActivity"],properties:[{name:"calledElementBinding",isAttr:!0,type:"String",default:"latest"},{name:"calledElementVersion",isAttr:!0,type:"String"},{name:"calledElementVersionTag",isAttr:!0,type:"String"},{name:"calledElementTenantId",isAttr:!0,type:"String"},{name:"caseRef",isAttr:!0,type:"String"},{name:"caseBinding",isAttr:!0,type:"String",default:"latest"},{name:"caseVersion",isAttr:!0,type:"String"},{name:"caseTenantId",isAttr:!0,type:"String"},{name:"variableMappingClass",isAttr:!0,type:"String"},{name:"variableMappingDelegateExpression",isAttr:!0,type:"String"},{name:"calledElementType",isAttr:!0,type:"String"},{name:"inheritVariables",isAttr:!0,type:"String"},{name:"sameDeployment",isAttr:!0,type:"String"}]},{name:"ServiceTaskLike",extends:["bpmn:ServiceTask","bpmn:BusinessRuleTask","bpmn:SendTask","bpmn:MessageEventDefinition"],properties:[{name:"expression",isAttr:!0,type:"String"},{name:"class",isAttr:!0,type:"String"},{name:"delegateExpression",isAttr:!0,type:"String"},{name:"resultVariable",isAttr:!0,type:"String"}]},{name:"DmnCapable",extends:["bpmn:BusinessRuleTask"],properties:[{name:"decisionRef",isAttr:!0,type:"String"},{name:"decisionRefBinding",isAttr:!0,type:"String",default:"latest"},{name:"decisionRefVersion",isAttr:!0,type:"String"},{name:"mapDecisionResult",isAttr:!0,type:"String",default:"resultList"},{name:"decisionRefTenantId",isAttr:!0,type:"String"}]},{name:"ExternalCapable",extends:["flowable:ServiceTaskLike"],properties:[{name:"type",isAttr:!0,type:"String"},{name:"topic",isAttr:!0,type:"String"}]},{name:"TaskPriorized",extends:["bpmn:Process","flowable:ExternalCapable"],properties:[{name:"taskPriority",isAttr:!0,type:"String"}]},{name:"Properties",superClass:["Element"],meta:{allowedIn:["*"]},properties:[{name:"values",type:"Property",isMany:!0}]},{name:"Property",superClass:["Element"],properties:[{name:"id",type:"String",isAttr:!0},{name:"name",type:"String",isAttr:!0},{name:"value",type:"String",isAttr:!0}]},{name:"Connector",superClass:["Element"],meta:{allowedIn:["flowable:ServiceTaskLike"]},properties:[{name:"inputOutput",type:"InputOutput"},{name:"connectorId",type:"String"}]},{name:"InputOutput",superClass:["Element"],meta:{allowedIn:["bpmn:FlowNode","flowable:Connector"]},properties:[{name:"inputOutput",type:"InputOutput"},{name:"connectorId",type:"String"},{name:"inputParameters",isMany:!0,type:"InputParameter"},{name:"outputParameters",isMany:!0,type:"OutputParameter"}]},{name:"InputOutputParameter",properties:[{name:"name",isAttr:!0,type:"String"},{name:"value",isBody:!0,type:"String"},{name:"definition",type:"InputOutputParameterDefinition"}]},{name:"InputOutputParameterDefinition",isAbstract:!0},{name:"List",superClass:["InputOutputParameterDefinition"],properties:[{name:"items",isMany:!0,type:"InputOutputParameterDefinition"}]},{name:"Map",superClass:["InputOutputParameterDefinition"],properties:[{name:"entries",isMany:!0,type:"Entry"}]},{name:"Entry",properties:[{name:"key",isAttr:!0,type:"String"},{name:"value",isBody:!0,type:"String"},{name:"definition",type:"InputOutputParameterDefinition"}]},{name:"Value",superClass:["InputOutputParameterDefinition"],properties:[{name:"id",isAttr:!0,type:"String"},{name:"name",isAttr:!0,type:"String"},{name:"value",isBody:!0,type:"String"}]},{name:"Script",superClass:["InputOutputParameterDefinition"],properties:[{name:"scriptFormat",isAttr:!0,type:"String"},{name:"resource",isAttr:!0,type:"String"},{name:"value",isBody:!0,type:"String"}]},{name:"Field",superClass:["Element"],meta:{allowedIn:["flowable:ServiceTaskLike","flowable:ExecutionListener","flowable:TaskListener"]},properties:[{name:"name",isAttr:!0,type:"String"},{name:"expression",type:"String"},{name:"stringValue",isAttr:!0,type:"String"},{name:"string",type:"String"}]},{name:"InputParameter",superClass:["InputOutputParameter"]},{name:"OutputParameter",superClass:["InputOutputParameter"]},{name:"Collectable",isAbstract:!0,extends:["bpmn:MultiInstanceLoopCharacteristics"],superClass:["flowable:AsyncCapable"],properties:[{name:"collection",isAttr:!0,type:"String"},{name:"elementVariable",isAttr:!0,type:"String"}]},{name:"FailedJobRetryTimeCycle",superClass:["Element"],meta:{allowedIn:["flowable:AsyncCapable","bpmn:MultiInstanceLoopCharacteristics"]},properties:[{name:"body",isBody:!0,type:"String"}]},{name:"ExecutionListener",superClass:["Element"],meta:{allowedIn:["bpmn:Task","bpmn:ServiceTask","bpmn:UserTask","bpmn:BusinessRuleTask","bpmn:ScriptTask","bpmn:ReceiveTask","bpmn:ManualTask","bpmn:ExclusiveGateway","bpmn:SequenceFlow","bpmn:ParallelGateway","bpmn:InclusiveGateway","bpmn:EventBasedGateway","bpmn:StartEvent","bpmn:IntermediateCatchEvent","bpmn:IntermediateThrowEvent","bpmn:EndEvent","bpmn:BoundaryEvent","bpmn:CallActivity","bpmn:SubProcess","bpmn:Process"]},properties:[{name:"expression",isAttr:!0,type:"String"},{name:"class",isAttr:!0,type:"String"},{name:"delegateExpression",isAttr:!0,type:"String"},{name:"event",isAttr:!0,type:"String"},{name:"script",type:"Script"},{name:"fields",type:"Field",isMany:!0}]},{name:"TaskListener",superClass:["Element"],meta:{allowedIn:["bpmn:UserTask"]},properties:[{name:"expression",isAttr:!0,type:"String"},{name:"class",isAttr:!0,type:"String"},{name:"delegateExpression",isAttr:!0,type:"String"},{name:"event",isAttr:!0,type:"String"},{name:"script",type:"Script"},{name:"fields",type:"Field",isMany:!0}]},{name:"ExtendedProperty",superClass:["Element"],meta:{allowedIn:["bpmn:UserTask"]},properties:[{name:"name",isAttr:!0,type:"String"},{name:"value",isAttr:!0,type:"String"},{name:"remark",isAttr:!0,type:"String"}]},{name:"FormProperty",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent","bpmn:UserTask"]},properties:[{name:"id",type:"String",isAttr:!0},{name:"name",type:"String",isAttr:!0},{name:"type",type:"String",isAttr:!0},{name:"required",type:"String",isAttr:!0},{name:"readable",type:"String",isAttr:!0},{name:"writable",type:"String",isAttr:!0},{name:"variable",type:"String",isAttr:!0},{name:"expression",type:"String",isAttr:!0},{name:"datePattern",type:"String",isAttr:!0},{name:"default",type:"String",isAttr:!0},{name:"values",type:"Value",isMany:!0}]},{name:"FormProp",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent","bpmn:UserTask"]},properties:[{name:"id",type:"String",isAttr:!0},{name:"name",type:"String",isAttr:!0},{name:"type",type:"String",isAttr:!0},{name:"required",type:"String",isAttr:!0},{name:"readable",type:"String",isAttr:!0},{name:"writable",type:"String",isAttr:!0},{name:"variable",type:"String",isAttr:!0},{name:"expression",type:"String",isAttr:!0},{name:"datePattern",type:"String",isAttr:!0},{name:"default",type:"String",isAttr:!0},{name:"values",type:"Value",isMany:!0}]},{name:"Button",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent","bpmn:UserTask"]},properties:[{name:"label",type:"String",isAttr:!0},{name:"prop",type:"String",isAttr:!0},{name:"display",type:"String",isAttr:!0}]},{name:"FormData",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent","bpmn:UserTask"]},properties:[{name:"fields",type:"FormField",isMany:!0},{name:"businessKey",type:"String",isAttr:!0}]},{name:"FormField",superClass:["Element"],properties:[{name:"id",type:"String",isAttr:!0},{name:"label",type:"String",isAttr:!0},{name:"type",type:"String",isAttr:!0},{name:"datePattern",type:"String",isAttr:!0},{name:"defaultValue",type:"String",isAttr:!0},{name:"properties",type:"Properties"},{name:"validation",type:"Validation"},{name:"values",type:"Value",isMany:!0}]},{name:"Validation",superClass:["Element"],properties:[{name:"constraints",type:"Constraint",isMany:!0}]},{name:"Constraint",superClass:["Element"],properties:[{name:"name",type:"String",isAttr:!0},{name:"config",type:"String",isAttr:!0}]},{name:"ConditionalEventDefinition",isAbstract:!0,extends:["bpmn:ConditionalEventDefinition"],properties:[{name:"variableName",isAttr:!0,type:"String"},{name:"variableEvent",isAttr:!0,type:"String"}]},{name:"Serial",superClass:["Element"],meta:{allowedIn:["bpmn:Process"]},properties:[{name:"name",isAttr:!0,type:"String"},{name:"prefix",isAttr:!0,type:"String"},{name:"dateFormat",isAttr:!0,type:"String"},{name:"suffixLength",isAttr:!0,type:"Number"},{name:"startSequence",isAttr:!0,type:"Number"},{name:"connector",isAttr:!0,type:"String"},{name:"cycle",isAttr:!0,type:"String"},{name:"useExistSN",isAttr:!0,type:"Boolean"}]},{name:"Assignee",superClass:["Element"],meta:{allowedIn:["bpmn:UserTask"]},properties:[{name:"type",type:"String",isAttr:!0},{name:"value",type:"String",isAttr:!0},{name:"text",type:"String",isAttr:!0}]},{name:"HideCopy",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent"]},properties:[{name:"value",type:"String",isAttr:!0}]},{name:"HideExamine",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent"]},properties:[{name:"value",type:"String",isAttr:!0}]},{name:"HideAttachment",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent"]},properties:[{name:"value",type:"String",isAttr:!0}]},{name:"ExFormKey",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent"]},properties:[{name:"value",type:"String",isAttr:!0}]},{name:"ExFormUrl",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent"]},properties:[{name:"value",type:"String",isAttr:!0}]},{name:"ExAppFormUrl",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent"]},properties:[{name:"value",type:"String",isAttr:!0}]},{name:"IndepFormKey",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent"]},properties:[{name:"value",type:"String",isAttr:!0}]},{name:"IndepFormSummary",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent"]},properties:[{name:"value",type:"String",isAttr:!0}]},{name:"AssigneeRetain",superClass:["Element"],meta:{allowedIn:["bpmn:SubProcess","bpmn:CallActivity"]},properties:[{name:"value",type:"String",isAttr:!0}]},{name:"CopyUser",superClass:["Element"],meta:{allowedIn:["bpmn:UserTask","bpmn:StartEvent"]},properties:[{name:"value",type:"String",isAttr:!0},{name:"text",type:"String",isAttr:!0}]},{name:"ExamineSupported",isAbstract:!0,extends:["bpmn:StartEvent","bpmn:UserTask"],properties:[{name:"hideCopy",isAttr:!0,type:"String"},{name:"hideExamine",isAttr:!0,type:"String"},{name:"hideAttachment",isAttr:!0,type:"String"}]}],emumerations:[]},eo={name:"@ui-ddy-process/design",version:"1.6.25",author:"ssc <273702440@qq.com>",type:"module",description:"ddy process design",main:"lib/nf-design-elp.js",files:["lib"],publishConfig:{access:"public",registry:"https://registry.npmjs.org/"},engines:{node:"^18.0.0 || >=20.0.0"},scripts:{build:"vite build",dev:"vite --host",lib:"vite build --mode lib",prettier:"prettier ./packages/**/*.vue --write"},dependencies:{"bpmn-js":"^18.6.2","bpmn-js-create-append-anything":"^1.0.0",bpmnlint:"^11.4.4",randomcolor:"^0.6.2","tiny-svg":"^4.1.4"},devDependencies:{"@nutflow/nf-form-elp":"^1.5.6","@so1ve/prettier-config":"^3.1.0","@vitejs/plugin-vue":"^5.2.4",axios:"^1.10.0","element-plus":"^2.10.2",prettier:"^3.5.3","rollup-plugin-visualizer":"^5.14.0",sass:"^1.89.2",vite:"^5.4.18","vite-plugin-remove-console":"^2.2.0","vite-plugin-static-copy":"^1.0.6",vue:"^3.5.16"}},cR={name:"nf-design",components:{NfToolbar:sh,NfPanel:nm},props:{options:{type:Object,default:()=>({})},storage:{type:Boolean,default:!1},accessKey:String},computed:{isEditMode(){return this.option.mode!="view"}},watch:{options:{handler(e){this.$nextTick(()=>{if(this.debounce){if(this.debounce=!1,this.storage){const t=localStorage[eo.name];t?this.option=JSON.parse(t):this.option=JSON.parse(JSON.stringify({...Pl,...e}))}else this.option=JSON.parse(JSON.stringify({...Pl,...e})),delete localStorage[eo.name];this.init(!0),setTimeout(()=>{this.debounce=!0},1e3)}})},deep:!0,immediate:!0}},data(){return{option:{},activeTab:"process",modeler:null,zoom:1,previewXML:"",previewVisible:!1,importXML:"",importVisible:!1,debounce:!0}},methods:{INIT_XML:Ka,init(e=!1){this.storage&&(localStorage[eo.name]=JSON.stringify(this.option)),e&&(this.isEditMode?this.initModeler():this.initViewer())},async initModeler(){this.modeler&&this.modeler.destroy(),this.modeler=s.markRaw(new Ba({container:this.$refs.modeler,additionalModules:[jz,this.$nfDesign.lang=="zh"?{translate:["value",gu]}:"",this.option.simulation?ez:"",this.option.minimap?Xu:"",this.option.lint?SY:""],linting:{bpmnlint:k6,active:this.isEditMode},moddleExtensions:{flowable:aR}})),await this.createNewDiagram(this.option.xml||Ka(this.option.process)),this.storage&&this.modeler.on("element.changed",()=>{this.getData("xml",!1,!1).then(e=>{this.option.xml=e,localStorage[eo.name]=JSON.stringify(this.option)})})},async initViewer(){this.modeler&&this.modeler.destroy(),this.modeler=s.markRaw(new et({container:this.$refs.modeler,additionalModules:[{translate:["value",gu]},yd,this.option.simulation?tz:"",this.option.minimap?Xu:"",Hc,jc]})),await this.createNewDiagram(this.option.xml||Ka(this.option.process)),this.option.flows&&this.option.flows.length>0&&this.setNodeColor(this.option.flows)},setNodeColor(e){const t=this.modeler.get("canvas"),n=this.modeler.get("elementRegistry"),A=this.modeler.get("tooltips");e.forEach(i=>{if(i.id&&i.class&&t.addMarker(i.id,i.class),i.id&&i.tooltip){const o=n.get(i.id);if(o){let{x:r,y:a,type:c}=o;["bpmn:StartEvent","bpmn:EndEvent"].includes(c)?(r=r-45,a=a+65):["bpmn:UserTask"].includes(c)&&(r=r-10,a=a+90),A.add({position:{x:r,y:a},html:i.tooltip})}}})},async createNewDiagram(e,t=!1){try{e=e.replace(/camunda:/g,"flowable:"),e=e.replace(/activiti:/g,"flowable:"),await this.modeler.importXML(e),this.isEditMode?this.fitViewport("init"):this.fitViewport("auto"),t&&this.$refs.panel.handleInitNodes(!0)}catch(n){console.error(n)}},fitViewport(e){const t=this.modeler.get("canvas");typeof e=="string"?e=="init"?t.zoom("fit-viewport"):e=="auto"&&t.zoom("fit-viewport","auto"):(this.zoom+=e?.1:-.1,t.zoom(this.zoom))},async getData(e,t=!1,n=!0,A=!0){if(n){const i=document.querySelector(".bjsl-button-error .label"),o=i==null?null:i.innerHTML;if(o&&!o.includes("0 错误")&&!o.includes("0 Errors"))throw this.$message.error("模型存在错误,请处理"),new Error("模型存在错误,请处理")}if(e=="xml")try{let{xml:i}=await this.modeler.saveXML({format:A});return this.option.engine!="flowable"&&(i=i.replace(/flowable:/g,this.option.engine+":")),t&&this.downloadFile(`${this.modeler.getDefinitions().rootElements[0].name}.bpmn20.xml`,i,"application/xml"),i}catch{}else try{const{svg:i}=await this.modeler.saveSVG({format:A});return t&&this.downloadFile(this.modeler.getDefinitions().rootElements[0].name,i,"image/svg+xml"),i}catch{}},downloadFile(e,t,n){let A=document.createElement("a"),i=window.URL.createObjectURL(new Blob([t],{type:n}));A.href=i,A.download=e,A.click(),window.URL.revokeObjectURL(i)},async handlePreview(e){const t=await this.getData("xml");e=="preview"?(this.previewXML=t,this.previewVisible=!0):e=="get"&&this.$emit("get",t)},handleImport(){this.option.exForm&&(delete this.option.exForm.column,delete this.option.exForm.exFormKey,delete this.option.exForm.exFormUrl,delete this.option.exForm.exAppFormUrl),this.createNewDiagram(this.importXML,!0),this.importVisible=!1},getElementRegistry(){const e=this.modeler.get("elementRegistry").getAll();return e.length==0?[]:(e[0].type!="bpmn:Process"&&e.unshift({businessObject:this.modeler.getDefinitions().rootElements.find(t=>t.$type=="bpmn:Process")}),{getAll(){return e}})}}},sR={class:"nf-design"},lR={class:"modeler",ref:"modeler"},BR={class:"nf-drawer__foot"};function gR(e,t,n,A,i,o){const r=s.resolveComponent("nf-toolbar"),a=s.resolveComponent("el-header"),c=s.resolveComponent("el-main"),l=s.resolveComponent("el-container"),B=s.resolveComponent("nf-panel"),g=s.resolveComponent("el-aside"),p=s.resolveComponent("nf-codemirror"),E=s.resolveComponent("el-drawer"),d=s.resolveComponent("el-button");return s.openBlock(),s.createElementBlock("div",sR,[s.createVNode(l,null,{default:s.withCtx(()=>[s.createVNode(l,null,{default:s.withCtx(()=>[s.withDirectives(s.createVNode(a,null,{default:s.withCtx(()=>[s.createVNode(r,{toolbar:i.option.toolbar,onOpen:t[0]||(t[0]=u=>o.createNewDiagram(u,!0)),onCreate:t[1]||(t[1]=u=>o.createNewDiagram(o.INIT_XML(),!0)),onFit:o.fitViewport,onUndo:t[2]||(t[2]=u=>i.modeler.get("commandStack").undo()),onRedo:t[3]||(t[3]=u=>i.modeler.get("commandStack").redo()),onDownload:o.getData,onImport:t[4]||(t[4]=u=>i.importVisible=!0),onPreview:o.handlePreview},{toolbar:s.withCtx(()=>[s.renderSlot(e.$slots,"toolbar")]),_:3},8,["toolbar","onFit","onDownload","onPreview"])]),_:3},512),[[s.vShow,o.isEditMode&&i.option.toolbar&&i.option.toolbar.length>0]]),s.createVNode(c,null,{default:s.withCtx(()=>[s.createElementVNode("div",lR,null,512)]),_:1})]),_:3}),o.isEditMode?(s.openBlock(),s.createBlock(g,{key:0,width:"380px"},{default:s.withCtx(()=>[i.modeler?(s.openBlock(),s.createBlock(B,{key:0,ref:"panel",modeler:i.modeler,"auto-init":i.option.autoInit,"form-option":i.option.form,"ex-form-option":i.option.exForm,"indep-form-option":i.option.indepForm,"user-option":i.option.user,"group-option":i.option.group,"button-option":i.option.button,"script-option":i.option.script,"condition-option":i.option.condition,"listener-option":i.option.listener,"extended-properties-option":i.option.extendedProperty},null,8,["modeler","auto-init","form-option","ex-form-option","indep-form-option","user-option","group-option","button-option","script-option","condition-option","listener-option","extended-properties-option"])):s.createCommentVNode("",!0)]),_:1})):s.createCommentVNode("",!0)]),_:3}),s.createVNode(E,{title:"查看",modelValue:i.previewVisible,"onUpdate:modelValue":t[6]||(t[6]=u=>i.previewVisible=u),"append-to-body":"","destroy-on-close":"",class:"nf-drawer",size:"60%"},{default:s.withCtx(()=>[s.createVNode(p,{modelValue:i.previewXML,"onUpdate:modelValue":t[5]||(t[5]=u=>i.previewXML=u),language:"xml"},null,8,["modelValue"])]),_:1},8,["modelValue"]),s.createVNode(E,{title:"导入",modelValue:i.importVisible,"onUpdate:modelValue":t[9]||(t[9]=u=>i.importVisible=u),"append-to-body":"","destroy-on-close":"",class:"nf-drawer",size:"60%"},{default:s.withCtx(()=>[s.createVNode(p,{modelValue:i.importXML,"onUpdate:modelValue":t[7]||(t[7]=u=>i.importXML=u),language:"xml",style:{height:"94%"}},null,8,["modelValue"]),s.createElementVNode("div",BR,[s.createVNode(d,{type:"primary",size:"default",onClick:o.handleImport},{default:s.withCtx(()=>t[10]||(t[10]=[s.createTextVNode(" 确定 ")])),_:1,__:[10]},8,["onClick"]),s.createVNode(d,{type:"danger",size:"default",onClick:t[8]||(t[8]=u=>i.importVisible=!1)},{default:s.withCtx(()=>t[11]||(t[11]=[s.createTextVNode(" 取消 ")])),_:1,__:[11]})])]),_:1},8,["modelValue"])])}const pR=F0(cR,[["render",gR]]),ZQ=(e,t={})=>{Vl.use(t.locale),Vl.i18n(t.i18n),e.config.globalProperties.$axios=t.axios||window.axios;let n="zh";t.locale&&(n=t.locale.nf.lang),e.config.globalProperties.$nfDesign={...t,lang:n},e.component("nf-design",pR)};return typeof window<"u"&&window.Vue&&ZQ(window.Vue),{author:"ssc",email:"273702440@qq.com",version:eo.version,install:ZQ}});
408
+ </svg>`;function Zi(e,t,n,A,i){this._contextPad=e,this._popupMenu=t,this._translate=n,this._canvas=A,this._rules=i,this.register()}Zi.$inject=["contextPad","popupMenu","translate","canvas","rules"],Zi.prototype.register=function(){this._contextPad.registerProvider(this)},Zi.prototype.getContextPadEntries=function(e){const t=this._popupMenu,n=this._translate,A=this._rules,i=this._getAppendMenuPosition.bind(this);if(A.allowed("shape.append",{element:e}))return{append:{group:"model",html:`<div class="entry">${Mz}</div>`,title:n("Append element"),action:{click:function(o,r){const a=Rl(i(r),{cursor:{x:o.x,y:o.y}});t.open(r,"bpmn-append",a,{title:n("Append element"),width:300,search:!0})}}}}},Zi.prototype._getAppendMenuPosition=function(e){const A=this._canvas.getContainer().querySelector(".djs-context-pad").getBoundingClientRect();return{x:A.right+5,y:A.top}};function Sl(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}function Va(e,t){var n=Tl(e);return n&&typeof n.$instanceOf=="function"&&n.$instanceOf(t)}function yz(e,t){return iz(t,function(n){return Va(e,n)})}function Tl(e){return e&&e.businessObject||e}function Iz(e){return JQ(e)&&VQ(e,"labelTarget")}var Fz=1e3;function X2(e){this._eventBus=e}X2.$inject=["eventBus"];function vz(e,t){return function(n){return e.call(t||null,n.context,n.command,n)}}X2.prototype.on=function(e,t,n,A,i,o){if((Xi(t)||jQ(t))&&(o=i,i=A,A=n,n=t,t=null),Xi(n)&&(o=i,i=A,A=n,n=Fz),JQ(i)&&(o=i,i=!1),!Xi(A))throw new Error("handlerFn must be a function");zl(e)||(e=[e]);var r=this._eventBus;WQ(e,function(a){var c=["commandStack",a,t].filter(function(l){return l}).join(".");r.on(c,n,i?vz(A,o):A,o)})},X2.prototype.canExecute=pt("canExecute"),X2.prototype.preExecute=pt("preExecute"),X2.prototype.preExecuted=pt("preExecuted"),X2.prototype.execute=pt("execute"),X2.prototype.executed=pt("executed"),X2.prototype.postExecute=pt("postExecute"),X2.prototype.postExecuted=pt("postExecuted"),X2.prototype.revert=pt("revert"),X2.prototype.reverted=pt("reverted");function pt(e){return function(n,A,i,o,r){(Xi(n)||jQ(n))&&(r=o,o=i,i=A,A=n,n=null),this.on(n,e,A,i,o,r)}}function DA(e){X2.call(this,e),this.init()}DA.$inject=["eventBus"],Sl(DA,X2),DA.prototype.addRule=function(e,t,n){var A=this;typeof e=="string"&&(e=[e]),e.forEach(function(i){A.canExecute(i,t,function(o,r,a){return n(o)},!0)})},DA.prototype.init=function(){};function La(e){DA.call(this,e)}Sl(La,DA),La.$inject=["eventBus"],La.prototype.init=function(){this.addRule("shape.append",function(e){const t=e.element,n=Tl(t);if(Iz(t)||yz(t,["bpmn:EndEvent","bpmn:Group","bpmn:TextAnnotation","bpmn:Lane","bpmn:Participant","bpmn:DataStoreReference","bpmn:DataObjectReference"])||bz(t)||Va(t,"bpmn:IntermediateThrowEvent")&&xz(t,"bpmn:LinkEventDefinition")||Va(t,"bpmn:SubProcess")&&n.triggeredByEvent)return!1})};function xz(e,t){const n=Tl(e);return!!LQ(n.eventDefinitions||[],function(A){return Va(A,t)})}function bz(e){return e.waypoints}var kl={__init__:["appendMenuProvider","appendContextPadProvider","appendRules"],appendMenuProvider:["type",Yn],appendContextPadProvider:["type",Zi],appendRules:["type",La]};function qi(e,t,n,A,i,o){this._elementFactory=e,this._popupMenu=t,this._create=n,this._autoPlace=A,this._mouse=i,this._translate=o,this.register()}qi.$inject=["elementFactory","popupMenu","create","autoPlace","mouse","translate"],qi.prototype.register=function(){this._popupMenu.registerProvider("bpmn-create",this)},qi.prototype.getPopupMenuEntries=function(){const e={};return _Q.forEach(t=>{const{actionName:n,className:A,label:i,target:o,description:r,group:a,search:c,rank:l}=t,B=this._createEntryAction(o);e[`create-${n}`]={label:i&&this._translate(i),className:A,description:r,group:a&&{...a,name:this._translate(a.name)},search:c,rank:l,action:{click:B,dragstart:B}}}),e},qi.prototype._createEntryAction=function(e){const t=this._create,n=this._mouse,A=this._popupMenu,i=this._elementFactory;let o;return r=>(A.close(),e.type==="bpmn:Participant"?o=i.createParticipantShape(e):o=i.create("shape",e),r instanceof KeyboardEvent&&(r=n.getLastMoveEvent()),t.start(r,o))};var Wa;typeof document<"u"&&(Wa=document.createElement("div"),Wa.innerHTML=' <link/><table></table><a href="/a">a</a><input type="checkbox"/>',Wa.getElementsByTagName("link").length,Wa=void 0);function Yz(e,t){return t=t||document,t.querySelector(e)}const Uz=900;function _a(e,t,n,A,i){this._palette=e,this._translate=t,this._popupMenu=n,this._canvas=A,this._mouse=i,this.register()}_a.$inject=["palette","translate","popupMenu","canvas","mouse"],_a.prototype.register=function(){this._palette.registerProvider(Uz,this)},_a.prototype.getPaletteEntries=function(e){const t=this._translate,n=this._popupMenu,A=this._canvas,i=this._mouse,o=r=>{if(r instanceof KeyboardEvent)return r=i.getLastMoveEvent(),{x:r.x,y:r.y};const l=r&&r.target||Yz('.djs-palette [data-action="create"]'),B=l.getBoundingClientRect();return l&&{x:B.left+B.width/2+35,y:B.top+B.height/2+10}};return{create:{group:"create",html:`<div class="entry"> ${Dz}</div>`,title:t("Create element"),action:{click:function(r){const a=o(r),c=A.getRootElement();n.open(c,"bpmn-create",a,{title:t("Create element"),width:300,search:!0})}}}}};var Gl={__init__:["createMenuProvider","createPaletteProvider"],createMenuProvider:["type",qi],createPaletteProvider:["type",_a]};function Hl(e){this._injector=e,this.registerActions()}Hl.$inject=["injector"],Hl.prototype.registerActions=function(){const e=this._injector.get("editorActions",!1),t=this._injector.get("selection",!1),n=this._injector.get("contextPad",!1),A=this._injector.get("palette",!1),i=this._injector.get("popupMenu",!1),o={};t&&n&&A&&i&&A&&Rl(o,{appendElement:function(r){const a=t&&t.get();a.length==1&&!i.isEmpty(a[0],"bpmn-append")?n.triggerEntry("append","click",r):A.triggerEntry("create","click",r)}}),A&&Rl(o,{createElement:function(r){A.triggerEntry("create","click",r)}}),e&&e.register(o)};var Nz={__depends__:[kl,Gl],__init__:["createAppendEditorActions"],createAppendEditorActions:["type",Hl]},zz=["c","C"],Rz=["v","V"],Sz=["y","Y"],OQ=["z","Z"];function Un(e){return e.altKey?!1:e.ctrlKey||e.metaKey}function Et(e,t){return e=zl(e)?e:[e],e.indexOf(t.key)!==-1||e.indexOf(t.code)!==-1}function XQ(e){return e.shiftKey}function Tz(e){return Un(e)&&Et(zz,e)}function kz(e){return Un(e)&&Et(Rz,e)}function Gz(e){return Un(e)&&!XQ(e)&&Et(OQ,e)}function Hz(e){return Un(e)&&(Et(Sz,e)||Et(OQ,e)&&XQ(e))}var Pz=500;function $i(e,t){var n=this;e.on("editorActions.init",Pz,function(A){var i=A.editorActions;n.registerBindings(t,i)})}$i.$inject=["eventBus","keyboard"],$i.prototype.registerBindings=function(e,t){function n(A,i){t.isRegistered(A)&&e.addListener(i)}n("undo",function(A){var i=A.keyEvent;if(Gz(i))return t.trigger("undo"),!0}),n("redo",function(A){var i=A.keyEvent;if(Hz(i))return t.trigger("redo"),!0}),n("copy",function(A){var i=A.keyEvent;if(Tz(i))return t.trigger("copy"),!0}),n("paste",function(A){var i=A.keyEvent;if(kz(i))return t.trigger("paste"),!0}),n("stepZoom",function(A){var i=A.keyEvent;if(Et(["+","Add","="],i)&&Un(i))return t.trigger("stepZoom",{value:1}),!0}),n("stepZoom",function(A){var i=A.keyEvent;if(Et(["-","Subtract"],i)&&Un(i))return t.trigger("stepZoom",{value:-1}),!0}),n("zoom",function(A){var i=A.keyEvent;if(Et("0",i)&&Un(i))return t.trigger("zoom",{value:1}),!0}),n("removeSelection",function(A){var i=A.keyEvent;if(Et(["Backspace","Delete","Del"],i))return t.trigger("removeSelection"),!0})};function Oa(e){this._injector=e,this._keyboard=this._injector.get("keyboard",!1),this._editorActions=this._injector.get("editorActions",!1),this._keyboard&&this._injector.invoke($i,this)}Sl(Oa,$i),Oa.$inject=["injector"],Oa.prototype.registerBindings=function(){const e=this._keyboard,t=this._editorActions;$i.prototype.registerBindings.call(this,e,t);function n(A,i){t&&t.isRegistered(A)&&e&&e.addListener(i)}n("appendElement",function(A){const i=A.keyEvent;if(!(e&&e.hasModifier(i))&&e&&e.isKey(["a","A"],i))return t&&t.trigger("appendElement",i),!0}),n("createElement",function(A){const i=A.keyEvent;if(!(e&&e.hasModifier(i))&&e&&e.isKey(["n","N"],i))return t&&t.trigger("createElement",i),!0})};var Jz={__depends__:[kl,Gl],__init__:["createAppendKeyboardBindings"],createAppendKeyboardBindings:["type",Oa]},jz={__depends__:[kl,Gl,Nz,Jz]},Vz=[{label:"Start event",actionName:"replace-with-none-start",className:"bpmn-icon-start-event-none",target:{type:"bpmn:StartEvent"}},{label:"Intermediate throw event",actionName:"replace-with-none-intermediate-throwing",className:"bpmn-icon-intermediate-event-none",target:{type:"bpmn:IntermediateThrowEvent"}},{label:"End event",actionName:"replace-with-none-end",className:"bpmn-icon-end-event-none",target:{type:"bpmn:EndEvent"}},{label:"Message start event",actionName:"replace-with-message-start",className:"bpmn-icon-start-event-message",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:MessageEventDefinition"}},{label:"Timer start event",actionName:"replace-with-timer-start",className:"bpmn-icon-start-event-timer",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:TimerEventDefinition"}},{label:"Conditional start event",actionName:"replace-with-conditional-start",className:"bpmn-icon-start-event-condition",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:ConditionalEventDefinition"}},{label:"Signal start event",actionName:"replace-with-signal-start",className:"bpmn-icon-start-event-signal",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:SignalEventDefinition"}}],Lz=[{label:"Start event",actionName:"replace-with-none-start",className:"bpmn-icon-start-event-none",target:{type:"bpmn:StartEvent"}},{label:"Intermediate throw event",actionName:"replace-with-none-intermediate-throwing",className:"bpmn-icon-intermediate-event-none",target:{type:"bpmn:IntermediateThrowEvent"}},{label:"End event",actionName:"replace-with-none-end",className:"bpmn-icon-end-event-none",target:{type:"bpmn:EndEvent"}}],Wz=[{label:"Start event",actionName:"replace-with-none-start",className:"bpmn-icon-start-event-none",target:{type:"bpmn:StartEvent"}},{label:"Intermediate throw event",actionName:"replace-with-none-intermediate-throw",className:"bpmn-icon-intermediate-event-none",target:{type:"bpmn:IntermediateThrowEvent"}},{label:"End event",actionName:"replace-with-none-end",className:"bpmn-icon-end-event-none",target:{type:"bpmn:EndEvent"}},{label:"Message intermediate catch event",actionName:"replace-with-message-intermediate-catch",className:"bpmn-icon-intermediate-event-catch-message",target:{type:"bpmn:IntermediateCatchEvent",eventDefinitionType:"bpmn:MessageEventDefinition"}},{label:"Message intermediate throw event",actionName:"replace-with-message-intermediate-throw",className:"bpmn-icon-intermediate-event-throw-message",target:{type:"bpmn:IntermediateThrowEvent",eventDefinitionType:"bpmn:MessageEventDefinition"}},{label:"Timer intermediate catch event",actionName:"replace-with-timer-intermediate-catch",className:"bpmn-icon-intermediate-event-catch-timer",target:{type:"bpmn:IntermediateCatchEvent",eventDefinitionType:"bpmn:TimerEventDefinition"}},{label:"Escalation intermediate throw event",actionName:"replace-with-escalation-intermediate-throw",className:"bpmn-icon-intermediate-event-throw-escalation",target:{type:"bpmn:IntermediateThrowEvent",eventDefinitionType:"bpmn:EscalationEventDefinition"}},{label:"Conditional intermediate catch event",actionName:"replace-with-conditional-intermediate-catch",className:"bpmn-icon-intermediate-event-catch-condition",target:{type:"bpmn:IntermediateCatchEvent",eventDefinitionType:"bpmn:ConditionalEventDefinition"}},{label:"Link intermediate catch event",actionName:"replace-with-link-intermediate-catch",className:"bpmn-icon-intermediate-event-catch-link",target:{type:"bpmn:IntermediateCatchEvent",eventDefinitionType:"bpmn:LinkEventDefinition",eventDefinitionAttrs:{name:""}}},{label:"Link intermediate throw event",actionName:"replace-with-link-intermediate-throw",className:"bpmn-icon-intermediate-event-throw-link",target:{type:"bpmn:IntermediateThrowEvent",eventDefinitionType:"bpmn:LinkEventDefinition",eventDefinitionAttrs:{name:""}}},{label:"Compensation intermediate throw event",actionName:"replace-with-compensation-intermediate-throw",className:"bpmn-icon-intermediate-event-throw-compensation",target:{type:"bpmn:IntermediateThrowEvent",eventDefinitionType:"bpmn:CompensateEventDefinition"}},{label:"Signal intermediate catch event",actionName:"replace-with-signal-intermediate-catch",className:"bpmn-icon-intermediate-event-catch-signal",target:{type:"bpmn:IntermediateCatchEvent",eventDefinitionType:"bpmn:SignalEventDefinition"}},{label:"Signal intermediate throw event",actionName:"replace-with-signal-intermediate-throw",className:"bpmn-icon-intermediate-event-throw-signal",target:{type:"bpmn:IntermediateThrowEvent",eventDefinitionType:"bpmn:SignalEventDefinition"}}],_z=[{label:"Start event",actionName:"replace-with-none-start",className:"bpmn-icon-start-event-none",target:{type:"bpmn:StartEvent"}},{label:"Intermediate throw event",actionName:"replace-with-none-intermediate-throw",className:"bpmn-icon-intermediate-event-none",target:{type:"bpmn:IntermediateThrowEvent"}},{label:"End event",actionName:"replace-with-none-end",className:"bpmn-icon-end-event-none",target:{type:"bpmn:EndEvent"}},{label:"Message end event",actionName:"replace-with-message-end",className:"bpmn-icon-end-event-message",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:MessageEventDefinition"}},{label:"Escalation end event",actionName:"replace-with-escalation-end",className:"bpmn-icon-end-event-escalation",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:EscalationEventDefinition"}},{label:"Error end event",actionName:"replace-with-error-end",className:"bpmn-icon-end-event-error",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:ErrorEventDefinition"}},{label:"Cancel end event",actionName:"replace-with-cancel-end",className:"bpmn-icon-end-event-cancel",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:CancelEventDefinition"}},{label:"Compensation end event",actionName:"replace-with-compensation-end",className:"bpmn-icon-end-event-compensation",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:CompensateEventDefinition"}},{label:"Signal end event",actionName:"replace-with-signal-end",className:"bpmn-icon-end-event-signal",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:SignalEventDefinition"}},{label:"Terminate end event",actionName:"replace-with-terminate-end",className:"bpmn-icon-end-event-terminate",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:TerminateEventDefinition"}}],Oz=[{label:"Exclusive gateway",actionName:"replace-with-exclusive-gateway",className:"bpmn-icon-gateway-xor",target:{type:"bpmn:ExclusiveGateway"}},{label:"Parallel gateway",actionName:"replace-with-parallel-gateway",className:"bpmn-icon-gateway-parallel",target:{type:"bpmn:ParallelGateway"}},{label:"Inclusive gateway",actionName:"replace-with-inclusive-gateway",className:"bpmn-icon-gateway-or",target:{type:"bpmn:InclusiveGateway"}},{label:"Complex gateway",actionName:"replace-with-complex-gateway",className:"bpmn-icon-gateway-complex",target:{type:"bpmn:ComplexGateway"}},{label:"Event-based gateway",actionName:"replace-with-event-based-gateway",className:"bpmn-icon-gateway-eventbased",target:{type:"bpmn:EventBasedGateway",instantiate:!1,eventGatewayType:"Exclusive"}}],Xz=[{label:"Transaction",actionName:"replace-with-transaction",className:"bpmn-icon-transaction",target:{type:"bpmn:Transaction",isExpanded:!0}},{label:"Event sub-process",actionName:"replace-with-event-subprocess",className:"bpmn-icon-event-subprocess-expanded",target:{type:"bpmn:SubProcess",triggeredByEvent:!0,isExpanded:!0}},{label:"Ad-hoc sub-process",actionName:"replace-with-ad-hoc-subprocess",className:"bpmn-icon-subprocess-expanded",target:{type:"bpmn:AdHocSubProcess",isExpanded:!0}},{label:"Sub-process (collapsed)",actionName:"replace-with-collapsed-subprocess",className:"bpmn-icon-subprocess-collapsed",target:{type:"bpmn:SubProcess",isExpanded:!1}}],Kz=[{label:"Sub-process",actionName:"replace-with-subprocess",className:"bpmn-icon-subprocess-expanded",target:{type:"bpmn:SubProcess",isExpanded:!0}},{label:"Transaction",actionName:"replace-with-transaction",className:"bpmn-icon-transaction",target:{type:"bpmn:Transaction",isExpanded:!0}},{label:"Event sub-process",actionName:"replace-with-event-subprocess",className:"bpmn-icon-event-subprocess-expanded",target:{type:"bpmn:SubProcess",triggeredByEvent:!0,isExpanded:!0}},{label:"Ad-hoc sub-process (collapsed)",actionName:"replace-with-collapsed-ad-hoc-subprocess",className:"bpmn-icon-subprocess-collapsed",target:{type:"bpmn:AdHocSubProcess",isExpanded:!1}}],KQ=[{label:"Transaction",actionName:"replace-with-transaction",className:"bpmn-icon-transaction",target:{type:"bpmn:Transaction",isExpanded:!0}},{label:"Sub-process",actionName:"replace-with-subprocess",className:"bpmn-icon-subprocess-expanded",target:{type:"bpmn:SubProcess",isExpanded:!0}},{label:"Ad-hoc sub-process",actionName:"replace-with-ad-hoc-subprocess",className:"bpmn-icon-subprocess-expanded",target:{type:"bpmn:AdHocSubProcess",isExpanded:!0}},{label:"Event sub-process",actionName:"replace-with-event-subprocess",className:"bpmn-icon-event-subprocess-expanded",target:{type:"bpmn:SubProcess",triggeredByEvent:!0,isExpanded:!0}}],Zz=KQ,qz=[{label:"Task",actionName:"replace-with-task",className:"bpmn-icon-task",target:{type:"bpmn:Task"}},{label:"User task",actionName:"replace-with-user-task",className:"bpmn-icon-user",target:{type:"bpmn:UserTask"}},{label:"Service task",actionName:"replace-with-service-task",className:"bpmn-icon-service",target:{type:"bpmn:ServiceTask"}},{label:"Send task",actionName:"replace-with-send-task",className:"bpmn-icon-send",target:{type:"bpmn:SendTask"}},{label:"Receive task",actionName:"replace-with-receive-task",className:"bpmn-icon-receive",target:{type:"bpmn:ReceiveTask"}},{label:"Manual task",actionName:"replace-with-manual-task",className:"bpmn-icon-manual",target:{type:"bpmn:ManualTask"}},{label:"Business rule task",actionName:"replace-with-rule-task",className:"bpmn-icon-business-rule",target:{type:"bpmn:BusinessRuleTask"}},{label:"Script task",actionName:"replace-with-script-task",className:"bpmn-icon-script",target:{type:"bpmn:ScriptTask"}},{label:"Call activity",actionName:"replace-with-call-activity",className:"bpmn-icon-call-activity",target:{type:"bpmn:CallActivity"}},{label:"Sub-process (collapsed)",actionName:"replace-with-collapsed-subprocess",className:"bpmn-icon-subprocess-collapsed",target:{type:"bpmn:SubProcess",isExpanded:!1}},{label:"Sub-process (expanded)",actionName:"replace-with-expanded-subprocess",className:"bpmn-icon-subprocess-expanded",target:{type:"bpmn:SubProcess",isExpanded:!0}},{label:"Ad-hoc sub-process (collapsed)",actionName:"replace-with-collapsed-ad-hoc-subprocess",className:"bpmn-icon-subprocess-collapsed",target:{type:"bpmn:AdHocSubProcess",isExpanded:!1}},{label:"Ad-hoc sub-process (expanded)",actionName:"replace-with-ad-hoc-subprocess",className:"bpmn-icon-subprocess-expanded",target:{type:"bpmn:AdHocSubProcess",isExpanded:!0}}],$z=[{label:"Data store reference",actionName:"replace-with-data-store-reference",className:"bpmn-icon-data-store",target:{type:"bpmn:DataStoreReference"}}],eR=[{label:"Data object reference",actionName:"replace-with-data-object-reference",className:"bpmn-icon-data-object",target:{type:"bpmn:DataObjectReference"}}],tR=[{label:"Message boundary event",actionName:"replace-with-message-boundary",className:"bpmn-icon-intermediate-event-catch-message",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:MessageEventDefinition",cancelActivity:!0}},{label:"Timer boundary event",actionName:"replace-with-timer-boundary",className:"bpmn-icon-intermediate-event-catch-timer",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:TimerEventDefinition",cancelActivity:!0}},{label:"Escalation boundary event",actionName:"replace-with-escalation-boundary",className:"bpmn-icon-intermediate-event-catch-escalation",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:EscalationEventDefinition",cancelActivity:!0}},{label:"Conditional boundary event",actionName:"replace-with-conditional-boundary",className:"bpmn-icon-intermediate-event-catch-condition",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:ConditionalEventDefinition",cancelActivity:!0}},{label:"Error boundary event",actionName:"replace-with-error-boundary",className:"bpmn-icon-intermediate-event-catch-error",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:ErrorEventDefinition",cancelActivity:!0}},{label:"Cancel boundary event",actionName:"replace-with-cancel-boundary",className:"bpmn-icon-intermediate-event-catch-cancel",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:CancelEventDefinition",cancelActivity:!0}},{label:"Signal boundary event",actionName:"replace-with-signal-boundary",className:"bpmn-icon-intermediate-event-catch-signal",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:SignalEventDefinition",cancelActivity:!0}},{label:"Compensation boundary event",actionName:"replace-with-compensation-boundary",className:"bpmn-icon-intermediate-event-catch-compensation",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:CompensateEventDefinition",cancelActivity:!0}},{label:"Message boundary event (non-interrupting)",actionName:"replace-with-non-interrupting-message-boundary",className:"bpmn-icon-intermediate-event-catch-non-interrupting-message",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:MessageEventDefinition",cancelActivity:!1}},{label:"Timer boundary event (non-interrupting)",actionName:"replace-with-non-interrupting-timer-boundary",className:"bpmn-icon-intermediate-event-catch-non-interrupting-timer",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:TimerEventDefinition",cancelActivity:!1}},{label:"Escalation boundary event (non-interrupting)",actionName:"replace-with-non-interrupting-escalation-boundary",className:"bpmn-icon-intermediate-event-catch-non-interrupting-escalation",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:EscalationEventDefinition",cancelActivity:!1}},{label:"Conditional boundary event (non-interrupting)",actionName:"replace-with-non-interrupting-conditional-boundary",className:"bpmn-icon-intermediate-event-catch-non-interrupting-condition",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:ConditionalEventDefinition",cancelActivity:!1}},{label:"Signal boundary event (non-interrupting)",actionName:"replace-with-non-interrupting-signal-boundary",className:"bpmn-icon-intermediate-event-catch-non-interrupting-signal",target:{type:"bpmn:BoundaryEvent",eventDefinitionType:"bpmn:SignalEventDefinition",cancelActivity:!1}}],nR=[{label:"Message start event",actionName:"replace-with-message-start",className:"bpmn-icon-start-event-message",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:MessageEventDefinition",isInterrupting:!0}},{label:"Timer start event",actionName:"replace-with-timer-start",className:"bpmn-icon-start-event-timer",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:TimerEventDefinition",isInterrupting:!0}},{label:"Conditional start event",actionName:"replace-with-conditional-start",className:"bpmn-icon-start-event-condition",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:ConditionalEventDefinition",isInterrupting:!0}},{label:"Signal start event",actionName:"replace-with-signal-start",className:"bpmn-icon-start-event-signal",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:SignalEventDefinition",isInterrupting:!0}},{label:"Error start event",actionName:"replace-with-error-start",className:"bpmn-icon-start-event-error",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:ErrorEventDefinition",isInterrupting:!0}},{label:"Escalation start event",actionName:"replace-with-escalation-start",className:"bpmn-icon-start-event-escalation",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:EscalationEventDefinition",isInterrupting:!0}},{label:"Compensation start event",actionName:"replace-with-compensation-start",className:"bpmn-icon-start-event-compensation",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:CompensateEventDefinition",isInterrupting:!0}},{label:"Message start event (non-interrupting)",actionName:"replace-with-non-interrupting-message-start",className:"bpmn-icon-start-event-non-interrupting-message",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:MessageEventDefinition",isInterrupting:!1}},{label:"Timer start event (non-interrupting)",actionName:"replace-with-non-interrupting-timer-start",className:"bpmn-icon-start-event-non-interrupting-timer",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:TimerEventDefinition",isInterrupting:!1}},{label:"Conditional start event (non-interrupting)",actionName:"replace-with-non-interrupting-conditional-start",className:"bpmn-icon-start-event-non-interrupting-condition",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:ConditionalEventDefinition",isInterrupting:!1}},{label:"Signal start event (non-interrupting)",actionName:"replace-with-non-interrupting-signal-start",className:"bpmn-icon-start-event-non-interrupting-signal",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:SignalEventDefinition",isInterrupting:!1}},{label:"Escalation start event (non-interrupting)",actionName:"replace-with-non-interrupting-escalation-start",className:"bpmn-icon-start-event-non-interrupting-escalation",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:EscalationEventDefinition",isInterrupting:!1}}],AR=[{label:"Sequence flow",actionName:"replace-with-sequence-flow",className:"bpmn-icon-connection"},{label:"Default flow",actionName:"replace-with-default-flow",className:"bpmn-icon-default-flow"},{label:"Conditional flow",actionName:"replace-with-conditional-flow",className:"bpmn-icon-conditional-flow"}],iR=[{label:"Expanded pool/participant",actionName:"replace-with-expanded-pool",className:"bpmn-icon-participant",target:{type:"bpmn:Participant",isExpanded:!0}},{label:function(e){var t="Empty pool/participant";return e.children&&e.children.length&&(t+=" (removes content)"),t},actionName:"replace-with-collapsed-pool",className:"bpmn-icon-lane",target:{type:"bpmn:Participant",isExpanded:!1}}],oR={"bpmn:MessageEventDefinition":[{label:"Message start event",actionName:"replace-with-message-start",className:"bpmn-icon-start-event-message",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:MessageEventDefinition"}},{label:"Message intermediate catch event",actionName:"replace-with-message-intermediate-catch",className:"bpmn-icon-intermediate-event-catch-message",target:{type:"bpmn:IntermediateCatchEvent",eventDefinitionType:"bpmn:MessageEventDefinition"}},{label:"Message intermediate throw event",actionName:"replace-with-message-intermediate-throw",className:"bpmn-icon-intermediate-event-throw-message",target:{type:"bpmn:IntermediateThrowEvent",eventDefinitionType:"bpmn:MessageEventDefinition"}},{label:"Message end event",actionName:"replace-with-message-end",className:"bpmn-icon-end-event-message",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:MessageEventDefinition"}}],"bpmn:TimerEventDefinition":[{label:"Timer start event",actionName:"replace-with-timer-start",className:"bpmn-icon-start-event-timer",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:TimerEventDefinition"}},{label:"Timer intermediate catch event",actionName:"replace-with-timer-intermediate-catch",className:"bpmn-icon-intermediate-event-catch-timer",target:{type:"bpmn:IntermediateCatchEvent",eventDefinitionType:"bpmn:TimerEventDefinition"}}],"bpmn:ConditionalEventDefinition":[{label:"Conditional start event",actionName:"replace-with-conditional-start",className:"bpmn-icon-start-event-condition",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:ConditionalEventDefinition"}},{label:"Conditional intermediate catch event",actionName:"replace-with-conditional-intermediate-catch",className:"bpmn-icon-intermediate-event-catch-condition",target:{type:"bpmn:IntermediateCatchEvent",eventDefinitionType:"bpmn:ConditionalEventDefinition"}}],"bpmn:SignalEventDefinition":[{label:"Signal start event",actionName:"replace-with-signal-start",className:"bpmn-icon-start-event-signal",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:SignalEventDefinition"}},{label:"Signal intermediate catch event",actionName:"replace-with-signal-intermediate-catch",className:"bpmn-icon-intermediate-event-catch-signal",target:{type:"bpmn:IntermediateCatchEvent",eventDefinitionType:"bpmn:SignalEventDefinition"}},{label:"Signal intermediate throw event",actionName:"replace-with-signal-intermediate-throw",className:"bpmn-icon-intermediate-event-throw-signal",target:{type:"bpmn:IntermediateThrowEvent",eventDefinitionType:"bpmn:SignalEventDefinition"}},{label:"Signal end event",actionName:"replace-with-signal-end",className:"bpmn-icon-end-event-signal",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:SignalEventDefinition"}}],"bpmn:ErrorEventDefinition":[{label:"Error start event",actionName:"replace-with-error-start",className:"bpmn-icon-start-event-error",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:ErrorEventDefinition"}},{label:"Error end event",actionName:"replace-with-error-end",className:"bpmn-icon-end-event-error",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:ErrorEventDefinition"}}],"bpmn:EscalationEventDefinition":[{label:"Escalation start event",actionName:"replace-with-escalation-start",className:"bpmn-icon-start-event-escalation",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:EscalationEventDefinition"}},{label:"Escalation intermediate throw event",actionName:"replace-with-escalation-intermediate-throw",className:"bpmn-icon-intermediate-event-throw-escalation",target:{type:"bpmn:IntermediateThrowEvent",eventDefinitionType:"bpmn:EscalationEventDefinition"}},{label:"Escalation end event",actionName:"replace-with-escalation-end",className:"bpmn-icon-end-event-escalation",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:EscalationEventDefinition"}}],"bpmn:CompensateEventDefinition":[{label:"Compensation start event",actionName:"replace-with-compensation-start",className:"bpmn-icon-start-event-compensation",target:{type:"bpmn:StartEvent",eventDefinitionType:"bpmn:CompensateEventDefinition"}},{label:"Compensation intermediate throw event",actionName:"replace-with-compensation-intermediate-throw",className:"bpmn-icon-intermediate-event-throw-compensation",target:{type:"bpmn:IntermediateThrowEvent",eventDefinitionType:"bpmn:CompensateEventDefinition"}},{label:"Compensation end event",actionName:"replace-with-compensation-end",className:"bpmn-icon-end-event-compensation",target:{type:"bpmn:EndEvent",eventDefinitionType:"bpmn:CompensateEventDefinition"}}]},rR=Object.freeze({__proto__:null,AD_HOC_SUBPROCESS_EXPANDED:Kz,BOUNDARY_EVENT:tR,DATA_OBJECT_REFERENCE:$z,DATA_STORE_REFERENCE:eR,END_EVENT:_z,EVENT_SUB_PROCESS:Zz,EVENT_SUB_PROCESS_START_EVENT:nR,GATEWAY:Oz,INTERMEDIATE_EVENT:Wz,PARTICIPANT:iR,SEQUENCE_FLOW:AR,START_EVENT:Vz,START_EVENT_SUB_PROCESS:Lz,SUBPROCESS_EXPANDED:Xz,TASK:qz,TRANSACTION:KQ,TYPED_EVENT:oR});Object.values(rR);const aR={name:"Flowable",uri:"http://flowable.org/bpmn",prefix:"flowable",xml:{tagAlias:"lowerCase"},associations:[],types:[{name:"Definitions",isAbstract:!0,extends:["bpmn:Definitions"],properties:[{name:"diagramRelationId",isAttr:!0,type:"String"}]},{name:"InOutBinding",superClass:["Element"],isAbstract:!0,properties:[{name:"source",isAttr:!0,type:"String"},{name:"sourceExpression",isAttr:!0,type:"String"},{name:"target",isAttr:!0,type:"String"},{name:"businessKey",isAttr:!0,type:"String"},{name:"local",isAttr:!0,type:"Boolean",default:!1},{name:"variables",isAttr:!0,type:"String"}]},{name:"In",superClass:["InOutBinding"],meta:{allowedIn:["bpmn:CallActivity"]}},{name:"Out",superClass:["InOutBinding"],meta:{allowedIn:["bpmn:CallActivity"]}},{name:"AsyncCapable",isAbstract:!0,extends:["bpmn:Activity","bpmn:Gateway","bpmn:Event"],properties:[{name:"async",isAttr:!0,type:"Boolean",default:!1},{name:"asyncBefore",isAttr:!0,type:"Boolean",default:!1},{name:"asyncAfter",isAttr:!0,type:"Boolean",default:!1},{name:"exclusive",isAttr:!0,type:"Boolean",default:!0}]},{name:"JobPriorized",isAbstract:!0,extends:["bpmn:Process","flowable:AsyncCapable"],properties:[{name:"jobPriority",isAttr:!0,type:"String"}]},{name:"SignalEventDefinition",isAbstract:!0,extends:["bpmn:SignalEventDefinition"],properties:[{name:"async",isAttr:!0,type:"Boolean",default:!1}]},{name:"ErrorEventDefinition",isAbstract:!0,extends:["bpmn:ErrorEventDefinition"],properties:[{name:"errorCodeVariable",isAttr:!0,type:"String"},{name:"errorMessageVariable",isAttr:!0,type:"String"}]},{name:"Error",isAbstract:!0,extends:["bpmn:Error"],properties:[{name:"flowable:errorMessage",isAttr:!0,type:"String"}]},{name:"PotentialStarter",superClass:["Element"],properties:[{name:"resourceAssignmentExpression",type:"bpmn:ResourceAssignmentExpression"}]},{name:"FormSupported",isAbstract:!0,extends:["bpmn:StartEvent","bpmn:UserTask"],properties:[{name:"formHandlerClass",isAttr:!0,type:"String"},{name:"formKey",isAttr:!0,type:"String"},{name:"formType",isAttr:!0,type:"String"},{name:"formReadOnly",isAttr:!0,type:"String"},{name:"indepFormKey",isAttr:!0,type:"String"},{name:"indepFormSummary",isAttr:!0,type:"String"},{name:"indepSummaryNode",isAttr:!0,type:"String"},{name:"exFormKey",isAttr:!0,type:"String"},{name:"exFormUrl",isAttr:!0,type:"String"},{name:"exAppFormUrl",isAttr:!0,type:"String"},{name:"backToRejecter",isAttr:!0,type:"String"},{name:"skipExpression",isAttr:!0,type:"String"}]},{name:"TemplateSupported",isAbstract:!0,extends:["bpmn:Process","bpmn:FlowElement"],properties:[{name:"modelerTemplate",isAttr:!0,type:"String"}]},{name:"Initiator",isAbstract:!0,extends:["bpmn:StartEvent"],properties:[{name:"initiator",isAttr:!0,type:"String"}]},{name:"ScriptTask",isAbstract:!0,extends:["bpmn:ScriptTask"],properties:[{name:"resultVariable",isAttr:!0,type:"String"},{name:"resource",isAttr:!0,type:"String"}]},{name:"Process",isAbstract:!0,extends:["bpmn:Process"],properties:[{name:"skipFirstNode",isAttr:!0,type:"Boolean"},{name:"skipWhenStartUser",isAttr:!0,type:"Boolean"},{name:"skipWhenAssignee",isAttr:!0,type:"Boolean"},{name:"rollbackNode",isAttr:!0,type:"String"},{name:"title",isAttr:!0,type:"String"},{name:"callBack",isAttr:!0,type:"String"},{name:"candidateStarterGroups",isAttr:!0,type:"String"},{name:"candidateStarterUsers",isAttr:!0,type:"String"},{name:"versionTag",isAttr:!0,type:"String"},{name:"historyTimeToLive",isAttr:!0,type:"String"},{name:"isStartableInTasklist",isAttr:!0,type:"Boolean",default:!0},{name:"executionListener",isAbstract:!0,type:"Expression"}]},{name:"EscalationEventDefinition",isAbstract:!0,extends:["bpmn:EscalationEventDefinition"],properties:[{name:"escalationCodeVariable",isAttr:!0,type:"String"}]},{name:"FormalExpression",isAbstract:!0,extends:["bpmn:FormalExpression"],properties:[{name:"resource",isAttr:!0,type:"String"}]},{name:"multiinstance_type",superClass:["Element"]},{name:"multiinstance_condition",superClass:["Element"]},{name:"Assignable",extends:["bpmn:Task","bpmn:UserTask"],properties:[{name:"flow:ccTask",isAttr:!0,type:"String"},{name:"assignee",isAttr:!0,type:"String"},{name:"candidateUsers",isAttr:!0,type:"String"},{name:"candidateGroups",isAttr:!0,type:"String"},{name:"dueDate",isAttr:!0,type:"String"},{name:"followUpDate",isAttr:!0,type:"String"},{name:"priority",isAttr:!0,type:"String"},{name:"multiinstance_condition",isAttr:!0,type:"String"},{name:"rollbackNode",isAttr:!0,type:"String"},{name:"assigneeRetain",isAttr:!0,type:"String"}]},{name:"CallActivity",extends:["bpmn:CallActivity"],properties:[{name:"calledElementBinding",isAttr:!0,type:"String",default:"latest"},{name:"calledElementVersion",isAttr:!0,type:"String"},{name:"calledElementVersionTag",isAttr:!0,type:"String"},{name:"calledElementTenantId",isAttr:!0,type:"String"},{name:"caseRef",isAttr:!0,type:"String"},{name:"caseBinding",isAttr:!0,type:"String",default:"latest"},{name:"caseVersion",isAttr:!0,type:"String"},{name:"caseTenantId",isAttr:!0,type:"String"},{name:"variableMappingClass",isAttr:!0,type:"String"},{name:"variableMappingDelegateExpression",isAttr:!0,type:"String"},{name:"calledElementType",isAttr:!0,type:"String"},{name:"inheritVariables",isAttr:!0,type:"String"},{name:"sameDeployment",isAttr:!0,type:"String"}]},{name:"ServiceTaskLike",extends:["bpmn:ServiceTask","bpmn:BusinessRuleTask","bpmn:SendTask","bpmn:MessageEventDefinition"],properties:[{name:"expression",isAttr:!0,type:"String"},{name:"class",isAttr:!0,type:"String"},{name:"delegateExpression",isAttr:!0,type:"String"},{name:"resultVariable",isAttr:!0,type:"String"}]},{name:"DmnCapable",extends:["bpmn:BusinessRuleTask"],properties:[{name:"decisionRef",isAttr:!0,type:"String"},{name:"decisionRefBinding",isAttr:!0,type:"String",default:"latest"},{name:"decisionRefVersion",isAttr:!0,type:"String"},{name:"mapDecisionResult",isAttr:!0,type:"String",default:"resultList"},{name:"decisionRefTenantId",isAttr:!0,type:"String"}]},{name:"ExternalCapable",extends:["flowable:ServiceTaskLike"],properties:[{name:"type",isAttr:!0,type:"String"},{name:"topic",isAttr:!0,type:"String"}]},{name:"TaskPriorized",extends:["bpmn:Process","flowable:ExternalCapable"],properties:[{name:"taskPriority",isAttr:!0,type:"String"}]},{name:"Properties",superClass:["Element"],meta:{allowedIn:["*"]},properties:[{name:"values",type:"Property",isMany:!0}]},{name:"Property",superClass:["Element"],properties:[{name:"id",type:"String",isAttr:!0},{name:"name",type:"String",isAttr:!0},{name:"value",type:"String",isAttr:!0}]},{name:"Connector",superClass:["Element"],meta:{allowedIn:["flowable:ServiceTaskLike"]},properties:[{name:"inputOutput",type:"InputOutput"},{name:"connectorId",type:"String"}]},{name:"InputOutput",superClass:["Element"],meta:{allowedIn:["bpmn:FlowNode","flowable:Connector"]},properties:[{name:"inputOutput",type:"InputOutput"},{name:"connectorId",type:"String"},{name:"inputParameters",isMany:!0,type:"InputParameter"},{name:"outputParameters",isMany:!0,type:"OutputParameter"}]},{name:"InputOutputParameter",properties:[{name:"name",isAttr:!0,type:"String"},{name:"value",isBody:!0,type:"String"},{name:"definition",type:"InputOutputParameterDefinition"}]},{name:"InputOutputParameterDefinition",isAbstract:!0},{name:"List",superClass:["InputOutputParameterDefinition"],properties:[{name:"items",isMany:!0,type:"InputOutputParameterDefinition"}]},{name:"Map",superClass:["InputOutputParameterDefinition"],properties:[{name:"entries",isMany:!0,type:"Entry"}]},{name:"Entry",properties:[{name:"key",isAttr:!0,type:"String"},{name:"value",isBody:!0,type:"String"},{name:"definition",type:"InputOutputParameterDefinition"}]},{name:"Value",superClass:["InputOutputParameterDefinition"],properties:[{name:"id",isAttr:!0,type:"String"},{name:"name",isAttr:!0,type:"String"},{name:"value",isBody:!0,type:"String"}]},{name:"Script",superClass:["InputOutputParameterDefinition"],properties:[{name:"scriptFormat",isAttr:!0,type:"String"},{name:"resource",isAttr:!0,type:"String"},{name:"value",isBody:!0,type:"String"}]},{name:"Field",superClass:["Element"],meta:{allowedIn:["flowable:ServiceTaskLike","flowable:ExecutionListener","flowable:TaskListener"]},properties:[{name:"name",isAttr:!0,type:"String"},{name:"expression",type:"String"},{name:"stringValue",isAttr:!0,type:"String"},{name:"string",type:"String"}]},{name:"InputParameter",superClass:["InputOutputParameter"]},{name:"OutputParameter",superClass:["InputOutputParameter"]},{name:"Collectable",isAbstract:!0,extends:["bpmn:MultiInstanceLoopCharacteristics"],superClass:["flowable:AsyncCapable"],properties:[{name:"collection",isAttr:!0,type:"String"},{name:"elementVariable",isAttr:!0,type:"String"}]},{name:"FailedJobRetryTimeCycle",superClass:["Element"],meta:{allowedIn:["flowable:AsyncCapable","bpmn:MultiInstanceLoopCharacteristics"]},properties:[{name:"body",isBody:!0,type:"String"}]},{name:"ExecutionListener",superClass:["Element"],meta:{allowedIn:["bpmn:Task","bpmn:ServiceTask","bpmn:UserTask","bpmn:BusinessRuleTask","bpmn:ScriptTask","bpmn:ReceiveTask","bpmn:ManualTask","bpmn:ExclusiveGateway","bpmn:SequenceFlow","bpmn:ParallelGateway","bpmn:InclusiveGateway","bpmn:EventBasedGateway","bpmn:StartEvent","bpmn:IntermediateCatchEvent","bpmn:IntermediateThrowEvent","bpmn:EndEvent","bpmn:BoundaryEvent","bpmn:CallActivity","bpmn:SubProcess","bpmn:Process"]},properties:[{name:"expression",isAttr:!0,type:"String"},{name:"class",isAttr:!0,type:"String"},{name:"delegateExpression",isAttr:!0,type:"String"},{name:"event",isAttr:!0,type:"String"},{name:"script",type:"Script"},{name:"fields",type:"Field",isMany:!0}]},{name:"TaskListener",superClass:["Element"],meta:{allowedIn:["bpmn:UserTask"]},properties:[{name:"expression",isAttr:!0,type:"String"},{name:"class",isAttr:!0,type:"String"},{name:"delegateExpression",isAttr:!0,type:"String"},{name:"event",isAttr:!0,type:"String"},{name:"script",type:"Script"},{name:"fields",type:"Field",isMany:!0}]},{name:"ExtendedProperty",superClass:["Element"],meta:{allowedIn:["bpmn:UserTask"]},properties:[{name:"name",isAttr:!0,type:"String"},{name:"value",isAttr:!0,type:"String"},{name:"remark",isAttr:!0,type:"String"}]},{name:"FormProperty",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent","bpmn:UserTask"]},properties:[{name:"id",type:"String",isAttr:!0},{name:"name",type:"String",isAttr:!0},{name:"type",type:"String",isAttr:!0},{name:"required",type:"String",isAttr:!0},{name:"readable",type:"String",isAttr:!0},{name:"writable",type:"String",isAttr:!0},{name:"variable",type:"String",isAttr:!0},{name:"expression",type:"String",isAttr:!0},{name:"datePattern",type:"String",isAttr:!0},{name:"default",type:"String",isAttr:!0},{name:"values",type:"Value",isMany:!0}]},{name:"FormProp",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent","bpmn:UserTask"]},properties:[{name:"id",type:"String",isAttr:!0},{name:"name",type:"String",isAttr:!0},{name:"type",type:"String",isAttr:!0},{name:"required",type:"String",isAttr:!0},{name:"readable",type:"String",isAttr:!0},{name:"writable",type:"String",isAttr:!0},{name:"variable",type:"String",isAttr:!0},{name:"expression",type:"String",isAttr:!0},{name:"datePattern",type:"String",isAttr:!0},{name:"default",type:"String",isAttr:!0},{name:"values",type:"Value",isMany:!0}]},{name:"Button",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent","bpmn:UserTask"]},properties:[{name:"label",type:"String",isAttr:!0},{name:"prop",type:"String",isAttr:!0},{name:"display",type:"String",isAttr:!0}]},{name:"FormData",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent","bpmn:UserTask"]},properties:[{name:"fields",type:"FormField",isMany:!0},{name:"businessKey",type:"String",isAttr:!0}]},{name:"FormField",superClass:["Element"],properties:[{name:"id",type:"String",isAttr:!0},{name:"label",type:"String",isAttr:!0},{name:"type",type:"String",isAttr:!0},{name:"datePattern",type:"String",isAttr:!0},{name:"defaultValue",type:"String",isAttr:!0},{name:"properties",type:"Properties"},{name:"validation",type:"Validation"},{name:"values",type:"Value",isMany:!0}]},{name:"Validation",superClass:["Element"],properties:[{name:"constraints",type:"Constraint",isMany:!0}]},{name:"Constraint",superClass:["Element"],properties:[{name:"name",type:"String",isAttr:!0},{name:"config",type:"String",isAttr:!0}]},{name:"ConditionalEventDefinition",isAbstract:!0,extends:["bpmn:ConditionalEventDefinition"],properties:[{name:"variableName",isAttr:!0,type:"String"},{name:"variableEvent",isAttr:!0,type:"String"}]},{name:"Serial",superClass:["Element"],meta:{allowedIn:["bpmn:Process"]},properties:[{name:"name",isAttr:!0,type:"String"},{name:"prefix",isAttr:!0,type:"String"},{name:"dateFormat",isAttr:!0,type:"String"},{name:"suffixLength",isAttr:!0,type:"Number"},{name:"startSequence",isAttr:!0,type:"Number"},{name:"connector",isAttr:!0,type:"String"},{name:"cycle",isAttr:!0,type:"String"},{name:"useExistSN",isAttr:!0,type:"Boolean"}]},{name:"Assignee",superClass:["Element"],meta:{allowedIn:["bpmn:UserTask"]},properties:[{name:"type",type:"String",isAttr:!0},{name:"value",type:"String",isAttr:!0},{name:"text",type:"String",isAttr:!0}]},{name:"HideCopy",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent"]},properties:[{name:"value",type:"String",isAttr:!0}]},{name:"HideExamine",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent"]},properties:[{name:"value",type:"String",isAttr:!0}]},{name:"HideAttachment",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent"]},properties:[{name:"value",type:"String",isAttr:!0}]},{name:"ExFormKey",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent"]},properties:[{name:"value",type:"String",isAttr:!0}]},{name:"ExFormUrl",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent"]},properties:[{name:"value",type:"String",isAttr:!0}]},{name:"ExAppFormUrl",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent"]},properties:[{name:"value",type:"String",isAttr:!0}]},{name:"IndepFormKey",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent"]},properties:[{name:"value",type:"String",isAttr:!0}]},{name:"IndepFormSummary",superClass:["Element"],meta:{allowedIn:["bpmn:StartEvent"]},properties:[{name:"value",type:"String",isAttr:!0}]},{name:"AssigneeRetain",superClass:["Element"],meta:{allowedIn:["bpmn:SubProcess","bpmn:CallActivity"]},properties:[{name:"value",type:"String",isAttr:!0}]},{name:"CopyUser",superClass:["Element"],meta:{allowedIn:["bpmn:UserTask","bpmn:StartEvent"]},properties:[{name:"value",type:"String",isAttr:!0},{name:"text",type:"String",isAttr:!0}]},{name:"ExamineSupported",isAbstract:!0,extends:["bpmn:StartEvent","bpmn:UserTask"],properties:[{name:"hideCopy",isAttr:!0,type:"String"},{name:"hideExamine",isAttr:!0,type:"String"},{name:"hideAttachment",isAttr:!0,type:"String"}]}],emumerations:[]},eo={name:"@ui-ddy-process/design",version:"1.6.27",author:"ssc <273702440@qq.com>",type:"module",description:"ddy process design",main:"lib/nf-design-elp.js",files:["lib"],publishConfig:{access:"public",registry:"https://registry.npmjs.org/"},engines:{node:"^18.0.0 || >=20.0.0"},scripts:{build:"vite build",dev:"vite --host",lib:"vite build --mode lib",prettier:"prettier ./packages/**/*.vue --write"},dependencies:{"bpmn-js":"^18.6.2","bpmn-js-create-append-anything":"^1.0.0",bpmnlint:"^11.4.4",randomcolor:"^0.6.2","tiny-svg":"^4.1.4"},devDependencies:{"@nutflow/nf-form-elp":"^1.5.6","@so1ve/prettier-config":"^3.1.0","@vitejs/plugin-vue":"^5.2.4",axios:"^1.10.0","element-plus":"^2.10.2",prettier:"^3.5.3","rollup-plugin-visualizer":"^5.14.0",sass:"^1.89.2",vite:"^5.4.18","vite-plugin-remove-console":"^2.2.0","vite-plugin-static-copy":"^1.0.6",vue:"^3.5.16"}},cR={name:"nf-design",components:{NfToolbar:sh,NfPanel:nm},props:{options:{type:Object,default:()=>({})},storage:{type:Boolean,default:!1},accessKey:String},computed:{isEditMode(){return this.option.mode!="view"}},watch:{options:{handler(e){this.$nextTick(()=>{if(this.debounce){if(this.debounce=!1,this.storage){const t=localStorage[eo.name];t?this.option=JSON.parse(t):this.option=JSON.parse(JSON.stringify({...Pl,...e}))}else this.option=JSON.parse(JSON.stringify({...Pl,...e})),delete localStorage[eo.name];this.init(!0),setTimeout(()=>{this.debounce=!0},1e3)}})},deep:!0,immediate:!0}},data(){return{option:{},activeTab:"process",modeler:null,zoom:1,previewXML:"",previewVisible:!1,importXML:"",importVisible:!1,debounce:!0}},methods:{INIT_XML:Ka,init(e=!1){this.storage&&(localStorage[eo.name]=JSON.stringify(this.option)),e&&(this.isEditMode?this.initModeler():this.initViewer())},async initModeler(){this.modeler&&this.modeler.destroy(),this.modeler=s.markRaw(new Ba({container:this.$refs.modeler,additionalModules:[jz,this.$nfDesign.lang=="zh"?{translate:["value",gu]}:"",this.option.simulation?ez:"",this.option.minimap?Xu:"",this.option.lint?SY:""],linting:{bpmnlint:k6,active:this.isEditMode},moddleExtensions:{flowable:aR}})),await this.createNewDiagram(this.option.xml||Ka(this.option.process)),this.storage&&this.modeler.on("element.changed",()=>{this.getData("xml",!1,!1).then(e=>{this.option.xml=e,localStorage[eo.name]=JSON.stringify(this.option)})})},async initViewer(){this.modeler&&this.modeler.destroy(),this.modeler=s.markRaw(new et({container:this.$refs.modeler,additionalModules:[{translate:["value",gu]},yd,this.option.simulation?tz:"",this.option.minimap?Xu:"",Hc,jc]})),await this.createNewDiagram(this.option.xml||Ka(this.option.process)),this.option.flows&&this.option.flows.length>0&&this.setNodeColor(this.option.flows)},setNodeColor(e){const t=this.modeler.get("canvas"),n=this.modeler.get("elementRegistry"),A=this.modeler.get("tooltips");e.forEach(i=>{if(i.id&&i.class&&t.addMarker(i.id,i.class),i.id&&i.tooltip){const o=n.get(i.id);if(o){let{x:r,y:a,type:c}=o;["bpmn:StartEvent","bpmn:EndEvent"].includes(c)?(r=r-45,a=a+65):["bpmn:UserTask"].includes(c)&&(r=r-10,a=a+90),A.add({position:{x:r,y:a},html:i.tooltip})}}})},async createNewDiagram(e,t=!1){try{e=e.replace(/camunda:/g,"flowable:"),e=e.replace(/activiti:/g,"flowable:"),await this.modeler.importXML(e),this.isEditMode?this.fitViewport("init"):this.fitViewport("auto"),t&&this.$refs.panel.handleInitNodes(!0)}catch(n){console.error(n)}},fitViewport(e){const t=this.modeler.get("canvas");typeof e=="string"?e=="init"?t.zoom("fit-viewport"):e=="auto"&&t.zoom("fit-viewport","auto"):(this.zoom+=e?.1:-.1,t.zoom(this.zoom))},async getData(e,t=!1,n=!0,A=!0){if(n){const i=document.querySelector(".bjsl-button-error .label"),o=i==null?null:i.innerHTML;if(o&&!o.includes("0 错误")&&!o.includes("0 Errors"))throw this.$message.error("模型存在错误,请处理"),new Error("模型存在错误,请处理")}if(e=="xml")try{let{xml:i}=await this.modeler.saveXML({format:A});return this.option.engine!="flowable"&&(i=i.replace(/flowable:/g,this.option.engine+":")),t&&this.downloadFile(`${this.modeler.getDefinitions().rootElements[0].name}.bpmn20.xml`,i,"application/xml"),i}catch{}else try{const{svg:i}=await this.modeler.saveSVG({format:A});return t&&this.downloadFile(this.modeler.getDefinitions().rootElements[0].name,i,"image/svg+xml"),i}catch{}},downloadFile(e,t,n){let A=document.createElement("a"),i=window.URL.createObjectURL(new Blob([t],{type:n}));A.href=i,A.download=e,A.click(),window.URL.revokeObjectURL(i)},async handlePreview(e){const t=await this.getData("xml");e=="preview"?(this.previewXML=t,this.previewVisible=!0):e=="get"&&this.$emit("get",t)},handleImport(){this.option.exForm&&(delete this.option.exForm.column,delete this.option.exForm.exFormKey,delete this.option.exForm.exFormUrl,delete this.option.exForm.exAppFormUrl),this.createNewDiagram(this.importXML,!0),this.importVisible=!1},getElementRegistry(){const e=this.modeler.get("elementRegistry").getAll();return e.length==0?[]:(e[0].type!="bpmn:Process"&&e.unshift({businessObject:this.modeler.getDefinitions().rootElements.find(t=>t.$type=="bpmn:Process")}),{getAll(){return e}})}}},sR={class:"nf-design"},lR={class:"modeler",ref:"modeler"},BR={class:"nf-drawer__foot"};function gR(e,t,n,A,i,o){const r=s.resolveComponent("nf-toolbar"),a=s.resolveComponent("el-header"),c=s.resolveComponent("el-main"),l=s.resolveComponent("el-container"),B=s.resolveComponent("nf-panel"),g=s.resolveComponent("el-aside"),p=s.resolveComponent("nf-codemirror"),E=s.resolveComponent("el-drawer"),d=s.resolveComponent("el-button");return s.openBlock(),s.createElementBlock("div",sR,[s.createVNode(l,null,{default:s.withCtx(()=>[s.createVNode(l,null,{default:s.withCtx(()=>[s.withDirectives(s.createVNode(a,null,{default:s.withCtx(()=>[s.createVNode(r,{toolbar:i.option.toolbar,onOpen:t[0]||(t[0]=u=>o.createNewDiagram(u,!0)),onCreate:t[1]||(t[1]=u=>o.createNewDiagram(o.INIT_XML(),!0)),onFit:o.fitViewport,onUndo:t[2]||(t[2]=u=>i.modeler.get("commandStack").undo()),onRedo:t[3]||(t[3]=u=>i.modeler.get("commandStack").redo()),onDownload:o.getData,onImport:t[4]||(t[4]=u=>i.importVisible=!0),onPreview:o.handlePreview},{toolbar:s.withCtx(()=>[s.renderSlot(e.$slots,"toolbar")]),_:3},8,["toolbar","onFit","onDownload","onPreview"])]),_:3},512),[[s.vShow,o.isEditMode&&i.option.toolbar&&i.option.toolbar.length>0]]),s.createVNode(c,null,{default:s.withCtx(()=>[s.createElementVNode("div",lR,null,512)]),_:1})]),_:3}),o.isEditMode?(s.openBlock(),s.createBlock(g,{key:0,width:"380px"},{default:s.withCtx(()=>[i.modeler?(s.openBlock(),s.createBlock(B,{key:0,ref:"panel",modeler:i.modeler,"auto-init":i.option.autoInit,"form-option":i.option.form,"ex-form-option":i.option.exForm,"indep-form-option":i.option.indepForm,"user-option":i.option.user,"group-option":i.option.group,"button-option":i.option.button,"script-option":i.option.script,"condition-option":i.option.condition,"listener-option":i.option.listener,"extended-properties-option":i.option.extendedProperty},null,8,["modeler","auto-init","form-option","ex-form-option","indep-form-option","user-option","group-option","button-option","script-option","condition-option","listener-option","extended-properties-option"])):s.createCommentVNode("",!0)]),_:1})):s.createCommentVNode("",!0)]),_:3}),s.createVNode(E,{title:"查看",modelValue:i.previewVisible,"onUpdate:modelValue":t[6]||(t[6]=u=>i.previewVisible=u),"append-to-body":"","destroy-on-close":"",class:"nf-drawer",size:"60%"},{default:s.withCtx(()=>[s.createVNode(p,{modelValue:i.previewXML,"onUpdate:modelValue":t[5]||(t[5]=u=>i.previewXML=u),language:"xml"},null,8,["modelValue"])]),_:1},8,["modelValue"]),s.createVNode(E,{title:"导入",modelValue:i.importVisible,"onUpdate:modelValue":t[9]||(t[9]=u=>i.importVisible=u),"append-to-body":"","destroy-on-close":"",class:"nf-drawer",size:"60%"},{default:s.withCtx(()=>[s.createVNode(p,{modelValue:i.importXML,"onUpdate:modelValue":t[7]||(t[7]=u=>i.importXML=u),language:"xml",style:{height:"94%"}},null,8,["modelValue"]),s.createElementVNode("div",BR,[s.createVNode(d,{type:"primary",size:"default",onClick:o.handleImport},{default:s.withCtx(()=>t[10]||(t[10]=[s.createTextVNode(" 确定 ")])),_:1,__:[10]},8,["onClick"]),s.createVNode(d,{type:"danger",size:"default",onClick:t[8]||(t[8]=u=>i.importVisible=!1)},{default:s.withCtx(()=>t[11]||(t[11]=[s.createTextVNode(" 取消 ")])),_:1,__:[11]})])]),_:1},8,["modelValue"])])}const pR=F0(cR,[["render",gR]]),ZQ=(e,t={})=>{Vl.use(t.locale),Vl.i18n(t.i18n),e.config.globalProperties.$axios=t.axios||window.axios;let n="zh";t.locale&&(n=t.locale.nf.lang),e.config.globalProperties.$nfDesign={...t,lang:n},e.component("nf-design",pR)};return typeof window<"u"&&window.Vue&&ZQ(window.Vue),{author:"ssc",email:"273702440@qq.com",version:eo.version,install:ZQ}});
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ui-ddy-process/design",
3
- "version": "1.6.25",
3
+ "version": "1.6.27",
4
4
  "author": "ssc <273702440@qq.com>",
5
5
  "type": "module",
6
6
  "description": "ddy process design",