(this.webpackJsonpstreamlit_component_template=this.webpackJsonpstreamlit_component_template||[]).push([[0],{64:function(t,e,r){t.exports=r(65)},65:function(t,e,r){"use strict";r.r(e);var a=r(17),n=r(10);null==document.getElementById("diag")?document.body.appendChild(document.createElement("div")).setAttribute("id","diag"):document.getElementById("diag").innerHTML="";var o=20,d=30,i=20,s=30,l=1200-s-d,c=400-o-i;a.a.events.addEventListener(a.a.RENDER_EVENT,(function(t){var e;n.b("svg").remove();var r=n.b("#diag").append("svg").attr("width",l+s+d).attr("height",c+o+i).style("background-color","white").append("g").attr("transform","translate("+s+","+o+")"),u=t.detail,m=u.args.data,g=u.args.key,p=75*m.words.length;document.body.appendChild(document.createElement("div")).setAttribute("id","diag");var f=m.words.map((function(t){return t.id}));null===(e=document.getElementById("diag"))||void 0===e||e.setAttribute("id","".concat(g));var b=n.a().range([0,p]).domain(f),h=r.selectAll("mynodes").data(m.words).enter().append("circle").attr("cx",(function(t){var e=b(t.id);return void 0===e?null:e})).attr("cy",c-30).attr("r",10).style("fill","#69b3a2");r.selectAll("mylabels").data(m.words).enter().append("text").attr("x",(function(t){var e=b(t.id);return void 0===e?null:e})).attr("y",c-5).text((function(t){return t.text})).style("text-anchor","middle"),r.selectAll("mylabels").data(m.words).enter().append("text").attr("x",(function(t){var e=b(t.id);return void 0===e?null:e})).attr("y",c+15).text((function(t){return t.tag})).style("text-anchor","middle"),r.append("svg:defs").selectAll("marker").data(m.arcs).enter().append("svg:marker").attr("id",(function(t){return t.start.toString()+t.end.toString()})).attr("viewBox","0 -5 10 10").attr("refX",8).attr("refY",0).attr("markerWidth",10).attr("markerHeight",10).attr("orient","auto-start-reverse").append("svg:path").attr("d","M0,-5L10,0L0,5").attr("class","color_change_marker"),r.selectAll("mylinks").data(m.arcs).join("path").attr("id",(function(t){return void 0===t?"":t.start.toString()+"_"+t.end.toString()})).attr("d",(function(t){var e=b(m.words[t.start].id),r=b(m.words[t.end].id);return void 0===e&&(e=0),void 0===r&&(r=0),["M",e<r?e:r,c-30,"A",e<r?(e-r)/2:(r-e)/2,e<r?(e-r)/2:(r-e)/2,0,0,1,e<r?r:e,",",c-30].join(" ")})).style("fill","none").attr("stroke","black").attr("stroke-width",1).attr("class","color_change_path").attr("marker-end",(function(t){return"right"===t.dir?"url(#"+t.start.toString()+t.end.toString()+")":"none"})).attr("marker-start",(function(t){return"left"===t.dir?"url(#"+t.start.toString()+t.end.toString()+")":"none"})),r.selectAll("myText_labels").data(m.arcs).enter().append("text").attr("dy",-5).append("textPath").attr("xlink:href",(function(t){return void 0===t?"":"#"+t.start.toString()+"_"+t.end.toString()})).attr("text-anchor","middle").attr("startOffset","50%").attr("class","dep").text((function(t){return t.label})),h.on("mouseout",(function(t,e){h.style("fill","#69b3a2"),n.c(".color_change_path").style("stroke","black").style("stroke-width",1),n.c(".color_change_marker").style("fill","black")})).on("mouseover",(function(t,e){h.style("fill","#b8b8b8"),n.c(".color_change_path").style("stroke",(function(t){return m.words[t.start]===e||m.words[t.end]===e?"#69b3b2":"#b8b8b8"})).style("stroke-width",(function(t){return m.words[t.start]===e||m.words[t.end]===e?2:1})),n.c(".color_change_marker").style("fill",(function(t){return m.words[t.start]===e||m.words[t.end]===e?"#69b3b2":"#b8b8b8"}))}));var v=n.d().scaleExtent([.2,100]).on("zoom",(function(t){n.b("svg g").attr("transform",t.transform)}));n.b("svg").call(v),a.a.setFrameHeight()})),a.a.setComponentReady(),a.a.setFrameHeight()}},[[64,1,2]]]);
//# sourceMappingURL=main.ce3bc050.chunk.js.map