/*! JointJS v3.1.1 (2019-10-28) - JavaScript diagramming library
This Source Code Form is subject to the terms of the Mozilla Public
License, v. 2.0. If a copy of the MPL was not distributed with this
file, You can obtain one at http://mozilla.org/MPL/2.0/.
*/
this.joint=this.joint||{},this.joint.shapes=this.joint.shapes||{},function(t,e,r,a,s){"use strict";a=a&&a.hasOwnProperty("default")?a.default:a;var n=e.Generic.define("pn.Place",{size:{width:50,height:50},attrs:{".root":{r:25,fill:"#ffffff",stroke:"#000000",transform:"translate(25, 25)"},".label":{"text-anchor":"middle","ref-x":.5,"ref-y":-20,ref:".root",fill:"#000000","font-size":12},".tokens > circle":{fill:"#000000",r:5},".tokens.one > circle":{transform:"translate(25, 25)"},".tokens.two > circle:nth-child(1)":{transform:"translate(19, 25)"},".tokens.two > circle:nth-child(2)":{transform:"translate(31, 25)"},".tokens.three > circle:nth-child(1)":{transform:"translate(18, 29)"},".tokens.three > circle:nth-child(2)":{transform:"translate(25, 19)"},".tokens.three > circle:nth-child(3)":{transform:"translate(32, 29)"},".tokens.alot > text":{transform:"translate(25, 18)","text-anchor":"middle",fill:"#000000"}}},{markup:''}),i=r.ElementView.extend({presentationAttributes:r.ElementView.addPresentationAttributes({tokens:["TOKENS"]}),initFlag:r.ElementView.prototype.initFlag.concat(["TOKENS"]),confirmUpdate:function(){for(var t,e=[],a=arguments.length;a--;)e[a]=arguments[a];var s=(t=r.ElementView.prototype.confirmUpdate).call.apply(t,[this].concat(e));return this.hasFlag(s,"TOKENS")&&(this.renderTokens(),this.update(),s=this.removeFlag(s,"TOKENS")),s},renderTokens:function(){var e=this.vel.findOne(".tokens").empty();["one","two","three","alot"].forEach(function(t){e.removeClass(t)});var t=this.model.get("tokens");if(t)switch(t){case 1:e.addClass("one"),e.append(a("circle"));break;case 2:e.addClass("two"),e.append([a("circle"),a("circle")]);break;case 3:e.addClass("three"),e.append([a("circle"),a("circle"),a("circle")]);break;default:e.addClass("alot"),e.append(a("text").text(t+""))}}}),l=e.Generic.define("pn.Transition",{size:{width:12,height:50},attrs:{rect:{width:12,height:50,fill:"#000000",stroke:"#000000"},".label":{"text-anchor":"middle","ref-x":.5,"ref-y":-20,ref:"rect",fill:"#000000","font-size":12}}},{markup:''}),o=s.Link.define("pn.Link",{attrs:{".marker-target":{d:"M 10 0 L 0 5 L 10 10 z"}}});t.Link=o,t.Place=n,t.PlaceView=i,t.Transition=l}(this.joint.shapes.pn=this.joint.shapes.pn||{},joint.shapes.basic,joint.dia,V,joint.dia);