(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-b25e7750"],{"01e1":function(t,e,i){"use strict";var s=i("3f15"),a=i("d2a4"),o=i("30eb"),n=i("959f"),r=TypeError,l="Reduce of empty array with no initial value",h=function(t){return function(e,i,h,d){var c=a(e),u=o(c),p=n(c);if(s(i),0===p&&h<2)throw new r(l);var m=t?p-1:0,g=t?-1:1;if(h<2)while(1){if(m in u){d=u[m],m+=g;break}if(m+=g,t?m<0:p<=m)throw new r(l)}for(;t?m>=0:p>m;m+=g)m in u&&(d=i(d,u[m],m,c));return d}};t.exports={left:h(!1),right:h(!0)}},"02ee":function(t,e,i){"use strict";i("a625")},"0354":function(t,e,i){"use strict";i("d1a8")},"0586":function(t,e,i){"use strict";i("a0a2")},"08a9":function(t,e,i){"use strict";var s=i("ef37"),a=i("0ddb"),o=i("44bb"),n=i("3b71"),r=URLSearchParams,l=r.prototype,h=a(l.append),d=a(l["delete"]),c=a(l.forEach),u=a([].push),p=new r("a=1&a=2&b=3");p["delete"]("a",1),p["delete"]("b",void 0),p+""!=="a=2"&&s(l,"delete",(function(t){var e=arguments.length,i=e<2?void 0:arguments[1];if(e&&void 0===i)return d(this,t);var s=[];c(this,(function(t,e){u(s,{key:e,value:t})})),n(e,1);var a,r=o(t),l=o(i),p=0,m=0,g=!1,f=s.length;while(p{this.myChart.resize()},600)},navForm:{deep:!0,handler(t){this.getData()}}},data(){return{radio:"数量",topDays:[],newNumber:0,myChart:"",option:""}},mounted(){this.role=localStorage.getItem("role"),window.addEventListener("resize",()=>{this.myChart&&setTimeout(()=>{this.myChart.resize()},500)})},methods:{getData(){this.instance({method:"post",url:"/large/data/screen/getCloseCaseTime",data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(1==t.data.code){let e=t.data.data;this.loadCharts(e)}})},loadCharts(t){var e=document.getElementById("lawsuit_times_pie");if(!e)return;this.myChart&&this.myChart.dispose(),this.myChart=o["init"](e,null,{renderer:"svg"});let i=[];t.forEach((t,e)=>{let s={value:t.caseNum,name:t.name};i.push(s)}),this.option={tooltip:{trigger:"item",formatter:"{b}: {c}件",confine:!0},legend:{right:"5%",top:"middle",orient:"vertical",itemWidth:12,itemHeight:12,textStyle:{color:"#fff",fontSize:"0.12rem"}},series:[{type:"pie",radius:"70%",center:["40%","50%"],avoidLabelOverlap:!1,label:{position:"inner",fontSize:10,color:"#fff",formatter:"{d}%"},labelLine:{show:!1},data:i}]},this.myChart.setOption(this.option)}}},r=n,l=(i("e27e"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"e6fd6d04",null);e["default"]=h.exports},1403:function(t,e,i){},"14f5":function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],staticClass:"module_wrap box_border",attrs:{"element-loading-text":"数据加载中","element-loading-spinner":"el-icon-loading","element-loading-background":"transparent"}},[t._m(0),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.loading,expression:"!loading"}],staticStyle:{height:"100%"}},[e("div",{attrs:{id:"depletion_sum_pie"}})])])},a=[function(){var t=this,e=t._self._c;return e("div",{staticClass:"box_title"},[e("span",[t._v("估损偏差率统计")])])}],o=(i("0faf"),i("b3ec"),i("6fc2"),i("ada4")),n={name:"DepletionSum",props:{isCollapse:{type:Boolean,default:!0},navForm:{type:Object,default:{}}},watch:{isCollapse(){setTimeout(()=>{this.myChart&&this.myChart.resize()},600)},navForm:{deep:!0,handler(t){this.getData()}}},data(){return{topDays:[],newNumber:0,option:"",myChart:"",loading:!0}},mounted(){this.role=localStorage.getItem("role"),window.addEventListener("resize",()=>{this.myChart&&setTimeout(()=>{this.myChart.resize()},500)})},methods:{getData(){this.loading=!0,this.instance({method:"post",url:"/large/data/screen/getMoneyLossEstimation",data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(this.loading=!1,1==t.data.code){let e=t.data.data;this.loadCharts(e)}})},loadCharts(t){var e=this.$store.getters.baseURL;e=e.replace(/manager/,"");var i=document.getElementById("depletion_sum_pie");if(!i)return;this.myChart&&this.myChart.dispose(),this.myChart=o["init"](i,null,{renderer:"svg"});let s=[],a=[];t.forEach((t,e)=>{s.push(t.name),a.push(t.caseNumRatio)}),this.option={tooltip:{trigger:"axis",formatter:"{b}: {c}万元"},color:"#cd6e72",xAxis:{type:"category",boundaryGap:!1,axisLabel:{showMaxLabel:!0,textStyle:{color:"#fff"}},splitLine:{show:!1},axisTick:{},axisLine:{onZero:!1},offset:5,data:s},yAxis:{type:"value",axisLabel:{showMaxLabel:!0,formatter:"{value} 万",textStyle:{color:"#fff"}},splitLine:{show:!1},axisLine:{show:!1},axisTick:{show:!1}},grid:{left:"2%",right:"4%",top:"5%",bottom:"10%",containLabel:!0},series:[{data:a,type:"line",smooth:!0,symbol:"image://"+e+"images/money_icon.png",symbolSize:20}]},this.myChart.setOption(this.option)}},updated(){this.myChart&&this.myChart.resize()}},r=n,l=(i("b1f9"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"adc5ed56",null);e["default"]=h.exports},1870:function(t,e,i){},"18dd":function(t,e,i){"use strict";var s=function(){var t=this,e=t._self._c;return e("div",{ref:"imgCont",staticClass:"imgCont",on:{mousewheel:function(e){return e.preventDefault(),t.rollImg(e)}}},[e("div",{staticClass:"iconBtn"},[e("span",{staticClass:"refreshBtn"},[e("i",{staticClass:"el-icon-zoom-out",on:{click:function(e){return e.stopPropagation(),t.outImg("out")}}}),e("i",{staticClass:"el-icon-zoom-in",on:{click:function(e){return e.stopPropagation(),t.outImg("in")}}}),e("i",{staticClass:"el-icon-refresh-left",on:{click:function(e){return e.stopPropagation(),t.rotate("left")}}}),e("i",{staticClass:"el-icon-refresh-right right",on:{click:function(e){return e.stopPropagation(),t.rotate("right")}}}),t._t("addIcon"),t.showHandworkFlag?e("i",{class:["markerTag","el-icon-success","preview-handwork-flag",{activeTag:t.handworkFlag,inactiveTag:!t.handworkFlag}],attrs:{title:t.handworkFlag?"已人工确认":"标记为已人工确认"},on:{click:function(e){return e.stopPropagation(),t.toggleHandworkFlag.apply(null,arguments)}}}):t._e()],2)]),e("div",{ref:"imgDiv",class:{bigImage:1,"width-first-mode":t.isWidthFirstMode},attrs:{id:"imgContainer"},on:{mousedown:function(e){return e.stopPropagation(),e.preventDefault(),t.moveImg(e)}}},[e("img",{class:["img-deal__image",{"img-deal__image--width-first":t.isWidthFirstMode}],attrs:{src:t.url},on:{error:function(e){return t.handleImageError(e)},load:t.handleImageLoad}}),e("div",{ref:"ocrFramesContainer",staticClass:"ocr-frames-container",class:{"ocr-frames-container--center":!t.isWidthFirstMode}},t._l(t.internalOcrFrames.length>0?t.internalOcrFrames:t.ocrFrames,(function(i,s){return e("el-tooltip",{key:"ocr-frame-"+s,staticClass:"ocr-frame",attrs:{content:i.text,placement:"top-start","open-delay":t.ocrTooltipOpenDelay,disabled:t.isDragging}},[e("div",{staticClass:"ocr-frame",on:{click:function(e){return t.copyCurrentOcrText(i.text,e)},mousedown:function(e){return e.stopPropagation(),e.preventDefault(),t.moveImg(e)}}})])})),1)])])},a=[],o=(i("0faf"),i("b3ec"),i("2502"),i("6fc2"),i("2130"),i("02f7"),i("2058"),i("d3d6"),i("9a69"),i("fb02"),i("2437"),i("a5d7"),i("746d"),i("08a9"),i("5966"),i("b75d"),{name:"ImgDeal",props:{url:{type:String},disableLegacyFallback:{type:Boolean,default:!1},imgData:{type:Object,default:null},ocrFrames:{type:Array,default:()=>[]},fitMode:{type:String,default:"contain",validator:t=>["contain","width-first"].includes(t)},widthFirstVerticalAlign:{type:String,default:"top",validator:t=>["top","bottom","auto"].includes(t)},showOcrFrames:{type:Boolean,default:!0},ocrTooltipOpenDelay:{type:Number,default:0},showHandworkFlag:{type:Boolean,default:!1},invoiceEditorMatchHighlight:{type:Boolean,default:!1}},components:{},data(){return{params:{zoomVal:1,left:0,top:0,currentX:0,currentY:0,translateX:0,translateY:0},deg:0,rotateData:-1,internalOcrFrames:[],activeChargeHighlight:null,activeTextHighlight:null,chargeMatchMap:{amount:{},project:{}},transformOrigin:null,lastDragAt:0,isDragging:!1}},computed:{entityId(){var t,e,i,s;return null!==(t=null!==(e=null===(i=this.imgData)||void 0===i?void 0:i.material_id)&&void 0!==e?e:null===(s=this.imgData)||void 0===s?void 0:s.id)&&void 0!==t?t:null},handworkFlag(){var t;const e=null===(t=this.imgData)||void 0===t?void 0:t.handwork_flag;if(!0===e)return!0;const i=Number(e);return!Number.isNaN(i)&&1===i},isWidthFirstMode(){return"width-first"===this.fitMode}},watch:{url:{handler(t){this.restImg(),t&&this.$emit("image-loading",{url:t,id:this.entityId})},immediate:!0},fitMode(){this.$nextTick(()=>{this.restImg()})},ocrFrames:{deep:!0,immediate:!0,handler(t,e){this.$nextTick(()=>{this.updateOcrFramesContainer()})}},showOcrFrames(){this.$nextTick(()=>{this.updateOcrFramesContainer()})},params:{deep:!0,handler(){this.applyTransform()}},deg:{handler(){this.applyTransform()}},imgData:{handler(t,e){t&&t!==e&&(this.updateImgUrlFromImgData(),this.restImg(),void 0===t.handwork_flag&&e&&void 0!==e.handwork_flag&&this.$set(t,"handwork_flag",e.handwork_flag)),t&&t.ocr_result?this.parseOcrResult(t.ocr_result):(this.internalOcrFrames=[],this.$nextTick(()=>{this.hideOcrFramesContainer()}))},immediate:!0,deep:!0}},created(){this.restImg()},mounted(){this.$refs.imgDiv&&this.$refs.imgDiv.complete&&this.$nextTick(()=>{this.updateOcrFramesContainer()})},beforeDestroy(){},methods:{restImg(){if(this.params={zoomVal:1,left:0,top:0,currentX:0,currentY:0,translateX:void 0,translateY:this.isWidthFirstMode?0:void 0},this.deg=0,this.$refs.imgDiv){let t=this.$refs.imgDiv;t.style.left="50%",t.style.top=this.isWidthFirstMode?"0":"50%",this.setInitialTranslateFromImage(),this.applyTransform()}},setInitialTranslateFromImage(){const t=this.$refs.imgDiv;if(!t)return;const e=t.querySelector("img");if(e&&(e.offsetWidth||e.naturalWidth)){const t=e.offsetWidth||e.naturalWidth,i=e.offsetHeight||e.naturalHeight;this.params.translateX=-t/2,this.params.translateY=this.isWidthFirstMode?this.getWidthFirstInitialTranslateY(i):-i/2,this.updateTransformOrigin(t,i)}else this.params.translateX=void 0,this.params.translateY=this.isWidthFirstMode?0:void 0,this.updateTransformOrigin()},getWidthFirstInitialTranslateY(t){var e,i;if(!this.isWidthFirstMode)return;if("top"===this.widthFirstVerticalAlign)return 0;if("auto"===this.widthFirstVerticalAlign){var s;const e=this.$refs.imgDiv,i=null===e||void 0===e||null===(s=e.querySelector)||void 0===s?void 0:s.call(e,"img"),n=(null===i||void 0===i?void 0:i.offsetWidth)||(null===i||void 0===i?void 0:i.naturalWidth)||0;if(n&&t){var a,o;if(t>n)return 0;const e=this.$refs.imgCont;if(!e)return 0;const i=null===(a=this.$el)||void 0===a||null===(o=a.querySelector)||void 0===o?void 0:o.call(a,".iconBtn"),s=null!==i&&void 0!==i&&i.offsetHeight?Number(i.offsetHeight):0,r=Math.max(0,Number(e.clientHeight||0)-s);return(r-t)/2}}if("bottom"!==this.widthFirstVerticalAlign&&"auto"!==this.widthFirstVerticalAlign)return 0;const n=this.$refs.imgCont;if(!n||!t)return 0;const r=null===(e=this.$el)||void 0===e||null===(i=e.querySelector)||void 0===i?void 0:i.call(e,".iconBtn"),l=null!==r&&void 0!==r&&r.offsetHeight?Number(r.offsetHeight):0,h=Math.max(0,Number(n.clientHeight||0)-l);return h-t},updateTransformOrigin(t,e){this.$refs.imgDiv&&(this.transformOrigin=t&&e?`${t/2}px ${e/2}px`:null,this.$refs.imgDiv.style.transformOrigin=this.transformOrigin||"50% 50%")},updateImgUrlFromImgData(){if(this.$refs.imgDiv&&this.imgData){const a=this.$refs.imgDiv.querySelector("img");if(!a)return;a.removeEventListener("load",this.handleImageLoad),a.addEventListener("load",this.handleImageLoad),delete a.dataset.originUrlAttempted,delete a.dataset.allUrlsAttempted,delete a.dataset.ossRetryAttempted;let o=null;var t,e,i,s;if(this.disableLegacyFallback)this.imgData.oss_preview_url?o=this.imgData.oss_preview_url:null!==(t=this.imgData.materialDetail)&&void 0!==t&&t.oss_preview_url?o=this.imgData.materialDetail.oss_preview_url:this.imgData.materialDetail&&Array.isArray(this.imgData.materialDetail)&&null!==(e=this.imgData.materialDetail[0])&&void 0!==e&&e.oss_preview_url&&(o=this.imgData.materialDetail[0].oss_preview_url);else this.imgData.url?o=this.imgData.url:null!==(i=this.imgData.materialDetail)&&void 0!==i&&i.url?o=this.imgData.materialDetail.url:this.imgData.materialDetail&&Array.isArray(this.imgData.materialDetail)&&null!==(s=this.imgData.materialDetail[0])&&void 0!==s&&s.url?o=this.imgData.materialDetail[0].url:this.imgData.absolutePath?o=this.imgData.absolutePath:this.imgData.file_url&&(o=this.imgData.file_url);o&&o!==a.src&&(a.src=o,this.$emit("image-loading",{url:o,id:this.entityId}))}},applyTransform(){if(this.$refs.imgDiv){let t=this.$refs.imgDiv,e=this.deg;const i=void 0!==this.params.translateX?this.params.translateX+"px":this.getDefaultTranslateValue("x"),s=void 0!==this.params.translateY?this.params.translateY+"px":this.getDefaultTranslateValue("y");t.style.transformOrigin=this.transformOrigin||"50% 50%",t.style.transform=`translate(${i}, ${s}) scale(${this.params.zoomVal}) rotate(${-e}deg)`,this.updateOcrFramesContainer()}},toggleHandworkFlag(){this.showHandworkFlag&&(this.handworkFlag||this.$emit("toggle-handwork-flag",1))},getDefaultTranslateValue(t="x"){return"y"===t&&this.isWidthFirstMode?"0":"-50%"},rollImg(t){this.params.zoomVal+=t.wheelDelta/1200,this.rollFunc()},outImg(t){"out"==t?this.params.zoomVal-=.2:this.params.zoomVal+=.2,this.rollFunc()},rollFunc(){if(!(this.params.zoomVal>=.2))return this.params.zoomVal=.2,this.applyTransform(),!1;this.applyTransform()},rotate(t){this.deg="right"==t?(this.deg-90+360)%360:(this.deg+90)%360,this.applyTransform()},getOcrFrameStyle(t,e=1){if(!t||void 0===t.left||void 0===t.top||void 0===t.width||void 0===t.height)return{};const i=t.left*e,s=t.top*e;let a=t.width*e,o=t.height*e;const n=t.text?t.text.length:0,r=10*n*e,l=25*e;a=Math.max(a,r),o=Math.max(o,l);const h=!!t.amountHighlight,d=Array.isArray(t.chargeAmountMatches)&&t.chargeAmountMatches.length>0||Array.isArray(t.chargeProjectMatches)&&t.chargeProjectMatches.length>0,c=this.isChargeFrameActive(t),u=!!t.isTarget;let p="rgb(255 255 255 / 50%)",m="dashed",g=.5;c?(p="rgba(64, 158, 255, 0.95)",m="solid",g=2):d?(p="rgba(103, 194, 58, 0.95)",m="solid",g=1.2):h?(p="rgba(255, 153, 0, 0.85)",m="solid",g=1):u&&(p="rgba(255, 77, 79, 0.7)",m="solid",g=.8);let f=i,v=s,y=a,b=o;if(c){const t=4;f=Math.max(0,f-t),v=Math.max(0,v-t),y+=2*t,b+=2*t}const w={position:"absolute",left:f+"px",top:v+"px",width:y+"px",height:b+"px",transformOrigin:"0 0",display:"flex",alignItems:"center",justifyContent:"center",fontSize:12*e+"px",border:`${g}px ${m} ${p}`,color:"#fff"};return c?(w.boxShadow="0 0 12px rgba(64, 158, 255, 0.9)",w.animation="chargePulse 1.2s ease-in-out infinite"):(w.boxShadow=d?"0 0 6px rgba(103, 194, 58, 0.6)":"none",w.animation="none"),w},parseOcrResult(t){var e;if(!t||"object"!==typeof t)return this.internalOcrFrames=[],void this.hideOcrFramesContainer();this.activeChargeHighlight=null,this.activeTextHighlight=null,this.resetChargeMatchMap();const i=(null===(e=this.imgData)||void 0===e||null===(e=e.materialDetail)||void 0===e?void 0:e[0])||this.imgData,s=Array.isArray(null===i||void 0===i?void 0:i.pipeline_result)?i.pipeline_result:null!==i&&void 0!==i&&i.pipeline_result?[i.pipeline_result]:[],a=s[0]||{},o=(null===a||void 0===a?void 0:a.invoice)||{},n=this.imgData,r=this.getChargeListFromImage(n),{amountTargets:l,projectTargets:h}=this.buildChargeTargets(r),d=this.invoiceEditorMatchHighlight?this.collectInvoiceEditorTokens(i):[],c=[{field:"invoice_no",label:"发票号",value:null===n||void 0===n?void 0:n.invoice_no},{field:"total_amount",label:"支付金额",value:null===o||void 0===o?void 0:o["总金额"]},{field:"person_amount",label:"个人支付总额",value:null===o||void 0===o?void 0:o["个人支付总额"]},{field:"other_amount",label:"其它支付总额",value:null===o||void 0===o?void 0:o["其它支付总额"]},{field:"payer",label:"交款人",value:null===o||void 0===o?void 0:o["交款人"]}];null!==n&&void 0!==n&&n.individualDetail&&Array.isArray(n.individualDetail)&&n.individualDetail.forEach((t,e)=>{this.isValidHighlightValue(null===t||void 0===t?void 0:t["金额"])&&c.push({field:"person_detail_"+e,label:null===t||void 0===t?void 0:t["支付方式名称"],value:null===t||void 0===t?void 0:t["金额"]})}),null!==n&&void 0!==n&&n.otherDetail&&Array.isArray(n.otherDetail)&&n.otherDetail.forEach((t,e)=>{this.isValidHighlightValue(null===t||void 0===t?void 0:t["金额"])&&c.push({field:"other_detail_"+e,label:null===t||void 0===t?void 0:t["支付方式名称"],value:null===t||void 0===t?void 0:t["金额"]})});const u=c.filter(t=>this.isValidHighlightValue(t.value)),p=[];let m=0;const g=[];Object.keys(t).forEach(e=>{if("__meta__"===e)return;const i=t[e],s=this.extractOcrBoxes(i);g.push(...s.map(t=>({box:t,text:i.text||e})))});const f=this.isMedicalBillImage();g.forEach(({box:t,text:e})=>{var i;const s=t[0][0],a=t[0][1],o=Math.abs(t[2][0]-t[0][0]),n=Math.abs(t[2][1]-t[0][1]);let r=null;const c=this.normalizeSearchText(e);for(const l of u){const t=this.normalizeSearchText(l.value);if(c.includes(t)){r=l;break}}const g=e,v=!!r,y=this.matchesAnyEditorToken(c,d),b=f&&this.shouldHighlightBillAmount(e)||y,w=this.findChargeAmountMatches(l,e),_=this.findChargeProjectMatches(h,e),x={left:s,top:a,width:o,height:n,text:g,field:(null===(i=r)||void 0===i?void 0:i.field)||"",uniqueKey:"ocr-frame-"+m,isTarget:v,amountHighlight:b};w.length>0&&(x.chargeAmountMatches=w,this.registerChargeMatches("amount",w,x.uniqueKey)),_.length>0&&(x.chargeProjectMatches=_,this.registerChargeMatches("project",_,x.uniqueKey)),p.push(x),m++}),this.internalOcrFrames=p,this.$nextTick(()=>{this.updateOcrFramesContainer()})},isInvoiceMaterial(){var t;const e=null===(t=this.imgData)||void 0===t?void 0:t.materials_type;return!(!e||"string"!==typeof e)&&e.includes("发票")},collectInvoiceEditorTokens(t){if(!this.invoiceEditorMatchHighlight)return[];if(!t||"object"!==typeof t)return[];if(!this.isInvoiceMaterial())return[];const e=Array.isArray(null===t||void 0===t?void 0:t.pipeline_result)?t.pipeline_result:null!==t&&void 0!==t&&t.pipeline_result?[t.pipeline_result]:[];if(!e.length)return[];const i=[],s=t=>{if(!this.isValidHighlightValue(t))return;const e=this.normalizeSearchText(t);e&&i.push(e)},a=t=>{var e;if(!t||"object"!==typeof t)return;const i=t.invoice&&"object"===typeof t.invoice?t.invoice:{};s(i["票据号码"]),s(i["交款人"]),s(i["总金额"]);const a=Array.isArray(t.analysis_result)?t.analysis_result[0]:null;a&&"object"===typeof a&&(s(a["个人支付总额"]),s(a["其它支付总额"]));const o=null===i||void 0===i||null===(e=i.items_detail)||void 0===e?void 0:e.items;Array.isArray(o)&&o.forEach(t=>{t&&"object"===typeof t&&(s(t.project_name),s(t.amount))})};e.forEach(a);const o=Array.from(new Set(i));return o.filter(t=>{if(!t)return!1;if(t.length>=3)return!0;const e=t.replace(/\D/g,"");return e.length>=3||t.length>=2})},matchesAnyEditorToken(t,e){if(!this.invoiceEditorMatchHighlight)return!1;if(!t||!Array.isArray(e)||0===e.length)return!1;const i=t.replace(/\D/g,"");for(const s of e){if(!s)continue;if(t.includes(s))return!0;const e=s.replace(/\D/g,"");if(e&&e.length>=3&&i.includes(e))return!0}return!1},isMedicalBillImage(){var t;const e=null===(t=this.imgData)||void 0===t?void 0:t.materials_type;return!(!e||"string"!==typeof e)&&e.includes("清单")},shouldHighlightBillAmount(t){if(!t||"string"!==typeof t)return!1;const e=t.trim();if(!e)return!1;const i=e.match(/^-?\d[\d,]*(?:\.\d+)?$/);if(!i)return!1;const s=Number.parseFloat(e.replace(/,/g,""));if(!Number.isFinite(s))return!1;const a=Math.abs(s);return a>=1e3&&a<=1e5},getChargeListFromImage(t){if(!t)return[];if(Array.isArray(t.chargeList)&&t.chargeList.length>0)return t.chargeList;const e=Array.isArray(null===t||void 0===t?void 0:t.pipeline_result)?t.pipeline_result[0]:null===t||void 0===t?void 0:t.pipeline_result,i=null===e||void 0===e?void 0:e.charge_list;return Array.isArray(i)?i:[]},buildChargeTargets(t=[]){const e=[],i=[];return Array.isArray(t)?(t.forEach((t,s)=>{if(!t||!1===t.amountShow)return;const a=this.parseChargeAmount(t.Amount);null!==a&&e.push({amount:a,index:s});const o=this.normalizeSearchText(t.ProjectName);o&&i.push({normalizedName:o,index:s})}),{amountTargets:e,projectTargets:i}):{amountTargets:e,projectTargets:i}},parseChargeAmount(t){if(null===t||void 0===t)return null;if("number"===typeof t&&Number.isFinite(t))return t;const e=String(t).replace(/[¥¥元,\s]/g,"");if(!e)return null;const i=Number.parseFloat(e);return Number.isFinite(i)?i:null},findChargeAmountMatches(t=[],e){if(!Array.isArray(t)||0===t.length)return[];const i=this.extractNumericValues(e);if(!i.length)return[];const s=[];return i.forEach(e=>{t.forEach(t=>{this.areAmountsEqual(e,t.amount)&&s.push(t.index)})}),[...new Set(s)]},findChargeProjectMatches(t=[],e){if(!Array.isArray(t)||0===t.length)return[];const i=this.normalizeSearchText(e);if(!i)return[];const s=[];return t.forEach(t=>{t.normalizedName&&i.includes(t.normalizedName)&&s.push(t.index)}),[...new Set(s)]},extractNumericValues(t){if(!t||"string"!==typeof t)return[];const e=t.match(/-?\d[\d,]*(?:\.\d+)?/g);return e?e.map(t=>{const e=t.replace(/,/g,""),i=Number.parseFloat(e);return Number.isFinite(i)?i:null}).filter(t=>null!==t):[]},areAmountsEqual(t,e){return!(!Number.isFinite(t)||!Number.isFinite(e))&&Math.abs(t-e)<.01},registerChargeMatches(t,e,i){var s;if(!Array.isArray(e)||0===e.length||!i)return;const a=null===(s=this.chargeMatchMap)||void 0===s?void 0:s[t];a&&e.forEach(t=>{a[t]||this.$set(a,t,[]),a[t].push(i)})},resetChargeMatchMap(){this.chargeMatchMap={amount:{},project:{}}},isChargeFrameActive(t){var e,i;if(!t)return!1;const s=null===(e=this.activeChargeHighlight)||void 0===e?void 0:e.focusKeys,a=null===(i=this.activeTextHighlight)||void 0===i?void 0:i.focusKeys,o=[...Array.isArray(s)?s:[],...Array.isArray(a)?a:[]];return!!o.length&&o.includes(t.uniqueKey)},setActiveChargeHighlight(t,e){var i;if(!t||void 0===e||null===e)return void this.clearActiveChargeHighlight();const s=(null===(i=this.chargeMatchMap)||void 0===i?void 0:i[t])&&this.chargeMatchMap[t][e]||[];s.length?(this.activeChargeHighlight={type:t,index:e,focusKeys:[...s]},this.$nextTick(()=>{this.updateOcrFramesPosition()})):this.clearActiveChargeHighlight()},clearActiveChargeHighlight(){this.activeChargeHighlight&&(this.activeChargeHighlight=null,this.$nextTick(()=>{this.updateOcrFramesPosition()}))},setActiveTextHighlight(t){const e=this.normalizeSearchText(t);if(!e)return void this.clearActiveTextHighlight();const i=this.internalOcrFrames.length>0?this.internalOcrFrames:this.ocrFrames;if(!Array.isArray(i)||0===i.length)return void this.clearActiveTextHighlight();const s=e.replace(/\D/g,""),a=[];i.forEach(t=>{if(!t||!t.uniqueKey)return;const i=this.normalizeSearchText(t.text);if(i)if(i.includes(e))a.push(t.uniqueKey);else if(s&&s.length>=3){const e=i.replace(/\D/g,"");e.includes(s)&&a.push(t.uniqueKey)}}),a.length?(this.activeTextHighlight={value:e,focusKeys:a},this.$nextTick(()=>{this.updateOcrFramesPosition()})):this.clearActiveTextHighlight()},clearActiveTextHighlight(){this.activeTextHighlight&&(this.activeTextHighlight=null,this.$nextTick(()=>{this.updateOcrFramesPosition()}))},isValidHighlightValue(t){if(null===t||void 0===t)return!1;if("number"===typeof t)return!Number.isNaN(t);if("string"===typeof t){const e=t.trim();if(!e)return!1;const i=e.toLowerCase();if("--"===i||"null"===i||"undefined"===i)return!1}return 0!==t&&"0"!==t},findOcrBoxes(t,e){if(!t||"object"!==typeof t)return[];const i=this.normalizeSearchText(e);if(!i)return[];const s=i.replace(/\D/g,""),a=[],o=[];return Object.keys(t).forEach(e=>{if("__meta__"===e)return;const n=t[e],r=this.extractOcrBoxes(n);if(!r.length)return;const l=[e,null===n||void 0===n?void 0:n.text].map(t=>this.normalizeSearchText(t)).filter(Boolean),h=l.some(t=>t.includes(i));if(h&&a.push(...r),s){const t=l.map(t=>t.replace(/\D/g,"")).filter(Boolean).some(t=>t.includes(s));t&&o.push(...r)}}),a.length?a:o.length?o:[]},extractOcrBoxes(t){if(!t||"object"!==typeof t)return[];const e=[];return Array.isArray(t.boxes)&&e.push(...t.boxes),Array.isArray(t.box)&&e.push(t.box),e.filter(t=>Array.isArray(t)&&t.length>=4)},normalizeSearchText(t){return null===t||void 0===t?"":String(t).replace(/\s+/g,"").replace(/[¥¥元,]/g,"").trim()},hideOcrFramesContainer(){this.$refs&&this.$refs.ocrFramesContainer&&(this.$refs.ocrFramesContainer.style.display="none")},updateOcrFramesContainer(){if(!this.$refs.ocrFramesContainer||!this.$refs.imgDiv)return;if(!this.showOcrFrames)return void this.hideOcrFramesContainer();const t=this.internalOcrFrames.length>0?this.internalOcrFrames:this.ocrFrames;if(!t||0===t.length)return void this.hideOcrFramesContainer();const e=this.$refs.imgDiv,i=this.$refs.ocrFramesContainer,s=e.querySelector("img"),a=s.naturalWidth||s.width,o=s.naturalHeight||s.height,n=s.clientWidth||s.width||a,r=s.clientHeight||s.height||o,l=n/a,h=r/o,d=Math.max(Math.min(l,h),0);i.style.width=a*d+"px",i.style.height=o*d+"px",i.style.display="block",this.updateOcrFramesTransform(d)},updateOcrFramesTransform(t){if(!this.$refs.ocrFramesContainer)return;const e=this.$refs.ocrFramesContainer.querySelectorAll(".ocr-frame"),i=this.internalOcrFrames.length>0?this.internalOcrFrames:this.ocrFrames;e.forEach((e,s)=>{if(i[s]){const a=this.getOcrFrameStyle(i[s],t);Object.assign(e.style,a)}})},handleImageLoad(t){var e,i;const s=(null===t||void 0===t||null===(e=t.target)||void 0===e?void 0:e.currentSrc)||(null===t||void 0===t||null===(i=t.target)||void 0===i?void 0:i.src)||this.url;this.$emit("image-loaded",{url:s,id:this.entityId}),this.$refs.imgDiv&&1===this.params.zoomVal&&(this.setInitialTranslateFromImage(),this.applyTransform()),this.$nextTick(()=>{this.updateOcrFramesContainer()})},moveImg(t){t.preventDefault();const e=this.$refs.imgCont,i=this.$refs.imgDiv;if(!e||!i)return;this.isDragging=!0;const s=t.clientX,a=t.clientY;let o=!1;const n=4,r=this.params.translateX,l=this.params.translateY,h=t=>{const e=t.clientX-s,i=t.clientY-a;!o&&(Math.abs(e)>n||Math.abs(i)>n)&&(o=!0),this.params.translateX=r+e,this.params.translateY=l+i,this.applyTransform(),this.updateOcrFramesPosition()},d=()=>{window.removeEventListener("mousemove",h,!0),window.removeEventListener("mouseup",d,!0),o&&(this.lastDragAt=Date.now()),this.$nextTick(()=>{this.isDragging=!1})};window.addEventListener("mousemove",h,!0),window.addEventListener("mouseup",d,!0),i.ondragstart=()=>!1},updateOcrFramesPosition(){if(!this.$refs.imgDiv||!this.$refs.ocrFramesContainer)return;const t=this.$refs.imgDiv,e=t.querySelector("img"),i=e.getBoundingClientRect(),s=e.naturalWidth||e.width,a=e.naturalHeight||e.height,o=i.width/s,n=i.height/a;let r=Math.min(o,n);this.params.zoomVal>0&&(r/=this.params.zoomVal);const l=this.internalOcrFrames.length>0?this.internalOcrFrames:this.ocrFrames,h=this.$refs.ocrFramesContainer.querySelectorAll(".ocr-frame");h.forEach((t,e)=>{if(l[e]){const i=l[e],s=this.getOcrFrameStyle(i,r);Object.assign(t.style,s)}})},handleImageError(t){if(this.disableLegacyFallback)return void this.$emit("image-error",t,this.imgData);const e=(null===t||void 0===t?void 0:t.target)||this.$refs.imgDiv;if(e&&e.src&&!e.dataset.allUrlsAttempted)try{if(!e.dataset.originUrlAttempted){var i,s,a,o;e.dataset.originUrlAttempted="true";let t=null;if(null!==(i=this.imgData)&&void 0!==i&&i.origin_url?t=this.imgData.origin_url:null!==(s=this.imgData)&&void 0!==s&&null!==(s=s.materialDetail)&&void 0!==s&&s.origin_url?t=this.imgData.materialDetail.origin_url:null!==(a=this.imgData)&&void 0!==a&&a.materialDetail&&Array.isArray(this.imgData.materialDetail)&&null!==(o=this.imgData.materialDetail[0])&&void 0!==o&&o.origin_url&&(t=this.imgData.materialDetail[0].origin_url),t&&"string"===typeof t&&""!==t.trim())try{new URL(t),e.src=t}catch(n){console.error("无效的origin_url:",t,n),e.src="/images/null.png",e.dataset.allUrlsAttempted="true"}else e.src="/images/null.png",e.dataset.allUrlsAttempted="true"}}catch(r){console.error("图片加载错误处理失败:",r),e.src="/images/null.png",e.dataset.allUrlsAttempted="true"}},copyCurrentOcrText(t,e){var i,s;if(this.lastDragAt&&Date.now()-this.lastDragAt<250)return null===e||void 0===e||null===(i=e.stopPropagation)||void 0===i||i.call(e),void(null===e||void 0===e||null===(s=e.preventDefault)||void 0===s||s.call(e));navigator.clipboard.writeText(t).then(()=>{this.$message.success("复制成功!")}).catch(t=>{console.error("复制失败:",t),this.$message.error("复制失败,请重试")})}}}),n=o,r=(i("5cdf"),i("1805")),l=Object(r["a"])(n,s,a,!1,null,"7a2afa8a",null);e["a"]=l.exports},1943:function(t,e,i){"use strict";var s=i("e5bf"),a=i("3bef"),o=i("3f15"),n=i("beb6"),r=i("bd07"),l=i("907e"),h=i("279c"),d=i("3cd7"),c=i("c25a"),u=TypeError,p=c((function(){[].keys().reduce((function(){}),void 0)})),m=!p&&h("reduce",u);s({target:"Iterator",proto:!0,real:!0,forced:p||m},{reduce:function(t){n(this);try{o(t)}catch(c){l(this,"throw",c)}var e=arguments.length<2,i=e?void 0:arguments[1];if(m)return d(m,this,e?[t]:[t,i]);var s=r(this),h=0;if(a(s,(function(s){e?(e=!1,i=s):i=t(i,s,h),h++}),{IS_RECORD:!0}),e)throw new u("Reduce of empty iterator with no initial value");return i}})},"1b89":function(t,e,i){"use strict";i("6107")},"1d24":function(t,e,i){"use strict";var s=i("7ef8");t.exports="NODE"===s},"1dfa":function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],class:"1"==t.echartsType?"module_wrap box_border":"module_wrap module_wrap2 box_border",attrs:{"element-loading-text":"数据加载中","element-loading-spinner":"el-icon-loading","element-loading-background":"transparent"}},[t._m(0),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.loading,expression:"!loading"}],staticStyle:{height:"100%"}},[e("div",{attrs:{id:"case_bar_tag"}})])])},a=[function(){var t=this,e=t._self._c;return e("div",{staticClass:"box_title box_title_radio"},[e("span",[t._v("事故省风险案件标签排行榜")])])}],o=(i("0faf"),i("b3ec"),i("6fc2"),i("e4c6"),i("320b"),i("ada4")),n={name:"ProvinceRiskTag",props:{isCollapse:{type:Boolean,default:!0},navForm:{type:Object,default:{}},echartsType:{type:String,default:""}},watch:{isCollapse(){setTimeout(()=>{this.myChart&&this.myChart.resize()},600)},navForm:{deep:!0,handler(t){this.getData()}}},data(){return{topDays:[],newNumber:0,myChart:null,yAxisData1:[],yAxisData2:[],sumSeriesData1:[],sumSeriesData2:[],numSeriesData1:[],numSeriesData2:[],option:"",radio:"数量",radio1:"前15",tmpCasesNumTopTen:null,loading:!0}},mounted(){this.role=localStorage.getItem("role"),window.addEventListener("resize",()=>{this.myChart&&this.myChart.resize()})},methods:{getData(){this.loading=!0;let t=null;switch(this.echartsType){case"1":t="/large/data/screen/getProvinceCasesLabelNumTopTen";break;case"2":t="/large/data/screen/getProvinceCasesLabelNumTopTen";break;default:break}t&&this.instance({method:"post",url:t,data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(this.loading=!1,1==t.data.code){let e=t.data.data;this.tmpCasesNumTopTen=e,this.loadCharts(e)}})},radioChange(){this.option&&("数量"==this.radio?(this.option.yAxis.data=this.yAxisData1,this.option.series[0].data=this.numSeriesData1,this.option.series[0].name="风险案件数量"):(this.option.yAxis.data=this.yAxisData2,this.option.series[0].data=this.sumSeriesData1,this.option.series[0].name="风险案件金额"),setTimeout(()=>{this.myChart.setOption(this.option)},100))},radioChange1(){let t=JSON.parse(JSON.stringify(this.numSeriesData1)),e=JSON.parse(JSON.stringify(this.sumSeriesData1)),i=JSON.parse(JSON.stringify(this.yAxisData1)),s=JSON.parse(JSON.stringify(this.yAxisData2));"前15"==this.radio1?"数量"==this.radio?(this.option.xAxis[0].data=i.slice(0,15),this.option.yAxis.data=i.slice(0,15),this.option.series[0].data=t.slice(0,15),this.option.series[0].name="风险标签案件占比"):(this.option.xAxis[0].data=i.slice(0,15),this.option.yAxis.data=s.slice(0,15),this.option.series[0].data=e.slice(0,15),this.option.series[0].name="风险案件金额"):"数量"==this.radio?(this.option.xAxis[0].data=i,this.option.yAxis.data=i,this.option.series[0].data=t,this.option.series[0].name="风险标签案件占比"):(this.option.xAxis[0].data=i,this.option.yAxis.data=s,this.option.series[0].data=e,this.option.series[0].name="风险案件金额"),setTimeout(()=>{this.myChart.setOption(this.option)},100)},loadCharts(t){var e=document.getElementById("case_bar_tag");e&&(this.myChart&&this.myChart.dispose(),this.myChart=o["init"](e,null,{renderer:"svg"}),this.yAxisData1=[],this.sumSeriesData1=[],this.sumSeriesData2=[],this.yAxisData2=[],this.numSeriesData1=[],this.numSeriesData2=[],t&&t.caseRiskNum&&t.caseRiskNum.forEach((t,e)=>{this.yAxisData1.push(t.name),this.numSeriesData1.push(t.caseNumRatio)}),t&&t.caseRiskMoney&&t.caseRiskMoney.forEach((t,e)=>{this.yAxisData2.push(t.name),this.sumSeriesData1.push(t.amountCaseFiled),this.sumSeriesData2.push(t.totalPayAmount)}),this.option={tooltip:{trigger:"axis",confine:!0,textStyle:{align:"left"}},grid:{left:"2%",right:"4%",top:"4%",bottom:"4%",containLabel:!0},xAxis:[{type:"category",axisTick:{alignWithLabel:!0},axisLabel:{showMaxLabel:!0,rotate:40,textStyle:{color:"#fff"},width:60,overflow:"truncate",ellipsis:"..."},data:this.yAxisData1}],yAxis:[{type:"value",splitLine:{show:!1},axisLabel:{showMaxLabel:!0,formatter:"{value} %",textStyle:{color:"#fff"}},data:this.yAxisData1}],series:[{name:"风险标签案件占比",type:"bar",itemStyle:{color:new o["graphic"].LinearGradient(0,0,1,0,[{offset:0,color:"#FFFFFF"},{offset:1,color:"#A574F3"}])},tooltip:{valueFormatter:function(t){return t+" %"}},stack:"total",barMaxWidth:"40%",data:this.numSeriesData1}]},this.myChart.setOption(this.option),this.radioChange1())}},updated(){this.myChart&&this.myChart.resize()}},r=n,l=(i("9f02"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"03f26592",null);e["default"]=h.exports},"1fd3":function(t,e,i){},"20ad":function(t,e,i){},"20b9":function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{staticClass:"content"},[e("div",{staticClass:"home_title"},[t._v("案件基础数据监控")]),e("el-radio-group",{staticClass:"map_tab",staticStyle:{"margin-bottom":"30px"},on:{change:t.tabsChange},model:{value:t.radio,callback:function(e){t.radio=e},expression:"radio"}},[e("el-radio-button",{attrs:{label:"1"}},[t._v("已决案件分布")]),e("el-radio-button",{attrs:{label:"2"}},[t._v("未决案件分布")])],1),e("div",{attrs:{id:"container",tabindex:"0"}})],1)},a=[],o=(i("0faf"),i("b3ec"),i("6fc2"),i("2130"),i("e4c6"),i("320b"),i("ada4")),n=i("6032"),r="",l={name:"ChinaMap",props:{isCollapse:{type:Boolean,default:!0},navForm:{type:Object,default:{}}},watch:{isCollapse(){setTimeout(()=>{this.listenResize()},600)},navForm:{deep:!0,handler(t){this.getData()}}},data(){return{map:"",loca:"",chart:null,origin:"",checkedPoint:[],mapData:{},radio:"1",tabsActive:1,myChartMap:"",provinceCount:[],realTimeData:[],cityCount:[],nowVehicleData:{}}},mounted(){r=this,this.origin=window.location.origin,this.role=localStorage.getItem("role"),this.userInfo=JSON.parse(localStorage.getItem("userInfo")),this.getData(1),window.addEventListener("resize",this.listenResize)},beforeDestroy(){window.removeEventListener("resize",this.listenResize)},methods:{listenResize(){this.myChartMap&&setTimeout(()=>{this.myChartMap.resize()},600)},linkVehicleMap(t){if(this.userInfo.batchId||0==this.role)return!1;let e=this.$router.resolve({path:"/VehicleMap",query:{deviceNumber:t.deviceNumber,startTime:t.tripStartTime,endTime:t.tripEndTime}});window.open(e.href,"_blank")},getLatestTrip(){this.realTimeData=[],this.instance.get("/homepage/getLatestTrip",{params:{companyId:this.userInfo.company}}).then(t=>{1==t.data.code&&this.initRouteData(t.data.data)})},getLatestTripByProvince(t){this.realTimeData=[],this.instance.get("/homepage/getLatestTripByProvince",{params:{companyId:this.userInfo.company,provinceName:t}}).then(t=>{1==t.data.code&&this.initRouteData(t.data.data)})},initRouteData(t){var e=t.length;if(e>0){for(var i=0;i{this.mapData=t.data.data;var e=[],i=[];this.mapData.cityDatas.length>0&&(this.mapData.cityDatas.forEach((t,i)=>{var s={name:t.cityName,parent:t.provinceName,value:t.casesNo,level:1,avgRiskValue:t.avgRiskValue,insuredNo:t.insuredNo,riskPointsNo:t.riskPointsNo};e.push(s)}),this.cityCount=e),this.mapData.provinceDatas.length>0&&(this.mapData.provinceDatas.forEach((t,e)=>{var s={name:t.cityName,parent:t.provinceName,value:t.casesNo,level:1,avgRiskValue:t.avgRiskValue,insuredNo:t.insuredNo,riskPointsNo:t.riskPointsNo};i.push(s)}),this.provinceCount=i),setTimeout(()=>{this.createMap()},300)})},createMap(){function t(){r.$axios.get("/map/data-china.json").then(t=>{o["registerMap"]("china",t.data),r.myChartMap=o["extendsMap"]("container",{bgColor:"transparent",mapName:"china",goDown:!0,callback:function(t,e,i){},data:r.cityCount})})}o["extendsMap"]=function(t,e){r.chart&&r.chart.dispose(),r.chart=o["init"](document.getElementById(t),null,{renderer:"svg"});var i={},s={mapName:"china",goDown:!1,bgColor:"#404a59",activeArea:[],data:[],callback:function(t,e,i){}};e&&(e=o["util"].extend(s,e));var a=[e.mapName],l=0,h={leftPlus:115,leftCur:150,left:198,top:240},d=[[0,0],[8,11],[0,22]],c={font:'18px "Microsoft YaHei", sans-serif',textColor:"#30FBFE",lineColor:"#30FBFE"},u={resetOption:function(t,i,s){var o=this.createBreadcrumb(s),n=a.indexOf(s),r=i.graphic.length;if(n<0){if(i.graphic.push(o),i.graphic[0].children[0].shape.x2=145,i.graphic[0].children[1].shape.x2=145,i.graphic.length>2){for(var d,c=[],p=0;pe.name==t.name);if(-1!=a){let t="";return 3==r.tabsActive&&(t="
分包商数量:"+s[a].insuredNo+"个"),"城市:"+s[a].name+"
案件数:"+s[a].value+"件
风险点个数:"+s[a].riskPointsNo+"个"+t}return t.name}{let e="";return 3==r.tabsActive&&(e="
分包商数量:"+t.data.insuredNo+"个"),"城市:"+t.data.name+"
案件数:"+t.data.num+"件
风险点个数:"+t.data.riskPointsNo+"个"+e}}},label:{show:!0,color:"#fff"},itemStyle:{borderColor:"#2ff7fb",borderWidth:1,opacity:1,areaColor:{type:"radial",x:.5,y:.5,r:.8,colorStops:[{offset:0,color:"RGBA(0, 36, 109, 0.5)"},{offset:1,color:"RGBA(0, 36, 109, 0.7)"}],globalCoord:!1}},emphasis:{itemStyle:{areaColor:"rgba(0, 69, 109, 0.8)",borderWidth:0},label:{color:"#fff"}}},series:[{type:"effectScatter",coordinateSystem:"geo",showEffectOn:"emphasis",rippleEffect:{period:5,scale:2.5,brushType:"fill"},itemStyle:{opacity:.9,color:"#E29550",shadowBlur:10,shadowColor:"#333"},symbolSize(t,i){var s=t[2],a=e.data[0].value,o=6;return o=s<.4*a?6:s<.7*a?8:10,o},zlevel:1,data:u.initSeriesData(e.data)}]};return r.chart.setOption(p),r.chart.on("click",(function(t){var s="china"==a[l]?"中国":a[l],h=this;if(e.goDown&&t.name!==s&&n["a"][t.name]){var d=n["a"][t.name];r.$axios.get(r.origin+"/"+d).then(e=>{i=e.data,o["registerMap"](t.name,i),u.resetOption(h,p,t.name)})}"中国"!=s&&u.resetOption(r.chart,p,"china")})),r.chart.setMap=function(t){var e=this;t.indexOf("市")<0&&(t+="市");var s=n["a"][t];if(s){var a=s;r.$axios.get(a).then(s=>{i=s.data,o["registerMap"](t,i),u.resetOption(e,p,t)})}},r.chart},t()},appendScript(t){var e=document.createElement("script");e.charset="utf-8",e.src=t,document.head.appendChild(e)}}},h=l,d=(i("ea38"),i("1805")),c=Object(d["a"])(h,s,a,!1,null,"8d469ab2",null);e["default"]=c.exports},2473:function(t,e,i){},"24f0":function(t,e,i){},2887:function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{staticClass:"module_wrap box_border"},[e("div",{staticClass:"box_border ratio_box"},[e("div",[e("b",[t._v("案均赔款金额:")]),e("span",[t._v(t._s(t.casesData.averageLossAmount)+"元")])])]),e("ul",{staticClass:"ratio_ul"},[e("li",{staticClass:"box_border"},[e("b",[t._v("车损案均")]),e("div",[t._v(t._s(t.casesData.averageAmountOfVehicleDamageCases)+" (元)")])]),e("li",{staticClass:"box_border"},[e("b",[t._v("物损案均")]),e("div",[t._v(t._s(t.casesData.averageAmountOfMaterialDamageCases)+" (元)")])]),e("li",{staticClass:"box_border"},[e("b",[t._v("门诊案均")]),e("div",[t._v(t._s(t.casesData.averageAmountOfHumanInjuryCases)+" (元)")])]),e("li",{staticClass:"box_border"},[e("b",[t._v("死亡案均")]),e("div",[t._v(t._s(t.casesData.averageAmountOfDeathCases)+" (万元)")])]),e("li",{staticClass:"box_border"},[e("b",[t._v("伤残案均")]),e("div",[t._v(t._s(t.casesData.averageAmountOfDisabilityCases)+" (元)")])]),e("li",{staticClass:"box_border"},[e("b",[t._v("住院案均")]),e("div",[t._v(t._s(t.casesData.averageAmountOfHospitalizationCases)+" (元)")])])])])},a=[],o={name:"ReparationsAmount",props:{navForm:{type:Object,default:{}}},data(){return{casesData:{},newNumber:0}},watch:{navForm:{immediate:!0,deep:!0,handler(t){this.getData()}}},mounted(){this.role=localStorage.getItem("role")},methods:{getData(){this.instance({method:"post",url:"/large/data/screen/getBusinessQualityData",data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(1==t.data.code){let e=t.data.data||{};e.averageLossAmount=e.averageLossAmount&&Math.round(e.averageLossAmount),e.averageAmountOfVehicleDamageCases=e.averageAmountOfVehicleDamageCases&&Math.round(e.averageAmountOfVehicleDamageCases),e.averageAmountOfMaterialDamageCases=e.averageAmountOfMaterialDamageCases&&Math.round(e.averageAmountOfMaterialDamageCases),e.averageAmountOfHumanInjuryCases=e.averageAmountOfHumanInjuryCases&&Math.round(e.averageAmountOfHumanInjuryCases),e.averageAmountOfDeathCases=e.averageAmountOfDeathCases&&Math.round(e.averageAmountOfDeathCases),e.averageAmountOfHospitalizationCases=e.averageAmountOfHospitalizationCases&&Math.round(e.averageAmountOfHospitalizationCases),e.averageAmountOfDisabilityCases=e.averageAmountOfDisabilityCases&&Math.round(e.averageAmountOfDisabilityCases),this.casesData=e}})}}},n=o,r=(i("9ac4"),i("1805")),l=Object(r["a"])(n,s,a,!1,null,"a05c11d0",null);e["default"]=l.exports},"29ae":function(t,e,i){},"2de5":function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{staticClass:"wrap"},[t._m(0),e("div",{staticClass:"search_box public_box"},[e("el-form",{staticClass:"demo-form-inline",attrs:{inline:!0,model:t.navForm}},[e("div",{staticClass:"flex"},[e("div",[e("el-form-item",{staticStyle:{"margin-right":"0.8rem"}},[e("el-upload",{staticClass:"upload_box",attrs:{accept:".xls,.xlsx",action:t.baseURL+"/case/importCaseExcel","show-file-list":!0,headers:t.unloaderHeader,limit:1,"on-remove":t.handleRemove,"on-success":t.handleAvatarSuccess,"before-upload":t.beforeAvatarUpload}},[[e("el-button",{attrs:{type:"primary"}},[e("i",{staticClass:"el-icon-upload el-icon--left"}),t._v("上传案件")])]],2)],1),e("el-form-item",[e("span",{staticClass:"hint_text"},[t._v("(若无批量案件上传,可按条件查询)")])]),e("br"),e("el-form-item",{attrs:{label:"案件类型:"}},[e("el-select",{staticClass:"width_150",attrs:{clearable:"",multiple:"",placeholder:"请选择"},model:{value:t.navForm.caseType,callback:function(e){t.$set(t.navForm,"caseType",e)},expression:"navForm.caseType"}},[e("el-option",{attrs:{label:"骑手人伤",value:"骑手人伤"}}),e("el-option",{attrs:{label:"三者人伤",value:"三者人伤"}}),e("el-option",{attrs:{label:"三者物损",value:"三者物损"}}),e("el-option",{attrs:{label:"三者车损",value:"三者车损"}})],1)],1),e("el-form-item",{attrs:{label:"结案状态:"}},[e("el-select",{staticClass:"width_150",attrs:{clearable:"",placeholder:"请选择"},on:{change:t.caseClosedStatusChange},model:{value:t.caseClosedStatus,callback:function(e){t.caseClosedStatus=e},expression:"caseClosedStatus"}},[e("el-option",{attrs:{label:"未决",value:"0"}}),e("el-option",{attrs:{label:"已决",value:"1"}})],1)],1),e("el-form-item",{attrs:{label:"案件状态:"}},[e("el-select",{staticClass:"width_150",attrs:{multiple:"",clearable:"",placeholder:"请选择"},model:{value:t.navForm.caseStatus,callback:function(e){t.$set(t.navForm,"caseStatus",e)},expression:"navForm.caseStatus"}},t._l(t.statusOptions,(function(t,i){return e("el-option",{key:i,attrs:{label:t.status,value:t.status}})})),1)],1),e("el-form-item",{attrs:{label:"事故省:"}},[e("el-select",{staticClass:"width_150",attrs:{clearable:"",placeholder:"请选择"},model:{value:t.navForm.accidentProvince,callback:function(e){t.$set(t.navForm,"accidentProvince",e)},expression:"navForm.accidentProvince"}},t._l(t.provinceOptions,(function(t){return e("el-option",{key:t,attrs:{label:t,value:t}})})),1)],1),e("el-form-item",{attrs:{label:"公估公司:"}},[e("el-input",{staticClass:"width_150",attrs:{placeholder:"请填写公估公司",clearable:""},model:{value:t.navForm.lossAdjusterCompany,callback:function(e){t.$set(t.navForm,"lossAdjusterCompany",e)},expression:"navForm.lossAdjusterCompany"}})],1),e("el-form-item",{attrs:{label:"被保险人:"}},[e("el-input",{staticClass:"width_150",attrs:{placeholder:"请填写分包商",clearable:""},model:{value:t.navForm.nameOfInsured,callback:function(e){t.$set(t.navForm,"nameOfInsured",e)},expression:"navForm.nameOfInsured"}})],1),e("el-form-item",{attrs:{label:"案件号/保单号:"}},[e("el-input",{staticClass:"width_180",attrs:{placeholder:"请填写案件号/保单号",clearable:""},model:{value:t.navForm.caseNo,callback:function(e){t.$set(t.navForm,"caseNo",e)},expression:"navForm.caseNo"}})],1),e("el-form-item",{staticClass:"dateBox",attrs:{label:"报案时间:"}},[e("el-row",{staticStyle:{width:"350px"}},[e("el-col",{attrs:{span:11}},[e("el-date-picker",{staticStyle:{width:"100%"},attrs:{placeholder:"请选择日期",clearable:"",type:"date","value-format":"yyyy-MM-dd"},model:{value:t.navForm.reportStartTime,callback:function(e){t.$set(t.navForm,"reportStartTime",e)},expression:"navForm.reportStartTime"}})],1),e("el-col",{staticClass:"line",staticStyle:{"text-align":"center"},attrs:{span:2}},[t._v("至")]),e("el-col",{attrs:{span:11}},[e("el-date-picker",{staticStyle:{width:"100%"},attrs:{placeholder:"请选择日期",clearable:"",type:"date","value-format":"yyyy-MM-dd"},model:{value:t.navForm.reportEndTime,callback:function(e){t.$set(t.navForm,"reportEndTime",e)},expression:"navForm.reportEndTime"}})],1)],1)],1),e("el-form-item",{staticClass:"dateBox",attrs:{label:"操作时间:"}},[e("el-row",{staticStyle:{width:"350px"}},[e("el-col",{attrs:{span:11}},[e("el-date-picker",{staticStyle:{width:"100%"},attrs:{placeholder:"请选择日期",clearable:"",type:"date","value-format":"yyyy-MM-dd"},model:{value:t.navForm.startTime,callback:function(e){t.$set(t.navForm,"startTime",e)},expression:"navForm.startTime"}})],1),e("el-col",{staticClass:"line",staticStyle:{"text-align":"center"},attrs:{span:2}},[t._v("至")]),e("el-col",{attrs:{span:11}},[e("el-date-picker",{staticStyle:{width:"100%"},attrs:{placeholder:"请选择日期",clearable:"",type:"date","value-format":"yyyy-MM-dd"},model:{value:t.navForm.endTime,callback:function(e){t.$set(t.navForm,"endTime",e)},expression:"navForm.endTime"}})],1)],1)],1),e("el-form-item",[e("el-button",{attrs:{type:"primary"},on:{click:t.searchTable}},[t._v("风险查询")])],1)],1)])])],1),e("div",{staticClass:"main"},[e("div",{staticClass:"table_box public_box"},[e("div",{staticClass:"table_title"},[e("b",[t._v("案件详情")]),e("div",{staticClass:"case_statistics"},[e("div",[t._v("自留验证案件"+t._s(t.tagCount.oneselfVerifyCount||0)+"个,其中红灯案件"+t._s(t.tagCount.oneselfVerifyRedCount||0)+"个,绿灯案件"+t._s(t.tagCount.oneselfVerifyGreenCount||0)+"个;")]),e("div",[t._v("模型验证案件"+t._s(t.tagCount.modelVerifyCount||0)+"个,其中红灯案件"+t._s(t.tagCount.modelVerifyRedCount||0)+"个,绿灯案件"+t._s(t.tagCount.modelVerifyGreenCount||0)+"个。")])]),t.tableData.length>0?e("el-button",{staticClass:"download",attrs:{type:"text"},on:{click:t.handleDownload}},[e("i",{staticClass:"el-icon-download el-icon--left"}),t._v("下载表单")]):t._e()],1),e("el-table",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],ref:"multipleTable",staticStyle:{width:"100%"},attrs:{data:t.tableData,"empty-text":t.caseExcelData.length>0||t.navForm.endTime?"暂无案件":"暂无案件,请上传案件清单或选择查询日期"},on:{"sort-change":t.sortChange}},[e("el-table-column",{attrs:{prop:"caseNo",label:"案件号",width:"210"}}),e("el-table-column",{attrs:{prop:"currentStatusDesc",label:"案件状态"}}),e("el-table-column",{attrs:{prop:"accidentProperty",label:"案件类型","show-overflow-tooltip":!0}}),e("el-table-column",{attrs:{prop:"valueAtRisk",label:"风险值",sortable:"custom"}}),e("el-table-column",{attrs:{prop:"oneselfVerify",label:"自留验证",width:"100"},scopedSlots:t._u([{key:"default",fn:function(i){return[i.row.oneselfVerify?e("el-tag",{staticStyle:{width:"30px"},attrs:{size:"mini",type:"红灯案件"==i.row.oneselfVerify?"danger":"success",effect:"dark"}}):t._e()]}}])}),e("el-table-column",{attrs:{prop:"modelVerify",label:"模型验证",width:"100"},scopedSlots:t._u([{key:"default",fn:function(i){return[i.row.modelVerify?e("el-tag",{staticStyle:{width:"30px"},attrs:{size:"mini",type:"红灯案件"==i.row.modelVerify?"danger":"success",effect:"dark"}}):t._e()]}}])}),e("el-table-column",{attrs:{prop:"handleTime",label:"操作时间","show-overflow-tooltip":!0}}),e("el-table-column",{attrs:{label:"操作",width:"180px"},scopedSlots:t._u([{key:"default",fn:function(i){return[e("div",{staticClass:"flex"},[e("span",{staticClass:"a_color",on:{click:function(e){return t.lookDetails(i.row)}}},[t._v("查看详情")]),e("span",{staticClass:"a_color",on:{click:function(e){return t.hanleVerify(1,"自留验证",i.row)}}},[t._v("自留验证")]),e("span",{staticClass:"a_color",on:{click:function(e){return t.hanleVerify(2,"模型验证",i.row)}}},[t._v("模型验证")])])]}}])})],1),e("el-pagination",{staticStyle:{"margin-top":"0.2rem"},attrs:{"current-page":t.currentPage,layout:"total, sizes, prev, pager, next, jumper","page-sizes":[10,20],"page-size":10,total:t.totalPage},on:{"current-change":t.handleCurrentChange,"size-change":t.handleSizeChange}})],1)]),e("el-dialog",{attrs:{visible:t.dialogVisibleVerify,title:t.verifyTitle,"modal-append-to-body":!1,"append-to-body":!0,center:"",width:"50%"},on:{"update:visible":function(e){t.dialogVisibleVerify=e}}},[e("el-form",{staticClass:"demo-form-inline",attrs:{inline:!0}},[e("el-form-item",{attrs:{label:"验证信息:"}},[e("el-radio-group",{model:{value:t.verifyRadio,callback:function(e){t.verifyRadio=e},expression:"verifyRadio"}},[e("el-radio-button",{staticClass:"bg_red",attrs:{label:"红灯案件"}}),e("el-radio-button",{staticClass:"bg_green",attrs:{label:"绿灯案件"}})],1)],1),"红灯案件"==t.verifyRadio?e("div",[e("el-form-item",{staticClass:"form-items",attrs:{label:"验证依据:"}},[e("el-cascader",{ref:"cascader",attrs:{options:t.tmpOptions,props:t.props,"collapse-tags":"",clearable:""},on:{change:t.getselKnowledgeList},model:{value:t.tmpDatas,callback:function(e){t.tmpDatas=e},expression:"tmpDatas"}})],1),e("br"),e("el-form-item",{staticClass:"form-items",attrs:{label:"验证结论:"}},t._l(t.conclusionTags,(function(i){return e("el-tag",{key:i.value,attrs:{closable:""},on:{close:function(e){return t.conclusionClose(i)}}},[t._v(" "+t._s(i.label)+" ")])})),1)],1):t._e()],1),e("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[e("el-button",{on:{click:t.cancelCaseDialog}},[t._v("取 消")]),e("el-button",{attrs:{type:"primary"},on:{click:t.updateCaseTag}},[t._v("确 定")])],1)],1),e("el-dialog",{staticClass:"case_detail",attrs:{visible:t.dialogVisible,"modal-append-to-body":!1,"append-to-body":!0,width:"70%"},on:{"update:visible":function(e){t.dialogVisible=e}}},[e("div",{staticClass:"dialog_box"},[e("div",{staticClass:"dialog_header"},[e("div",[t._v("案件号:"+t._s(t.checkedRowDetail.caseNo))]),e("div",[t._v("是否快赔:"+t._s(t.checkedRowDetail.quickPayOrNot))])]),e("div",{staticClass:"dialog_main"},[e("el-steps",{attrs:{active:t.stepsActive,"align-center":"","process-status":"finish"}},t._l(t.checkedRowDetail.stageOfCaseVoList,(function(s,a){return e("el-step",{key:a,attrs:{title:s.stageName}},[s.arrivalOrNot?e("template",{slot:"description"},[e("div",{staticClass:"status_icon"},[s.yesOrNo&&s.caseRiskPoints.length>0?e("img",{attrs:{src:i("8baa"),alt:""}}):e("img",{attrs:{src:i("a9c0"),alt:""}})]),e("div",{staticStyle:{color:"#333"}},[s.yesOrNo&&s.caseRiskPoints.length>0?e("div",[e("p",[t._v("此阶段存在"+t._s(s.caseRiskPoints.length)+"个风险点")]),e("ul",{staticClass:"risk_point"},t._l(s.caseRiskPoints,(function(i,a){return e("li",{key:a},[e("p",[t._v(t._s(a+1+"、"+i.riskTip))]),e("div",{staticClass:"status_box"},[1==i.riskType?[0==i.status?e("span",{staticClass:"a_color",on:{click:function(e){return t.handleAttention(s,i)}}},[t._v("待关注")]):1==i.status?e("span",{staticStyle:{color:"#e6a23c"}},[t._v("已关注")]):t._e()]:2==i.riskType?[0==i.status?e("span",{staticClass:"a_color",on:{click:function(e){return t.handleAttention(s,i)}}},[t._v("待处理")]):t._e()]:t._e(),2==i.status?e("span",{staticStyle:{color:"#67c23a"}},[t._v("已处理")]):t._e()],2)])})),0)]):e("p",[t._v("此阶段无风险")])])]):t._e()],2)})),1),t.checkedRowDetail.riderAsThirdCases&&(t.checkedRowDetail.riderAsThirdCases.length>0||t.checkedRowDetail.thirdVehicleInCases.length>0||t.checkedRowDetail.riderAccumulatedCases.length>0||t.checkedRowDetail.riderMultiCases.length>0||t.checkedRowDetail.thirdInjuredCases.length>0)?e("div",{staticClass:"relevancy_case"},[e("p",[t._v("风险关联案件:")]),t.checkedRowDetail.riderAsThirdCases.length>0?[e("div",{staticClass:"small_title"},[t._v("该骑手在以下案件中为三者:")]),e("div",t._l(t.checkedRowDetail.riderAsThirdCases,(function(i,s){return e("span",{key:s},[t._v(t._s(i+";"))])})),0)]:t._e(),t.checkedRowDetail.thirdVehicleInCases.length>0?[e("div",{staticClass:"small_title"},[t._v("该三者车辆在以下案件中出现:")]),e("div",t._l(t.checkedRowDetail.thirdVehicleInCases,(function(i,s){return e("span",{key:s},[t._v(t._s(i+";"))])})),0)]:t._e(),t.checkedRowDetail.thirdInjuredCases.length>0?[e("div",{staticClass:"small_title"},[t._v("同一三者在以下案件中出现:")]),e("div",t._l(t.checkedRowDetail.thirdInjuredCases,(function(i,s){return e("span",{key:s},[t._v(t._s(i+";"))])})),0)]:t._e(),t.checkedRowDetail.riderMultiCases.length>0?[e("div",{staticClass:"small_title"},[t._v("骑手近期在以下案件中出险:")]),e("div",t._l(t.checkedRowDetail.riderMultiCases,(function(i,s){return e("span",{key:s},[t._v(t._s(i+";"))])})),0)]:t._e(),t.checkedRowDetail.riderAccumulatedCases.length>0?[e("div",{staticClass:"small_title"},[t._v("该骑手在以下案件中累计赔付:")]),e("div",t._l(t.checkedRowDetail.riderAccumulatedCases,(function(i,s){return e("span",{key:s},[t._v(t._s(i+";"))])})),0)]:t._e()],2):t._e()],1)])])],1)},a=[function(){var t=this,e=t._self._c;return e("div",{staticClass:"page_title"},[e("b",[t._v("在线质检案件")]),e("span",[t._v("(案件列表显示满足筛选规则的案件)")])])}],o=(i("0faf"),i("b210"),i("b3ec"),i("6fc2"),i("1943"),i("e4c6"),i("320b"),i("08a9"),i("5966"),i("b75d"),i("5f87")),n={name:"onlineTesting",components:{},data(){return{caseExcelData:[],verifyTitle:"自留验证",checkedRow:"",dialogVisible:!1,relevancyVisible:!1,dialogVisibleVerify:!1,verifyRadio:"",verifyValue:"",baseURL:"",unloaderHeader:{token:""},fullscreenLoading:!1,uploadFile:{},fileName:"",activeName:"first",loading:!1,nowFilter:"",statusOptions:[],baseStatusOptions:[],provinceOptions:["辽宁省","江苏省","广西壮族自治区","福建省","四川省","黑龙江省","山东省","江西省","陕西省","吉林省","北京市","安徽省","河北省","河南省","重庆市","天津市","湖北省","甘肃省","上海市","云南省","贵州省","内蒙古自治区","山西省","海南省","浙江省","宁夏回族自治区","青海省","广东省","新疆维吾尔自治区","湖南省","西藏自治区","香港特别行政区","澳门特别行政区","台湾省"],navForm:{startTime:"",endTime:"",reportStartTime:"",reportEndTime:"",caseType:[],value:"",nameOfInsured:"",lossAdjusterCompany:"",accidentProvince:"",caseStatus:[],meituanCaseInfoList:[]},tagCount:{},caseClosedStatus:"",stepsActive:0,checkedRowDetail:{},riskOptions:[],customFilterOptionList:[],currentPage:1,pageSize:10,totalPage:0,tableData:[],props:{multiple:!0},tmpOptions:[],parentLevelOption:[],childLevelOption:[],levelOptionObj:{},parentLevel:"",childLevel:"",conclusionParent:[],conclusionTags:[],tmpDatas:[]}},methods:{getselKnowledgeList(){let t=this.$refs["cascader"].getCheckedNodes();t.length>0?(this.conclusionTags=[],this.conclusionParent=[],t.forEach(t=>{t.parent&&(this.conclusionParent.push({value:t.parent.value,name:t.parent.label}),this.conclusionTags.push({value:t.data.value,label:t.data.label,parentValue:t.parent.value}))})):this.conclusionTags=[]},conclusionClose(t){var e=JSON.parse(JSON.stringify(this.tmpDatas));let i=this.conclusionTags.findIndex(e=>e.value==t.value);this.conclusionTags.splice(i,1);let s=e.findIndex(e=>e[0]==t.parentValue&&e[1]==t.value);e.splice(s,1),this.tmpDatas=e},unique(t){var e={};return t=t.reduce((function(t,i){return!e[i.value]&&(e[i.value]=t.push(i)),t}),[]),t},getRiskCharacteristics(){this.instance.get("/meituanCaseTag/riskCharacteristics",{params:{}}).then(t=>{let e=t.data;1==e.code&&(this.parentLevelOption=[],this.childLevelOption=[],this.levelOptionObj={},e.data.length>0&&e.data.forEach((t,e)=>{t.label=t.key,t.value=t.key+e,t.val.length>0&&(t.children=t.val,t.val.forEach((t,e)=>{t.value=t["key"]+e,t.label=t.key}),this.levelOptionObj[t["key"]]=t["val"])}),this.tmpOptions=e.data)})},hanleVerify(t,e,i){if(this.verifyRadio="",this.dialogVisibleVerify=!0,this.verifyTitle=e,this.verifyValue=t,this.checkedRow=i,this.conclusionTags=[],this.tmpDatas=[],i.firstVerdictType){let t=this.levelOptionObj[i.firstVerdictType];i.firstVerdictList.forEach(e=>{t.forEach(t=>{t.key==e&&(this.conclusionTags.push(t),this.tmpOptions.forEach(e=>{e.label==i.firstVerdictType&&this.tmpDatas.push([e.value,t.value])}))})})}else if(i.verdictType){let t=this.levelOptionObj[i.verdictType];i.verdictList.forEach(e=>{t.forEach(t=>{t.key==e&&(this.conclusionTags.push(t),this.tmpOptions.forEach(e=>{e.label==i.verdictType&&this.tmpDatas.push([e.value,t.value])}))})})}},updateCaseTag(){let t=JSON.parse(JSON.stringify(this.checkedRow)),e=[],i=!1;this.conclusionTags.length>0&&this.conclusionTags.forEach(t=>{e.push(t.label)}),1==this.verifyValue?(t.modelVerify="",t.oneselfVerify=this.verifyRadio,t.firstVerdictList=e,t.firstVerdictType=this.conclusionParent.length>0&&this.unique(this.conclusionParent)[0].name):2==this.verifyValue&&(t.oneselfVerify="",t.modelVerify=this.verifyRadio,t.verdictList=e,t.verdictType=this.conclusionParent.length>0&&this.unique(this.conclusionParent)[0].name),0==this.tmpDatas.length?this.$message.error("请选择验证依据。"):i=!0,i&&this.instance.post("/meituanCaseTag/updateCaseTag",t).then(t=>{1==t.data.code&&(this.getTbodyData(),this.cancelCaseDialog(),this.$message.success("恭喜你,保存成功!"))})},cancelCaseDialog(){this.conclusionTags=[],this.verifyRadio="",this.tmpDatas=[],this.dialogVisibleVerify=!1},caseClosedStatusChange(t){let e=JSON.parse(JSON.stringify(this.baseStatusOptions));if(""==t)this.statusOptions=e;else{let i=[];e.forEach((e,s)=>{t==e.type&&i.push(e)}),this.statusOptions=i}},getCaseStatus(){this.restaurants=[],this.instance.get("/case/getCaseStatus",{params:{}}).then(t=>{1==t.data.code&&(this.statusOptions=t.data.data,this.baseStatusOptions=t.data.data)})},sortChange(t){this.navForm.sortField=t.prop,this.navForm.sortOrder="ascending"==t.order?"asc":"desc",this.getTbodyData()},handleAttention(t,e){var i="此操作表示已关注该风险,将修改案件信息, 是否继续?";2==e.riskType&&(i="此操作表示已核实该提示内容符合实情, 无风险,是否继续?"),this.$confirm(i,"提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(()=>{var t={id:e.id,status:1==e.riskType?1:2,stage:e.stage,meituanCaseNo:this.checkedRowDetail.meituanCaseNo};this.instance.post("/case/operationMark",t).then(t=>{1==t.data.code&&(e.status=1==e.riskType?1:2,2==e.status&&this.checkedRowDetail.numberOfRiskPoints--,this.$message({type:"success",message:t.data.message}))})}).catch(()=>{this.$message({type:"info",message:"已取消"})})},handleRemove(t,e){this.caseExcelData=[]},getCommonFilterOptionList(){this.instance.post("/case/getCommonFilterOptionList",{}).then(t=>{1==t.data.code&&(this.riskOptions=t.data.data)})},lookDetails(t){const e=this.$loading({lock:!0,text:"Loading",spinner:"el-icon-loading",background:"rgba(0, 0, 0, 0.7)"});this.instance.post("/case/getCaseDetail",{caseNo:t.caseNo}).then(t=>{e.close(),1==t.data.code&&(this.dialogVisible=!0,this.stepsActive=0,this.checkedRowDetail=t.data.data,t.data.data.stageOfCaseVoList.forEach((t,e)=>{t.arrivalOrNot&&(this.stepsActive=e)}))})},handleAvatarSuccess(t,e){this.fullscreenLoading.close(),this.fileName=e.name,this.uploadFile=t.data,1==t.code?(this.$message.success(t.message),this.caseExcelData=t.data):this.$message.error(t.message)},beforeAvatarUpload(t){if(t.size/1024>5e3)return this.$message.error("抱歉,上传文件不得大于5M!"),!1;this.unloaderHeader.Authorization="Bearer "+Object(o["c"])(),this.fullscreenLoading=this.$loading({lock:!0,text:"上传中,请稍后",spinner:"el-icon-loading",background:"rgba(0, 0, 0, 0.7)"})},handleSelectionChange(t){this.multipleSelection=t},searchTable(){this.caseExcelData.length>0||this.navForm.caseNo||this.navForm.startTime&&this.navForm.endTime||this.navForm.reportStartTime&&this.navForm.reportEndTime?(this.currentPage=1,this.getTbodyData()):this.$message.error("请上传文件或者选择结案时间、报案时间之后再查询!")},searchTagCount(t){this.instance.post("/meituanCaseTag/searchTagCount",t).then(t=>{1==t.data.code&&(this.tagCount=t.data.data||{})})},getTbodyData(){this.loading=!0,this.tableData=[];var t=JSON.parse(JSON.stringify(this.navForm));t.meituanCaseInfoList=this.caseExcelData,this.nowFilter=JSON.parse(JSON.stringify(t)),t.pageNum=this.currentPage,t.pageSize=this.pageSize,this.searchTagCount(t),this.instance.post("/meituanCaseTag/searchPage",t).then(t=>{this.loading=!1,1==t.data.code?(this.tableData=t.data.data.list,this.totalPage=parseInt(t.data.data.total)):this.totalPage=0})},handleSizeChange(t){this.pageSize=t,this.getTbodyData()},handleCurrentChange(t){this.currentPage=Number(t),this.getTbodyData()},handleDownload(){var t=JSON.parse(JSON.stringify(this.nowFilter));this.fullscreenLoading=this.$loading({lock:!0,text:"下载中,请稍后",spinner:"el-icon-loading",background:"rgba(0, 0, 0, 0.7)"}),this.instance({method:"post",url:"/case/exportCaseExcel",data:t,responseType:"blob",headers:{}}).then(t=>{if(this.fullscreenLoading.close(),t.data.size<200)return this.$message.error("单次下载案件不能超过10000条,请分段下载!"),!1;let e=window.URL.createObjectURL(new Blob([t.data])),i=document.createElement("a");i.style.display="none",i.href=e,i.setAttribute("download","案件下载清单.csv"),document.body.appendChild(i),i.click()}).catch((function(t){console.log(t)}))}},mounted(){this.getCaseStatus(),this.baseURL=this.$store.getters.baseURL;const t=new Date;let e=new Date(t.getTime()-6048e5);this.navForm.reportStartTime=this.dateFormatting(e,"yyyy-MM-dd"),this.navForm.reportEndTime=this.dateFormatting(t,"yyyy-MM-dd"),this.getTbodyData(),this.getRiskCharacteristics()}},r=n,l=(i("499d"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"2de4759b",null);e["default"]=h.exports},3311:function(t,e,i){},"341e":function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],staticClass:"module_wrap box_border",attrs:{"element-loading-text":"数据加载中","element-loading-spinner":"el-icon-loading","element-loading-background":"transparent"}},[e("div",{staticClass:"box_title"},[t._v(t._s("全国"==t.navForm.accidentProvince?"全国伤残案均金额排行榜":"伤残损案均金额统计"))]),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.loading,expression:"!loading"}],staticStyle:{height:"55%"}},[e("div",{directives:[{name:"show",rawName:"v-show",value:"全国"==t.province,expression:"province == '全国'"}],attrs:{id:"assessment_deviation_bar"}}),e("div",{directives:[{name:"show",rawName:"v-show",value:"全国"!=t.province,expression:"province != '全国'"}],attrs:{id:"assessment_deviation_bar2"}}),t.tableData.length>0?e("div",{staticClass:"tables_box"},[e("el-table",{attrs:{data:[t.tableData[0]],"max-height":"200"}},t._l(t.tableData,(function(i,s){return e("el-table-column",{key:s,attrs:{label:i.accItem,width:String(i.accAmount).length>5?"100":""},scopedSlots:t._u([{key:"default",fn:function(e){return[t._e(),t._v(" "+t._s(i.accAmount?i.accAmount:"--")+" 元 ")]}}],null,!0)})})),1)],1):t._e()])])},a=[],o=(i("0faf"),i("b3ec"),i("6fc2"),i("2130"),i("ada4")),n={name:"AssessmentDeviation",props:{isCollapse:{type:Boolean,default:!0},navForm:{type:Object,default:{}}},watch:{isCollapse(){setTimeout(()=>{this.myChart&&this.myChart.resize()},600)},navForm:{immediate:!0,deep:!0,handler(t){this.province=t.accidentProvince,this.getData()}}},data(){return{topDays:[],newNumber:0,myChart:"",myChart2:"",option:"",province:"",tableData:[],loading:!0}},mounted(){this.role=localStorage.getItem("role"),window.addEventListener("resize",()=>{this.myChart&&setTimeout(()=>{this.myChart.resize()},500)})},methods:{getData(){this.loading=!0,this.instance({method:"post",url:"/large/data/screen/disabledRanking",data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(this.loading=!1,1==t.data.code){let e=t.data.data;if(e.length>0){let t=e.map(t=>({...t,accItem:this.$$abbreviateCity(t.accItem)}));"全国"==this.province?(t=t.splice(0,20),this.loadCharts(t)):this.loadCharts2(t)}}})},loadCharts2(t){var e=document.getElementById("assessment_deviation_bar2");if(!e)return;this.myChart2=o["init"](e,null,{renderer:"svg"});let i=[],s=[],a=[];t.forEach((t,e)=>{i.push(t.accItem),s.push(t.prvAmount),a.push(t.accAmount)}),this.tableData=t;let n={tooltip:{confine:!0,formatter:"{b}: {c}元",axisPointer:{type:"shadow"}},legend:{data:[this.province,"全国"],itemWidth:12,itemHeight:12,itemGap:20,textStyle:{color:"#fff"},left:"center"},grid:{top:25,left:"10",right:"10",bottom:"10",containLabel:!0},xAxis:{type:"category",splitLine:{show:!1},axisTick:{show:!0,alignWithLabel:!0},axisLabel:{showMaxLabel:!0,rotate:30,color:"#fff",width:70,overflow:"truncate",ellipsis:"..."},data:i},yAxis:{splitLine:{show:!1},axisTick:{show:!1},axisLabel:{color:"#fff",formatter:"{value} 元"}},series:[{name:this.province,type:"bar",itemStyle:{color:"#A55576"},stack:"total",barMaxWidth:"40%",data:s},{name:"全国",type:"bar",itemStyle:{color:new o["graphic"].LinearGradient(0,0,0,1,[{offset:0,color:"#FFFFFF"},{offset:1,color:"#52D3AA"}])},stack:"total",barMaxWidth:"40%",data:a}]};this.myChart2.setOption(n)},loadCharts(t){var e=document.getElementById("assessment_deviation_bar");if(!e)return;this.myChart&&this.myChart.dispose(),this.myChart=o["init"](e,null,{renderer:"svg"});let i=[],s=[];t.forEach((t,e)=>{i.push(t.accItem),s.push(t.accAmount)}),this.tableData=t;let a={tooltip:{confine:!0,formatter:"{b}: {c}元",axisPointer:{type:"shadow"}},legend:{itemWidth:12,itemHeight:12,itemGap:20,textStyle:{color:"#fff"},left:"center"},grid:{top:25,left:"10",right:"10",bottom:"10",containLabel:!0},xAxis:{type:"category",splitLine:{show:!1},axisTick:{show:!0,alignWithLabel:!0},axisLabel:{showMaxLabel:!0,rotate:30,color:"#fff",width:70,overflow:"truncate",ellipsis:"..."},data:i},yAxis:{splitLine:{show:!1},axisTick:{show:!1},axisLabel:{color:"#fff",formatter:"{value} 元"}},series:[{type:"bar",itemStyle:{color:new o["graphic"].LinearGradient(0,0,0,1,[{offset:0,color:"#FFFFFF"},{offset:1,color:"#52D3AA"}])},stack:"total",barMaxWidth:"35%",data:s}]};this.myChart.setOption(a,!0)}},updated(){this.myChart&&this.myChart.resize()}},r=n,l=(i("cf9b"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"68c6c8d5",null);e["default"]=h.exports},3659:function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],staticClass:"module_wrap box_border",attrs:{"element-loading-text":"数据加载中","element-loading-spinner":"el-icon-loading","element-loading-background":"transparent"}},[e("div",{staticClass:"box_title"},[t._v("公估公司吞吐率统计")]),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.loading,expression:"!loading"}],staticStyle:{height:"100%"}},[e("div",{attrs:{id:"rate_pie"}}),t.tableData.length>0?e("div",{staticClass:"tables_box"},[e("el-table",{attrs:{data:[t.tableData[0]],"max-height":"200"}},t._l(t.tableData,(function(i,s){return e("el-table-column",{key:s,attrs:{label:i.assessor,width:"全国"==t.province?"":"100"},scopedSlots:t._u([{key:"default",fn:function(a){return[t._e(),e("p",[t._v(t._s(i.assessorCaseNum?i.assessorCaseNum:"0")+" "),s>0?e("span",[t._v("件")]):t._e()]),e("p",[t._v(t._s(i.assessorTagCaseNum?i.assessorTagCaseNum:"0")+" "),s>0?e("span",[t._v("件")]):t._e()]),e("p",[t._v(t._s(i.assessorRatio?i.assessorRatio:"0")+" "),s>0?e("span",[t._v("%")]):t._e()])]}}],null,!0)})})),1)],1):t._e()])])},a=[],o=(i("0faf"),i("b3ec"),i("6fc2"),i("e4c6"),i("320b"),i("ada4")),n={name:"CaseRate",props:{isCollapse:{type:Boolean,default:!0},navForm:{type:Object,default:{}}},watch:{isCollapse(){setTimeout(()=>{this.myChart&&this.myChart.resize()},600)},navForm:{deep:!0,handler(t){this.province=t.accidentProvince,this.getData()}}},data(){return{topDays:[],newNumber:0,myChart:"",tableData:[],loading:!0,province:""}},mounted(){this.role=localStorage.getItem("role"),this.getData(),window.addEventListener("resize",()=>{this.myChart&&setTimeout(()=>{this.myChart.resize()},500)})},methods:{getData(){this.loading=!0;let t="";this.instance({method:"post",url:t+"/large/data/screen/meituanThroughputRate",data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(this.loading=!1,1==t.data.code){let e=t.data.data;e.length>0&&this.loadCharts(e)}})},loadCharts(t){var e=document.getElementById("rate_pie");if(!e)return;this.myChart&&this.myChart.dispose(),this.myChart=o["init"](e,null,{renderer:"svg"});let i=[],s=[];t.forEach((t,e)=>{i.push(t.assessor),s.push(t.assessorRatio)}),this.tableData=JSON.parse(JSON.stringify(t)),this.tableData.unshift({assessor:"公估公司",assessorCaseNum:"报案量",assessorTagCaseNum:"结案量",assessorRatio:"吞吐率"});var a={tooltip:{trigger:"axis",axisPointer:{type:"shadow"},formatter:function(e){let i=e[0].dataIndex;return e[0].name+"
报案量:"+t[i].assessorCaseNum+"件
结案量:"+t[i].assessorTagCaseNum+"件
吞吐率:"+t[i].assessorRatio+"%"}},xAxis:{data:i,axisTick:{show:!1},axisLine:{show:!1},axisLabel:{color:"#fff",rotate:40}},yAxis:{splitLine:{show:!1},axisTick:{show:!1},axisLine:{show:!1},axisLabel:{show:!0,color:"#fff",formatter:"{value} %"}},grid:{top:"20",bottom:"0",left:"10",right:"10",containLabel:!0},color:["#5FB3D7"],series:[{name:"hill",type:"pictorialBar",barCategoryGap:"-40%",label:{position:"top",color:"#fff",formatter:"{c}%"},symbol:"path://M0,10 L10,10 C5.5,10 5.5,5 5,0 C4.5,5 4.5,10 0,10 z",itemStyle:{},barWidth:"80%",emphasis:{itemStyle:{opacity:1}},data:s,z:10}]};this.myChart.setOption(a)}},updated(){this.myChart&&this.myChart.resize()}},r=n,l=(i("96e5"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"5a5839e2",null);e["default"]=h.exports},3717:function(t,e,i){},3839:function(t,e,i){},"385f":function(t,e,i){"use strict";i("caa1")},"394e":function(t,e,i){"use strict";i("8b91")},3958:function(t,e,i){},"3b0c":function(t,e,i){},"3b71":function(t,e,i){"use strict";var s=TypeError;t.exports=function(t,e){if(t0?e("div",{staticClass:"tables_box"},[e("el-table",{attrs:{data:[t.tableData[0]],"max-height":"200"}},t._l(t.tableData,(function(i,s){return e("el-table-column",{key:s,attrs:{label:i.accItem,width:String(i.accAmount).length>5?"100":""},scopedSlots:t._u([{key:"default",fn:function(e){return[t._e(),t._v(" "+t._s(i.accAmount?i.accAmount:"--")+" 元 ")]}}],null,!0)})})),1)],1):t._e()])])},a=[],o=(i("0faf"),i("b3ec"),i("6fc2"),i("2130"),i("ada4")),n={name:"PassingRate",props:{isCollapse:{type:Boolean,default:!0},navForm:{type:Object,default:{}}},watch:{isCollapse(){setTimeout(()=>{this.myChart&&this.myChart.resize()},600)},navForm:{immediate:!0,deep:!0,handler(t){this.province=t.accidentProvince,this.getData()}}},data(){return{topDays:[],newNumber:0,myChart:"",myChart2:"",option:"",province:"",tableData:[],loading:!0}},mounted(){this.role=localStorage.getItem("role"),window.addEventListener("resize",()=>{this.myChart&&setTimeout(()=>{this.myChart.resize()},500)})},methods:{getData(){this.loading=!0,this.instance({method:"post",url:"/large/data/screen/humanInjuryRanking",data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(this.loading=!1,1==t.data.code){let e=t.data.data;if(e.length>0){let t=e.map(t=>({...t,accItem:this.$$abbreviateCity(t.accItem)}));"全国"==this.province?(t=t.splice(0,20),this.loadCharts(t)):this.loadCharts2(t)}}})},loadCharts2(t){var e=document.getElementById("passing_rate_bar2");if(!e)return;this.myChart2&&this.myChart2.dispose(),this.myChart2=o["init"](e,null,{renderer:"svg"});let i=[],s=[],a=[];t.forEach((t,e)=>{i.push(t.accItem),s.push(t.prvAmount),a.push(t.accAmount)}),this.tableData=t;let n={tooltip:{trigger:"axis"},legend:{textStyle:{color:"#fff",fontSize:12},itemGap:20},grid:{top:25,left:"10",right:"10",bottom:"10",containLabel:!0},xAxis:[{type:"category",boundaryGap:!1,axisLine:{show:!0,lineStyle:{color:"#233653"}},axisLabel:{showMaxLabel:!0,rotate:30,color:"#fff",width:70,overflow:"truncate",ellipsis:"..."},splitLine:{show:!1},axisTick:{show:!1},data:i}],yAxis:[{nameTextStyle:{color:"#7ec7ff",fontSize:12,padding:10},min:0,splitLine:{show:!1},axisTick:{show:!1},axisLabel:{color:"#fff",formatter:"{value} 元"}}],series:[{name:this.province,type:"line",symbol:"circle",showAllSymbol:!0,symbolSize:0,smooth:!0,lineStyle:{normal:{width:2,color:"#519B37"}},itemStyle:{color:"#519B37"},tooltip:{valueFormatter:function(t){return t+" 元"}},areaStyle:{normal:{color:new o["graphic"].LinearGradient(0,0,0,1,[{offset:0,color:"rgba(77,192,36,.3)"},{offset:1,color:"rgba(77,192,36, 0)"}],!1),shadowColor:"rgba(10,219,250, 0.5)",shadowBlur:20}},data:s},{name:"全国",type:"line",symbol:"circle",showAllSymbol:!0,symbolSize:0,smooth:!0,lineStyle:{normal:{width:2,color:"#BFCD3D"}},itemStyle:{color:"#BFCD3D"},tooltip:{valueFormatter:function(t){return t+" 元"}},areaStyle:{normal:{color:new o["graphic"].LinearGradient(0,0,0,1,[{offset:0,color:"rgba(248,172,6,.3)"},{offset:1,color:"rgba(248,172,6, 0)"}],!1),shadowColor:"rgba(10,219,250, 0.5)",shadowBlur:20}},data:a}]};this.myChart2.setOption(n)},loadCharts(t){var e=document.getElementById("passing_rate_bar");if(!e)return;this.myChart=o["init"](e,null,{renderer:"svg"});let i=[],s=[];t.forEach((t,e)=>{i.push(t.accItem),s.push(t.accAmount)}),this.tableData=t;const a=8,n=4,r=o["graphic"].extendShape({shape:{x:0,y:0},buildPath:function(t,e){const i=e.xAxisPoint,s=[e.x,e.y],o=[e.x-a,e.y-n],r=[i[0]-a,i[1]-n],l=[i[0],i[1]];t.moveTo(s[0],s[1]).lineTo(o[0],o[1]).lineTo(r[0],r[1]).lineTo(l[0],l[1]).closePath()}}),l=o["graphic"].extendShape({shape:{x:0,y:0},buildPath:function(t,e){const i=e.xAxisPoint,s=[e.x,e.y],o=[i[0],i[1]],r=[i[0]+a,i[1]-n],l=[e.x+a,e.y-n];t.moveTo(s[0],s[1]).lineTo(o[0],o[1]).lineTo(r[0],r[1]).lineTo(l[0],l[1]).closePath()}}),h=o["graphic"].extendShape({shape:{x:0,y:0},buildPath:function(t,e){const i=[e.x,e.y],s=[e.x+a,e.y-n],o=[e.x,e.y-a],r=[e.x-a,e.y-n];t.moveTo(i[0],i[1]).lineTo(s[0],s[1]).lineTo(o[0],o[1]).lineTo(r[0],r[1]).closePath()}});o["graphic"].registerShape("CubeLeft",r),o["graphic"].registerShape("CubeRight",l),o["graphic"].registerShape("CubeTop",h);let d={tooltip:{trigger:"axis",axisPointer:{type:"shadow"},formatter:"{b0} : {c0}元"},grid:{top:20,left:"10",right:"10",bottom:"10",containLabel:!0},xAxis:{type:"category",data:i,axisLabel:{showMaxLabel:!0,rotate:40,color:"#fff",width:60,overflow:"truncate",ellipsis:"..."},axisTick:{alignWithLabel:!0}},yAxis:{type:"value",splitLine:{show:!1},axisTick:{show:!1},axisLabel:{color:"#fff",formatter:"{value} 元"}},series:[{type:"custom",renderItem:(t,e)=>{const i=e.coord([e.value(0),e.value(1)]);return{type:"group",children:[{type:"CubeLeft",shape:{api:e,xValue:e.value(0),yValue:e.value(1),x:i[0],y:i[1],xAxisPoint:e.coord([e.value(0),0])},style:{fill:new o["graphic"].LinearGradient(0,0,0,1,[{offset:0,color:"#ffffff"},{offset:1,color:"#ADE050"}])}},{type:"CubeRight",shape:{api:e,xValue:e.value(0),yValue:e.value(1),x:i[0],y:i[1],xAxisPoint:e.coord([e.value(0),0])},style:{fill:new o["graphic"].LinearGradient(0,0,0,1,[{offset:0,color:"#ffffff"},{offset:1,color:"#ADE050"}])}},{type:"CubeTop",shape:{api:e,xValue:e.value(0),yValue:e.value(1),x:i[0],y:i[1],xAxisPoint:e.coord([e.value(0),0])},style:{fill:new o["graphic"].LinearGradient(0,0,0,1,[{offset:0,color:"#FFFFFF"},{offset:1,color:"#FFFFFF"}])}}]}},data:s},{type:"bar",itemStyle:{color:"transparent"},tooltip:{},data:s}]};this.myChart.setOption(d,!0)}},updated(){this.myChart&&this.myChart.resize()}},r=n,l=(i("d8bb"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"06f32db2",null);e["default"]=h.exports},4619:function(t,e,i){t.exports=i.p+"img/success_icon.7a9bbf6b.png"},"48fc":function(module,__webpack_exports__,__webpack_require__){"use strict";var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__("0faf"),core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default=__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__),core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__=__webpack_require__("b3ec"),core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1___default=__webpack_require__.n(core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__),core_js_modules_es_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_2__=__webpack_require__("6fc2"),core_js_modules_es_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_2___default=__webpack_require__.n(core_js_modules_es_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_2__),echarts__WEBPACK_IMPORTED_MODULE_3__=__webpack_require__("ada4");__webpack_exports__["a"]={name:"CaseTime",props:{isCollapse:{type:Boolean,default:!0},navForm:{type:Object,default:{}}},watch:{isCollapse(){setTimeout(()=>{this.myChart&&this.myChart.resize()},600)},navForm:{deep:!0,handler(t){this.province=t.accidentProvince,this.getData()}}},data(){return{topDays:[],newNumber:0,myChart:""}},mounted(){this.role=localStorage.getItem("role"),this.getData(),window.addEventListener("resize",()=>{this.myChart&&setTimeout(()=>{this.myChart.resize()},500)})},methods:{getData(){this.instance({method:"post",url:"/large/data/screen/meituanCaseReportingVo",data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(1==t.data.code){let e=t.data.data;e.length>0&&this.loadCharts(e)}})},loadCharts(response){var chartDom=document.getElementById("case_time_bar");if(!chartDom)return;this.myChart&&this.myChart.dispose(),this.myChart=echarts__WEBPACK_IMPORTED_MODULE_3__["init"](chartDom,null,{renderer:"svg"});let xAxisData=[],seriesData=[];response.forEach((t,e)=>{xAxisData.push(t.name+"天"),seriesData.push(t.caseNumRatio)});var total=eval(seriesData.join("+")),option={tooltip:{formatter(t){let e=t.dataIndex;return t.name+": "+response[e].caseNum+"件"},show:!0},grid:{top:20,left:"10",right:"10",bottom:"10",containLabel:!0},xAxis:{type:"category",axisLabel:{showMaxLabel:!0,textStyle:{color:"#fff"}},axisTick:{alignWithLabel:!0},data:xAxisData},yAxis:{type:"value",axisLabel:{showMaxLabel:!0,textStyle:{color:"#fff"}},splitLine:{show:!1},axisTick:{show:!1}},series:[{type:"bar",barWidth:"40%",data:seriesData,label:{show:!0,position:"top",color:"#fff",formatter:"{c} %"},itemStyle:{color:new echarts__WEBPACK_IMPORTED_MODULE_3__["graphic"].LinearGradient(0,0,0,1,[{offset:0,color:"#e7a0a6"},{offset:.5,color:"#dc7b86"},{offset:1,color:"#d7636e"}])}}]};this.myChart.setOption(option)}}}},"499d":function(t,e,i){"use strict";i("999c")},"49f2":function(t,e,i){"use strict";i.r(e);var s=function(){var t=this;t._self._c;return t._m(0)},a=[function(){var t=this,e=t._self._c;return e("div",{staticClass:"module_wrap box_border"},[e("div",{staticClass:"box_title"},[t._v("结案周期分布")]),e("div",{attrs:{id:"case_cycle_pie"}})])}],o=(i("0faf"),i("b3ec"),i("6fc2"),i("ada4")),n={name:"CaseCycle",props:{isCollapse:{type:Boolean,default:!0},navForm:{type:Object,default:{}}},watch:{isCollapse(){setTimeout(()=>{this.myChart&&this.myChart.resize()},600)},navForm:{deep:!0,handler(t){this.province=t.accidentProvince,this.getData()}}},data(){return{topDays:[],newNumber:0,myChart:""}},mounted(){this.role=localStorage.getItem("role"),this.getData(),window.addEventListener("resize",()=>{this.myChart&&setTimeout(()=>{this.myChart.resize()},500)})},methods:{getData(){this.instance({method:"post",url:"/large/data/screen/meituanCaseNumVo",data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(1==t.data.code){let e=t.data.data;e.length>0&&this.loadCharts(e)}})},loadCharts(t){var e=document.getElementById("case_cycle_pie");if(!e)return;this.myChart&&this.myChart.dispose(),this.myChart=o["init"](e,null,{renderer:"svg"});let i=[];t.forEach((t,e)=>{let s={value:t.caseNum,name:t.name,itemStyle:{borderColor:"#E3A505",shadowColor:"#433f24"}};1==e?s.itemStyle={borderColor:"#98fd7f",shadowColor:"#195c4b"}:2==e?s.itemStyle={borderColor:"#D1818B",shadowColor:"#632053"}:3==e&&(s.itemStyle={borderColor:"#2485af",shadowColor:"#082159"}),i.push(s)});var s={tooltip:{trigger:"item",formatter:"{b}: {c}件",confine:!0},legend:{bottom:"5%",itemWidth:12,itemHeight:12,textStyle:{color:"#fff"},left:"center"},series:[{type:"pie",radius:"55%",center:["50%","40%"],avoidLabelOverlap:!1,label:{position:"inner",fontSize:10,color:"#fff",formatter:"{d}%"},labelLine:{show:!1},itemStyle:{borderColor:"#e4393c",borderWidth:5,color:"#0A1A2E",shadowBlur:5,shadowColor:"rgba(85, 255, 0, 1)"},selectedMode:"single",data:i}]};this.myChart.setOption(s,!0)}}},r=n,l=(i("0354"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"7fe3d7b2",null);e["default"]=h.exports},"4f4d":function(t,e,i){"use strict";i("24f0")},"4f8c":function(t,e,i){},"4fd9":function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{staticClass:"module_wrap box_border"},[e("div",{staticClass:"box_border ratio_box"},[e("div",[e("b",[t._v("结案率:")]),e("span",[t._v(t._s(t.casesData.closingRate)+"%")])]),e("div",[e("b",[t._v("24小时报案率:")]),e("span",[t._v(t._s(t.casesData.durationOfFirstReportingDelay)+"%")])])]),e("ul",{staticClass:"ratio_ul"},[e("li",{staticClass:"box_border"},[e("b",[t._v("已决案件")]),e("div",[t._v(t._s(t.casesData.settledCaseNo)+" (笔)")])]),e("li",{staticClass:"box_border"},[e("b",[t._v("已决总赔款")]),e("div",[t._v(t._s(t.casesData.totalCompensationAmount)+" (万元)")])]),e("li",{staticClass:"box_border"},[e("b",[t._v("未决案件")]),e("div",[t._v(t._s(t.casesData.unsettledCaseNo)+" (笔)")])]),e("li",{staticClass:"box_border"},[e("b",[t._v("未决总估损")]),e("div",[t._v(t._s(t.casesData.predictCompensationAmount)+" (万元)")])])]),e("div",{staticClass:"box_border ratio_box bottom_box"},[e("div",[e("div",{staticStyle:{height:"50%","margin-top":"-10px"}},[e("b",[t._v("吞吐率:")]),e("span",[t._v(t._s(t.casesData.throughputRate)+"%")])]),e("p",[t._v("吞吐率结果与时间类型(报案/结案)无关,仅与所选统计周期相关。")])])])])},a=[],o={name:"SettleLawsuit",props:{navForm:{type:Object,default:()=>({})}},watch:{navForm:{deep:!0,handler(t){this.getData()}}},data(){return{casesData:{},newNumber:0}},mounted(){this.role=localStorage.getItem("role"),this.getData()},methods:{getData(){this.instance({method:"post",url:"/large/data/screen/meituanCaseData",data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{1==t.data.code&&(this.casesData=t.data.data)})}}},n=o,r=(i("3db5"),i("8f38"),i("1805")),l=Object(r["a"])(n,s,a,!1,null,"8d57dd2a",null);e["default"]=l.exports},"538b":function(t,e,i){"use strict";var s=function(){var t=this,e=t._self._c;return e("div",{staticClass:"wrap"},[t._e(),e("div",{staticClass:"public_box"},[e("div",{staticClass:"box_content"},[e("p",{staticClass:"box_title title_hot"},[t._v("案件基础条件")]),e("el-row",[e("el-col",{attrs:{span:7,offset:1}},[e("span",[t._v("案件号:"+t._s(t.caseData.caseNo))])]),e("el-col",{attrs:{span:6}},[e("span",[t._v("保单号:"+t._s(t.caseData.policyNo))])]),e("el-col",{attrs:{span:10}},[e("span",[t._v("保险公司:"+t._s(t.caseData.insureCompany))])])],1),e("el-row",[e("el-col",{attrs:{span:7,offset:1}},[e("span",[t._v("报案时间:"+t._s(t.caseData.reportTime))])]),e("el-col",{attrs:{span:6}},[e("span",[t._v("结案时间:"+t._s(t.caseData.closeTime))])]),e("el-col",{attrs:{span:10}},[e("span",[t._v("险种:"+t._s(t.caseData.insureType))])])],1),e("el-row",[e("el-col",{attrs:{span:7,offset:1}},[e("span",[t._v("案件时长:"+t._s(t.caseData.caseTimeStr))])]),e("el-col",{attrs:{span:6}},[e("span",[t._v("实际赔付金额:"+t._s(t.caseData.payAmount?t.caseData.payAmount:"")+" 元")])]),e("el-col",{attrs:{span:10}},[e("span",[t._v("案件状态:"+t._s(t.caseData.caseStatus))])])],1),e("el-row",[e("el-col",{attrs:{span:7,offset:1}},[e("span",[t._v("事故地点:"+t._s(t.caseData.accidentAddress))])])],1)],1),e("div",{staticClass:"box_content"},[e("p",{staticClass:"box_title title_hot"},[t._v("质检情况反馈")]),e("el-row",[e("el-col",{attrs:{span:7,offset:1}},[e("span",[t._v("质检人:"+t._s(t.caseData.username))])]),e("el-col",{attrs:{span:6}},[e("span",[t._v("时长:"+t._s(t.caseData.consumeTimeStr))])]),e("el-col",{attrs:{span:10}},[e("span",[t._v("任务分配时间:"+t._s(t.caseData.inletTime))])])],1),e("el-row",[e("el-col",{attrs:{span:7,offset:1}},[e("span",[t._v("开始时间:"+t._s(t.caseData.handlerTime))])]),e("el-col",{attrs:{span:6}},[e("span",[t._v("结束时间:"+t._s(t.caseData.submitTime))])]),e("el-col",{attrs:{span:10}},[e("span",[t._v("人工理算金额总和:"+t._s(t.caseData.adjustAmount))])])],1),t.caseData.submit?e("el-form",{ref:"ruleForm",staticClass:"demo-ruleForm",attrs:{model:t.navForm,rules:t.navFormRules}},[e("el-row",[e("el-col",{attrs:{span:6,offset:1}},[e("el-form-item",{staticClass:"label_title",attrs:{label:"车损人工理算金额:",prop:"vehicleDamageAmount"}},[e("el-row",[e("el-col",{attrs:{span:13}},[e("el-input",{model:{value:t.navForm.vehicleDamageAmount,callback:function(e){t.$set(t.navForm,"vehicleDamageAmount",e)},expression:"navForm.vehicleDamageAmount"}})],1)],1)],1)],1),e("el-col",{attrs:{span:10,offset:1}},[e("el-form-item",{attrs:{label:"原因:",prop:"vehicleDamageReason"}},[e("el-col",{attrs:{span:10}},[e("el-input",{attrs:{type:"textarea",rows:2,placeholder:"请输入内容"},model:{value:t.navForm.vehicleDamageReason,callback:function(e){t.$set(t.navForm,"vehicleDamageReason",e)},expression:"navForm.vehicleDamageReason"}})],1)],1)],1)],1),e("el-row",[e("el-col",{attrs:{span:6,offset:1}},[e("el-form-item",{staticClass:"label_title",attrs:{label:"人伤人工理算金额:",prop:"humanInjuryAmount"}},[e("el-row",[e("el-col",{attrs:{span:13}},[e("el-input",{model:{value:t.navForm.humanInjuryAmount,callback:function(e){t.$set(t.navForm,"humanInjuryAmount",e)},expression:"navForm.humanInjuryAmount"}})],1)],1)],1)],1),e("el-col",{attrs:{span:10,offset:1}},[e("el-form-item",{attrs:{label:"原因:",prop:"humanInjuryReason"}},[e("el-col",{attrs:{span:10}},[e("el-input",{attrs:{type:"textarea",rows:2,placeholder:"请输入内容"},model:{value:t.navForm.humanInjuryReason,callback:function(e){t.$set(t.navForm,"humanInjuryReason",e)},expression:"navForm.humanInjuryReason"}})],1)],1)],1)],1)],1):t._e(),t.caseData.submit?e("el-row",{staticClass:"text_center"},[e("el-button",{attrs:{type:"primary"},on:{click:function(e){return t.submitForm("ruleForm")}}},[t._v("提交")])],1):t._e(),t.caseData.submit?t._e():e("el-row",[e("el-col",{attrs:{span:6,offset:1}},[e("span",[t._v("车损人工理算金额:"+t._s(t.caseData.vehicleDamageAmount))])]),e("el-col",{attrs:{span:8,offset:1}},[e("span",[t._v("原因:"+t._s(t.caseData.vehicleDamageReason))])])],1),t.caseData.submit?t._e():e("el-row",[e("el-col",{attrs:{span:6,offset:1}},[e("span",[t._v("人伤人工理算金额:"+t._s(t.caseData.humanInjuryAmount))])]),e("el-col",{attrs:{span:8,offset:1}},[e("span",[t._v("原因:"+t._s(t.caseData.humanInjuryReason))])])],1)],1)])])},a=[],o=(i("e4c6"),{name:"caseInfo",props:{caseData:{}},data(){return{navForm:{humanInjuryAmount:"",humanInjuryReason:"",vehicleDamageAmount:"",vehicleDamageReason:""},navFormRules:{vehicleDamageAmount:[{required:!0,message:"请输入内容",trigger:"blur"}],vehicleDamageReason:[{required:!0,message:"请输入内容",trigger:"blur"}],humanInjuryAmount:[{required:!0,message:"请输入内容",trigger:"blur"}],humanInjuryReason:[{required:!0,message:"请输入内容",trigger:"blur"}]},inputValue:""}},watch:{caseData(t){t&&(this.navForm={humanInjuryAmount:t.humanInjuryAmount,humanInjuryReason:t.humanInjuryReason,vehicleDamageAmount:t.vehicleDamageAmount,vehicleDamageReason:t.vehicleDamageReason})}},methods:{submitForm(t){this.$refs[t].validate(t=>{t&&this.instance.post("/caseJobCheck/commitCaseJob/"+this.caseData.caseNo,this.navForm).then(t=>{let e=t.data;1==e.code?(e.data.rowIndex=this.caseData.rowIndex,this.caseData=e.data,this.caseData.submit=!0,sessionStorage.setItem("caseData",JSON.stringify(this.caseData)),this.$message.success(t.data.message),this.$emit("submitCase",!1)):this.$message.error(t.data.message)})})}}}),n=o,r=(i("ca96"),i("1805")),l=Object(r["a"])(n,s,a,!1,null,null,null);e["a"]=l.exports},"569d":function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return t.modalVisible?e("div",{staticClass:"modal",on:{click:function(e){return e.target!==e.currentTarget?null:t.handleReturn.apply(null,arguments)}}},[e("div",{staticClass:"modal_box"},["success"==t.pageType?[t._m(0),e("div",{staticClass:"modal_success"},[e("el-button",{attrs:{type:"primary",size:"default",plain:""},on:{click:t.handleReturn}},[t._v("提交成功")])],1)]:[t._m(1),e("div",{staticClass:"modal_text"},[e("span",[t._v("共有 ")]),e("b",[t._v(t._s(t.tipsNum)+"项 ")]),e("span",[t._v("报价异常")])]),e("div",{staticClass:"modal_btn_group"},[e("el-button",{attrs:{size:"default"},on:{click:t.handleSubmit}},[t._v("仍要提交")]),e("el-button",{attrs:{size:"default"},on:{click:t.handleReturn}},[t._v("返回修改")])],1)]],2)]):t._e()},a=[function(){var t=this,e=t._self._c;return e("div",{staticClass:"modal_img"},[e("img",{attrs:{src:i("4619")}})])},function(){var t=this,e=t._self._c;return e("div",{staticClass:"modal_img"},[e("img",{attrs:{src:i("fc27")}})])}],o={name:"ResultModal",props:{pageType:{type:String,default:"success"},tipsNum:{type:Number,default:0},modalVisible:{type:Boolean,default:!1}},components:{},data(){return{}},methods:{handleReturn(){this.$emit("handleReturn")},handleSubmit(){this.$emit("addWorkOrders")}}},n=o,r=(i("6a7e"),i("1805")),l=Object(r["a"])(n,s,a,!1,null,"2606f454",null);e["default"]=l.exports},"580d":function(t,e,i){"use strict";i("7b82")},"593c":function(t,e,i){"use strict";i("6e97")},5942:function(t,e,i){},5966:function(t,e,i){"use strict";var s=i("ef37"),a=i("0ddb"),o=i("44bb"),n=i("3b71"),r=URLSearchParams,l=r.prototype,h=a(l.getAll),d=a(l.has),c=new r("a=1");!c.has("a",2)&&c.has("a",void 0)||s(l,"has",(function(t){var e=arguments.length,i=e<2?void 0:arguments[1];if(e&&void 0===i)return d(this,t);var s=h(this,t);n(e,1);var a=o(i),r=0;while(r{let e=t.data;1==e.code?this.getTaskList():this.$message.error(t.data.message)})},lookDetails(t,e,i){if(e&&this.instance.post("/caseJobCheck/handleCaseJob/"+t.caseNo,{}).then(t=>{let e=t.data;1==e.code&&(this.caseRowData=e.data,this.caseRowData.submit=!0,this.caseRowData.rowIndex=i)}),!e){let t=sessionStorage.getItem("caseData")?JSON.parse(sessionStorage.getItem("caseData")):{};this.$set(this.tableData,t.rowIndex,t)}this.caseInfo=e},getTaskList(t){let e=JSON.parse(JSON.stringify(this.navForm));e.page=t?1:e.page,e.size=t?10:e.size,this.instance.post("/caseJobCheck/myPageJob",e).then(t=>{let e=t.data;1==e.code?(this.tableData=e.data.list,this.navForm.size=e.data.size,this.navForm.page=e.data.current,this.navForm.total=e.data.total):this.$message.error(t.data.message)})},handleSizeChange(t){this.navForm.size=t,this.getTaskList()},handleCurrentChange(t){this.navForm.page=t,this.getTaskList()},submitCase(t){this.caseInfo=!1,this.getTaskList()}}},r=n,l=(i("4f4d"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,null,null);e["default"]=h.exports},"5de3":function(t,e,i){"use strict";i("3839")},6032:function(t,e,i){"use strict";i.d(e,"b",(function(){return o})),i.d(e,"c",(function(){return s})),i.d(e,"a",(function(){return a}));var s={"上海市":[121.487899486,31.24916171],"临沧市":[100.092612914,23.8878061038],"丽江市":[100.229628399,26.8753510895],"保山市":[99.1779956133,25.1204891962],"大理白族自治州":[100.223674789,25.5968996394],"德宏傣族景颇族自治州":[98.5894342874,24.441239663],"怒江傈僳族自治州":[98.8599320425,25.8606769782],"文山壮族苗族自治州":[104.246294318,23.3740868504],"昆明市":[102.714601139,25.0491531005],"昭通市":[103.725020656,27.3406329636],"普洱市":[100.98005773,22.7887777801],"曲靖市":[103.782538888,25.5207581429],"楚雄彝族自治州":[101.529382239,25.0663556742],"玉溪市":[102.545067892,24.3704471344],"红河哈尼族彝族自治州":[103.384064757,23.3677175165],"西双版纳傣族自治州":[100.803038275,22.0094330022],"迪庆藏族自治州":[99.7136815989,27.8310294612],"乌兰察布市":[113.112846391,41.0223629468],"乌海市":[106.831999097,39.6831770068],"兴安盟":[122.048166514,46.0837570652],"包头市":[109.846238532,40.6471194257],"呼伦贝尔市":[119.760821794,49.2016360546],"呼和浩特市":[111.66035052,40.8283188731],"巴彦淖尔市":[107.42380672,40.7691799024],"赤峰市":[118.930761192,42.2971123203],"通辽市":[122.260363263,43.633756073],"鄂尔多斯市":[109.993706251,39.8164895606],"锡林郭勒盟":[116.027339689,43.9397048423],"阿拉善盟":[105.695682871,38.8430752644],"北京市":[116.395645038,39.9299857781],"台中市":[119.337634104,26.0911937119],"台北市":[114.130474436,22.3748329286],"台南市":[121.360525873,38.9658447898],"嘉义市":[114.246701335,22.7288657203],"高雄市":[111.590952812,21.9464822541],"吉林市":[126.564543989,43.8719883344],"四平市":[124.391382074,43.1755247011],"延边朝鲜族自治州":[129.485901958,42.8964136037],"松原市":[124.832994532,45.1360489701],"白城市":[122.840776679,45.6210862752],"白山市":[126.435797675,41.945859397],"辽源市":[125.133686052,42.9233026191],"通化市":[125.942650139,41.7363971299],"长春市":[125.313642427,43.8983376071],"乐山市":[103.760824239,29.6009576111],"内江市":[105.073055992,29.5994615348],"凉山彝族自治州":[102.259590803,27.8923929037],"南充市":[106.105553984,30.8009651682],"宜宾市":[104.633019062,28.7696747963],"巴中市":[106.757915842,31.8691891592],"广元市":[105.81968694,32.4410401584],"广安市":[106.635720331,30.4639838879],"德阳市":[104.402397818,31.1311396527],"成都市":[104.067923463,30.6799428454],"攀枝花市":[101.722423152,26.5875712571],"泸州市":[105.443970289,28.8959298039],"甘孜藏族自治州":[101.969232063,30.0551441144],"眉山市":[103.841429563,30.0611150799],"绵阳市":[104.705518975,31.5047012581],"自贡市":[104.776071339,29.3591568895],"资阳市":[104.635930302,30.132191434],"达州市":[107.494973447,31.2141988589],"遂宁市":[105.564887792,30.5574913504],"阿坝藏族羌族自治州":[102.228564689,31.9057628583],"雅安市":[103.009356466,29.9997163371],"天津市":[117.210813092,39.1439299033],"中卫市":[105.196754199,37.5211241916],"吴忠市":[106.208254199,37.9935610029],"固原市":[106.285267996,36.0215234807],"石嘴山市":[106.379337202,39.0202232836],"银川市":[106.206478608,38.5026210119],"亳州市":[115.787928245,33.8712105653],"六安市":[116.505252683,31.7555583552],"合肥市":[117.282699092,31.8669422607],"安庆市":[117.058738772,30.5378978174],"宣城市":[118.752096311,30.9516423543],"宿州市":[116.988692412,33.6367723858],"池州市":[117.494476772,30.6600192482],"淮北市":[116.791447429,33.9600233054],"淮南市":[117.018638863,32.6428118237],"滁州市":[118.324570351,32.3173505954],"芜湖市":[118.384108423,31.3660197875],"蚌埠市":[117.357079866,32.9294989067],"铜陵市":[117.819428729,30.9409296947],"阜阳市":[115.820932259,32.9012113306],"马鞍山市":[118.515881847,31.6885281589],"黄山市":[118.293569632,29.7344348562],"东营市":[118.583926333,37.4871211553],"临沂市":[118.340768237,35.0724090744],"威海市":[122.093958366,37.5287870813],"德州市":[116.328161364,37.4608259263],"日照市":[119.507179943,35.4202251931],"枣庄市":[117.279305383,34.8078830784],"泰安市":[117.089414917,36.1880777589],"济南市":[117.024967066,36.6827847272],"济宁市":[116.600797625,35.4021216643],"淄博市":[118.059134278,36.8046848542],"滨州市":[117.968292415,37.4053139418],"潍坊市":[119.142633823,36.7161148731],"烟台市":[121.30955503,37.5365615629],"聊城市":[115.986869139,36.4558285147],"莱芜市":[117.684666912,36.2336541336],"菏泽市":[115.463359775,35.2624404961],"青岛市":[120.384428184,36.1052149013],"临汾市":[111.538787596,36.0997454436],"吕梁市":[111.143156602,37.527316097],"大同市":[113.290508673,40.1137444997],"太原市":[112.550863589,37.890277054],"忻州市":[112.727938829,38.461030573],"晋中市":[112.7385144,37.6933615268],"晋城市":[112.867332758,35.4998344672],"朔州市":[112.479927727,39.3376719662],"运城市":[111.006853653,35.0388594798],"长治市":[113.120292086,36.2016643857],"阳泉市":[113.569237602,37.8695294932],"东莞市":[113.763433991,23.0430238154],"中山市":[113.422060021,22.5451775145],"云浮市":[112.050945959,22.9379756855],"佛山市":[113.134025635,23.0350948405],"广州市":[113.307649675,23.1200491021],"惠州市":[114.41065808,23.1135398524],"揭阳市":[116.379500855,23.5479994669],"梅州市":[116.126403098,24.304570606],"汕头市":[116.728650288,23.3839084533],"汕尾市":[115.372924289,22.7787305002],"江门市":[113.078125341,22.5751167835],"河源市":[114.713721476,23.7572508505],"深圳市":[114.025973657,22.5460535462],"清远市":[113.040773349,23.6984685504],"湛江市":[110.365067263,21.2574631038],"潮州市":[116.630075991,23.6618116765],"珠海市":[113.562447026,22.2569146461],"肇庆市":[112.47965337,23.0786632829],"茂名市":[110.931245331,21.6682257188],"阳江市":[111.977009756,21.8715173045],"韶关市":[113.594461107,24.8029603119],"北海市":[109.122627919,21.472718235],"南宁市":[108.297233556,22.8064929356],"崇左市":[107.357322038,22.4154552965],"来宾市":[109.231816505,23.7411659265],"柳州市":[109.42240181,24.3290533525],"桂林市":[110.260920147,25.262901246],"梧州市":[111.30547195,23.4853946367],"河池市":[108.069947709,24.6995207829],"玉林市":[110.151676316,22.6439736084],"百色市":[106.631821404,23.9015123679],"贵港市":[109.613707557,23.1033731644],"贺州市":[111.552594179,24.4110535471],"钦州市":[108.638798056,21.9733504653],"防城港市":[108.351791153,21.6173984705],"乌鲁木齐市":[87.5649877411,43.8403803472],"伊犁哈萨克自治州":[81.2978535304,43.9222480963],"克孜勒苏柯尔克孜自治州":[76.1375644775,39.7503455778],"克拉玛依市":[84.8811801861,45.5943310667],"博尔塔拉蒙古自治州":[82.0524362672,44.9136513743],"吐鲁番地区":[89.1815948657,42.9604700169],"和田地区":[79.9302386372,37.1167744927],"哈密地区":[93.5283550928,42.8585963324],"喀什地区":[75.9929732675,39.4706271887],"塔城地区":[82.9748805837,46.7586836297],"昌吉回族自治州":[87.2960381257,44.0070578985],"阿克苏地区":[80.2698461793,41.1717309015],"阿勒泰地区":[88.1379154871,47.8397444862],"南京市":[118.778074408,32.0572355018],"南通市":[120.873800951,32.0146645408],"宿迁市":[118.296893379,33.9520497337],"常州市":[119.981861013,31.7713967447],"徐州市":[117.188106623,34.2715534311],"扬州市":[119.427777551,32.4085052546],"无锡市":[120.305455901,31.5700374519],"泰州市":[119.919606016,32.4760532748],"淮安市":[119.030186365,33.6065127393],"盐城市":[120.148871818,33.3798618771],"苏州市":[120.619907115,31.317987368],"连云港市":[119.173872217,34.601548967],"镇江市":[119.455835405,32.2044094436],"上饶市":[117.955463877,28.4576225539],"九江市":[115.999848022,29.7196395261],"南昌市":[115.893527546,28.6895780001],"吉安市":[114.992038711,27.1138476502],"宜春市":[114.400038672,27.8111298958],"抚州市":[116.360918867,27.9545451703],"新余市":[114.947117417,27.8223215586],"景德镇市":[117.186522625,29.3035627684],"萍乡市":[113.859917033,27.639544223],"赣州市":[114.935909079,25.8452955363],"鹰潭市":[117.035450186,28.2413095972],"保定市":[115.494810169,38.886564548],"唐山市":[118.183450598,39.6505309225],"廊坊市":[116.703602223,39.5186106251],"张家口市":[114.89378153,40.8111884911],"承德市":[117.933822456,40.9925210525],"沧州市":[116.863806476,38.2976153503],"石家庄市":[114.522081844,38.0489583146],"秦皇岛市":[119.604367616,39.9454615659],"衡水市":[115.686228653,37.7469290459],"邢台市":[114.520486813,37.0695311969],"邯郸市":[114.482693932,36.6093079285],"三门峡市":[111.181262093,34.7833199411],"信阳市":[114.085490993,32.1285823075],"南阳市":[112.542841901,33.0114195691],"周口市":[114.654101942,33.6237408181],"商丘市":[115.641885688,34.4385886402],"安阳市":[114.351806508,36.1102667222],"平顶山市":[113.300848978,33.7453014565],"开封市":[114.351642118,34.8018541758],"新乡市":[113.912690161,35.3072575577],"洛阳市":[112.447524769,34.6573678177],"漯河市":[114.0460614,33.5762786885],"濮阳市":[115.026627441,35.7532978882],"焦作市":[113.211835885,35.234607555],"许昌市":[113.83531246,34.0267395887],"郑州市":[113.64964385,34.7566100641],"驻马店市":[114.049153547,32.9831581541],"鹤壁市":[114.297769838,35.7554258742],"丽水市":[119.929575843,28.4562995521],"台州市":[121.440612936,28.6682832857],"嘉兴市":[120.760427699,30.7739922396],"宁波市":[121.579005973,29.8852589659],"杭州市":[120.219375416,30.2592444615],"温州市":[120.690634734,28.002837594],"湖州市":[120.137243163,30.8779251557],"绍兴市":[120.592467386,30.0023645805],"舟山市":[122.169872098,30.0360103026],"衢州市":[118.875841652,28.9569104475],"金华市":[119.652575704,29.1028991054],"三亚市":[109.522771281,18.2577759149],"三沙市":[112.350383075,16.840062894],"海口市":[110.330801848,20.022071277],"十堰市":[110.801228917,32.6369943395],"咸宁市":[114.300060592,29.8806567577],"孝感市":[113.935734392,30.9279547842],"宜昌市":[111.310981092,30.732757818],"恩施土家族苗族自治州":[109.491923304,30.2858883166],"武汉市":[114.316200103,30.5810841269],"荆州市":[112.241865807,30.332590523],"荆门市":[112.217330299,31.0426112029],"襄阳市":[112.250092848,32.2291685915],"鄂州市":[114.895594041,30.3844393228],"随州市":[113.379358364,31.7178576082],"黄冈市":[114.906618047,30.4461089379],"黄石市":[115.050683164,30.2161271277],"娄底市":[111.996396357,27.7410733023],"岳阳市":[113.146195519,29.3780070755],"常德市":[111.653718137,29.0121488552],"张家界市":[110.481620157,29.1248893532],"怀化市":[109.986958796,27.5574829012],"株洲市":[113.131695341,27.8274329277],"永州市":[111.614647686,26.4359716468],"湘潭市":[112.935555633,27.835095053],"湘西土家族苗族自治州":[109.7457458,28.3179507937],"益阳市":[112.366546645,28.5880877799],"衡阳市":[112.583818811,26.8981644154],"邵阳市":[111.461525404,27.2368112449],"郴州市":[113.037704468,25.7822639757],"长沙市":[112.979352788,28.2134782309],"澳门半岛":[113.566432335,22.1950041592],"澳门离岛":[113.557519102,22.2041179884],"临夏回族自治州":[103.215249178,35.5985143488],"兰州市":[103.823305441,36.064225525],"嘉峪关市":[98.2816345853,39.8023973267],"天水市":[105.736931623,34.5843194189],"定西市":[104.626637601,35.5860562418],"平凉市":[106.688911157,35.55011019],"庆阳市":[107.644227087,35.7268007545],"张掖市":[100.459891869,38.939320297],"武威市":[102.640147343,37.9331721429],"甘南藏族自治州":[102.917442486,34.9922111784],"白银市":[104.171240904,36.5466817062],"酒泉市":[98.5084145062,39.7414737682],"金昌市":[102.208126263,38.5160717995],"陇南市":[104.934573406,33.3944799729],"三明市":[117.642193934,26.2708352794],"南平市":[118.181882949,26.6436264742],"厦门市":[118.103886046,24.4892306125],"宁德市":[119.54208215,26.6565274192],"泉州市":[118.600362343,24.901652384],"漳州市":[117.676204679,24.5170647798],"福州市":[119.330221107,26.0471254966],"莆田市":[119.077730964,25.4484501367],"龙岩市":[117.017996739,25.0786854335],"山南地区":[91.7506438744,29.2290269317],"拉萨市":[91.111890896,29.6625570621],"日喀则地区":[88.8914855677,29.2690232039],"昌都地区":[97.18558158,31.1405756319],"林芝地区":[94.3499854582,29.6669406258],"那曲地区":[92.0670183689,31.4806798301],"阿里地区":[81.1076686895,30.4045565883],"六盘水市":[104.85208676,26.5918660603],"安顺市":[105.928269966,26.2285945777],"毕节市":[105.333323371,27.4085621313],"贵阳市":[106.709177096,26.6299067414],"遵义市":[106.931260316,27.6999613771],"铜仁市":[109.168558028,27.6749026906],"黔东南苗族侗族自治州":[107.985352573,26.5839917665],"黔南布依族苗族自治州":[107.52320511,26.2645359974],"黔西南布依族苗族自治州":[104.900557798,25.0951480559],"丹东市":[124.338543115,40.1290228266],"大连市":[121.593477781,38.9487099383],"抚顺市":[123.929819767,41.8773038296],"朝阳市":[120.446162703,41.5718276679],"本溪市":[123.77806237,41.3258376266],"沈阳市":[123.432790922,41.8086447835],"盘锦市":[122.07322781,41.141248023],"营口市":[122.233391371,40.6686510665],"葫芦岛市":[120.860757645,40.7430298813],"辽阳市":[123.172451205,41.2733392656],"铁岭市":[123.854849615,42.2997570121],"锦州市":[121.147748738,41.1308788759],"阜新市":[121.660822129,42.0192501071],"鞍山市":[123.007763329,41.1187436822],"重庆市":[106.530635013,29.5446061089],"咸阳市":[108.707509278,34.345372996],"商洛市":[109.934208154,33.8739073951],"安康市":[109.038044563,32.70437045],"宝鸡市":[107.170645452,34.3640808097],"延安市":[109.500509757,36.6033203523],"榆林市":[109.745925744,38.2794392401],"汉中市":[107.045477629,33.0815689782],"渭南市":[109.483932697,34.5023579758],"西安市":[108.953098279,34.2777998978],"铜川市":[108.968067013,34.9083676964],"果洛藏族自治州":[100.223722769,34.4804845846],"海东地区":[102.085206987,36.5176101677],"海北藏族自治州":[100.879802174,36.9606541011],"海南藏族自治州":[100.624066094,36.2843638038],"海西蒙古族藏族自治州":[97.3426254153,37.3737990706],"玉树藏族自治州":[97.0133161374,33.0062399097],"西宁市":[101.76792099,36.640738612],"黄南藏族自治州":[102.007600308,35.5228515517],"九龙":[114.173291988,22.3072458588],"新界":[114.146701965,22.4274312754],"香港岛":[114.183870524,22.2721034276],"七台河市":[131.019048047,45.7750053686],"伊春市":[128.910765978,47.7346850751],"佳木斯市":[130.284734586,46.8137796047],"双鸭山市":[131.17140174,46.6551020625],"哈尔滨市":[126.657716855,45.7732246332],"大兴安岭地区":[124.19610419,51.991788968],"大庆市":[125.02183973,46.59670902],"牡丹江市":[129.608035396,44.5885211528],"绥化市":[126.989094572,46.646063927],"鸡西市":[130.941767273,45.3215398866],"鹤岗市":[130.292472051,47.3386659037],"黑河市":[127.500830295,50.2506900907],"齐齐哈尔市":[123.987288942,47.3476998134]},a={"中国":"map/data-china.json","上海":"map/data-hainan.json","河北":"map/data-xizang.json","山西":"map/data-zhejiang.json","内蒙古":"map/data-yunnan.json","辽宁":"map/data-xinjiang.json","吉林":"map/data-tianjin.json","黑龙江":"map/data-sichuan.json","江苏":"map/data-shanxi.json","浙江":"map/data-shangxi.json","安徽":"map/data-shanghai.json","福建":"map/data-shangdong.json","江西":"map/data-qinghai.json","山东":"map/data-ningxia.json","河南":"map/data-neimenggu.json","湖北":"map/data-liaoning.json","湖南":"map/data-jilin.json","广东":"map/data-jiangxi.json","广西":"map/data-jiangsu.json","海南":"map/data-hunan.json","四川":"map/data-hubei.json","贵州":"map/data-henan.json","云南":"map/data-heilongjiang.json","西藏":"map/data-hebei.json","陕西":"map/data-guizhou.json","甘肃":"map/data-guangxi.json","青海":"map/data-guangdong.json","宁夏":"map/data-gansu.json","新疆":"map/data-chongqing.json","北京":"map/data-aomen.json","天津":"map/data-anhui.json","重庆":"map/data-beijing.json","香港":"map/data-fujian.json","澳门":"map/data-xianggang.json"},o={"中国":"zhongguo","上海":"shanghai","河北":"hebei","山西":"shangxi","内蒙古":"neimenggu","辽宁":"liaoning","吉林":"jilin","黑龙江":"heilongjiang","江苏":"jiangsu","浙江":"zhejiang","安徽":"anhui","福建":"fujian","江西":"jiangxi","山东":"shangdong","河南":"henan","湖北":"hubei","湖南":"hunan","广东":"guangdong","广西":"guangxi","海南":"hainan","四川":"sichuan","贵州":"guizhou","云南":"yunnan","西藏":"xizang","陕西":"shanxi","甘肃":"gansu","青海":"qinghai","宁夏":"ningxia","新疆":"xinjiang","北京":"beijing","天津":"tianjin","重庆":"chongqing","香港":"xianggang","澳门":"aomen"}},6107:function(t,e,i){},6276:function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{staticClass:"relationship_graph"},[e("div",{staticClass:"page_title"},[e("b",[t._v(t._s(t.pageTitle))])]),e("div",{staticClass:"search_box public_box"},[e("el-form",{ref:"searchForm",attrs:{inline:!0,model:t.searchForm}},[e("el-form-item",{attrs:{label:"",prop:"caseNo"}},[e("el-input",{staticClass:"width_450",attrs:{maxlength:"50",placeholder:"输入案件号,姓名,身份证号,车牌号,车架号,医院名称进行搜索",clearable:""},model:{value:t.searchForm.keyword,callback:function(e){t.$set(t.searchForm,"keyword",e)},expression:"searchForm.keyword"}})],1),e("el-form-item",{attrs:{label:"报案时间",prop:"caseNo"}},[e("el-date-picker",{staticClass:"date_style",attrs:{type:"date","value-format":"yyyy-MM-dd",placeholder:"选择日期"},model:{value:t.searchForm.startRepTime,callback:function(e){t.$set(t.searchForm,"startRepTime",e)},expression:"searchForm.startRepTime"}}),t._v(" - "),e("el-date-picker",{staticClass:"date_style",attrs:{type:"date","value-format":"yyyy-MM-dd",placeholder:"选择日期"},model:{value:t.searchForm.endRepTime,callback:function(e){t.$set(t.searchForm,"endRepTime",e)},expression:"searchForm.endRepTime"}})],1),e("el-form-item",{attrs:{label:"损伤类型",prop:"caseNo"}},[e("el-select",{staticClass:"width_150",attrs:{placeholder:"请选择",clearable:""},model:{value:t.searchForm.lossType,callback:function(e){t.$set(t.searchForm,"lossType",e)},expression:"searchForm.lossType"}},t._l(t.lossTypeOptions,(function(t){return e("el-option",{key:t.code,attrs:{label:t.label,value:t.code}})})),1)],1),e("el-form-item",{attrs:{label:"案件状态",prop:"caseStatus"}},[e("el-select",{staticClass:"width_130",attrs:{placeholder:"请选择",multiple:"",filterable:"",clearable:""},model:{value:t.searchForm.caseStatus,callback:function(e){t.$set(t.searchForm,"caseStatus",e)},expression:"searchForm.caseStatus"}},t._l(t.statusOptions,(function(t,i){return e("el-option",{key:i,attrs:{label:t.status,value:t.status}})})),1)],1),e("el-form-item",{attrs:{label:"实际赔付金额区间",prop:""}},[e("el-input",{staticClass:"width_140",attrs:{maxlength:"50",placeholder:"请输入",clearable:"",oninput:"value=value.replace(/[^\\d.]/g, '').replace(/\\.{2,}/g, '.').replace('.', '$#$').replace(/\\./g, '').replace('$#$', '.').replace(/^(\\-)*(\\d+)\\.(\\d\\d).*$/, '$1$2.$3').replace(/^\\./g, '').replace(/^0+(\\d)/, '$1')"},model:{value:t.searchForm.geAmount,callback:function(e){t.$set(t.searchForm,"geAmount",e)},expression:"searchForm.geAmount"}}),t._v(" - "),e("el-input",{staticClass:"width_140",attrs:{maxlength:"50",placeholder:"请输入",clearable:"",oninput:"value=value.replace(/[^\\d.]/g, '').replace(/\\.{2,}/g, '.').replace('.', '$#$').replace(/\\./g, '').replace('$#$', '.').replace(/^(\\-)*(\\d+)\\.(\\d\\d).*$/, '$1$2.$3').replace(/^\\./g, '').replace(/^0+(\\d)/, '$1')"},model:{value:t.searchForm.leAmount,callback:function(e){t.$set(t.searchForm,"leAmount",e)},expression:"searchForm.leAmount"}})],1),e("el-form-item",{attrs:{label:"案发地址",prop:""}},[e("el-select",{staticClass:"width_120",attrs:{placeholder:"省",clearable:""},on:{change:t.provinceChange1},model:{value:t.searchForm.caseProvince,callback:function(e){t.$set(t.searchForm,"caseProvince",e)},expression:"searchForm.caseProvince"}},t._l(t.provinceOptions,(function(t){return e("el-option",{key:t.areaCode,attrs:{label:t.areaName,value:t.areaName+"-"+t.areaCode}})})),1),t._v(" - "),e("el-select",{staticClass:"width_120",attrs:{placeholder:"市",disabled:t.cityDisabled,clearable:"",filterable:""},on:{change:t.provinceChange2},model:{value:t.searchForm.caseCity,callback:function(e){t.$set(t.searchForm,"caseCity",e)},expression:"searchForm.caseCity"}},t._l(t.cityOptions,(function(t){return e("el-option",{key:t.areaCode,attrs:{label:t.areaName,value:t.areaName+"-"+t.areaCode}})})),1),t._v(" - "),e("el-select",{staticClass:"width_120",attrs:{placeholder:"区",disabled:t.districtDisabled,clearable:"",filterable:""},model:{value:t.searchForm.caseCounty,callback:function(e){t.$set(t.searchForm,"caseCounty",e)},expression:"searchForm.caseCounty"}},t._l(t.districtOptions,(function(t){return e("el-option",{key:t.areaCode,attrs:{label:t.areaName,value:t.areaName+"-"+t.areaCode}})})),1)],1),e("el-form-item",[e("el-button",{staticStyle:{"margin-left":"0.2rem"},attrs:{type:"primary"},on:{click:e=>t.getGraphData(!1,e)}},[t._v("查询")]),e("el-button",{staticStyle:{"margin-left":"0.2rem"},attrs:{type:"primary",disabled:!t.myChartData},on:{click:t.download}},[t._v("下载")])],1)],1)],1),e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.networkLoading,expression:"networkLoading"}],staticClass:"content_box public_box",staticStyle:{height:"calc(100vh - 230px)"}},[e("div",{ref:"chartContent",staticClass:"chart_content",attrs:{id:"chart_content"}}),e("div",{staticClass:"cricleMenu",attrs:{id:"cricleMenu"}},[e("div",{staticClass:"sector sector1",attrs:{title:"查看详情"},on:{click:function(e){return t.menuClick(1)}}},[e("div",{staticClass:"menuIcon iconfont icon-details"})]),e("div",{staticClass:"sector sector2",attrs:{title:"隐藏该节点"},on:{click:function(e){return t.menuClick(2)}}},[e("div",{staticClass:"menuIcon iconfont icon-yanjing_yincang_o"})]),e("div",{staticClass:"sector sector3",attrs:{title:"展开隐藏关系"},on:{click:function(e){return t.menuClick(3)}}},[e("div",{staticClass:"menuIcon iconfont icon-ico"})]),e("div",{staticClass:"line1"}),e("div",{staticClass:"line2"}),e("div",{staticClass:"line3"}),e("div",{staticClass:"menu_center",style:"background:"+t.menuCenterColor,on:{click:t.hideCricle}},[e("img",{directives:[{name:"show",rawName:"v-show",value:t.selectedNodeImg,expression:"selectedNodeImg"}],attrs:{src:t.selectedNodeImg}})])]),e("div",{staticClass:"cricleStyle",attrs:{id:"cricleStyle"}},[e("div",{staticClass:"menu_center"},[e("div",{staticClass:"custom_center",style:"background:"+t.hoverCenterColor+"; borderColor:"+t.hoverCenterBorderColor,on:{click:t.setCricleMenu}})])]),e("div",{staticClass:"cavasBgc"}),t.myChartData?e("div",{staticClass:"suspend"},[e("div",{class:{suspend_sidebar:1,suspend_left:1},style:t.leftExpandFlag?"":"width:20px !important;border: 1px solid #888;"},[e("ul",{staticClass:"titleUl"},[e("li",{class:{activeTitle:t.leftExpandFlag},on:{click:function(e){t.leftExpandFlag=!t.leftExpandFlag}}},[e("i",{class:t.leftExpandFlag?"el-icon-arrow-left":"el-icon-arrow-right"}),t._v(t._s(t.leftExpandFlag?"快捷分析":""))])]),t.leftExpandFlag?e("ul",{staticClass:"leftSidebarUl",staticStyle:{height:"calc(100vh - 230px)"}},[t._l(t.leftSideBar,(function(i,s){return e("li",{key:s,class:{activeIndex:s==t.leftActiveIndex},on:{click:function(e){return t.sidebarClick(s,"left")}}},[t._v(t._s(i.label))])})),e("i",{staticClass:"resetBtn el-icon-refresh-right",on:{click:function(e){return t.sidebarReset(0,"",!0)}}})],2):t._e()]),e("div",{class:{suspend_sidebar:1,suspend_right:1},style:t.rightExpandFlag?"":"width:20px !important;border: 1px solid #888;padding: 10px 0px;"},[e("ul",{staticClass:"titleUl"},[e("li",{class:{activeTitle:t.rightExpandFlag},on:{click:function(e){t.rightExpandFlag=!t.rightExpandFlag}}},[t._v(t._s(t.rightExpandFlag?"快捷筛选":"")+" "),e("i",{class:t.rightExpandFlag?"el-icon-arrow-right":"el-icon-arrow-left"})])]),t.rightExpandFlag?e("ul",{staticClass:"rightSidebarUl",staticStyle:{height:"calc(100vh - 230px)"}},[t._l(t.rightSideBar,(function(i,s){return e("li",{key:s,ref:"activeSideBar"+s,refInFor:!0,class:{activeIndex:s==t.getActiveCurrentVal(s)},on:{click:function(e){return t.sidebarClick(s,"right")}}},[e("p",[e("span",{class:"iconfont "+i.icon})]),e("p",[t._v(t._s(i.label))]),e("div",{staticClass:"cover"})])})),e("i",{staticClass:"resetBtn el-icon-refresh-right",on:{click:function(e){return t.sidebarReset(1)}}})],2):t._e()])]):t._e(),e("div",{class:{info_sidebar:1,show_sidebar:t.showSidebarFlag}},[e("div",{staticClass:"sidebar_title",style:"background:"+t.infoTitleBgc},[t._v(t._s(t.infoTitleTxt))]),e("i",{staticClass:"closeBtn el-icon-close",on:{click:function(e){t.showSidebarFlag=!1}}}),t.showSidebarFlag?e("div",{staticClass:"infoContent"},[t._l(t.currentNodeInfo.showTxtArr,(function(i,s){return e("el-row",{key:s,class:{activeRow:s%2==0}},[e("el-col",{staticClass:"sidebar_left",attrs:{span:8,offset:1}},[t._v(t._s(i.label)+":")]),i.hidden?"案件号"!=i.label?e("el-col",{attrs:{span:12,offset:1}},[e("overflow-txt",{attrs:{txt:i.value}})],1):e("el-col",{attrs:{span:12,offset:1}},[e("div",{staticClass:"tooltipText",on:{click:function(e){return t.hrefDetail(i.value)}}},[e("overflow-txt",{attrs:{txt:i.value}})],1)]):e("el-col",{attrs:{span:12,offset:1}},[t._v(t._s(i.value))])],1)})),"Case"!=t.currentNodeInfo.type&&"IdCardAddress"!=t.currentNodeInfo.type?e("el-row",[e("el-col",{staticClass:"sidebar_left",attrs:{span:8,offset:1}},[t._v("关联案件号:")]),e("el-col",{class:{case_content:1,short_content:t.clientHeight<800},attrs:{span:12,offset:1}},t._l(t.relatedCases,(function(i,s){return e("div",{key:s,staticClass:"tooltipText",on:{click:function(e){return t.hrefDetail(i)}}},[e("overflow-txt",{attrs:{txt:i}})],1)})),0)],1):t._e()],2):t._e()])]),e("transition",{attrs:{name:"el-fade-in-linear"}})],1)},a=[],o=(i("0faf"),i("b3ec"),i("2502"),i("6fc2"),i("e4c6"),i("320b"),i("3960"),i("5281"),i("08a9"),i("5966"),i("b75d"),i("644c"),i("1fd3"),i("ffb0")),n=i.n(o),r={props:{isCollapse:{type:Boolean,default:!0}},data(){return{showSidebarFlag:!1,drawer:!1,options:[{value:"选项1",label:"黄金糕"},{value:"选项2",label:"双皮奶"},{value:"选项3",label:"蚵仔煎"},{value:"选项4",label:"龙须面"},{value:"选项5",label:"北京烤鸭"}],networkLoading:!1,focusFlag:!1,hoverShow:!1,pageTitle:"",graphData:{},graphNodeObj:{},graphShow:!1,locationOrigin:"",searchForm:{keyword:"",startRepTime:"",endRepTime:"",lossType:"",geAmount:"",leAmount:"",caseProvince:"",caseCity:"",caseCounty:"",caseStatus:""},lossTypeOptions:[{code:1,label:"车物损"},{code:2,label:"人伤"},{code:3,label:"全部"}],provinceOptions:[],cityOptions:[],districtOptions:[],cityDisabled:!0,districtDisabled:!0,selectNodeId:null,hoverToolTips:{caseNo:"",reportTime:"",accidentProperty:"",currentStatusDesc:"",totalPayAmount:""},tooltipsData:{},leftExpandFlag:!0,rightExpandFlag:!0,leftActiveIndex:null,rightActiveIndex:1,leftSideBar:[{label:"骑手作为三者出险"},{label:"同一车辆多次出险"},{label:"骑手和三者疑似认识"},{label:"出险大于一次的骑手"},{label:"出险最多包商"},{label:"出险大于一次的修理厂"}],rightSideBar:[{icon:"icon-record-full",label:"案件",type:"Case"},{icon:"icon-renyuan",label:"人员",type:"Person"},{icon:"icon-shigu",label:"三者车",type:"Vehicle"},{icon:"icon-dizhi",label:"地址",type:"IdCardAddress"},{icon:"icon-wxbzhanghu",label:"收款账户",type:"Account"},{icon:"icon-xiulichang",label:"修理厂",type:"Repair"},{icon:"icon-hospital-building",label:"医院",type:"Hospital"},{icon:"icon-fenbaoshang",label:"包商",type:"Contractor"}],showMenu:!1,menuPosition:null,chartStoreData:null,nodesMapData:{},relationsMapData:{},currentActiveNodeId:null,currentHoverNodeId:null,myChartData:null,currentNodeInfo:null,classifyNodesData:{},cricleShow:!1,nodeTypeData:{Case:{color:"#CA90C0",borderColor:"#B261A4",type:"案件"},Person:{color:"#58C7E3",borderColor:"#23B3D7",type:"人"},Vehicle:{color:"#DA7094",borderColor:"#C73F6E",type:"三者车"},IdCardAddress:{color:"#569480",borderColor:"#5bc9a6",type:"地址"},Account:{color:"#F79767",borderColor:"#F36823",type:"收款账户"},Phone:{color:"#F26667",borderColor:"#E92829",type:"电话"},Appraisal:{color:"#ECB5CA",borderColor:"#DB7197",type:"鉴定机构"},Repair:{color:"#FFC453",borderColor:"#D7A012",type:"修理厂"},Hospital:{color:"#4C8EDA",borderColor:"#2871C1",type:"医院"},Contractor:{color:"#8DCC93",borderColor:"#5EB567",type:"包商"}},infoTitleBgc:"",infoTitleTxt:"",statusOptions:[],isExtendNode:!1,sourceGraphData:null,animationFlag:!0,menuCenterTxt:"",menuCenterColor:"",hoverCenterColor:"",hoverCenterBorderColor:"",activeCurrent0:null,activeCurrent1:null,activeCurrent2:null,activeCurrent3:3,activeCurrent4:4,activeCurrent5:5,activeCurrent6:6,activeCurrent7:7,activeCurrent8:8,relatedCases:[],hoverStyleOptions:{},nodeDragFlag:!1,analyseHighlightNodes:[],analyseHighlightEdges:[],drawWatchTime:null,analyseScreen:{0:[0,1],1:[0,2],2:[0,1,3],3:[0,1],4:[0,7],5:[0,5]},selectedNodeId:null,selectedNodeImg:null,edgesOptions:{arrows:"from",color:{color:"#a5abb6",highlight:"#ef5350",hover:"#a5abb6",inherit:"from",opacity:1},font:{color:"#000",size:12,align:"middle"},scaling:{min:1,max:1},arrowStrikethrough:!0,endPointOffset:{from:0},selectionWidth:1,hoverWidth:function(t){return t},width:1,shadow:!1},edgeColor:{color:"#ef5350",highlight:"#ef5350",hover:"#ef5350",inherit:"from",opacity:1},isStopped:!1,number:0,intervalId:null,checkStoppedId:null,lastUpdateTime:0,timeoutThreshold:2e3,searchData:null,queryAtlasData:null}},computed:{clientHeight(){return window.innerHeight}},mounted(){window.addEventListener("resize",()=>{this.resizeNetwork()}),this.pageTitle=this.$route.meta.title,this.locationOrigin=-1!=location.origin.indexOf("localhost")?"http://jiaanantest.platform.sigreal.cn":location.origin,this.getGraphData(),this.findProvince(),this.getCaseStatus()},beforeDestroy(){window.removeEventListener("resize",this.handleResize),this.network&&this.network.destroy()},methods:{checkIfStopped(){const t=Date.now();t-this.lastUpdateTime>this.timeoutThreshold&&(clearInterval(this.intervalId),clearInterval(this.checkStoppedId),this.isStopped=!0,console.log("动画停止了"))},startIncrement(){this.intervalId=setInterval(this.incrementNumber,100),this.isStopped=!1,this.lastUpdateTime=Date.now()},stopIncrement(){clearInterval(this.intervalId),clearInterval(this.checkStoppedId),this.isStopped=!0},resetDataStatus(t){this.nodesMapData={},this.relationsMapData={},this.classifyNodesData={},this.hoverStyleOptions={},this.analyseHighlightNodes=[],this.analyseHighlightEdges=[],this.myChartData=null,this.network=null,this.showSidebarFlag=!1,this.animationFlag=!1,this.networkLoading=!0,this.focusFlag=!1,this.selectNodeId=null,t||(this.leftActiveIndex=null,this.rightActiveIndex=null,this.sidebarReset(0),this.sidebarReset(1,!0)),this.analyseHighlightNodes=[],this.analyseHighlightEdges=[],this.hideCricle()},resizeNetwork(){this.network&&this.network.redraw()},hrefDetail(t){let e,i=!1;this.instance.get("/case/getMeituanCaseNo?caseNo="+t,{params:{}}).then(t=>{let s=t.data;1==s.code&&s.data?(i=!0,e=s.data):this.$message.error("该案件查询失败!");let a="https://www.jchunuo.com/fe/insurance-claim-service-platform/index.html#/detail/caseDetail/";i&&(a=-1!=e.indexOf("old")?"https://awp.meituan.com/ffe/insurance-claim-platform/index/index.html?code=MGAr4r&state=dx_auth_interceptor#/case?caseId=":"https://www.jchunuo.com/fe/insurance-claim-service-platform/index.html#/detail/caseDetail/",window.open(a+e))})},handleResize(){this.network&&this.network.fit({animation:!0})},getCaseStatus(){this.restaurants=[],this.instance.get("/case/getCaseStatus",{params:{}}).then(t=>{1==t.data.code&&(this.statusOptions=t.data.data,this.baseStatusOptions=t.data.data)})},getActiveCurrentVal(t){return this["activeCurrent"+t]},findProvince(){this.instance.post("/area/findProvince",{}).then(t=>{let e=t.data;1==e.code&&e.data&&(this.provinceOptions=e.data)})},findCity(){let t=this.searchForm.caseProvince.split("-")[1];this.instance.post("/area/findCity/"+t,{}).then(t=>{let e=t.data;1==e.code&&e.data&&(this.cityDisabled=!1,this.districtDisabled=!1,this.cityOptions=e.data)})},findDistrict(){let t=this.searchForm.caseCity.split("-")[1];this.instance.post("/area/findDistrict/"+t,{}).then(t=>{let e=t.data;1==e.code&&e.data&&(this.districtDisabled=!1,this.districtOptions=e.data)})},provinceChange1(t){this.searchForm.caseCity="",this.searchForm.caseCounty="",this.cityDisabled=!0,this.districtDisabled=!0,t&&this.findCity()},provinceChange2(t){this.searchForm.caseCounty="",this.districtDisabled=!0,t&&this.findDistrict()},sidebarClick(t,e){"left"==e?(this.analyseNodesData(t),this.hideCricle()):(this.hideCricle(),this["activeCurrent"+t]==t?this["activeCurrent"+t]=null:this["activeCurrent"+t]=t,this.updateNetwork(this.rightSideBar[t],this["activeCurrent"+t]==t))},updateNetwork(t,e){let i=this.classifyNodesData[t.type+"Ids"];this.network&&i.forEach(t=>{this.network.clustering.updateClusteredNode(t,{hidden:e})})},extendNodes(){let t=this.nodesMapData[this.currentActiveNodeId];this.instance.post("/neo4j/searchDataLink",{node:t}).then(t=>{let e=t.data;if(1==e.code){this.isExtendNode=!0;let t=e.data.nodes,i=e.data.relations,s=[],a=[],o=[];t.forEach(t=>{this.sourceGraphData.nodes.push(t),1==t.depth&&(this.nodesMapData[t.elementId]?o.push(t):s.push(t))}),i.forEach(t=>{let e=t.startNodeId+"---"+t.type+"---"+t.endNodeId;t.id=e,this.sourceGraphData.relations.push(t),this.relationsMapData[e]||a.push(t)});let n=this.handleNodesData(s,a,!0);s.length>0?n.nodes.forEach(t=>{this.myChartData.nodes.add(t)}):o.forEach(t=>{this.network.clustering.updateClusteredNode(t.elementId,{hidden:!1})}),a.length>0&&n.edges.forEach(t=>{this.myChartData.edges.add(t)});let r=this.sourceGraphData.nodes.filter((t,e,i)=>i.findIndex(e=>e.elementId===t.elementId)===e);this.sourceGraphData.nodes=r;let l=this.sourceGraphData.relations.filter((t,e,i)=>i.findIndex(e=>e.id===t.id)===e);this.sourceGraphData.relations=l,this.nodesClassify()}})},searchNodeCases(){let t={logic:1,nodes:this.queryAtlasData.nodes,relations:this.queryAtlasData.relations,node:this.nodesMapData[this.currentActiveNodeId]};this.instance.post("/neo4j/searchNodeCases",t).then(t=>{let e=t.data;1==e.code&&(this.relatedCases=e.data)})},analyseNodesData(t){this.networkLoading=!0,this.instance.post("/neo4j/analyseData",this.handleSearchData("analyse",t)).then(e=>{let i=e.data;if(1==i.code){this.queryAtlasData=i.data,this.leftActiveIndex=t,this.network&&this.clearNetwork(),this.resetDataStatus(!0),this.makeVis(i.data.nodes,i.data.relations),this.analyseHighlightNodes=i.data.highlightNodes,this.analyseHighlightEdges=i.data.highlightRelations,this.setHighlightNodesAndEdges(i.data.highlightNodes,i.data.highlightRelations),this.rightSideBar.forEach((t,e)=>{e==this.getActiveCurrentVal(e)&&this.updateNetwork(this.rightSideBar[e],this["activeCurrent"+e]==e)});let e=this.analyseScreen[this.leftActiveIndex];e&&e.forEach(t=>{"null"!=String(this["activeCurrent"+t])&&this.sidebarClick(t,"right")}),this.networkLoading=!1}else this.networkLoading=!1})},sidebarReset(t,e,i){0==t?(this.leftActiveIndex=null,this.clearNodesAndEdges(),this.focusNodes(),i&&this.getGraphData(!0)):(this.hideCricle(),this.rightSideBar.forEach((t,i)=>{this["activeCurrent"+i]=i<3?null:i,!e&&this.updateNetwork(this.rightSideBar[i],this["activeCurrent"+i]==i)}))},clearNodesAndEdges(){let t,e;this.network&&this.network.selectNodes([]);for(const s in this.nodesMapData)t=this.nodesMapData[s],this.myChartData.nodes.update({id:t.elementId,color:{background:this.nodeTypeData[t.type].color,border:this.nodeTypeData[t.type].borderColor},borderWidth:3});let i=JSON.parse(JSON.stringify(this.edgesOptions));i.color={color:"#A4AAB6",highlight:"#ef5350",inherit:"from",opacity:1};for(const s in this.relationsMapData)e=this.relationsMapData[s],i.id=s,this.myChartData.edges.update(i)},clearNetwork(){let t={nodes:new n.a.DataSet([]),edges:new n.a.DataSet([])};this.network.setData(t)},focusNodes(t){if(this.selectNodeId&&(t&&this.network.focus(this.selectNodeId,{scale:1}),this.network.selectNodes([this.selectNodeId])),"null"==String(this.leftActiveIndex)){this.clearRightSide();let t=[3,4,5,6,7];t.forEach(t=>{this.sidebarClick(t,"right")})}},clearRightSide(){let t=[0,1,2,3,4,5,6,7];t.forEach(t=>{"null"!=String(this["activeCurrent"+t])&&(this.sidebarClick(t,"right"),this["activeCurrent"+t]=null)})},handleNodesData(t,e,i,s){let a=new n.a.DataSet([]),o=new n.a.DataSet([]);if(e.forEach((t,e)=>{t.id=t.startNodeId+"---"+t.type+"---"+t.endNodeId,t.from=t.endNodeId,t.to=t.startNodeId,t.label=t.type,this.relationsMapData[t.id]||(this.relationsMapData[t.id]=t,a.add(t))}),s){let t=this.findWithDuplicateIds(e);t.forEach((t,e)=>{e>0&&(t.id=t.startNodeId+"---"+t.type+"---"+t.endNodeId+"---"+e,t.from=t.endNodeId,t.to=t.startNodeId,t.label=t.type,this.relationsMapData[t.id]=t,a.add(t))})}return t.forEach(t=>{let e=t.properties;switch(t.type){case"Case":t.text=e.caseNo?e.caseNo:"",this.tooltipsData[t.elementId]={caseNo:e.caseNo,reportTime:e.reportTime,insureTypeName:e.insureTypeName,accidentProperty:e.accidentProperty,currentStatusDesc:e.currentStatusDesc,totalPayAmount:e.totalPayAmount};break;case"Person":t.text=t.properties.name?t.properties.name:t.properties.identityNo;break;case"Vehicle":t.text=t.properties.vin?t.properties.vin:"";break;case"IdCardAddress":let i=t.properties.prov?t.properties.prov:"",s=t.properties.city?t.properties.city:"",a=t.properties.district?t.properties.district:"",o=t.properties.concat_address?t.properties.concat_address:"";t.text=i+s+a+o;break;case"Account":t.text=t.properties.accountName+" "+t.properties.accountNo;break;case"Phone":t.text=t.properties.phone?t.properties.phone:"";break;case"Appraisal":t.text=t.properties.organization?t.properties.organization:"";break;case"Repair":t.text=t.properties.repairName?t.properties.repairName:"";break;default:break}t.label=t.text,t.id=t.elementId,t.label==this.searchForm.keyword&&(this.selectNodeId=t.id),t.shape="dot",t.shape="circularImage",t.image=`${this.locationOrigin}/images/graph/${t.type}.png`,t.color={background:this.nodeTypeData[t.type].color,border:this.nodeTypeData[t.type].borderColor,hover:{background:this.nodeTypeData[t.type].color,border:this.nodeTypeData[t.type].borderColor},highlight:{border:"#ffd775",background:this.nodeTypeData[t.type].color}},this.nodesMapData[t.elementId]||(this.nodesMapData[t.elementId]=t,o.add(t))}),{nodes:o,edges:a}},download(){this.instance({method:"post",url:"/neo4j/downloadCase",data:{caseNos:this.classifyNodesData.caseNos},responseType:"blob"}).then(t=>{let e=window.URL.createObjectURL(new Blob([t.data])),i=document.createElement("a");i.style.display="none",i.href=e,i.setAttribute("download","案件列表.xls"),document.body.appendChild(i),i.click()})},getGraphData(t){this.network&&this.clearNetwork(),this.resetDataStatus(t);let e=JSON.parse(JSON.stringify(this.handleSearchData("search")));this.searchData=e,this.instance.post("/neo4j/searchData",e).then(t=>{let e=t.data;1==e.code?(this.sourceGraphData=e.data,this.queryAtlasData=e.data,this.makeVis(e.data.nodes,e.data.relations),this.networkLoading=!1):this.$message.error("查询失败!")})},handleSearchData(t,e){let i={},s=JSON.parse(JSON.stringify(this.searchForm));return"analyse"==t&&(i={logic:e+1},s=this.searchData||{}),s.startRepTime&&-1==s.startRepTime.indexOf(" 00:00:00")&&(s.startRepTime=s.startRepTime?s.startRepTime+" 00:00:00":""),s.endRepTime&&-1==s.endRepTime.indexOf(" 23:59:59")&&(s.endRepTime=s.endRepTime?s.endRepTime+" 23:59:59":""),s.caseProvince=s.caseProvince&&s.caseProvince.length>0&&s.caseProvince.split("-").length>0?s.caseProvince.split("-")[0]:"",s.caseCity=s.caseCity&&s.caseCity.length>0&&s.caseCity.split("-").length>0?s.caseCity.split("-")[0]:"",s.caseCounty=s.caseCounty&&s.caseCounty.length>0&&s.caseCounty.split("-").length>0?s.caseCounty.split("-")[0]:"",{...i,...s}},makeVis(t,e){let i=this;this.myChartData=this.handleNodesData(t,e,!1,!0);let s=document.getElementById("chart_content");const a={autoResize:!1,nodes:{font:{color:"#000",size:20},scaling:{min:0,max:0,label:{enabled:!0,min:8,max:8,maxVisible:0}},size:30,borderWidth:3},edges:i.edgesOptions,groups:{ws:{shape:"dot",color:"white"}},interaction:{hover:!0,zoomView:!0,dragView:!0},physics:{barnesHut:{gravitationalConstant:-8e4,springConstant:.1,springLength:200,centralGravity:.5},stabilization:{enabled:!0,iterations:1,updateInterval:1,onlyDynamicEdges:!1,fit:!0}},layout:{randomSeed:2}};this.network=new n.a.Network(s,this.myChartData,a),this.nodesClassify(),setTimeout(()=>{this.focusNodes()},3e3),this.network.on("stabilized",()=>{this.focusFlag||(this.focusFlag=!0)}),this.network.on("selectNode",t=>{this.selectedNodeId=t.nodes[0]}),this.network.on("afterDrawing",()=>{if(this.number++,this.animationFlag=!0,this.selectedNodeId){this.currentActiveNodeId=this.selectedNodeId;var t=this.network.getPositions([this.selectedNodeId]),e=t[this.selectedNodeId],i=this.network.getScale();let s=this.network.canvasToDOM({x:e.x,y:e.y});this.network.moveNode(this.selectedNodeId,e.x,e.y),this.setCriclePosition(Math.floor(s.x-54),Math.floor(s.y-55),i)}}),this.network.on("dragStart",t=>{this.animationFlag=!1,this.nodeDragFlag=!0,this.hideHoverStyle()}),this.network.on("dragEnd",t=>{t.nodes&&t.nodes.length>0&&(this.nodeDragFlag=!1,this.network.clustering.updateClusteredNode(t.nodes[0],{physics:!1}),this.network.stopSimulation())}),this.network.on("dragStart",t=>{this.hideCricle()}),this.network.on("controlNodeDragging",t=>{this.hideCricle()}),this.network.on("zoom",t=>{this.hideCricle()}),this.network.on("click",t=>{if(t.nodes.length>0){this.currentActiveNodeId=t.nodes[0],this.selectedNodeId=this.currentActiveNodeId;let e=this.network.getPosition(t.nodes[0]),i=this.network.getScale(),s=this.network.canvasToDOM({x:e.x,y:e.y});this.cricleShow?this.hideCricle():this.setCriclePosition(Math.floor(s.x-54),Math.floor(s.y-55),i,!0)}else this.showSidebarFlag=!1,this.hideCricle()}),this.network.on("hoverNode",t=>{t.pointer.DOM&&i.animationFlag&&!i.nodeDragFlag||this.hideHoverStyle()}),this.network.on("blurNode",t=>{this.hideHoverStyle()})},checkAnimationStatus(){let t=!0;setInterval(()=>{this.animationFlag||(t=!1)},1e3);return t},findWithDuplicateIds(t){const e=new Map;return t.forEach(t=>{const i=t.id;e.has(i)?e.set(i,e.get(i)+1):e.set(i,1)}),t.filter(t=>e.get(t.id)>1)},setHighlightNodesAndEdges(t,e){this.clearNodesAndEdges();let i=[],s=[],a=t;a&&a.forEach(t=>{i.push(t.elementId),this.myChartData.nodes.update({id:t.elementId,color:{background:this.nodeTypeData[t.type].color,border:"#FFD488"},borderWidth:5})});let o,n=e,r={color:this.edgeColor};e&&n.forEach(t=>{o=t.startNodeId+"---"+t.type+"---"+t.endNodeId,t.tmpId=o,t.id=o,s.push(o),r.id=t.id,this.myChartData.edges.update(r)});let l=this.findWithDuplicateIds(n);l.forEach((t,e)=>{e>0&&(t.id=t.startNodeId+"---"+t.type+"---"+t.endNodeId+"---"+e,r.id=t.id,this.myChartData.edges.update(r))})},setHoverStyle(t){let e=this.network.getPosition(t);this.currentHoverNodeId=t,this.currentActiveNodeId=t;let i=this.network.getScale(),s=this.network.canvasToDOM({x:e.x,y:e.y});this.setHoverPosition(Math.floor(s.x-49),Math.floor(s.y-49),i)},getNodeSize(t){var e=this.network.body.nodes[t];if(e){var i=this.network.getBoundingBox(e.id);return{width:i.width,height:i.height}}return null},setCricleMenu(){if(this.currentHoverNodeId){let t=this.network.getPosition(this.currentHoverNodeId),e=this.network.getScale(),i=this.network.canvasToDOM({x:t.x,y:t.y});this.cricleShow?this.hideCricle():this.animationFlag&&this.setCriclePosition(Math.floor(i.x-19),Math.floor(i.y-20),e,!0)}else this.hideCricle()},drawTextWithWrap(t,e,i,s,a,o,n){let r=e.split(" "),l="";t.fillStyle=i,r.forEach(e=>{let i=this.splitStringByLength(e,15);i.forEach(e=>{let i=l+e+" ",r=t.measureText(i),h=r.width;h>o&&""!==l?(t.fillText(l,s,a),l=e+" ",a+=n):l=i})}),t.fillStyle=i,t.fillText(l,s,a)},splitStringByLength(t,e){let i=[];for(let s=0;st.length?t.length:a,i.push(t.substring(s,a))}return i},menuClick(t){switch(t){case 1:this.relatedCases=[],this.currentNodeInfo=this.setNodesSidebarData(this.nodesMapData[this.currentActiveNodeId]),this.showSidebarFlag=!0,this.infoTitleTxt=this.nodeTypeData[this.currentNodeInfo.type].type,this.infoTitleBgc=this.nodeTypeData[this.currentNodeInfo.type].color,this.searchNodeCases();break;case 2:this.network&&this.network.clustering.updateClusteredNode(this.currentActiveNodeId,{hidden:!0});break;default:this.extendNodes();break}this.hideHoverStyle(),this.hideCricle()},setNodesSidebarData(t){let e=[];switch(t.type){case"Case":e=[{label:"案件号",hidden:!0,value:t.properties.caseNo||""},{label:"报案时间",value:t.properties.reportTime||""},{label:"险种类型",value:t.properties.insureTypeName||""},{label:"事故属性",value:t.properties.accidentProperty||""},{label:"当前状态",value:t.properties.currentStatusDesc||""},{label:"赔偿金额",value:t.properties.totalPayAmount?t.properties.totalPayAmount+"元":""}];break;case"Person":e=[{label:"id",value:t.properties.matchId||""},{label:"姓名",value:t.properties.name||""},{label:"身份证号",value:t.properties.identityNo||""}];break;case"Vehicle":e=[{label:"车牌号",value:t.properties.plateNo||""},{label:"车架号",value:t.properties.vin||""}];break;case"IdCardAddress":let i=t.properties.prov?t.properties.prov:"",s=t.properties.city?t.properties.city:"",a=t.properties.district?t.properties.district:"",o=t.properties.concat_address?t.properties.concat_address:"";e=[{label:"详细地址",value:i+s+a+o},{label:"省",value:i},{label:"市",value:s},{label:"区(县)",value:a},{label:"乡",value:o}];break;case"Account":e=[{label:"账户",value:t.properties.accountNo||""},{label:"账户名称",value:t.properties.accountName||""},{label:"开户行",value:t.properties.headBankName||""}];break;case"Phone":e=[{label:"电话号码",value:t.properties.phone||""}];break;case"Appraisal":e=[{label:"鉴定机构名称",value:t.properties.organization||""}];break;case"Repair":e=[{label:"修理厂名称",value:t.properties.repairName||""}];break;case"Hospital":e=[{label:"医院名称",value:t.properties.hospitalName||""}];break;case"Contractor":e=[{label:"包商名",value:t.properties.contractorName||""}];break;default:break}return t.showTxtArr=e,t},setCriclePosition(t,e,i,s){let a=document.getElementById("cricleMenu");a.style=`left: ${t}px; top: ${e}px;transform:scale(${i});display:block;`,this.menuCenterColor=this.nodeTypeData[this.nodesMapData[this.currentActiveNodeId].type].color,this.menuCenterTxt=this.nodeTypeData[this.nodesMapData[this.currentActiveNodeId].type].type,s&&(this.selectedNodeImg=null,this.selectedNodeImg=this.nodesMapData[this.selectedNodeId].image)},hideCricle(){this.selectedNodeId=null;let t=document.getElementById("cricleMenu");t&&(t.style="display:none")},setHoverPosition(t,e,i){this.hoverStyleOptions={x:t,y:e,scale:i};let s=document.getElementById("cricleStyle");s.style=`left: ${t}px; top: ${e}px;transform:scale(${i});display:block;`,this.hoverCenterColor=this.nodeTypeData[this.nodesMapData[this.currentHoverNodeId].type].color,this.hoverCenterBorderColor=this.nodeTypeData[this.nodesMapData[this.currentHoverNodeId].type].borderColor},hideHoverStyle(){let t=document.getElementById("cricleStyle");t.style="display:none;"},hideMenu(){this.showMenu=!1},nodesClassify(){let t=[],e=[],i=[],s=[],a=[],o=[],n=[],r=[],l=[],h=[],d=[];this.myChartData.nodes.forEach(c=>{switch(c.type){case"Case":h.push(c.id),d.push(c.properties.caseNo||"");break;case"Person":l.push(c.id);break;case"Vehicle":r.push(c.id);break;case"IdCardAddress":o.push(c.id);break;case"Account":n.push(c.id);break;case"Phone":a.push(c.id);break;case"Appraisal":s.push(c.id);break;case"Repair":i.push(c.id);break;case"Hospital":e.push(c.id);break;case"Contractor":t.push(c.id);break;default:break}}),this.classifyNodesData={CaseIds:h,PersonIds:l,VehicleIds:r,IdCardAddressIds:o,AccountIds:n,PhoneIds:a,AppraisalIds:s,RepairIds:i,HospitalIds:e,ContractorIds:t,caseNos:d}}},beforeDestroy(){clearInterval(this.intervalId),clearInterval(this.checkStoppedId)},watch:{isCollapse:{handler(t){this.hideCricle(),setTimeout(()=>{this.resizeNetwork()},600)},immediate:!0}}},l=r,h=(i("ad18"),i("1805")),d=Object(h["a"])(l,s,a,!1,null,"b65d04e6",null);e["default"]=d.exports},6282:function(t,e,i){!function(e,i){t.exports=i()}(0,(function(){return function(t){function e(s){if(i[s])return i[s].exports;var a=i[s]={i:s,l:!1,exports:{}};return t[s].call(a.exports,a,a.exports,e),a.l=!0,a.exports}var i={};return e.m=t,e.c=i,e.i=function(t){return t},e.d=function(t,i,s){e.o(t,i)||Object.defineProperty(t,i,{configurable:!1,enumerable:!0,get:s})},e.n=function(t){var i=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(i,"a",i),i},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="/dist/",e(e.s=2)}([function(t,e,i){var s=i(4)(i(1),i(5),null,null);t.exports=s.exports},function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var s=i(3);e.default={props:{startVal:{type:Number,required:!1,default:0},endVal:{type:Number,required:!1,default:2017},duration:{type:Number,required:!1,default:3e3},autoplay:{type:Boolean,required:!1,default:!0},decimals:{type:Number,required:!1,default:0,validator:function(t){return t>=0}},decimal:{type:String,required:!1,default:"."},separator:{type:String,required:!1,default:","},prefix:{type:String,required:!1,default:""},suffix:{type:String,required:!1,default:""},useEasing:{type:Boolean,required:!1,default:!0},easingFn:{type:Function,default:function(t,e,i,s){return i*(1-Math.pow(2,-10*t/s))*1024/1023+e}}},data:function(){return{localStartVal:this.startVal,displayValue:this.formatNumber(this.startVal),printVal:null,paused:!1,localDuration:this.duration,startTime:null,timestamp:null,remaining:null,rAF:null}},computed:{countDown:function(){return this.startVal>this.endVal}},watch:{startVal:function(){this.autoplay&&this.start()},endVal:function(){this.autoplay&&this.start()}},mounted:function(){this.autoplay&&this.start(),this.$emit("mountedCallback")},methods:{start:function(){this.localStartVal=this.startVal,this.startTime=null,this.localDuration=this.duration,this.paused=!1,this.rAF=(0,s.requestAnimationFrame)(this.count)},pauseResume:function(){this.paused?(this.resume(),this.paused=!1):(this.pause(),this.paused=!0)},pause:function(){(0,s.cancelAnimationFrame)(this.rAF)},resume:function(){this.startTime=null,this.localDuration=+this.remaining,this.localStartVal=+this.printVal,(0,s.requestAnimationFrame)(this.count)},reset:function(){this.startTime=null,(0,s.cancelAnimationFrame)(this.rAF),this.displayValue=this.formatNumber(this.startVal)},count:function(t){this.startTime||(this.startTime=t),this.timestamp=t;var e=t-this.startTime;this.remaining=this.localDuration-e,this.useEasing?this.countDown?this.printVal=this.localStartVal-this.easingFn(e,0,this.localStartVal-this.endVal,this.localDuration):this.printVal=this.easingFn(e,this.localStartVal,this.endVal-this.localStartVal,this.localDuration):this.countDown?this.printVal=this.localStartVal-(this.localStartVal-this.endVal)*(e/this.localDuration):this.printVal=this.localStartVal+(this.localStartVal-this.startVal)*(e/this.localDuration),this.countDown?this.printVal=this.printValthis.endVal?this.endVal:this.printVal,this.displayValue=this.formatNumber(this.printVal),e1?this.decimal+e[1]:"",a=/(\d+)(\d{3})/;if(this.separator&&!this.isNumber(this.separator))for(;a.test(i);)i=i.replace(a,"$1"+this.separator+"$2");return this.prefix+i+s+this.suffix}},destroyed:function(){(0,s.cancelAnimationFrame)(this.rAF)}}},function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var s=i(0),a=function(t){return t&&t.__esModule?t:{default:t}}(s);e.default=a.default,"undefined"!=typeof window&&window.Vue&&window.Vue.component("count-to",a.default)},function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var s=0,a="webkit moz ms o".split(" "),o=void 0,n=void 0;if("undefined"==typeof window)e.requestAnimationFrame=o=function(){},e.cancelAnimationFrame=n=function(){};else{e.requestAnimationFrame=o=window.requestAnimationFrame,e.cancelAnimationFrame=n=window.cancelAnimationFrame;for(var r=void 0,l=0;l{this.myChart&&this.myChart.resize()},600)},navForm:{immediate:!0,deep:!0,handler(t){this.getData()}}},data(){return{topDays:[],newNumber:0,myChart:"",loading:!0}},mounted(){this.role=localStorage.getItem("role"),window.addEventListener("resize",()=>{this.myChart&&setTimeout(()=>{this.myChart.resize()},500)})},methods:{getData(){this.loading=!0,this.instance({method:"post",url:"/large/data/screen/getClaimAmountClassification",data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(this.loading=!1,1==t.data.code){let e=t.data.data;e.length>0&&this.loadCharts(e)}})},loadCharts(t){var e=document.getElementById("reparations_amount_type_pie");if(!e)return;this.myChart&&this.myChart.dispose(),this.myChart=o["init"](e,null,{renderer:"svg"});let i=[];t.forEach((t,e)=>{let s={value:t.caseNumRatio,name:t.name,itemStyle:{borderColor:"#E3A505",shadowColor:"#433f24"}};1==e?s.itemStyle={borderColor:"#28fd7f",shadowColor:"#195c4b"}:2==e?s.itemStyle={borderColor:"#b1009a",shadowColor:"#632053"}:3==e?s.itemStyle={borderColor:"#2485af",shadowColor:"#082159"}:4==e?s.itemStyle={borderColor:"#e485af",shadowColor:"#382159"}:5==e&&(s.itemStyle={borderColor:"#f4893f",shadowColor:"#082359"}),i.push(s)});var s={tooltip:{trigger:"item",formatter:"{b}: {c}元",confine:!0},legend:{itemWidth:12,itemHeight:12,textStyle:{color:"#fff"},right:"5%",top:"middle",orient:"vertical"},series:[{type:"pie",radius:"60%",center:["40%","50%"],avoidLabelOverlap:!1,label:{position:"inner",fontSize:10,color:"#fff",formatter:"{d}%"},labelLine:{show:!1},itemStyle:{borderColor:"#e4393c",borderWidth:5,color:"#0A1A2E",shadowBlur:5,shadowColor:"rgba(85, 255, 0, 1)"},selectedMode:"single",data:i}]};this.myChart.setOption(s,!0)}},updated(){this.myChart&&this.myChart.resize()}},r=n,l=(i("a7c4"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"e504d1b2",null);e["default"]=h.exports},"6a7e":function(t,e,i){"use strict";i("a889")},"6b0b":function(t,e,i){"use strict";i("7363")},"6d87":function(t,e,i){},"6ddb":function(t,e,i){"use strict";i("3958")},"6e97":function(t,e,i){},"6f61":function(t,e,i){},"6f90":function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],staticClass:"module_wrap box_border",attrs:{"element-loading-text":"数据加载中","element-loading-spinner":"el-icon-loading","element-loading-background":"transparent"}},[e("div",{staticClass:"box_title"},[t._v(t._s("全国"==t.navForm.accidentProvince?"全国死亡案均金额排行榜":"死亡案均金额统计"))]),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.loading,expression:"!loading"}],staticStyle:{height:"55%"}},[e("div",{directives:[{name:"show",rawName:"v-show",value:"全国"==t.province,expression:"province == '全国'"}],attrs:{id:"case_num_sum_bar"}}),e("div",{directives:[{name:"show",rawName:"v-show",value:"全国"!=t.province,expression:"province != '全国'"}],attrs:{id:"case_num_sum_bar2"}}),t.tableData.length>0?e("div",{staticClass:"tables_box"},[e("el-table",{attrs:{data:[t.tableData[0]],"max-height":"200"}},t._l(t.tableData,(function(i,s){return e("el-table-column",{key:s,attrs:{label:i.accItem,width:String(i.accAmount).length>5?"100":""},scopedSlots:t._u([{key:"default",fn:function(e){return[t._e(),t._v(" "+t._s(i.accAmount?i.accAmount:"--")+" 元 ")]}}],null,!0)})})),1)],1):t._e()])])},a=[],o=(i("0faf"),i("b3ec"),i("6fc2"),i("2130"),i("ada4")),n={name:"CaseNumSum",props:{isCollapse:{type:Boolean,default:!0},navForm:{type:Object,default:{}}},watch:{isCollapse(){setTimeout(()=>{this.myChart&&this.myChart.resize()},600)},navForm:{immediate:!0,deep:!0,handler(t){this.province=t.accidentProvince,this.getData()}}},data(){return{topDays:[],newNumber:0,myChart:"",myChart2:"",option:"",province:"",tableData:[],loading:!0}},mounted(){this.role=localStorage.getItem("role"),window.addEventListener("resize",()=>{this.myChart&&setTimeout(()=>{this.myChart.resize()},500)})},methods:{getData(){this.loading=!0,this.instance({method:"post",url:"/large/data/screen/deathRanking",data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(this.loading=!1,1==t.data.code){let e=t.data.data;if(e.length>0){let t=e.map(t=>({...t,accItem:this.$$abbreviateCity(t.accItem)}));"全国"==this.province?(t=t.splice(0,20),this.loadCharts(t)):this.loadCharts2(t)}}})},loadCharts2(t){var e=document.getElementById("case_num_sum_bar2");if(!e)return;this.myChart2&&this.myChart2.dispose(),this.myChart2=o["init"](e,null,{renderer:"svg"});let i=[],s=[],a=[];t.forEach((t,e)=>{i.push(t.accItem),s.push(t.prvAmount),a.push(t.accAmount)}),this.tableData=t;let n={tooltip:{confine:!0,formatter:"{a}
{b}: {c}元",axisPointer:{type:"shadow"}},legend:{data:[this.province,"全国"],itemWidth:12,itemHeight:12,itemGap:20,textStyle:{color:"#fff"},left:"center"},grid:{top:25,left:"10",right:"10",bottom:"10",containLabel:!0},xAxis:{type:"category",splitLine:{show:!1},axisTick:{show:!0,alignWithLabel:!0},axisLabel:{showMaxLabel:!0,rotate:30,color:"#fff",width:70,overflow:"truncate",ellipsis:"..."},data:i},yAxis:{type:"value",splitLine:{show:!1},axisTick:{show:!1},axisLabel:{color:"#fff",formatter:"{value} 元"},axisLine:{show:!1}},color:new o["graphic"].LinearGradient(0,0,0,1,[{offset:0,color:"#FFFFFF"},{offset:1,color:"#B153F5"}]),series:[{name:this.province,type:"bar",itemStyle:{color:"#5283BD"},stack:"total",emphasis:{focus:"series"},barMaxWidth:"40%",data:s},{name:"全国",type:"bar",itemStyle:{color:new o["graphic"].LinearGradient(0,0,0,1,[{offset:0,color:"#FFFFFF"},{offset:1,color:"#F2B95D"}])},emphasis:{focus:"series"},stack:"total",barMaxWidth:"35%",data:a}]};this.myChart2.setOption(n)},loadCharts(t){var e=document.getElementById("case_num_sum_bar");if(!e)return;this.myChart=o["init"](e,null,{renderer:"svg"});let i=[],s=[];t.forEach((t,e)=>{i.push(t.accItem),s.push(t.accAmount)}),this.tableData=t;var a={tooltip:{trigger:"axis",formatter:"{b0} : {c0}元"},xAxis:{data:i,axisTick:{show:!1},axisLabel:{showMaxLabel:!0,rotate:40,color:"#fff",width:60,overflow:"truncate",ellipsis:"..."}},yAxis:{splitLine:{show:!1},axisTick:{show:!1},axisLine:{show:!1},axisLabel:{show:!0,color:"#fff",formatter:"{value} 元"}},grid:{top:"20",bottom:"5",left:"10",right:"10",containLabel:!0},color:["#88B3BD"],color:new o["graphic"].LinearGradient(0,0,0,1,[{offset:0,color:"#FFFFFF"},{offset:1,color:"#B153F5"}]),series:[{name:"hill",type:"pictorialBar",barCategoryGap:"-40%",symbol:"path://M0,10 L10,10 C5.5,10 5.5,5 5,0 C4.5,5 4.5,10 0,10 z",barWidth:"80%",label:{position:"top",color:"#fff",formatter:function(t){return Math.round(t.value/1e4)+" 万"}},emphasis:{itemStyle:{opacity:1}},data:s,z:10}]};this.myChart.setOption(a)}},updated(){this.myChart&&this.myChart.resize()}},r=n,l=(i("e2b4"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"2c47c9d0",null);e["default"]=h.exports},"72cc":function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{staticClass:"wrap"},[t._m(0),e("div",{staticClass:"search_box public_box"},[e("el-form",{staticClass:"demo-form-inline",attrs:{inline:!0,model:t.navForm}},[e("el-form-item",{staticClass:"noneMarginBottom",attrs:{label:"险种分类:"}},[e("el-select",{staticClass:"width_150",attrs:{filterable:"",clearable:"",placeholder:"请选择分类"},model:{value:t.navForm.insureTypeId,callback:function(e){t.$set(t.navForm,"insureTypeId",e)},expression:"navForm.insureTypeId"}},t._l(t.insureTypeList,(function(t,i){return e("el-option",{key:i,attrs:{label:t.metaData,value:t.id}})})),1)],1),e("el-form-item",{staticClass:"noneMarginBottom",attrs:{label:"险种名称:"}},[e("el-input",{staticClass:"width_150",attrs:{placeholder:"请填写名称",clearable:""},model:{value:t.navForm.insureName,callback:function(e){t.$set(t.navForm,"insureName",e)},expression:"navForm.insureName"}})],1),e("el-form-item",{staticClass:"noneMarginBottom"},[e("el-button",{attrs:{type:"primary"},on:{click:function(e){return t.searchTable(!0)}}},[t._v("查询")])],1)],1)],1),e("div",{staticClass:"table_box public_box"},[e("p",{staticStyle:{"text-align":"right","margin-bottom":"10px"}},[e("el-button",{attrs:{type:"primary"},on:{click:function(e){t.dialogVisibleVerify=!0}}},[t._v("新增+")])],1),e("el-table",{ref:"multipleTable",staticStyle:{width:"100%"},attrs:{data:t.tableData}},[e("el-table-column",{attrs:{prop:"insureType",label:"险种分类"}}),e("el-table-column",{attrs:{prop:"insureName",label:"险种名称"},scopedSlots:t._u([{key:"default",fn:function(i){return[i.row.insureName&&i.row.insureName.length>13?e("el-tooltip",{attrs:{effect:"dark",content:i.row.insureName,placement:"top-start"}},[e("span",[t._v(t._s(i.row.insureName.slice(0,13)+"..."))])]):e("span",[t._v(t._s(i.row.insureName))])]}}])}),e("el-table-column",{attrs:{prop:"thirdAmount",label:"三者赔付最高限额(万元)",width:"170"}}),e("el-table-column",{attrs:{prop:"deliveryAmount",label:"骑手医疗赔付责任限额(元)",width:"180"}}),e("el-table-column",{attrs:{prop:"rabidDogAmount",label:"狂犬疫苗赔偿限额(元)",width:"170"}}),e("el-table-column",{attrs:{prop:"deductibleAmount",label:"骑手医疗每次扣除免赔(元)",width:"180"}}),e("el-table-column",{attrs:{prop:"createUser",label:"创建人"}}),e("el-table-column",{attrs:{prop:"createTime",label:"创建时间",width:"140"}})],1),e("el-pagination",{staticStyle:{"margin-top":"0.2rem"},attrs:{"current-page":t.navForm.page,layout:"total, sizes, prev, pager, next, jumper","page-sizes":[10,20],"page-size":t.navForm.size,total:t.navForm.totalPage},on:{"current-change":t.handleCurrentChange,"size-change":t.handleSizeChange}})],1),e("el-dialog",{attrs:{visible:t.dialogVisibleVerify,title:"新增人伤险种赔付条款","append-to-body":!0,center:"",width:"50%"},on:{"update:visible":function(e){t.dialogVisibleVerify=e},close:function(e){return t.saveAddForm(!1)}}},[e("el-form",{ref:"addFormRef",staticClass:"unit-dialog_form",attrs:{inline:!0,model:t.addForm,rules:t.addFormRules,"label-position":"right","label-width":"170px"}},[e("el-form-item",{staticClass:"form_select",attrs:{label:"险种分类:",prop:"insureTypeId"}},[e("el-select",{attrs:{placeholder:"请选择",filterable:""},model:{value:t.addForm.insureTypeId,callback:function(e){t.$set(t.addForm,"insureTypeId",e)},expression:"addForm.insureTypeId"}},t._l(t.insureTypeList,(function(t,i){return e("el-option",{key:i,attrs:{label:t.metaData,value:t.id}})})),1)],1),e("el-form-item",{attrs:{label:"险种名称:",prop:"insureName"}},[e("el-input",{attrs:{placeholder:"请输入内容"},model:{value:t.addForm.insureName,callback:function(e){t.$set(t.addForm,"insureName",e)},expression:"addForm.insureName"}})],1),e("el-form-item",{attrs:{label:"三者赔付最高限额:",prop:"thirdAmount"}},[e("el-input",{attrs:{type:"number",oninput:"if(value.length > 13){value = value.slice(0,13)}",placeholder:"请输入内容"},model:{value:t.addForm.thirdAmount,callback:function(e){t.$set(t.addForm,"thirdAmount",t._n(e))},expression:"addForm.thirdAmount"}}),t._v("万元 ")],1),e("el-form-item",{attrs:{label:"骑手医疗赔付责任限额:",prop:"deliveryAmount"}},[e("el-input",{attrs:{type:"number",oninput:"if(value.length > 13){value = value.slice(0,13)}",placeholder:"请输入内容"},model:{value:t.addForm.deliveryAmount,callback:function(e){t.$set(t.addForm,"deliveryAmount",t._n(e))},expression:"addForm.deliveryAmount"}}),t._v("元 ")],1),e("el-form-item",{attrs:{label:"狂犬疫苗医疗赔偿限额:",prop:"rabidDogAmount"}},[e("el-input",{attrs:{type:"number",oninput:"if(value.length > 13){value = value.slice(0,13)}",placeholder:"请输入内容"},model:{value:t.addForm.rabidDogAmount,callback:function(e){t.$set(t.addForm,"rabidDogAmount",t._n(e))},expression:"addForm.rabidDogAmount"}}),t._v("元 ")],1),e("el-form-item",{attrs:{label:"骑手医疗每次扣除免赔:",prop:"deductibleAmount"}},[e("el-input",{attrs:{type:"number",oninput:"if(value.length > 13){value = value.slice(0,13)}",placeholder:"请输入内容"},model:{value:t.addForm.deductibleAmount,callback:function(e){t.$set(t.addForm,"deductibleAmount",t._n(e))},expression:"addForm.deductibleAmount"}}),t._v("元 ")],1)],1),e("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[e("el-button",{on:{click:function(e){return t.saveAddForm(!1)}}},[t._v("取 消")]),e("el-button",{attrs:{type:"primary"},on:{click:function(e){return t.saveAddForm(!0)}}},[t._v("确 定")])],1)],1)],1)},a=[function(){var t=this,e=t._self._c;return e("div",{staticClass:"page_title"},[e("b",[t._v("人伤险种赔付设置")])])}],o={name:"onlineTesting",components:{},data(){return{navForm:{insureTypeId:"",insureName:"",page:1,size:10,totalPage:0},insureTypeList:[],options:[],tableData:[],dialogVisibleVerify:!1,addForm:{insureTypeId:"",insureName:"",thirdAmount:"",deliveryAmount:"",rabidDogAmount:"",deductibleAmount:""},addFormRules:{insureTypeId:[{required:!0,message:"请选择分类",trigger:"change"}],insureName:[{required:!0,message:"请输入名称",trigger:"blur"}]}}},mounted(){this.getInsureType(),this.searchTable()},methods:{searchTable(t){this.navForm.page=t?1:this.navForm.page,this.instance.post("/medicalFileLimit/searchPage",this.navForm).then(t=>{var e=t.data;1==e.code&&(this.tableData=e.data.list,this.navForm.totalPage=e.data.total)})},handleCurrentChange(t){this.navForm.page=t,this.searchTable()},handleSizeChange(t){this.navForm.size=t,this.searchTable()},saveAddForm(t){t?this.$refs.addFormRef.validate(t=>{if(t){let t=this.insureTypeList.findIndex(t=>t.id==this.addForm.insureTypeId);this.addForm.insureType=-1!=t?this.insureTypeList[t].metaData:"",this.instance.post("/medicalFileLimit",this.addForm).then(t=>{let e=t.data;1==e.code?(this.searchTable(),this.$message.success("新增人伤险种赔付条款成功"),this.dialogVisibleVerify=!1,this.$refs.addFormRef.resetFields()):this.$message.error(e.message)})}}):(this.dialogVisibleVerify=!1,this.$refs.addFormRef.resetFields())},getInsureType(){this.instance.post("/backstage/getDict",{dictType:"MEDICAL_LIMIT_TYPE"}).then(t=>{var e=t.data;1==e.code&&(this.insureTypeList=e.data)})}}},n=o,r=(i("c060"),i("1805")),l=Object(r["a"])(n,s,a,!1,null,null,null);e["default"]=l.exports},7363:function(t,e,i){},"74e6":function(t,e,i){},"78ec":function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{staticClass:"invoice-content"},[e("div",{staticClass:"align-title autoC"},[t._v("图像查重平台")]),e("div",{staticClass:"align-inputs autoC"},[e("i",{staticClass:"input-icon el-icon-search"}),e("el-input",{staticClass:"align-input",attrs:{placeholder:"请输入案件号"},nativeOn:{keyup:function(e){return!e.type.indexOf("key")&&t._k(e.keyCode,"enter",13,e.key,"Enter")?null:t.invoiceSearch.apply(null,arguments)}},model:{value:t.caseNo,callback:function(e){t.caseNo=e},expression:"caseNo"}}),e("span",{staticClass:"input-btn",on:{click:t.invoiceSearch}},[t._v("查验")])],1),e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.searchLoading,expression:"searchLoading"}],staticClass:"align-center"},[t.searchData.length>0?[t.menuShow?e("ul",{class:t.searchData.length<6?"small_amount clearfix":"large autoC clearfix"},t._l(t.searchData,(function(i,s){return e("li",{key:s,on:{click:function(e){return t.invoiceDetail(i)}}},[e("el-card",{staticClass:"box-card"},[e("div",{staticClass:"clearfix",attrs:{slot:"header"},slot:"header"},[e("p",{staticStyle:{"margin-bottom":"5px"}},[t._v("风险案件号:")]),e("p",{staticStyle:{"margin-bottom":"8px"}},[t._v(t._s(i?i.caseNo:""))]),e("p",{staticStyle:{"margin-bottom":"5px"}},[t._v("保单号:")]),e("p",{staticStyle:{"margin-bottom":"8px"}},[t._v(t._s(i.targetInvoiceList&&i.targetInvoiceList[0]?i.targetInvoiceList[0].policyNo:""))]),e("p",{staticStyle:{"margin-bottom":"5px"}},[t._v("出险时间:")]),e("p",{staticStyle:{"margin-bottom":"8px"}},[t._v(t._s(i.targetInvoiceList&&i.targetInvoiceList[0]?i.targetInvoiceList[0].accidentTime:""))])]),e("div",{staticClass:"card_content",on:{click:function(e){return t.invoiceDetail(i)}}},[e("div",{staticClass:"caseInvoice"},[e("p",[t._v("重复图像数:"+t._s(i.caseInvoiceList?i.caseInvoiceList.length:""))])])])])],1)})),0):e("ul",{class:t.searchData.length<6?"small_amount clearfix":"menuFalseLarge autoC clearfix"},t._l(t.searchData,(function(i,s){return e("li",{key:s,on:{click:function(e){return t.invoiceDetail(i)}}},[e("el-card",{staticClass:"box-card"},[e("div",{staticClass:"clearfix",attrs:{slot:"header"},slot:"header"},[e("p",{staticStyle:{"margin-bottom":"5px"}},[t._v("风险案件号:")]),e("p",{staticStyle:{"margin-bottom":"8px"}},[t._v(t._s(i?i.caseNo:""))]),e("p",{staticStyle:{"margin-bottom":"5px"}},[t._v("保单号:")]),e("p",{staticStyle:{"margin-bottom":"8px"}},[t._v(t._s(i.targetInvoiceList&&i.targetInvoiceList[0]?i.targetInvoiceList[0].policyNo:""))]),e("p",{staticStyle:{"margin-bottom":"5px"}},[t._v("出险时间:")]),e("p",{staticStyle:{"margin-bottom":"8px"}},[t._v(t._s(i.targetInvoiceList&&i.targetInvoiceList[0]?i.targetInvoiceList[0].accidentTime:""))])]),e("div",{staticClass:"card_content",on:{click:function(e){return t.invoiceDetail(i)}}},[e("div",{staticClass:"caseInvoice"},[e("p",[t._v("重复图像数:"+t._s(i.caseInvoiceList?i.caseInvoiceList.length:""))])])])])],1)})),0)]:t._e(),0==t.searchData.length?e("el-empty",{attrs:{description:t.caseNo?t.descriptionTxt:"暂无数据"}}):t._e()],2),e("el-dialog",{staticClass:"popup_invoice",attrs:{center:"","append-to-body":"",visible:t.dialogVisible,width:"90%","before-close":t.closeDIalog},on:{"update:visible":function(e){t.dialogVisible=e}}},[e("div",{staticClass:"dialog_invoice clearfix"},[e("div",{staticClass:"dialog_left fl"},[e("p",{staticClass:"dialog_title",on:{click:function(e){return t.copyTxt(t.caseNo)}}},[t._v(" 查询案件号: "),t.caseNo&&t.caseNo.length>40?e("span",[t._v(t._s(t.caseNo.slice(0,40)+"..."))]):t.caseNo?e("span",[t._v(t._s(t.caseNo))]):t._e()]),e("p",{staticStyle:{"margin-bottom":"10px"},on:{click:function(e){return t.copyTxt(t.imgListData.left.imgUrlList[0].policyNo)}}},[t._v("保单号:"+t._s(t.imgListData.left.imgUrlList&&t.imgListData.left.imgUrlList[0]?t.imgListData.left.imgUrlList[0].policyNo:""))]),e("p",{staticStyle:{"margin-bottom":"10px"}},[t._v("出险时间:"+t._s(t.imgListData.left.imgUrlList&&t.imgListData.left.imgUrlList[0]?t.imgListData.left.imgUrlList[0].accidentTime:""))]),e("div",{staticClass:"invoice_carousel"},[t._e(),e("img-deal",{ref:"imgDeal",attrs:{url:t.previewCaseInvoiceImg}})],1),e("div",{staticClass:"invoice_content"},[t.imgListData.left.imgUrlList.length>0?e("div",{staticClass:"preview-box"},[e("i",{staticClass:"left-btn el-icon-arrow-left",on:{click:function(e){return t.imgLeft("left")}}}),e("div",{staticClass:"img_list"},[e("ul",{staticClass:"img_ul"},[t._l(t.imgListData.left.imgUrlList,(function(i,s){return[e("li",{key:s,staticClass:"Img_li",style:t.leftImgStyle,on:{click:function(e){return t.switchPreviewImg(i,s,"left")}}},[e("img",{class:s===t.imgListData.left.imgActiveIndex?"img_activeBorder":"",attrs:{src:i.imageUrl}})])]}))],2)]),e("i",{staticClass:"right-btn el-icon-arrow-right",on:{click:function(e){return t.imgRight("left")}}})]):t._e()])]),e("div",{staticClass:"dialog_right fr"},[e("p",{staticClass:"dialog_title",on:{click:function(e){return t.copyTxt(t.invoiceData.caseNo)}}},[t._v(" 风险案件号: "),t.invoiceData.caseNo&&t.invoiceData.caseNo.length>40?e("span",[t._v(t._s(t.invoiceData.caseNo.slice(0,40)+"..."))]):e("span",[t._v(t._s(t.invoiceData?t.invoiceData.caseNo:""))])]),e("p",{staticStyle:{"margin-bottom":"10px"},on:{click:function(e){return t.copyTxt(t.imgListData.right.imgUrlList[0].policyNo)}}},[t._v("保单号:"+t._s(t.imgListData.right.imgUrlList&&t.imgListData.right.imgUrlList[0]?t.imgListData.right.imgUrlList[0].policyNo:""))]),e("p",{staticStyle:{"margin-bottom":"10px"}},[t._v("出险时间:"+t._s(t.imgListData.right.imgUrlList&&t.imgListData.right.imgUrlList[0]?t.imgListData.right.imgUrlList[0].accidentTime:""))]),e("div",{staticClass:"invoice_carousel"},[t._e(),e("img-deal",{ref:"imgDeal",attrs:{url:t.previewTargetInvoiceImg}})],1),e("div",{staticClass:"invoice_content"},[t.imgListData.right.imgUrlList.length>0?e("div",{staticClass:"preview-box"},[e("i",{staticClass:"left-btn el-icon-arrow-left",on:{click:function(e){return t.imgLeft("left")}}}),e("div",{staticClass:"img_list"},[e("ul",{staticClass:"img_ul"},[t._l(t.imgListData.right.imgUrlList,(function(i,s){return[e("li",{key:s+100,staticClass:"Img_li",style:t.leftImgStyle,on:{click:function(e){return t.switchPreviewImg(i,s,"left")}}},[e("img",{class:s===t.imgListData.left.imgActiveIndex?"img_activeBorder":"",attrs:{src:i.imageUrl}})])]}))],2)]),e("i",{staticClass:"right-btn el-icon-arrow-right",on:{click:function(e){return t.imgRight("left")}}})]):t._e()])])])]),e("div",{staticClass:"footer"},[t._v("Copyright @2023 北京宏瓴科技发展有限公司")])],1)},a=[],o=(i("e4c6"),i("320b"),i("18dd")),n={components:{ImgDeal:o["a"]},data(){return{searchLoading:!1,dialogVisible:!1,caseNo:"6020200807032022042276254",dataImgUrl:"",imgLoad:!1,searchObj:{},searchData:[],invoiceData:{},descriptionTxt:"暂无数据",caseInvoiceCurrentIndex:1,targetInvoiceCurrentIndex:1,imgUrlList:[],previewCaseInvoiceImg:"",previewTargetInvoiceImg:"",imgActiveIndex:0,imgDistance:0,allDistance:0,imgListData:{left:{imgUrlList:[],imgActiveIndex:0,imgDistance:0,allDistance:0},right:{imgUrlList:[],imgActiveIndex:0,imgDistance:0,allDistance:0}},menuShow:!0}},computed:{leftImgStyle(){return{transform:`translate3d(${this.imgListData.left.imgDistance}px, 0, 0)`}},rightImgStyle(){return{transform:`translate3d(${this.imgListData.right.imgDistance}px, 0, 0)`}}},mounted(){"E7IpJc*6(=}<"==localStorage.getItem("AUTH_TOKEN")&&(this.menuShow=!1,document.getElementsByClassName("fold_icon")[0].style.display="none",document.getElementsByClassName("header_right")[0].style.display="none",document.getElementsByClassName("header")[0].style.position="relative",document.getElementsByClassName("header")[0].style.zIndex=9)},methods:{invoiceSearch(){this.searchObj={},this.searchData=[],this.searchLoading=this.caseNo,this.caseNo&&this.instance.post("/case/invoiceDuplicateCheck",{caseNo:this.caseNo}).then(t=>{this.searchLoading=!1,1==t.data.code?(this.searchData=t.data.data,t.data.data.length<1&&(this.descriptionTxt="暂未发现图像异常案件"),this.$message.success(t.data.message)):this.$message.error(t.data.message)})},invoiceDetail(t){this.dialogVisible=!0,this.invoiceData=t,this.invoiceData.caseInvoiceList.length>0&&(this.imgListData.left.imgUrlList=this.invoiceData.caseInvoiceList,this.previewCaseInvoiceImg=this.invoiceData.caseInvoiceList[0].imageUrl),this.invoiceData.targetInvoiceList.length>0&&(this.imgListData.right.imgUrlList=this.invoiceData.targetInvoiceList,this.previewTargetInvoiceImg=this.invoiceData.targetInvoiceList[0].imageUrl)},imgOload(t){this.imgLoad=t},copyTxt(t){let e=document.createElement("input");e.value=t,document.body.appendChild(e),e.select(),document.execCommand("Copy"),e.remove(),this.$message.success("复制成功")},leftCarouselChange(t){this.caseInvoiceCurrentIndex=t+1},rightCarouselChange(t){this.targetInvoiceCurrentIndex=t+1},imgLeft(t){if(this.imgListData[t].imgActiveIndex>0?this.imgListData[t].imgActiveIndex--:this.imgListData[t].imgActiveIndex=0,this.imgListData[t].imgActiveIndex>=6){var e=0;const i=window.setInterval(()=>{if(e<45)return this.imgListData[t].imgDistance+=2,void e++;window.clearInterval(i)},10)}this.previewCaseInvoiceImg=this.imgListData["left"].imgUrlList[this.imgListData["left"].imgActiveIndex].imageUrl,this.previewTargetInvoiceImg=this.imgListData["right"].imgUrlList[this.imgListData["left"].imgActiveIndex].imageUrl},imgRight(t){if(this.imgListData[t].imgActiveIndex=7&&this.imgListData[t].imgActiveIndex<=this.imgListData[t].imgUrlList.length-1){this.imgListData[t].allDistance=-90*(this.imgListData[t].imgActiveIndex-4);var e=0;const i=window.setInterval(()=>{if(e<45)return this.imgListData[t].imgDistance-=2,void e++;window.clearInterval(i)},10)}}else{this.imgListData[t].imgActiveIndex=0;e=0;var i=Math.abs(JSON.parse(JSON.stringify(this.imgListData[t].imgDistance)))/4;const s=window.setInterval(()=>{if(e0?[t._l(t.caseTotalRemined.contentList,(function(i,s){return[i.isNo?[i.caseNo.length>60?e("el-tooltip",{key:i.caseNo,attrs:{effect:"dark",placement:"top-start"}},[e("div",{staticStyle:{"max-width":"400px"},attrs:{slot:"content"},slot:"content"},[t._v(t._s(i.caseNo))]),e("div",{staticStyle:{"margin-top":"5px"}},[t._v(t._s(i.caseNo.slice(0,60)+"..."))])]):e("div",{key:i,staticStyle:{"margin-top":"5px"}},[t._v(t._s(i.caseNo))])]:e("p",{key:s,staticStyle:{"margin-top":"5px","line-height":"20px"},domProps:{innerHTML:t._s(i)}})]}))]:e("p",{staticStyle:{"text-align":"center"}},[t._v("暂无数据")])],2)])],1)]),e("div",{staticClass:"regions_content clearfix"},[e("h3",[t._v("分月案均金额")]),e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.monthlyAnalysisRemined.loading,expression:"monthlyAnalysisRemined.loading"}],staticClass:"regions-box regions-content_left fl"},[e("div",{directives:[{name:"show",rawName:"v-show",value:t.monthlyAnalysisRemined.showChart,expression:"monthlyAnalysisRemined.showChart"}],staticClass:"chart_box",attrs:{id:"chart2"}}),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.monthlyAnalysisRemined.showChart,expression:"!monthlyAnalysisRemined.showChart"}],staticClass:"chart_box"},[e("p",{staticClass:"noneData"},[t._v("暂无数据")])])]),e("div",{staticClass:"regions-box regions-content_right fr clearfix"},[e("el-tabs",{on:{"tab-click":function(e){return t.handleClick(t.monthlyAnalysisRemined)}},model:{value:t.monthlyAnalysisRemined.activeName,callback:function(e){t.$set(t.monthlyAnalysisRemined,"activeName",e)},expression:"monthlyAnalysisRemined.activeName"}},[e("el-tab-pane",{attrs:{label:"异常点",name:"first"}}),e("el-tab-pane",{attrs:{label:"分析",name:"second"}}),e("el-tab-pane",{attrs:{label:"建议",name:"third"}})],1),e("div",{staticClass:"abnormal fl"},[e("div",{staticClass:"abnormal-txt"},[t.monthlyAnalysisRemined.contentList.length>0?[t._l(t.monthlyAnalysisRemined.contentList,(function(i,s){return[i.isNo?[i.caseNo.length>60?e("el-tooltip",{key:i.caseNo,attrs:{effect:"dark",placement:"top-start"}},[e("div",{staticStyle:{"max-width":"400px"},attrs:{slot:"content"},slot:"content"},[t._v(t._s(i.caseNo))]),e("div",{staticStyle:{"margin-top":"5px"}},[t._v(t._s(i.caseNo.slice(0,60)+"..."))])]):e("div",{key:i,staticStyle:{"margin-top":"5px"}},[t._v(t._s(i.caseNo))])]:e("p",{key:s,staticStyle:{"margin-top":"5px","line-height":"20px"},domProps:{innerHTML:t._s(i)}})]}))]:e("p",{staticStyle:{"text-align":"center"}},[t._v("暂无数据")])],2)])],1)]),e("div",{staticClass:"regions_content clearfix"},[e("h3",[t._v("零结案、注销案件月度情况")]),e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.monthlyCancel.loading,expression:"monthlyCancel.loading"}],staticClass:"regions-box regions-content_left fl"},[e("div",{directives:[{name:"show",rawName:"v-show",value:t.monthlyCancel.showChart,expression:"monthlyCancel.showChart"}],staticClass:"chart_box",attrs:{id:"chart3"}}),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.monthlyCancel.showChart,expression:"!monthlyCancel.showChart"}],staticClass:"chart_box"},[e("p",{staticClass:"noneData"},[t._v("暂无数据")])])]),e("div",{staticClass:"regions-box regions-content_right fr clearfix"},[e("el-tabs",{on:{"tab-click":function(e){return t.handleClick(t.monthlyCancel)}},model:{value:t.monthlyCancel.activeName,callback:function(e){t.$set(t.monthlyCancel,"activeName",e)},expression:"monthlyCancel.activeName"}},[e("el-tab-pane",{attrs:{label:"异常点",name:"first"}}),e("el-tab-pane",{attrs:{label:"分析",name:"second"}}),e("el-tab-pane",{attrs:{label:"建议",name:"third"}})],1),e("div",{staticClass:"abnormal fl"},[e("div",{staticClass:"abnormal-txt"},[t.monthlyCancel.contentList.length>0?[t._l(t.monthlyCancel.contentList,(function(i,s){return[i.isNo?[i.caseNo.length>60?e("el-tooltip",{key:i.caseNo,attrs:{effect:"dark",placement:"top-start"}},[e("div",{staticStyle:{"max-width":"400px"},attrs:{slot:"content"},slot:"content"},[t._v(t._s(i.caseNo))]),e("div",{staticStyle:{"margin-top":"5px"}},[t._v(t._s(i.caseNo.slice(0,60)+"..."))])]):e("div",{key:i,staticStyle:{"margin-top":"5px"}},[t._v(t._s(i.caseNo))])]:e("p",{key:s,staticStyle:{"margin-top":"5px","line-height":"20px"},domProps:{innerHTML:t._s(i)}})]}))]:e("p",{staticStyle:{"text-align":"center"}},[t._v("暂无数据")])],2)])],1)]),e("div",{staticClass:"regions_content clearfix"},[e("h3",[t._v("月度案件数量(案件金额高于5000、低于5000)")]),e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.monthlyAnalysisRemind.loading,expression:"monthlyAnalysisRemind.loading"}],staticClass:"regions-box regions-content_left fl"},[e("div",{directives:[{name:"show",rawName:"v-show",value:t.monthlyAnalysisRemind.showChart,expression:"monthlyAnalysisRemind.showChart"}],staticClass:"chart_box",attrs:{id:"chart4"}}),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.monthlyAnalysisRemind.showChart,expression:"!monthlyAnalysisRemind.showChart"}],staticClass:"chart_box"},[e("p",{staticClass:"noneData"},[t._v("暂无数据")])])]),e("div",{staticClass:"regions-box regions-content_right fr clearfix"},[e("el-tabs",{on:{"tab-click":function(e){return t.handleClick(t.monthlyAnalysisRemind)}},model:{value:t.monthlyAnalysisRemind.activeName,callback:function(e){t.$set(t.monthlyAnalysisRemind,"activeName",e)},expression:"monthlyAnalysisRemind.activeName"}},[e("el-tab-pane",{attrs:{label:"异常点",name:"first"}}),e("el-tab-pane",{attrs:{label:"分析",name:"second"}}),e("el-tab-pane",{attrs:{label:"建议",name:"third"}})],1),e("div",{staticClass:"abnormal fl"},[e("div",{staticClass:"abnormal-txt"},[t.monthlyAnalysisRemind.contentList.length>0?[t._l(t.monthlyAnalysisRemind.contentList,(function(i,s){return[i.isNo?[i.caseNo.length>60?e("el-tooltip",{key:i.caseNo,attrs:{effect:"dark",placement:"top-start"}},[e("div",{staticStyle:{"max-width":"400px"},attrs:{slot:"content"},slot:"content"},[t._v(t._s(i.caseNo))]),e("div",{staticStyle:{"margin-top":"5px"}},[t._v(t._s(i.caseNo.slice(0,60)+"..."))])]):e("div",{key:i,staticStyle:{"margin-top":"5px"}},[t._v(t._s(i.caseNo))])]:e("p",{key:s,staticStyle:{"margin-top":"5px","line-height":"20px"},domProps:{innerHTML:t._s(i)}})]}))]:e("p",{staticStyle:{"text-align":"center"}},[t._v("暂无数据")])],2)])],1)])]),e("el-tab-pane",{attrs:{label:"区域",name:"second"}},[e("div",{staticClass:"regions_content clearfix"},[e("h3",{staticStyle:{"padding-left":"16px","margin-top":"10px"}},[t._v("各市案件量、总赔款")]),e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.cityAnalysisRemind.loading,expression:"cityAnalysisRemind.loading"}],staticClass:"regions-box regions-content_left fl"},[e("div",{directives:[{name:"show",rawName:"v-show",value:t.cityAnalysisRemind.showChart,expression:"cityAnalysisRemind.showChart"}],staticClass:"chart_box",staticStyle:{height:"650px","min-height":"500px"},attrs:{id:"chart5"}}),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.cityAnalysisRemind.showChart,expression:"!cityAnalysisRemind.showChart"}],staticClass:"chart_box"},[e("p",{staticClass:"noneData"},[t._v("暂无数据")])])]),e("div",{staticClass:"regions-box regions-content_right fr clearfix"},[e("el-tabs",{on:{"tab-click":function(e){return t.handleClick(t.cityAnalysisRemind)}},model:{value:t.cityAnalysisRemind.activeName,callback:function(e){t.$set(t.cityAnalysisRemind,"activeName",e)},expression:"cityAnalysisRemind.activeName"}},[e("el-tab-pane",{attrs:{label:"异常点",name:"first"}}),e("el-tab-pane",{attrs:{label:"分析",name:"second"}}),e("el-tab-pane",{attrs:{label:"建议",name:"third"}})],1),e("div",{staticClass:"abnormal fl"},[e("div",{staticClass:"abnormal-txt"},[t.cityAnalysisRemind.contentList.length>0?[t._l(t.cityAnalysisRemind.contentList,(function(i,s){return[i.isNo?[i.caseNo.length>60?e("el-tooltip",{key:i.caseNo,attrs:{effect:"dark",placement:"top-start"}},[e("div",{staticStyle:{"max-width":"400px"},attrs:{slot:"content"},slot:"content"},[t._v(t._s(i.caseNo))]),e("div",{staticStyle:{"margin-top":"5px"}},[t._v(t._s(i.caseNo.slice(0,60)+"..."))])]):e("div",{key:i,staticStyle:{"margin-top":"5px"}},[t._v(t._s(i.caseNo))])]:e("p",{key:s,staticStyle:{"margin-top":"5px","line-height":"20px"},domProps:{innerHTML:t._s(i)}})]}))]:e("p",{staticStyle:{"text-align":"center"}},[t._v("暂无数据")])],2)])],1)]),e("div",{staticClass:"regions_content clearfix"},[e("h3",[t._v("案均赔款量")]),e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.cityAnalysisAvgRemind.loading,expression:"cityAnalysisAvgRemind.loading"}],staticClass:"regions-box regions-content_left fl"},[e("div",{directives:[{name:"show",rawName:"v-show",value:t.cityAnalysisAvgRemind.showChart,expression:"cityAnalysisAvgRemind.showChart"}],staticClass:"chart_box",staticStyle:{height:"650px","min-height":"500px"},attrs:{id:"chart6"}}),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.cityAnalysisAvgRemind.showChart,expression:"!cityAnalysisAvgRemind.showChart"}],staticClass:"chart_box"},[e("p",{staticClass:"noneData"},[t._v("暂无数据")])])]),e("div",{staticClass:"regions-box regions-content_right fr clearfix"},[e("el-tabs",{on:{"tab-click":function(e){return t.handleClick(t.cityAnalysisAvgRemind)}},model:{value:t.cityAnalysisAvgRemind.activeName,callback:function(e){t.$set(t.cityAnalysisAvgRemind,"activeName",e)},expression:"cityAnalysisAvgRemind.activeName"}},[e("el-tab-pane",{attrs:{label:"异常点",name:"first"}}),e("el-tab-pane",{attrs:{label:"分析",name:"second"}}),e("el-tab-pane",{attrs:{label:"建议",name:"third"}})],1),e("div",{staticClass:"abnormal fl"},[e("div",{staticClass:"abnormal-txt"},[t.cityAnalysisAvgRemind.contentList.length>0?[t._l(t.cityAnalysisAvgRemind.contentList,(function(i,s){return[i.isNo?[i.caseNo.length>60?e("el-tooltip",{key:i.caseNo,attrs:{effect:"dark",placement:"top-start"}},[e("div",{staticStyle:{"max-width":"400px"},attrs:{slot:"content"},slot:"content"},[t._v(t._s(i.caseNo))]),e("div",{staticStyle:{"margin-top":"5px"}},[t._v(t._s(i.caseNo.slice(0,60)+"..."))])]):e("div",{key:i,staticStyle:{"margin-top":"5px"}},[t._v(t._s(i.caseNo))])]:e("p",{key:s,staticStyle:{"margin-top":"5px","line-height":"20px"},domProps:{innerHTML:t._s(i)}})]}))]:e("p",{staticStyle:{"text-align":"center"}},[t._v("暂无数据")])],2)])],1)]),e("div",{staticClass:"regions_content clearfix"},[e("h3",[t._v("城市案件量Top3")]),e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.cityTopReportRemind1.loading,expression:"cityTopReportRemind1.loading"}],staticClass:"regions-box regions-content_left fl"},[e("div",{directives:[{name:"show",rawName:"v-show",value:t.cityTopReportRemind1.showChart,expression:"cityTopReportRemind1.showChart"}],staticClass:"chart_box",attrs:{id:"chart7"}}),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.cityTopReportRemind1.showChart,expression:"!cityTopReportRemind1.showChart"}],staticClass:"chart_box"},[e("p",{staticClass:"noneData"},[t._v("暂无数据")])])]),e("div",{staticClass:"regions-box regions-content_right fr clearfix"},[e("el-tabs",{on:{"tab-click":function(e){return t.handleClick(t.cityTopReportRemind1)}},model:{value:t.cityTopReportRemind1.activeName,callback:function(e){t.$set(t.cityTopReportRemind1,"activeName",e)},expression:"cityTopReportRemind1.activeName"}},[e("el-tab-pane",{attrs:{label:"异常点",name:"first"}}),e("el-tab-pane",{attrs:{label:"分析",name:"second"}}),e("el-tab-pane",{attrs:{label:"建议",name:"third"}})],1),e("div",{staticClass:"abnormal fl"},[e("div",{staticClass:"abnormal-txt"},[t.cityTopReportRemind1.contentList.length>0?[t._l(t.cityTopReportRemind1.contentList,(function(i,s){return[i.isNo?[i.caseNo.length>60?e("el-tooltip",{key:i.caseNo,attrs:{effect:"dark",placement:"top-start"}},[e("div",{staticStyle:{"max-width":"400px"},attrs:{slot:"content"},slot:"content"},[t._v(t._s(i.caseNo))]),e("div",{staticStyle:{"margin-top":"5px"}},[t._v(t._s(i.caseNo.slice(0,60)+"..."))])]):e("div",{key:i,staticStyle:{"margin-top":"5px"}},[t._v(t._s(i.caseNo))])]:e("p",{key:s,staticStyle:{"margin-top":"5px","line-height":"20px"},domProps:{innerHTML:t._s(i)}})]}))]:e("p",{staticStyle:{"text-align":"center"}},[t._v("暂无数据")])],2)])],1)]),e("div",{staticClass:"regions_content clearfix"},[e("h3",[t._v("城市总赔款Top3")]),e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.cityTopReportRemind2.loading,expression:"cityTopReportRemind2.loading"}],staticClass:"regions-box regions-content_left fl"},[e("div",{directives:[{name:"show",rawName:"v-show",value:t.cityTopReportRemind2.showChart,expression:"cityTopReportRemind2.showChart"}],staticClass:"chart_box",attrs:{id:"chart8"}}),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.cityTopReportRemind2.showChart,expression:"!cityTopReportRemind2.showChart"}],staticClass:"chart_box"},[e("p",{staticClass:"noneData"},[t._v("暂无数据")])])]),e("div",{staticClass:"regions-box regions-content_right fr clearfix"},[e("el-tabs",{on:{"tab-click":function(e){return t.handleClick(t.cityTopReportRemind2)}},model:{value:t.cityTopReportRemind2.activeName,callback:function(e){t.$set(t.cityTopReportRemind2,"activeName",e)},expression:"cityTopReportRemind2.activeName"}},[e("el-tab-pane",{attrs:{label:"异常点",name:"first"}}),e("el-tab-pane",{attrs:{label:"分析",name:"second"}}),e("el-tab-pane",{attrs:{label:"建议",name:"third"}})],1),e("div",{staticClass:"abnormal fl"},[e("div",{staticClass:"abnormal-txt"},[t.cityTopReportRemind2.contentList.length>0?[t._l(t.cityTopReportRemind2.contentList,(function(i,s){return[i.isNo?[i.caseNo.length>60?e("el-tooltip",{key:i.caseNo,attrs:{effect:"dark",placement:"top-start"}},[e("div",{staticStyle:{"max-width":"400px"},attrs:{slot:"content"},slot:"content"},[t._v(t._s(i.caseNo))]),e("div",{staticStyle:{"margin-top":"5px"}},[t._v(t._s(i.caseNo.slice(0,60)+"..."))])]):e("div",{key:i,staticStyle:{"margin-top":"5px"}},[t._v(t._s(i.caseNo))])]:e("p",{key:s,staticStyle:{"margin-top":"5px","line-height":"20px"},domProps:{innerHTML:t._s(i)}})]}))]:e("p",{staticStyle:{"text-align":"center"}},[t._v("暂无数据")])],2)])],1)]),e("div",{staticClass:"regions_content clearfix"},[e("h3",[t._v("城市案均赔款Top3")]),e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.cityTopReportRemind3.loading,expression:"cityTopReportRemind3.loading"}],staticClass:"regions-box regions-content_left fl"},[e("div",{directives:[{name:"show",rawName:"v-show",value:t.cityTopReportRemind3.showChart,expression:"cityTopReportRemind3.showChart"}],staticClass:"chart_box",attrs:{id:"chart9"}}),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.cityTopReportRemind3.showChart,expression:"!cityTopReportRemind3.showChart"}],staticClass:"chart_box"},[e("p",{staticClass:"noneData"},[t._v("暂无数据")])])]),e("div",{staticClass:"regions-box regions-content_right fr clearfix"},[e("el-tabs",{on:{"tab-click":function(e){return t.handleClick(t.cityTopReportRemind3)}},model:{value:t.cityTopReportRemind3.activeName,callback:function(e){t.$set(t.cityTopReportRemind3,"activeName",e)},expression:"cityTopReportRemind3.activeName"}},[e("el-tab-pane",{attrs:{label:"异常点",name:"first"}}),e("el-tab-pane",{attrs:{label:"分析",name:"second"}}),e("el-tab-pane",{attrs:{label:"建议",name:"third"}})],1),e("div",{staticClass:"abnormal fl"},[e("div",{staticClass:"abnormal-txt"},[t.cityTopReportRemind3.contentList.length>0?[t._l(t.cityTopReportRemind3.contentList,(function(i,s){return[i.isNo?[i.caseNo.length>60?e("el-tooltip",{key:i.caseNo,attrs:{effect:"dark",placement:"top-start"}},[e("div",{staticStyle:{"max-width":"400px"},attrs:{slot:"content"},slot:"content"},[t._v(t._s(i.caseNo))]),e("div",{staticStyle:{"margin-top":"5px"}},[t._v(t._s(i.caseNo.slice(0,60)+"..."))])]):e("div",{key:i,staticStyle:{"margin-top":"5px"}},[t._v(t._s(i.caseNo))])]:e("p",{key:s,staticStyle:{"margin-top":"5px","line-height":"20px"},domProps:{innerHTML:t._s(i)}})]}))]:e("p",{staticStyle:{"text-align":"center"}},[t._v("暂无数据")])],2)])],1)])]),e("el-tab-pane",{attrs:{label:"长尾效应",name:"third"}},[e("div",{staticClass:"regions_content clearfix"},[e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.chart16Loading,expression:"chart16Loading"}],staticClass:"regions-box regions-content_left fl"},[e("div",{directives:[{name:"show",rawName:"v-show",value:t.chart16Remind.showChart,expression:"chart16Remind.showChart"}],staticClass:"chart_box",attrs:{id:"chart16"}}),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.chart16Remind.showChart,expression:"!chart16Remind.showChart"}],staticClass:"chart_box"},[e("p",{staticClass:"noneData"},[t._v("暂无数据")])])]),e("div",{staticClass:"regions-box regions-content_right fr clearfix"},[e("h3",{staticStyle:{"margin-top":"10px","padding-left":"0"}},[t._v("长尾效应-计算长尾时间")]),e("div",{staticClass:"content-excel fl"},[e("el-row",[e("el-col",{attrs:{span:13}},[t._v("计算长尾时间")]),e("el-col",{attrs:{span:7,offset:2}},[e("el-select",{attrs:{placeholder:"请选择",size:"mini"},model:{value:t.excelDate,callback:function(e){t.excelDate=e},expression:"excelDate"}},t._l(t.excelOptions,(function(t){return e("el-option",{key:t,attrs:{label:t,value:t}})})),1)],1)],1),e("el-row",[e("el-col",{attrs:{span:13}},[t._v("案件量")]),e("el-col",{attrs:{span:7,offset:2}},[t._v(t._s(t.tmpContentExcel[t.excelDate]?t.tmpContentExcel[t.excelDate].caseNum:0))])],1),e("el-row",[e("el-col",{attrs:{span:13}},[t._v("赔付总金额")]),e("el-col",{attrs:{span:7,offset:2}},[t._v(t._s(t.tmpContentExcel[t.excelDate]?t.tmpContentExcel[t.excelDate].totalPayAmount2:0)+" 万")])],1),e("el-row",[e("el-col",{attrs:{span:13}},[t._v("案均赔付金额")]),e("el-col",{attrs:{span:7,offset:2}},[t._v(t._s(t.tmpContentExcel[t.excelDate]?t.tmpContentExcel[t.excelDate].avgPayAmount:0)+" 元")])],1),e("el-row",[e("el-col",{attrs:{span:13}},[t._v("出险时间与首次赔付时间平均值")]),e("el-col",{attrs:{span:7,offset:2}},[t._v(t._s(t.tmpContentExcel[t.excelDate]?t.tmpContentExcel[t.excelDate].accDiffFirstPayTime:0)+" 天")])],1),e("el-row",[e("el-col",{attrs:{span:13}},[t._v("出险时间与末次赔付时间平均值")]),e("el-col",{attrs:{span:7,offset:2}},[t._v(t._s(t.tmpContentExcel[t.excelDate]?t.tmpContentExcel[t.excelDate].accDiffLastPayTime:0)+" 天")])],1),e("el-row",[e("el-col",{attrs:{span:13}},[t._v("首次赔付时间与末次赔付时间平均值")]),e("el-col",{attrs:{span:7,offset:2}},[t._v(t._s(t.tmpContentExcel[t.excelDate]?t.tmpContentExcel[t.excelDate].firstDiffLastPayTime:0)+" 天")])],1)],1)])]),e("div",{staticClass:"regions_content clearfix"},[e("h3",[t._v("大额赔偿案件")]),e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.bigAmountCaseRemind.loading,expression:"bigAmountCaseRemind.loading"}],staticClass:"regions-box regions-content_left fl"},[e("div",{directives:[{name:"show",rawName:"v-show",value:t.bigAmountCaseRemind.showChart,expression:"bigAmountCaseRemind.showChart"}],staticClass:"chart_box",attrs:{id:"chart15"}}),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.bigAmountCaseRemind.showChart,expression:"!bigAmountCaseRemind.showChart"}],staticClass:"chart_box"},[e("p",{staticClass:"noneData"},[t._v("暂无数据")])])]),e("div",{staticClass:"regions-box regions-content_right fr clearfix"},[e("el-tabs",{on:{"tab-click":function(e){return t.handleClick(t.bigAmountCaseRemind)}},model:{value:t.bigAmountCaseRemind.activeName,callback:function(e){t.$set(t.bigAmountCaseRemind,"activeName",e)},expression:"bigAmountCaseRemind.activeName"}},[e("el-tab-pane",{attrs:{label:"异常点",name:"first"}}),e("el-tab-pane",{attrs:{label:"分析",name:"second"}}),e("el-tab-pane",{attrs:{label:"建议",name:"third"}})],1),e("div",{staticClass:"abnormal fl"},[e("div",{staticClass:"abnormal-txt"},[t.bigAmountCaseRemind.contentList.length>0?[t._l(t.bigAmountCaseRemind.contentList,(function(i,s){return[i.isNo?[i.caseNo.length>60?e("el-tooltip",{key:i.caseNo,attrs:{effect:"dark",placement:"top-start"}},[e("div",{staticStyle:{"max-width":"400px"},attrs:{slot:"content"},slot:"content"},[t._v(t._s(i.caseNo))]),e("div",{staticStyle:{"margin-top":"5px"}},[t._v(t._s(i.caseNo.slice(0,60)+"..."))])]):e("div",{key:i,staticStyle:{"margin-top":"5px"}},[t._v(t._s(i.caseNo))])]:e("p",{key:s,staticStyle:{"margin-top":"5px","line-height":"20px"},domProps:{innerHTML:t._s(i)}})]}))]:e("p",{staticStyle:{"text-align":"center"}},[t._v("暂无数据")])],2)])],1)])]),e("el-tab-pane",{attrs:{label:"重点骑手",name:"fourth"}},[e("div",{staticClass:"regions_content clearfix"},[e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.keyRidersRemind.loading,expression:"keyRidersRemind.loading"}],staticClass:"regions-box regions-content_left fl"},[e("el-table",{staticStyle:{width:"100%"},attrs:{data:t.keyRidersData,stripe:""}},[e("el-table-column",{attrs:{type:"index",width:"50"}}),e("el-table-column",{attrs:{prop:"itemName",label:"骑手ID",width:"180"}}),e("el-table-column",{attrs:{prop:"itemValue3",label:"合计赔付金额"}}),e("el-table-column",{attrs:{prop:"itemValue1",label:"报案数"}}),e("el-table-column",{attrs:{prop:"itemValue2",label:"赔付案件数"}})],1)],1),e("div",{staticClass:"regions-box regions-content_right fr clearfix"},[e("el-tabs",{on:{"tab-click":function(e){return t.handleClick(t.keyRidersRemind)}},model:{value:t.keyRidersRemind.activeName,callback:function(e){t.$set(t.keyRidersRemind,"activeName",e)},expression:"keyRidersRemind.activeName"}},[e("el-tab-pane",{attrs:{label:"异常点",name:"first"}}),e("el-tab-pane",{attrs:{label:"分析",name:"second"}}),e("el-tab-pane",{attrs:{label:"建议",name:"third"}})],1),e("div",{staticClass:"abnormal fl"},[e("div",{staticClass:"abnormal-txt"},[t.keyRidersRemind.contentList.length>0?[t._l(t.keyRidersRemind.contentList,(function(i,s){return[i.isNo?[i.caseNo.length>60?e("el-tooltip",{key:i.caseNo,attrs:{effect:"dark",placement:"top-start"}},[e("div",{staticStyle:{"max-width":"400px"},attrs:{slot:"content"},slot:"content"},[t._v(t._s(i.caseNo))]),e("div",{staticStyle:{"margin-top":"5px"}},[t._v(t._s(i.caseNo.slice(0,60)+"..."))])]):e("div",{key:i,staticStyle:{"margin-top":"5px"}},[t._v(t._s(i.caseNo))])]:e("p",{key:s,staticStyle:{"margin-top":"5px","line-height":"20px"},domProps:{innerHTML:t._s(i)}})]}))]:e("p",{staticStyle:{"text-align":"center"}},[t._v("暂无数据")])],2)])],1)])]),e("el-tab-pane",{attrs:{label:"重点包商",name:"fifth"}},[e("div",{staticClass:"regions-box regions-content_left fl"},[e("el-table",{directives:[{name:"loading",rawName:"v-loading",value:t.keyContractorsRemind.loading,expression:"keyContractorsRemind.loading"}],staticStyle:{width:"100%"},attrs:{data:t.keyContractorsData,stripe:""}},[e("el-table-column",{attrs:{type:"index",width:"50"}}),e("el-table-column",{attrs:{prop:"itemName",label:"包商名称",width:"190"}}),e("el-table-column",{attrs:{prop:"itemValue3",label:"合计赔付金额"}}),e("el-table-column",{attrs:{prop:"itemValue1",label:"报案数"}}),e("el-table-column",{attrs:{prop:"itemValue2",label:"赔付案件数"}}),e("el-table-column",{attrs:{prop:"itemValue4",label:"件均赔款"}})],1)],1),e("div",{staticClass:"regions-box regions-content_right fr clearfix"},[e("el-tabs",{on:{"tab-click":function(e){return t.handleClick(t.keyContractorsRemind)}},model:{value:t.keyContractorsRemind.activeName,callback:function(e){t.$set(t.keyContractorsRemind,"activeName",e)},expression:"keyContractorsRemind.activeName"}},[e("el-tab-pane",{attrs:{label:"异常点",name:"first"}}),e("el-tab-pane",{attrs:{label:"分析",name:"second"}}),e("el-tab-pane",{attrs:{label:"建议",name:"third"}})],1),e("div",{staticClass:"abnormal fl"},[e("div",{staticClass:"abnormal-txt",staticStyle:{"max-height":"500px"}},[t.keyContractorsRemind.contentList.length>0?t._l(t.keyContractorsRemind.contentList,(function(i,s){return e("p",{key:s,staticStyle:{"margin-top":"5px","line-height":"20px"},domProps:{innerHTML:t._s(i)}})})):e("p",{staticStyle:{"text-align":"center"}},[t._v("暂无数据")])],2)])],1)])],1)],1)])},a=[],o=(i("0faf"),i("b3ec"),i("6fc2"),i("ada4")),n={data(){return{searchForm:{endCaseCloseTime:"",insuranceType:1,regionName:"河北省",startCaseCloseTime:""},caseTotalData:{},keyRidersData:[],keyContractorsData:[],provinceOption:[],caseTotalRemined:{activeName:"first",contentList:[],errorList:[],abnormal:[],analysis:[],advocate:[],activeTxt:"",showChart:!1,loading:!0},monthlyAnalysisRemined:{activeName:"first",contentList:[],errorList:[],abnormal:[],analysis:[],advocate:[],activeTxt:"",showChart:!1},monthlyCancel:{activeName:"first",contentList:[],errorList:[],abnormal:[],analysis:[],advocate:[],activeTxt:"",showChart:!1},monthlyAnalysisRemind:{activeName:"first",contentList:[],errorList:[],abnormal:[],analysis:[],advocate:[],activeTxt:"",showChart:!1},cityAnalysisRemind:{activeName:"first",contentList:[],errorList:[],abnormal:[],analysis:[],advocate:[],activeTxt:"",showChart:!1},cityAnalysisAvgRemind:{activeName:"first",contentList:[],errorList:[],abnormal:[],analysis:[],advocate:[],activeTxt:"",showChart:!1},cityTopReportRemind1:{activeName:"first",contentList:[],errorList:[],abnormal:[],analysis:[],advocate:[],activeTxt:"",showChart:!1},cityTopReportRemind2:{activeName:"first",contentList:[],errorList:[],abnormal:[],analysis:[],advocate:[],activeTxt:"",showChart:!1},cityTopReportRemind3:{activeName:"first",contentList:[],errorList:[],abnormal:[],analysis:[],advocate:[],activeTxt:"",showChart:!1},bigAmountCaseRemind:{activeName:"first",contentList:[],errorList:[],abnormal:[],analysis:[],advocate:[],activeTxt:"",showChart:!1},keyRidersRemind:{activeName:"first",contentList:[],errorList:[],abnormal:[],analysis:[],advocate:[],activeTxt:"",showChart:!1},keyContractorsRemind:{activeName:"first",contentList:[],errorList:[],abnormal:[],analysis:[],advocate:[],activeTxt:"",showChart:!1},chart16Remind:{activeName:"first",contentList:[],errorList:[],abnormal:[],analysis:[],advocate:[],activeTxt:"",showChart:!1},datePickerVal:"",tabActive:"first",contentExcel:{},tmpContentExcel:{},excelOptions:[],excelDate:"",chart16Loading:!0,pickerOptions:{shortcuts:[{text:"本月",onClick(t){t.$emit("pick",[new Date,new Date])}},{text:"今年至今",onClick(t){const e=new Date,i=new Date((new Date).getFullYear(),0);t.$emit("pick",[i,e])}},{text:"最近六个月",onClick(t){const e=new Date,i=new Date;i.setMonth(i.getMonth()-6),t.$emit("pick",[i,e])}},{text:"最近一年",onClick(t){const e=new Date,i=new Date;i.setMonth(i.getMonth()-12),t.$emit("pick",[i,e])}}]},chart1:null,chart2:null,chart3:null,chart4:null,chart5:null,chart6:null,chart7:null,chart8:null,chart9:null,chart10:null,chart15:null,chart15:null}},mounted(){let t=new Date,e=new Date;e.setMonth(e.getMonth()-12),e=this.getNowFormatDate(e),t=this.getNowFormatDate(t),this.datePickerVal=[e,t],this.getProvince(),this.regionsInterface();let i=this;window.addEventListener("resize",(function(){i.chart1&&i.chart1.resize(),i.chart2&&i.chart2.resize(),i.chart3&&i.chart3.resize(),i.chart4&&i.chart4.resize(),i.chart5&&i.chart5.resize(),i.chart6&&i.chart6.resize(),i.chart7&&i.chart7.resize(),i.chart8&&i.chart8.resize(),i.chart9&&i.chart9.resize(),i.chart16&&i.chart16.resize(),i.chart10&&i.chart10.resize(),i.chart15&&i.chart15.resize()}))},methods:{getProvince(){this.instance.post("/regionalAnalysis/searchProvince",this.searchForm).then(t=>{let e=t.data;1==e.code&&(this.provinceOption=e.data)})},regionsInterface(){if(this.datePickerVal.length>0){this.searchForm.startCaseCloseTime=this.datePickerVal[0];let t=this.datePickerVal[1],e=this.getLastDate(this.datePickerVal[1]),i=t.slice(0,8);this.searchForm.endCaseCloseTime=i+e}this.caseTotalRemined.loading=!0,this.monthlyAnalysisRemined.loading=!0,this.monthlyCancel.loading=!0,this.monthlyAnalysisRemind.loading=!0,this.cityAnalysisRemind.loading=!0,this.cityAnalysisAvgRemind.loading=!0,this.cityTopReportRemind1.loading=!0,this.cityTopReportRemind2.loading=!0,this.cityTopReportRemind3.loading=!0,this.bigAmountCaseRemind.loading=!0,this.keyRidersRemind.loading=!0,this.keyContractorsRemind.loading=!0,this.getCaseTotalCount(),this.caseTotalMonthlyAnalysis(),this.monthlyCancelAnalysis(),this.monthlyAnalysis(),this.cityAnalysis(),this.cityTopReport(),this.cityTopTotal(),this.cityTopAvg(),this.cityAnalysisAvg(),this.longTailCase(),this.bigAmountCase(),this.keyRiders(),this.keyContractors()},getCaseTotalCount(){this.instance.post("/regionalAnalysis/caseTotalCount",this.searchForm).then(t=>{let e=t.data;1==e.code&&(this.caseTotalData=e.data.base,e.data.errorList&&e.data.errorList.length>0?this.caseTotalCountError(e.data.errorList):(this.caseTotalRemined.analysis=[],this.caseTotalRemined.advocate=[]),e.data.itemList.length>0?(this.caseTotalChart(e.data.itemList),this.caseTotalRemined.errorList=e.data.errorList,this.handleContent(this.caseTotalRemined),this.caseTotalRemined.showChart=!0):this.caseTotalRemined.showChart=!1),this.caseTotalRemined.loading=!1})},caseTotalCountError(t){this.searchForm.errorList=t,this.instance.post("/regionalAnalysis/caseTotalCountError",this.searchForm).then(t=>{let e=t.data;1==e.code&&e.data&&(this.caseTotalRemined.analysisVos=e.data.analysisVos,this.handleAnalysisVos(this.caseTotalRemined))})},caseTotalChart(t){let e=["报案量","结案量"],i=[],s=[],a=[];t.forEach(t=>{i.push(t.itemName),s.push(t.itemValue1),a.push(t.itemValue2)});let n={tooltip:{trigger:"axis",axisPointer:{type:"cross",crossStyle:{color:"#999"}}},legend:{data:e},xAxis:[{type:"category",data:i,axisPointer:{type:"shadow"}}],yAxis:[{type:"value",axisLabel:{formatter:"{value}"}}],series:[{name:"报案量",type:"bar",label:{show:!0,position:"top"},tooltip:{valueFormatter:function(t){return t}},data:s},{name:"结案量",type:"bar",label:{show:!0,position:"top"},tooltip:{valueFormatter:function(t){return t}},data:a}]},r=document.getElementById("chart1");r&&(this.chart1=o["init"](r),this.chart1.setOption(n),setTimeout(()=>{this.chart1.resize()},30))},caseTotalMonthlyAnalysis(){this.instance.post("/regionalAnalysis/caseTotalMonthlyAnalysis",this.searchForm).then(t=>{let e=t.data;1==e.code&&(e.data.errorList&&e.data.errorList.length>0?this.caseTotalMonthlyAnalysisError(e.data.errorList):(this.monthlyAnalysisRemined.analysis=[],this.monthlyAnalysisRemined.advocate=[]),e.data.itemList.length>0?(this.monthlyAnalysisChart(e.data.itemList),this.monthlyAnalysisRemined.errorList=e.data.errorList,this.handleContent(this.monthlyAnalysisRemined),this.monthlyAnalysisRemined.showChart=!0):this.monthlyAnalysisRemined.showChart=!1),this.monthlyAnalysisRemined.loading=!1})},caseTotalMonthlyAnalysisError(t){this.searchForm.errorList=t,this.instance.post("/regionalAnalysis/caseTotalMonthlyAnalysisError",this.searchForm).then(t=>{let e=t.data;1==e.code&&e.data&&(this.monthlyAnalysisRemined.analysisVos=e.data.analysisVos,this.handleAnalysisVos(this.monthlyAnalysisRemined))})},monthlyAnalysisChart(t){let e=["案件金额(元)","案均金额(元)"],i=[],s=[],a=[],n=[],r=[];t.forEach(t=>{i.push(t.itemName),s.push(t.itemValue3),a.push(t.itemValue1),n.push(t.itemValue2),r.push(t.itemValue4)});let l={tooltip:{trigger:"axis",axisPointer:{type:"cross",crossStyle:{color:"#999"}}},legend:{data:e},xAxis:[{type:"category",data:i,axisPointer:{type:"shadow"}}],yAxis:[{type:"value",name:"案件金额"},{type:"value",name:"案均金额",splitLine:{show:!1}}],series:[{name:"案件金额(元)",type:"bar",label:{show:!0,position:"top"},tooltip:{valueFormatter:function(t){return t}},data:s},{name:"案均金额(元)",type:"line",yAxisIndex:1,tooltip:{valueFormatter:function(t){return t}},data:r}]},h=document.getElementById("chart2");h&&(this.chart2=o["init"](h),this.chart2.setOption(l),setTimeout(()=>{this.chart2.resize()},30))},monthlyCancelAnalysis(){this.instance.post("/regionalAnalysis/monthlyCancelAnalysis",this.searchForm).then(t=>{let e=t.data;1==e.code&&(e.data.itemList.length>0?(this.monthlyCancelAnalysisChart(e.data.itemList),this.monthlyCancel.errorList=e.data.errorList,this.handleContent(this.monthlyCancel),this.monthlyCancel.showChart=!0):this.monthlyCancel.showChart=!1),this.monthlyCancel.loading=!1})},monthlyCancelAnalysisChart(t){let e=["零结案","注销案件"],i=[],s=[],a=[];t.forEach(t=>{i.push(t.itemName),s.push(t.itemValue1),a.push(t.itemValue2)});let n={tooltip:{trigger:"axis",axisPointer:{type:"cross",crossStyle:{color:"#999"}}},legend:{data:e},xAxis:[{type:"category",data:i,axisPointer:{type:"shadow"}}],yAxis:[{type:"value",axisLabel:{formatter:"{value}"}}],series:[{name:"零结案",type:"bar",label:{show:!0,position:"top"},tooltip:{valueFormatter:function(t){return t}},data:s},{name:"注销案件",type:"bar",label:{show:!0,position:"top"},tooltip:{valueFormatter:function(t){return t}},data:a}]},r=document.getElementById("chart3");r&&(this.chart3=o["init"](r),this.chart3.setOption(n),setTimeout(()=>{this.chart3.resize()},30))},monthlyAnalysis(){this.instance.post("/regionalAnalysis/monthlyAnalysis",this.searchForm).then(t=>{let e=t.data;1==e.code&&(e.data.errorList&&e.data.errorList.length>0?this.monthlyAnalysisError(e.data.errorList):(this.monthlyAnalysisRemind.analysis=[],this.monthlyAnalysisRemind.advocate=[]),e.data.itemList.length>0?(this.monthlyAnalysis5000Chart(e.data.itemList),this.monthlyAnalysisRemind.errorList=e.data.errorList,this.handleContent(this.monthlyAnalysisRemind),this.monthlyAnalysisRemind.showChart=!0):this.monthlyAnalysisRemind.showChart=!1),this.monthlyAnalysisRemind.loading=!1})},monthlyAnalysisError(t){this.searchForm.errorList=t,this.instance.post("/regionalAnalysis/monthlyAnalysisError",this.searchForm).then(t=>{let e=t.data;1==e.code&&e.data&&(this.monthlyAnalysisRemind.analysisVos=e.data.analysisVos,this.handleAnalysisVos(this.monthlyAnalysisRemind))})},monthlyAnalysis5000Chart(t){let e=["低于5000","高于5000"],i=[],s=[],a=[];t.forEach(t=>{i.push(t.itemName),s.push(t.itemValue1),a.push(t.itemValue2)});let n={tooltip:{trigger:"axis"},legend:{data:e},xAxis:[{type:"category",boundaryGap:!1,data:i}],yAxis:[{type:"value",name:"低于5000"},{type:"value",name:"高于5000",splitLine:{show:!1},minInterval:1,min:1,max:()=>a.length>0?Math.max(...a):1}],series:[{name:"低于5000",type:"line",stack:"Total",areaStyle:{},emphasis:{focus:"series"},data:s},{name:"高于5000",type:"line",stack:"Total",areaStyle:{},emphasis:{focus:"series"},data:a}]},r=document.getElementById("chart4");r&&(this.chart4=o["init"](r),this.chart4.setOption(n),setTimeout(()=>{this.chart4.resize()},30))},cityAnalysis(){this.instance.post("/regionalAnalysis/cityAnalysis",this.searchForm).then(t=>{let e=t.data;1==e.code&&(e.data.errorList&&e.data.errorList.length>0?this.cityAnalysisError(e.data.errorList):(this.cityAnalysisRemind.analysis=[],this.cityAnalysisRemind.advocate=[]),e.data.itemList.length>0?(this.cityAnalysisChart(e.data.itemList),this.cityAnalysisRemind.errorList=e.data.errorList,this.handleContent(this.cityAnalysisRemind),this.cityAnalysisRemind.showChart=!0):this.cityAnalysisRemind.showChart=!1),this.cityAnalysisRemind.loading=!1})},cityAnalysisError(t){this.searchForm.errorList=t,this.instance.post("/regionalAnalysis/cityAnalysisError",this.searchForm).then(t=>{let e=t.data;1==e.code&&e.data&&(this.cityAnalysisRemind.analysisVos=e.data.analysisVos,this.handleAnalysisVos(this.cityAnalysisRemind))})},longTailCase(){this.instance.post("/regionalAnalysis/longTailCase",this.searchForm).then(t=>{let e=t.data;1==e.code&&(this.excelOptions=[],e.data.length>0?(this.excelDate=e.data[0].itemName,this.longTailCaseChart(e.data),e.data.forEach(t=>{this.excelOptions.push(t.itemName),this.tmpContentExcel[t.itemName]=t}),this.chart16Remind.showChart=!0):this.chart16Remind.showChart=!1),this.chart16Loading=!1})},cityAnalysisChart(t){let e=["案件量","总赔款量(万元)"],i=[],s=[],a=[];t.sort((t,e)=>t.itemValue1-e.itemValue1),t.forEach(t=>{i.push(t.itemName),s.push(t.itemValue1),a.push((t.itemValue3/1e4).toFixed(2))});let n={tooltip:{trigger:"axis",axisPointer:{type:"shadow"}},legend:{data:e},grid:{left:"3%",right:"4%",bottom:"3%",containLabel:!0},xAxis:{type:"value",boundaryGap:[0,.01]},yAxis:{type:"category",data:i},series:[{name:"案件量",type:"bar",itemStyle:{normal:{label:{show:!0,position:"right"}}},data:s},{type:"bar",name:"总赔款量(万元)",showSymbol:!1,data:a}]},r=document.getElementById("chart5");r&&(this.chart5=o["init"](r),this.chart5.setOption(n),setTimeout(()=>{this.chart5.resize()},30))},longTailCaseChart(t){let e=["案件量","双零案件量"],i=[],s=[],a=[];t.forEach(t=>{i.push(t.itemName),s.push(t.caseNum),a.push(t.zeroCaseNum)});let n={tooltip:{trigger:"axis",axisPointer:{type:"cross",crossStyle:{color:"#999"}}},legend:{data:e},xAxis:[{type:"category",data:i,axisPointer:{type:"shadow"}}],yAxis:[{type:"value",axisLabel:{formatter:"{value}"}}],series:[{name:"案件量",type:"bar",label:{show:!0,position:"top"},tooltip:{valueFormatter:function(t){return t}},data:s},{name:"双零案件量",type:"bar",label:{show:!0,position:"top"},tooltip:{valueFormatter:function(t){return t}},data:a}]},r=document.getElementById("chart16");r&&(this.chart16=o["init"](r),this.chart16.setOption(n),setTimeout(()=>{this.chart16.resize()},30))},cityTopReport(){this.instance.post("/regionalAnalysis/cityTopReport",this.searchForm).then(t=>{let e=t.data;1==e.code&&(e.data.length>0?(this.cityTopReportChart(e.data),this.cityTopReportRemind1.errorList=e.data.errorList,this.handleContent(this.cityTopReportRemind1),this.cityTopReportRemind1.showChart=!0):this.cityTopReportRemind1.showChart=!1),this.cityTopReportRemind1.loading=!1})},cityAnalysisAvg(){this.instance.post("/regionalAnalysis/cityAnalysisAvg",this.searchForm).then(t=>{let e=t.data;1==e.code&&(e.data.errorList&&e.data.errorList.length>0?this.cityAnalysisAvgError(e.data.errorList):(this.cityAnalysisAvgRemind.analysis=[],this.cityAnalysisAvgRemind.advocate=[]),e.data.itemList.length>0?(this.cityAnalysisAvgChart(e.data.itemList,e.data.base),this.cityAnalysisAvgRemind.errorList=e.data.errorList,this.handleContent(this.cityAnalysisAvgRemind),this.cityAnalysisAvgRemind.showChart=!0):this.cityAnalysisAvgRemind.showChart=!1),this.cityAnalysisAvgRemind.loading=!1})},cityAnalysisAvgError(t){this.searchForm.errorList=t,this.instance.post("/regionalAnalysis/cityAnalysisAvgError",this.searchForm).then(t=>{let e=t.data;1==e.code&&e.data&&(this.cityAnalysisAvgRemind.analysisVos=e.data.analysisVos,this.handleAnalysisVos(this.cityAnalysisAvgRemind))})},cityAnalysisAvgChart(t,e){let i=["案均赔款(元)",{name:"全省均线",lineStyle:{type:"dotted",width:3,color:"#67C23A"}},{name:"全国均线",lineStyle:{type:"dotted",width:3,color:"red"}}],s=[],a=[],n=[],r=[],l=e.itemValue4,h=e.otherValue;t.sort((t,e)=>t.itemValue4-e.itemValue4),t.forEach((t,e)=>{s.push(t.itemName),a.push(t.itemValue4),n.push(0),r.push(0)});let d={tooltip:{trigger:"axis",axisPointer:{type:"shadow"}},color:["rgb(84,112,198)","#67C23A","red"],legend:{data:i},grid:{left:"3%",right:"4%",bottom:"3%",containLabel:!0},xAxis:{type:"value",boundaryGap:[0,.01]},yAxis:{type:"category",data:s},series:[{name:"案均赔款(元)",type:"bar",itemStyle:{normal:{label:{show:!0,position:"right"}}},markLine:{symbol:"none",data:[{type:"average",name:"全省均线",xAxis:l,lineStyle:{normal:{color:"#67C23A"}},label:{textStyle:{color:"#fff"}}},{type:"average",name:"全国均线",xAxis:h,lineStyle:{normal:{color:"red"}},label:{textStyle:{color:"#fff"}}}]},data:a},{type:"line",name:"全省均线",showSymbol:!1,data:[]},{type:"line",name:"全国均线",showSymbol:!1,data:[]}]},c=document.getElementById("chart6");c&&(this.chart6=o["init"](c),this.chart6.setOption(d),setTimeout(()=>{this.chart6.resize()},30))},cityTopReportChart(t){let e=[],i=[],s={data1:[],data2:[],data3:[]};t.forEach((t,a)=>{e.push(t.cityName),t.itemList&&t.itemList.length>0&&(i=[],t.itemList.forEach(t=>{i.push(t.itemName),s["data"+(a+1)].push(t.itemValue1)}))});let a={tooltip:{trigger:"axis"},legend:{data:e},grid:{left:"3%",right:"4%",bottom:"3%",containLabel:!0},xAxis:{type:"category",boundaryGap:!1,data:i},yAxis:{type:"value"},series:[{name:e[0],type:"line",stack:"Total",data:s.data1},{name:e[1],type:"line",stack:"Total",data:s.data2},{name:e[2],type:"line",stack:"Total",data:s.data3}]},n=document.getElementById("chart7");n&&(this.chart7=o["init"](n),this.chart7.setOption(a),setTimeout(()=>{this.chart7.resize()},30))},cityTopTotal(){this.instance.post("/regionalAnalysis/cityTopTotal",this.searchForm).then(t=>{let e=t.data;1==e.code&&(e.data.length>0?(this.cityTopTotalChart(e.data),this.cityTopReportRemind2.errorList=e.data.errorList,this.handleContent(this.cityTopReportRemind2),this.cityTopReportRemind2.showChart=!0):this.cityTopReportRemind2.showChart=!1),this.cityTopReportRemind2.loading=!1})},cityTopTotalChart(t){let e=[],i=[],s={data1:[],data2:[],data3:[]};t.forEach((t,a)=>{e.push(t.cityName),t.itemList&&t.itemList.length>0&&(i=[],t.itemList.forEach(t=>{i.push(t.itemName),s["data"+(a+1)].push(t.itemValue1)}))});let a={tooltip:{trigger:"axis"},legend:{data:e},grid:{left:"3%",right:"4%",bottom:"3%",containLabel:!0},xAxis:{type:"category",boundaryGap:!1,data:i},yAxis:{type:"value"},series:[{name:e[0],type:"line",stack:"Total",data:s.data1},{name:e[1],type:"line",stack:"Total",data:s.data2},{name:e[2],type:"line",stack:"Total",data:s.data3}]},n=document.getElementById("chart8");n&&(this.chart8=o["init"](n),this.chart8.setOption(a),setTimeout(()=>{this.chart8.resize()},30))},cityTopAvg(){this.instance.post("/regionalAnalysis/cityTopAvg",this.searchForm).then(t=>{let e=t.data;1==e.code&&(e.data.length>0?(this.cityTopAvgChart(e.data),this.cityTopReportRemind3.errorList=e.data.errorList,this.handleContent(this.cityTopReportRemind3),this.cityTopReportRemind3.showChart=!0):this.cityTopReportRemind3.showChart=!1),this.cityTopReportRemind3.loading=!1})},cityTopAvgChart(t){let e=[],i=[],s={data1:[],data2:[],data3:[]};t.forEach((t,a)=>{e.push(t.cityName),t.itemList&&t.itemList.length>0&&(i=[],t.itemList.forEach(t=>{i.push(t.itemName),s["data"+(a+1)].push(t.itemValue1)}))});let a={tooltip:{trigger:"axis"},legend:{data:e},grid:{left:"3%",right:"4%",bottom:"3%",containLabel:!0},xAxis:{type:"category",boundaryGap:!1,data:i},yAxis:{type:"value"},series:[{name:e[0],type:"line",stack:"Total",data:s.data1},{name:e[1],type:"line",stack:"Total",data:s.data2},{name:e[2],type:"line",stack:"Total",data:s.data3}]},n=document.getElementById("chart9");n&&(this.chart9=o["init"](n),this.chart9.setOption(a),setTimeout(()=>{this.chart9.resize()},30))},totalCityAnalysis(){},bigAmountCase(){this.instance.post("/regionalAnalysis/bigAmountCase",this.searchForm).then(t=>{let e=t.data;1==e.code&&(e.data.itemList.length>0?(this.bigAmountCaseChart(e.data.itemList),this.bigAmountCaseRemind.errorList=e.data.errorList,this.handleContent(this.bigAmountCaseRemind),this.bigAmountCaseRemind.showChart=!0):this.bigAmountCaseRemind.showChart=!1),this.bigAmountCaseRemind.loading=!1})},bigAmountCaseChart(t){let e=["案件量(起)","案件金额(元)"],i=[],s=[],a=[];t.forEach(t=>{i.push(t.itemName),s.push(t.itemValue1),a.push(t.itemValue3)});let n={tooltip:{trigger:"axis",axisPointer:{type:"cross",crossStyle:{color:"#999"}}},legend:{data:e},xAxis:[{type:"category",data:i,axisPointer:{type:"shadow"}}],yAxis:[{type:"value",name:"案件量(起)",min:0,max:250,interval:50},{type:"value",name:"案件金额(元)",splitLine:{show:!1},min:0,max:()=>a.length>0?Math.max(...a):1}],series:[{name:"案件量(起)",type:"bar",data:s},{name:"案件金额(元)",type:"line",label:{show:!0,position:"top"},yAxisIndex:1,data:a}]},r=document.getElementById("chart15");r&&(this.chart15=o["init"](r),this.chart15.setOption(n),setTimeout(()=>{this.chart15.resize()},30))},keyRiders(){this.instance.post("/regionalAnalysis/keyRiders",this.searchForm).then(t=>{let e=t.data;1==e.code&&(this.keyRidersData=e.data.itemList,this.keyRidersRemind.errorList=e.data.errorList,this.handleContent(this.keyRidersRemind)),this.keyRidersRemind.loading=!1})},keyContractors(){this.instance.post("/regionalAnalysis/keyContractors",this.searchForm).then(t=>{let e=t.data;1==e.code&&(this.keyContractorsData=e.data.itemList,this.keyContractorsRemind.errorList=e.data.errorList,this.handleContent(this.keyContractorsRemind)),this.keyContractorsRemind.loading=!1})},handleContent(t){t&&t.errorList&&t.errorList.length>0&&(t.abnormal=[],t.errorList.forEach(e=>{e.errorMsg&&t.abnormal.push(e.errorMsg.replace(/\n|\r\n/g,"
").replace(/ /g,"  ")),e.errorList&&e.errorList.length>0&&e.errorList.forEach(e=>{t.abnormal.push(e)})}),this.handleClick(t))},handleAnalysisVos(t){t&&t.analysisVos&&t.analysisVos.length>0&&(t.analysis=[],t.advocate=[],t.analysisVos.forEach(e=>{e.isShow&&e.infoList.forEach(i=>{t.analysis.push(e.itemName+" "+i.msg.replace(/\n|\r\n/g,"
").replace(/ /g,"  ")),t.advocate.push(e.itemName+" "+i.recommend.replace(/\n|\r\n/g,"
").replace(/ /g,"  ")),i.listInfo.length>0&&(t.analysis.push("案件号:"),i.listInfo.forEach((e,s)=>{t.analysis.push({caseNo:e,isNo:!0}),s==i.listInfo.length-1&&t.analysis.push('
')}))})}))},handleClick(t){switch(t.activeName){case"second":t.contentList=t.analysis;break;case"third":t.contentList=t.advocate;break;default:t.contentList=t.abnormal;break}},tabsClick(){switch(this.tabActive){case"first":setTimeout(()=>{this.chart1&&this.chart1.resize(),this.chart2&&this.chart2.resize(),this.chart3&&this.chart3.resize(),this.chart4&&this.chart4.resize()},20);break;case"second":setTimeout(()=>{this.chart5&&this.chart5.resize(),this.chart6&&this.chart6.resize(),this.chart7&&this.chart7.resize(),this.chart8&&this.chart8.resize(),this.chart9&&this.chart9.resize()},20);break;case"third":setTimeout(()=>{this.chart16&&this.chart16.resize(),this.chart10&&this.chart10.resize(),this.chart15&&this.chart15.resize()},20);break;case"fourth":break;default:break}},getNowFormatDate(t){t=t;var e="-",i=t.getFullYear(),s=t.getMonth()+1,a=t.getDate();s>=1&&s<=9&&(s="0"+s),a>=0&&a<=9&&(a="0"+a);var o=i+e+s+e+a;return o},getLastDate(t){let e=new Date(t),i=new Date(e.getFullYear(),e.getMonth()+1,0);return i.getDate()}}},r=n,l=(i("f9a0"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"03a847a0",null);e["default"]=h.exports},"7b82":function(t,e,i){},"7c3f":function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],class:"1"==t.echartsType?"module_wrap box_border":"module_wrap module_wrap2 box_border",attrs:{"element-loading-text":"数据加载中","element-loading-spinner":"el-icon-loading","element-loading-background":"transparent"}},[e("div",{staticClass:"box_title box_title_radio"},[e("span",[t._v("分包商风险案件"+t._s("1"==t.echartsType?"":"占比")+"排行榜")]),1==t.echartsType?e("div",{staticClass:"radio_group"},[e("el-radio-group",{attrs:{size:"mini"},on:{change:t.radioChange},model:{value:t.radio,callback:function(e){t.radio=e},expression:"radio"}},[e("el-radio-button",{attrs:{label:"数量"}}),e("el-radio-button",{attrs:{label:"金额"}})],1)],1):t._e()]),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.loading,expression:"!loading"}],staticStyle:{height:"100%"}},[1==t.echartsType?e("div",{attrs:{id:"risk_case_bar"}}):e("div",{attrs:{id:"risk_case_bar2"}})])])},a=[],o=(i("0faf"),i("b3ec"),i("6fc2"),i("ada4")),n={name:"RiskCase",props:{isCollapse:{type:Boolean,default:!0},navForm:{type:Object,default:{}},echartsType:{type:String,default:""}},watch:{isCollapse(){setTimeout(()=>{this.myChart&&this.myChart.resize()},600)},navForm:{deep:!0,handler(t){this.getData()}}},data(){return{loading:!0,topDays:[],radio:"数量",newNumber:0,xAxisData1:[],xAxisData2:[],sumSeriesData1:[],sumSeriesData2:[],numSeriesData1:[],numSeriesData2:[],option:"",myChart:null}},mounted(){this.role=localStorage.getItem("role"),window.addEventListener("resize",()=>{this.myChart&&this.myChart.resize()}),window.onresize=()=>{this.myChart.resize()}},methods:{getData(){if(this.echartsType){this.loading=!0;let t=null;switch(this.echartsType){case"1":t="/large/data/screen/getSubcontractorCasesNumTopTen";break;case"2":t="/large/data/screen/getSubcontractorCasesRatioTopTen";break;default:break}t&&this.instance({method:"post",url:t,data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(this.loading=!1,1==t.data.code){let e=t.data.data;"1"==this.echartsType?this.loadCharts(e):this.loadCharts2(e)}})}},radioChange(){this.option&&(this.option.series[0].name="案件数量",this.option.series[1].name="赔款金额","数量"==this.radio?(this.option.xAxis[0].data=this.xAxisData1,this.option.series[0].data=this.numSeriesData1,this.option.series[1].data=this.numSeriesData2):(this.option.xAxis[0].data=this.xAxisData2,this.option.series[0].data=this.sumSeriesData1,this.option.series[1].data=this.sumSeriesData2),setTimeout(()=>{this.myChart.setOption(this.option)},100))},loadCharts(t){var e=document.getElementById("risk_case_bar");e&&(this.myChart&&this.myChart.dispose(),this.myChart=o["init"](e,null,{renderer:"svg"}),this.xAxisData1=[],this.sumSeriesData1=[],this.sumSeriesData2=[],this.xAxisData2=[],this.numSeriesData1=[],this.numSeriesData2=[],t&&t.caseRiskNum.forEach((t,e)=>{this.xAxisData1.push(t.name),this.numSeriesData1.push(t.caseNum),this.numSeriesData2.push((t.totalPayAmount/1e4).toFixed(2))}),t&&t.caseRiskMoney&&t.caseRiskMoney.length>0&&t.caseRiskMoney.forEach((t,e)=>{this.xAxisData2.push(t.name),this.sumSeriesData1.push(t.caseNum),this.sumSeriesData2.push((t.totalPayAmount/1e4).toFixed(2))}),this.option={color:1==this.echartsType?["#F9AB8E","#B4FF86"]:["#96b4d8","#09d5d6"],tooltip:{trigger:"axis",confine:!0,textStyle:{align:"left"}},grid:{top:"5",left:"10",right:"10",bottom:"15",containLabel:!0},legend:{data:["案件数量","赔款金额"],itemWidth:12,itemHeight:12,textStyle:{color:"#fff"},left:"center"},xAxis:[{type:"category",data:this.xAxisData1,axisPointer:{type:"shadow"},axisLabel:{showMaxLabel:!0,rotate:50,textStyle:{color:"#fff"},width:60,overflow:"truncate",ellipsis:"..."},axisTick:{alignWithLabel:!0}}],yAxis:[{type:"value",axisLabel:{showMaxLabel:!0,formatter:"{value} 件",textStyle:{color:"#fff"}},splitLine:{show:!1},axisTick:{show:!1}},{type:"value",axisLabel:{showMaxLabel:!0,formatter:"{value} 万",textStyle:{color:"#fff"}},splitLine:{show:!1},axisTick:{show:!1}}],series:[{name:"案件数量",type:"bar",tooltip:{valueFormatter:function(t){return t+" 件"}},data:this.numSeriesData1},{name:"赔款金额",type:"line",yAxisIndex:1,tooltip:{valueFormatter:function(t){return t+" 万元"}},smooth:!0,showSymbol:!1,data:this.numSeriesData2}]},this.myChart.setOption(this.option))},loadCharts2(t){var e=document.getElementById("risk_case_bar2");e&&(this.myChart=o["init"](e,null,{renderer:"svg"}),this.xAxisData1=[],this.sumSeriesData1=[],this.numSeriesData1=[],t&&t.caseRiskNum.forEach((t,e)=>{this.xAxisData1.push(t.name),this.numSeriesData1.push(t.caseNumRatio)}),this.option={color:["#96b4d8","#09d5d6"],tooltip:{trigger:"axis",confine:!0,textStyle:{align:"left"}},grid:{top:30,left:"10",right:"10",bottom:"15",containLabel:!0},legend:{data:[""],itemWidth:12,itemHeight:12,textStyle:{color:"#fff"},left:"center"},xAxis:[{type:"category",data:this.xAxisData1,axisPointer:{type:"shadow"},axisLabel:{showMaxLabel:!0,rotate:50,textStyle:{color:"#fff"},width:60,overflow:"truncate",ellipsis:"..."},axisTick:{alignWithLabel:!0}}],yAxis:[{type:"value",axisLabel:{showMaxLabel:!0,formatter:"{value} %",textStyle:{color:"#fff"}},splitLine:{show:!1},axisTick:{show:!1}}],series:[{name:"案件数量占比",type:"bar",tooltip:{valueFormatter:function(t){return t+" %"}},data:this.numSeriesData1}]},this.myChart.setOption(this.option))}},updated(){this.myChart&&this.myChart.resize()}},r=n,l=(i("0586"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"84a5fad0",null);e["default"]=h.exports},"7ef8":function(t,e,i){"use strict";var s=i("1e2f"),a=i("2248"),o=i("f56d"),n=function(t){return a.slice(0,t.length)===t};t.exports=function(){return n("Bun/")?"BUN":n("Cloudflare-Workers")?"CLOUDFLARE":n("Deno/")?"DENO":n("Node.js/")?"NODE":s.Bun&&"string"==typeof Bun.version?"BUN":s.Deno&&"object"==typeof Deno.version?"DENO":"process"===o(s.process)?"NODE":s.window&&s.document?"BROWSER":"REST"}()},"83fa":function(t,e,i){"use strict";i("efff")},"848b":function(t,e,i){"use strict";i("3717")},8524:function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA4AAAAOCAYAAAAfSC3RAAAAAXNSR0IArs4c6QAAAR9JREFUOE+lkjFLA0EQhb/ZO7yIRC0UPFv9AWLtH7CwUYi9RTrboIKNgnK1vYKVBCzESv+ApWnstLJQOKsEhIvcjmzCyeVyCahbDTvzZt68eULuLZx05o03savIBshSP6Uvgt7atHv2flCNs3LJgvA02VKRcxGm882yWJW2qO687QfX7q8HdCCMaYKarHC2Ar6Bj898G7FYW3NgcfQwwXNx0lXNY6YC65fpAAE3GZssy2KUHClyWKS3GkLgCw+vOsRc0GMJo+4jsJLPTvrQ3PZ4ipW9e1u2ckvC6KsNWi1mG2uGuSmhcTdItV8nnT8CccBhqq7n+Im0RoozDtgTp+wcTpyLTY/Ag/pNSpy75c85RhmgTErIGeBflsvAvzH5Nw2riopUTh/+AAAAAElFTkSuQmCC"},"865a":function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA4AAAAPCAYAAADUFP50AAAAAXNSR0IArs4c6QAAACxJREFUOE9jZCATMJKpj2FEaBTv/mVOTgAxSnb++k9fjWQ7lRxngvSMhAQAANArCOzCTubyAAAAAElFTkSuQmCC"},"865f":function(t,e,i){},"8b91":function(t,e,i){},"8baa":function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAAAXNSR0IArs4c6QAAAvJJREFUaEPtmb9rFFEQx79vr8teMIXYGUErC7WIEAsFLSW2+icod/f2SsHK2Ai22bk7vD/BlGqTJgEFEbRItBY8yxRGvA2CZEfe3g82d7t7+2MObsEHxzXvzZvPm9l5M/MUSj5UyfXHf4CRBY9qtYuVSmXDUuoymFcBrDJg/s0p9WB+SvXA/FX5/uuldvuHhPULWcBrNtfg+/cA3AWwnkUhBez5zDuqUtmxt7Y+Z1kbnpsLYKj4QwDmJzG6sKxuHpDMAJ7WLwUVn4Tv2kSPspxIJgBP61cA7mfZIPNcpd7brnsr7brUAP1GY18pdTWt4ILzejbRhTQyUgF4WnMaYdJzbKKZ+s2c4Gn93YREaeXSyGPmg2qrdS1pbiKA5zjvwHwzzWYxc7YB/Cz40W/bRA/idIgFkIg2IxcQcMHY6BQJMIzznwqcfLBUEACwrOtR90Q0gFCsFwUAIq0wBSB1+uIWMAIjrDAF0G80niilnhd1n3kA+MCzZaLNxFzoWOtdBm4vIgCAjzbRjViA43r9PFuWSX1FhvA3EOj09+Tk0kqn822k4CkX8rSuA2iJaC8dhYZK+UBzmciNBnCcNphriwwApTq265qDDsakBd4A2FhoAOCtTWSKqEiAAwBXFhzgi000zopPWaCv9ZECziwyAAO/qkQrkRYoPYCntagL+cCd4AIFdqWsCiDehTytRT9iQaXDohI+YuEwOheAGWFU9CKbB0DiRSadSswDIDGVMBsKJnNd9v0PlmV5PGjFSLRjkpM5AyCUTk/Vsb+13rSAp0WskiqdLlrQMHBYJToXpajnOIdgPpsbIk1BY4QXKehN03aJKIj/k6Oge6YrKQOAQdc5V1E/NwtkKeqLWgGAaxM1wxY41voFA49zuk+2tspok0KNLWbT89+HUn/AvA6l1nIqn6+xNYYoc2sxBFHe5u4IotTt9ZAlyvvAEYIo7xPTGGJwT5TzkS8cCkv7zBoVz0v50J3zYhJdNvONTHS3OQgrPcA/0mSHQN9TImUAAAAASUVORK5CYII="},"8e5e":function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],staticClass:"module_wrap box_border",attrs:{"element-loading-text":"数据加载中","element-loading-spinner":"el-icon-loading","element-loading-background":"transparent"}},[e("div",{staticClass:"box_title"},[t._v("7天报案结案量统计")]),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.loading,expression:"!loading"}],staticStyle:{height:"100%"}},[e("div",{attrs:{id:"processing_time_bar1"}})])])},a=[],o=(i("0faf"),i("b3ec"),i("6fc2"),i("ada4")),n={name:"ProcessingTime",props:{isCollapse:{type:Boolean,default:!0},navForm:{type:Object,default:{}}},watch:{isCollapse(){setTimeout(()=>{this.myChart&&this.myChart.resize()},1e3)},navForm:{deep:!0,handler(t){this.getData()}}},data(){return{topDays:[],newNumber:0,myChart:"",loading:!0}},mounted(){this.role=localStorage.getItem("role"),window.addEventListener("resize",()=>{this.myChart&&setTimeout(()=>{this.myChart.resize()},500)})},methods:{getData(){this.loading=!0,this.instance({method:"post",url:"/large/data/screen/getLast7DayCaseNum",data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(this.loading=!1,1==t.data.code){let e=t.data.data;e.length>0&&this.loadCharts(e)}})},loadCharts(t){var e=document.getElementById("processing_time_bar1");if(!e)return;this.myChart&&this.myChart.dispose(),this.myChart=o["init"](e,null,{renderer:"svg"});let i=[],s=[],a=[];t.forEach((t,e)=>{i.push(t.name),s.push(t.caseNum),a.push(t.totalCaseNum)});var n={color:["#1BC0C4","#E461A2"],tooltip:{trigger:"axis",confine:!0,textStyle:{align:"left"}},grid:{left:"20px",right:"5px",top:"30px",bottom:"0%",containLabel:!0},xAxis:[{type:"category",data:i,axisPointer:{type:"shadow"},axisLabel:{showMaxLabel:!0,rotate:30,textStyle:{color:"#fff"}},axisTick:{alignWithLabel:!0}}],yAxis:[{type:"value",axisLabel:{showMaxLabel:!0,formatter:"{value}",textStyle:{color:"#fff"}},splitLine:{show:!1},axisTick:{show:!1}}],legend:{textStyle:{color:"#fff"}},color:["#1BC0C4","#E461A2"],series:[{name:"报案量",type:"bar",tooltip:{valueFormatter:function(t){return t+"件"}},data:s},{name:"结案量",type:"bar",tooltip:{valueFormatter:function(t){return t+"件"}},data:a}]};this.myChart.setOption(n)}},updated(){this.myChart&&this.myChart.resize()}},r=n,l=(i("9e0a"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"4e66ad92",null);e["default"]=h.exports},"8f38":function(t,e,i){"use strict";i("aaa1")},9033:function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{staticClass:"iframe-box"},[e("div",{staticClass:"zhegai"}),t.iframeSrc.length>=0?e("iframe",{style:"height:"+t.resizeHeight,attrs:{id:"iframe1",src:t.iframeSrc,frameborder:"0"}}):t._e()])},a=[],o={data(){return{testNum:0,iframeSrc:"",resizeHeight:"653"}},mounted(){this.getDashboard(),this.resizeHeight=window.innerHeight-10+"px",window.onresize=()=>{this.resizeHeight=window.innerHeight-10+"px"}},methods:{testIframe(){this.testNum++,this.testNum>5&&(this.iframeSrc="http://jiaanantest.platform.sigreal.cn/staging/workManage?t=123",setTimeout(()=>{const t=document.getElementById("iframe1"),e=t.contentWindow,i=e.document,s=i.getElementById("pageTitle");s.innerHTML="Hello World!",s.style.color="red"},5e3))},getDashboard(){this.instance.get("/metabase/getDashboard/6",{params:{}}).then(t=>{let e=t.data;1==e.code&&(this.iframeSrc=e.data)})}}},n=o,r=(i("5de3"),i("1805")),l=Object(r["a"])(n,s,a,!1,null,null,null);e["default"]=l.exports},9142:function(t,e,i){},"96b4":function(t,e,i){"use strict";var s,a=new Uint8Array(16);function o(){if(!s&&(s="undefined"!==typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!==typeof msCrypto&&"function"===typeof msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto),!s))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return s(a)}var n=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;function r(t){return"string"===typeof t&&n.test(t)}for(var l=r,h=[],d=0;d<256;++d)h.push((d+256).toString(16).substr(1));function c(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=(h[t[e+0]]+h[t[e+1]]+h[t[e+2]]+h[t[e+3]]+"-"+h[t[e+4]]+h[t[e+5]]+"-"+h[t[e+6]]+h[t[e+7]]+"-"+h[t[e+8]]+h[t[e+9]]+"-"+h[t[e+10]]+h[t[e+11]]+h[t[e+12]]+h[t[e+13]]+h[t[e+14]]+h[t[e+15]]).toLowerCase();if(!l(i))throw TypeError("Stringified UUID is invalid");return i}var u=c;function p(t,e,i){t=t||{};var s=t.random||(t.rng||o)();if(s[6]=15&s[6]|64,s[8]=63&s[8]|128,e){i=i||0;for(var a=0;a<16;++a)e[i+a]=s[a];return e}return u(s)}e["a"]=p},"96e5":function(t,e,i){"use strict";i("5a52")},"999c":function(t,e,i){},"9a65":function(t,e,i){"use strict";i("d4e4")},"9ac4":function(t,e,i){"use strict";i("bc27")},"9b9e":function(t,e,i){"use strict";i("3311")},"9cd9":function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],staticClass:"module_wrap box_border",attrs:{"element-loading-text":"数据加载中","element-loading-spinner":"el-icon-loading","element-loading-background":"transparent"}},[e("div",{staticClass:"box_title box_title_radio"},[e("span",[t._v("风险案件数量&金额统计")]),e("div",{staticClass:"radio_group"},[e("el-radio-group",{attrs:{size:"mini"},on:{change:t.radioChange},model:{value:t.radio,callback:function(e){t.radio=e},expression:"radio"}},[e("el-radio-button",{attrs:{label:"数量"}}),e("el-radio-button",{attrs:{label:"金额"}})],1)],1)]),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.loading,expression:"!loading"}],staticStyle:{height:"100%"}},[e("div",{attrs:{id:"risk_number_amount_pie"}})])])},a=[],o=(i("0faf"),i("b3ec"),i("6fc2"),i("ada4")),n={name:"RiskNumberAmount",props:{isCollapse:{type:Boolean,default:!0},navForm:{type:Object,default:{}}},watch:{isCollapse(){setTimeout(()=>{this.myChart&&this.myChart.resize()},600)},navForm:{deep:!0,handler(t){this.province=t.accidentProvince,this.getData()}}},data(){return{radio:"数量",topDays:[],newNumber:0,seriesDataNum:[],seriesDataSum:[],yAxisDataNum:[],yAxisDataSum:[],maxDataNum:[],maxDataSum:[],myChart:"",option:"",loading:!0}},mounted(){this.role=localStorage.getItem("role"),this.getData(),window.addEventListener("resize",()=>{this.myChart&&setTimeout(()=>{this.myChart.resize()},500)})},methods:{getData(){this.loading=!0,this.instance({method:"post",url:"/large/data/screen/caseRiskNumVo",data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(this.loading=!1,1==t.data.code){this.radio="数量";let e=t.data.data;this.loadCharts(e)}})},radioChange(){"数量"==this.radio?(this.option.series.forEach((t,e)=>{t.data=this.seriesDataNum,t.symbolBoundingData=this.maxDataNum}),this.option.yAxis.data=this.yAxisDataNum,this.option.xAxis.max=this.maxDataNum,this.option.tooltip.formatter="{b}: {c}件"):(this.option.series.forEach((t,e)=>{t.data=this.seriesDataSum,t.symbolBoundingData=this.maxDataSum}),this.option.yAxis.data=this.yAxisDataSum,this.option.xAxis.max=this.maxDataSum,this.option.tooltip.formatter="{b}: {c}元"),setTimeout(()=>{this.myChart.setOption(this.option)},100)},loadCharts(t){var e=document.getElementById("risk_number_amount_pie");if(e){this.myChart&&this.myChart.dispose(),this.myChart=o["init"](e,null,{renderer:"svg"}),this.seriesDataNum=[],this.seriesDataSum=[],this.yAxisDataNum=[],this.yAxisDataSum=[],t.caseRiskNum.forEach((t,e)=>{this.seriesDataNum.push(t.caseNum),this.yAxisDataNum.push(t.name)}),t.caseRiskMoney.forEach((t,e)=>{this.seriesDataSum.push(t.caseNumRatio),this.yAxisDataSum.push(t.name)}),this.maxDataNum=t.caseRiskNum[0].caseNum,this.maxDataSum=t.caseRiskMoney[0].caseNumRatio;this.option={tooltip:{formatter:"{b}: {c}件"},xAxis:{max:this.maxDataNum,splitLine:{show:!1},offset:10,axisTick:{show:!1},axisLine:{show:!1},axisLabel:{show:!1}},yAxis:{data:this.yAxisDataNum,inverse:!0,axisTick:{show:!1},axisLine:{show:!1},axisLabel:{margin:10,textStyle:{color:"#fff"}}},grid:{top:20,left:"5",right:"90",bottom:"20",containLabel:!0},series:[{name:"",type:"pictorialBar",symbol:"reat",symbolOffset:["-1%",0],symbolSize:["102%",16],itemStyle:{normal:{color:"#184D48"}},z:-180,symbolRepeat:null,symbolBoundingData:this.maxDataNum,data:this.seriesDataNum},{name:"",type:"pictorialBar",symbol:"reat",symbolOffset:["-0.5%",0],symbolSize:["101%",14],itemStyle:{normal:{color:"black"}},z:-20,symbolRepeat:null,symbolBoundingData:this.maxDataNum,data:this.seriesDataNum},{type:"pictorialBar",symbol:"rect",itemStyle:{normal:{barBorderRadius:5,color:"#37DACC"}},symbolRepeat:"fixed",symbolMargin:"5%",symbolClip:!0,symbolSize:12,symbolBoundingData:this.maxDataNum,data:this.seriesDataNum,z:99999999},{type:"pictorialBar",itemStyle:{normal:{color:"#184D48"}},label:{show:!0,position:"right",offset:[6,0],textStyle:{color:"darkorange"}},symbolRepeat:"fixed",symbolMargin:"5%",symbol:"rect",symbolSize:12,symbolBoundingData:this.maxDataNum,data:this.seriesDataNum,z:99999}]},this.myChart.setOption(this.option)}}},updated(){this.myChart&&this.myChart.resize()}},r=n,l=(i("6ddb"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"27ea5ffb",null);e["default"]=h.exports},"9e0a":function(t,e,i){"use strict";i("f7e8")},"9f02":function(t,e,i){"use strict";i("a314")},a06b:function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],staticClass:"module_wrap box_border",attrs:{"element-loading-text":"数据加载中","element-loading-spinner":"el-icon-loading","element-loading-background":"transparent"}},[e("div",{staticClass:"box_title"},[t._v("案件风险等级近七日变换趋势")]),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.loading,expression:"!loading"}],staticStyle:{height:"55%"}},[e("div",{attrs:{id:"risk_grade_bar"}})])])},a=[],o=(i("0faf"),i("b3ec"),i("6fc2"),i("ada4")),n={name:"RiskGrade",props:{isCollapse:{type:Boolean,default:!0},navForm:{type:Object,default:{}}},watch:{isCollapse(){setTimeout(()=>{this.myChart&&this.myChart.resize()},600)},navForm:{deep:!0,handler(t){this.province=t.accidentProvince,this.getData()}}},data(){return{topDays:[],newNumber:0,myChart:"",loading:!0}},mounted(){this.role=localStorage.getItem("role"),this.getData(),window.addEventListener("resize",()=>{this.myChart&&setTimeout(()=>{this.myChart.resize()},500)})},methods:{getData(){this.loading=!0,this.instance({method:"post",url:"/large/data/screen/caseLevelDayNumVo",data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(this.loading=!1,1==t.data.code){let e=t.data.data;e.length>0&&this.loadCharts(e)}})},loadCharts(t){var e=document.getElementById("risk_grade_bar");if(!e)return;this.myChart&&this.myChart.dispose(),this.myChart=o["init"](e,null,{renderer:"svg"});let i=[],s=[],a=[];t.forEach((t,e)=>{i.push(t.dayTime),s.push(t.caseNum),a.push(t.caseReduceNum)});var n={color:["#E8A5B1","#F95C8B"],tooltip:{trigger:"axis",axisPointer:{type:"cross",crossStyle:{color:"#999"}},textStyle:{align:"left"}},grid:{top:"20",left:"10",right:"10",bottom:"5",containLabel:!0},legend:{data:["风险案件数","报案总量"],itemWidth:12,itemHeight:12,itemGap:20,textStyle:{color:"#fff"},left:"center"},xAxis:[{type:"category",data:i,axisPointer:{type:"shadow"},axisLabel:{showMaxLabel:!0,textStyle:{color:"#fff"}},axisTick:{alignWithLabel:!0}}],yAxis:[{type:"value",axisLabel:{showMaxLabel:!0,formatter:"{value} 件",textStyle:{color:"#fff"}},splitLine:{show:!1},axisTick:{show:!1}},{type:"value",axisLabel:{showMaxLabel:!0,formatter:"{value} 件",textStyle:{color:"#fff"}},splitLine:{show:!1},axisTick:{show:!1}}],series:[{name:"报案总量",type:"bar",tooltip:{valueFormatter:function(t){return t+" 件"}},data:s},{name:"风险案件数",type:"line",yAxisIndex:1,tooltip:{valueFormatter:function(t){return t+" 件"}},smooth:!0,showSymbol:!1,areaStyle:{color:new o["graphic"].LinearGradient(0,0,0,1,[{offset:0,color:"#1faf8c"},{offset:1,color:"#165d59"}])},data:a}]};this.myChart.setOption(n)}},updated(){this.myChart&&this.myChart.resize()}},r=n,l=(i("1b89"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"a0504888",null);e["default"]=h.exports},a0a2:function(t,e,i){},a314:function(t,e,i){},a533:function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{staticClass:"wrap"},[t._m(0),e("div",{staticClass:"search_box public_box"},[e("el-form",{staticClass:"demo-form-inline",attrs:{inline:!0,model:t.navForm}},[e("div",{staticClass:"flex"},[e("div",[e("el-form-item",{staticStyle:{"margin-right":"0.8rem"}},[e("el-upload",{staticClass:"upload_box",attrs:{accept:".xls,.xlsx",action:t.baseURL+"/case/importCaseExcel","show-file-list":!0,headers:t.unloaderHeader,limit:1,"on-remove":t.handleRemove,"on-success":t.handleAvatarSuccess,"before-upload":t.beforeAvatarUpload}},[[e("el-button",{attrs:{type:"primary"}},[e("i",{staticClass:"el-icon-upload el-icon--left"}),t._v("上传案件")])]],2)],1),e("el-form-item",[e("span",{staticClass:"hint_text"},[t._v("(若无批量案件上传,可按条件查询)")])]),e("br"),e("el-form-item",{attrs:{label:"事故省:"}},[e("el-select",{staticClass:"width_150",attrs:{placeholder:"请选择"},model:{value:t.navForm.accidentProvince,callback:function(e){t.$set(t.navForm,"accidentProvince",e)},expression:"navForm.accidentProvince"}},t._l(t.provinceOptions,(function(t){return e("el-option",{key:t,attrs:{label:t,value:t}})})),1)],1),e("el-form-item",{attrs:{label:"公估公司:"}},[e("el-input",{staticClass:"width_150",attrs:{placeholder:"请填写公估公司",clearable:""},model:{value:t.navForm.lossAdjusterCompany,callback:function(e){t.$set(t.navForm,"lossAdjusterCompany",e)},expression:"navForm.lossAdjusterCompany"}})],1),e("el-form-item",{attrs:{label:"被保险人:"}},[e("el-input",{staticClass:"width_150",attrs:{placeholder:"请填写分包商",clearable:""},model:{value:t.navForm.nameOfInsured,callback:function(e){t.$set(t.navForm,"nameOfInsured",e)},expression:"navForm.nameOfInsured"}})],1),e("el-form-item",{staticClass:"dateBox",attrs:{label:"报案时间:"}},[e("el-row",{staticStyle:{width:"370px"}},[e("el-col",{attrs:{span:11}},[e("el-date-picker",{staticStyle:{width:"100%"},attrs:{placeholder:"请选择日期",clearable:"",type:"date","value-format":"yyyy-MM-dd"},model:{value:t.navForm.reportStartTime,callback:function(e){t.$set(t.navForm,"reportStartTime",e)},expression:"navForm.reportStartTime"}})],1),e("el-col",{staticClass:"line",staticStyle:{"text-align":"center"},attrs:{span:2}},[t._v("至")]),e("el-col",{attrs:{span:11}},[e("el-date-picker",{staticStyle:{width:"100%"},attrs:{placeholder:"请选择日期",clearable:"",type:"date","value-format":"yyyy-MM-dd"},model:{value:t.navForm.reportEndTime,callback:function(e){t.$set(t.navForm,"reportEndTime",e)},expression:"navForm.reportEndTime"}})],1)],1)],1),e("el-form-item",{staticClass:"dateBox",attrs:{label:"结案时间:"}},[e("el-row",{staticStyle:{width:"370px"}},[e("el-col",{attrs:{span:11}},[e("el-date-picker",{staticStyle:{width:"100%"},attrs:{placeholder:"请选择日期",clearable:"",type:"date","value-format":"yyyy-MM-dd"},model:{value:t.navForm.startTime,callback:function(e){t.$set(t.navForm,"startTime",e)},expression:"navForm.startTime"}})],1),e("el-col",{staticClass:"line",staticStyle:{"text-align":"center"},attrs:{span:2}},[t._v("至")]),e("el-col",{attrs:{span:11}},[e("el-date-picker",{staticStyle:{width:"100%"},attrs:{placeholder:"请选择日期",clearable:"",type:"date","value-format":"yyyy-MM-dd"},model:{value:t.navForm.endTime,callback:function(e){t.$set(t.navForm,"endTime",e)},expression:"navForm.endTime"}})],1)],1)],1),e("el-form-item",[e("el-button",{attrs:{type:"primary"},on:{click:t.searchTable}},[t._v("风险查询")])],1)],1)])])],1),e("div",{staticClass:"main"},[e("div",{staticClass:"table_box public_box"},[e("div",{staticClass:"table_title"},[e("b",[t._v("案件详情")]),t.tableData.length>0?e("el-button",{staticClass:"download",attrs:{type:"text"},on:{click:t.handleDownload}},[e("i",{staticClass:"el-icon-download el-icon--left"}),t._v("下载表单")]):t._e()],1),e("el-table",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],ref:"multipleTable",staticStyle:{width:"100%"},attrs:{data:t.tableData,"empty-text":t.caseExcelData.length>0||t.navForm.endTime?"暂无案件":"暂无案件,请上传案件清单或选择查询日期"}},[e("el-table-column",{attrs:{prop:"meituanCaseNo",label:"美团案件号"}}),e("el-table-column",{attrs:{prop:"accidentTime",label:"出险时间"}}),e("el-table-column",{attrs:{prop:"reportTime",label:"报案时间"}}),e("el-table-column",{attrs:{prop:"insureTypeName",label:"保险险种"}}),e("el-table-column",{attrs:{prop:"currentStatusDesc",label:"案件状态"}}),e("el-table-column",{attrs:{prop:"caseClosedTime",label:"结案时间"}}),e("el-table-column",{attrs:{prop:"totalPayAmount",label:"结案金额"}}),e("el-table-column",{attrs:{prop:"valueAtRisk",label:"风险值"}}),e("el-table-column",{attrs:{label:"操作"},scopedSlots:t._u([{key:"default",fn:function(i){return[e("span",{staticClass:"a_color",on:{click:function(e){return t.lookDetails(i.row)}}},[t._v("查看详情")])]}}])})],1),e("el-pagination",{staticStyle:{"margin-top":"0.2rem"},attrs:{"current-page":t.currentPage,layout:"total, sizes, prev, pager, next, jumper","page-sizes":[10,20],"page-size":10,total:t.totalPage},on:{"current-change":t.handleCurrentChange,"size-change":t.handleSizeChange}})],1)]),e("el-dialog",{attrs:{visible:t.dialogVisible,"modal-append-to-body":!1,width:"65%"},on:{"update:visible":function(e){t.dialogVisible=e}}},[e("div",{staticClass:"dialog_box"},[e("div",{staticClass:"dialog_header"},[e("div",[t._v("案件号:"+t._s(t.checkedRowDetail.caseNo))]),e("div",[t._v("是否快赔:"+t._s(t.checkedRowDetail.quickPayOrNot))])]),e("div",{staticClass:"dialog_main"},[e("div",{staticClass:"dialog_row"},[e("div",{staticClass:"dialog_col"},[e("div",{staticClass:"detail_title"},[t._v("涉事方信息:")]),e("ul",[e("li",[t._v("出险人姓名:"+t._s(t.checkedRowDetail.nameOfDeliveryMan))]),e("li",[t._v("三者姓名:"+t._s(t.checkedRowDetail.nameOfThirdParty))]),e("li",[t._v("被保险人:"+t._s(t.checkedRowDetail.nameOfInsured))]),e("li",[t._v("投保人:"+t._s(t.checkedRowDetail.insuranceApplicant))])])]),e("div",{staticClass:"dialog_col"},[e("div",{staticClass:"detail_title"},[t._v("审核信息:")]),e("ul",[e("li",[t._v("公估公司:"+t._s(t.checkedRowDetail.lossAdjusterCompany))]),e("li",[t._v("初审人:"+t._s(t.checkedRowDetail.firstCheckMan))]),e("li",[t._v("复审人:"+t._s(t.checkedRowDetail.reviewer))])])])]),e("div",{staticClass:"dialog_row"},[e("div",{staticClass:"dialog_col"},[e("div",{staticClass:"detail_title"},[t._v("事故省市:")]),e("ul",[e("li",[t._v(t._s(t.checkedRowDetail.accidentProvincesAndCities))])])])]),e("div",{staticClass:"dialog_row"},[e("div",{staticClass:"dialog_col",staticStyle:{width:"100%"}},[e("div",{staticClass:"detail_title"},[t._v("赔付信息:")]),e("ul",[e("li",[t._v("总赔款金额:"+t._s(t.checkedRowDetail.totalPayAmount)+"元")])]),e("div",{staticClass:"adjustment_detail"},[e("div",[t._v("理算明细:")]),e("ul",[e("li",[e("span",[t._v("车损:"+t._s(t.checkedRowDetail.vehicleDamage)+" 元")]),e("span",[t._v("门诊医疗费:"+t._s(t.checkedRowDetail.outPatientMedicalExpenses)+" 元")])]),e("li",[e("span",[t._v("伤残赔偿金:"+t._s(t.checkedRowDetail.disabilityCompensation)+" 元")]),e("span",[t._v("骑手住院津贴:"+t._s(t.checkedRowDetail.hospitalizationAllowanceForDeliveryMan)+" 元")])]),e("li",[e("span",[t._v("误工费:"+t._s(t.checkedRowDetail.lostWages)+" 元")]),e("span",[t._v("其他补助:"+t._s(t.checkedRowDetail.otherAllowance)+" 元")])]),e("li",[e("span",[t._v("物损金额:"+t._s(t.checkedRowDetail.itemDamage)+" 元")])])])])])])])])])],1)},a=[function(){var t=this,e=t._self._c;return e("div",{staticClass:"page_title"},[e("b",[t._v("案件风险值查询")]),e("span",[t._v("(案件列表显示满足筛选规则的案件)")])])}],o=(i("e4c6"),i("320b"),i("08a9"),i("5966"),i("b75d"),i("5f87")),n={name:"caseRisk",components:{},data(){return{caseExcelData:[],dialogVisible:!1,baseURL:"",unloaderHeader:{token:""},fullscreenLoading:!1,uploadFile:{},fileName:"",activeName:"first",loading:!1,nowFilter:"",provinceOptions:["辽宁省","江苏省","广西壮族自治区","福建省","四川省","黑龙江省","山东省","江西省","陕西省","吉林省","北京市","安徽省","河北省","河南省","重庆市","天津市","湖北省","甘肃省","上海市","云南省","贵州省","内蒙古自治区","山西省","海南省","浙江省","宁夏回族自治区","青海省","广东省","新疆维吾尔自治区","湖南省","西藏自治区","香港特别行政区","澳门特别行政区","台湾省"],navForm:{startTime:"",endTime:"",value:"",nameOfInsured:"",meituanCaseInfoList:[]},checkedRowDetail:{},riskOptions:[],customFilterOptionList:[],currentPage:1,pageSize:10,totalPage:0,tableData:[]}},methods:{handleRemove(t,e){this.caseExcelData=[]},getCommonFilterOptionList(){this.instance.post("/case/getCommonFilterOptionList",{}).then(t=>{1==t.data.code&&(this.riskOptions=t.data.data)})},lookDetails(t){this.checkedRowDetail=t,this.dialogVisible=!0},handleAvatarSuccess(t,e){this.fullscreenLoading.close(),this.fileName=e.name,this.uploadFile=t.data,1==t.code?(this.$message.success(t.message),this.caseExcelData=t.data):this.$message.error(t.message)},beforeAvatarUpload(t){if(t.size/1024>5e3)return this.$message.error("抱歉,上传文件不得大于5M!"),!1;this.unloaderHeader.token=Object(o["c"])(),this.fullscreenLoading=this.$loading({lock:!0,text:"上传中,请稍后",spinner:"el-icon-loading",background:"rgba(0, 0, 0, 0.7)"})},handleSelectionChange(t){this.multipleSelection=t},searchTable(){this.caseExcelData.length>0||this.navForm.startTime&&this.navForm.endTime?(this.currentPage=1,this.getTbodyData()):this.$message.error("请上传文件或者选择结案时间之后再查询!")},getTbodyData:function(){this.loading=!0,this.tableData=[];var t=JSON.parse(JSON.stringify(this.navForm));t.meituanCaseInfoList=this.caseExcelData,this.nowFilter=JSON.parse(JSON.stringify(t)),t.pageNum=this.currentPage,t.pageSize=this.pageSize,this.instance.post("/case/getCaseList",t).then(t=>{this.loading=!1,1==t.data.code?(this.tableData=t.data.data.list,this.totalPage=parseInt(t.data.data.total)):this.totalPage=0})},handleSizeChange(t){this.pageSize=t,this.getTbodyData()},handleCurrentChange:function(t){this.currentPage=Number(t),this.getTbodyData()},handleDownload(){var t=JSON.parse(JSON.stringify(this.nowFilter));this.fullscreenLoading=this.$loading({lock:!0,text:"下载中,请稍后",spinner:"el-icon-loading",background:"rgba(0, 0, 0, 0.7)"}),this.instance({method:"post",url:"/case/exportCaseExcel",data:t,responseType:"blob",headers:{}}).then(t=>{this.fullscreenLoading.close();let e=window.URL.createObjectURL(new Blob([t.data])),i=document.createElement("a");i.style.display="none",i.href=e,i.setAttribute("download","案件下载清单.csv"),document.body.appendChild(i),i.click()}).catch((function(t){console.log(t)}))}},mounted(){this.getCommonFilterOptionList(),this.baseURL=this.$store.getters.baseURL}},r=n,l=(i("c614"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"196fd0b0",null);e["default"]=h.exports},a625:function(t,e,i){},a7c4:function(t,e,i){"use strict";i("d786")},a889:function(t,e,i){},a9c0:function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAAAXNSR0IArs4c6QAAA7lJREFUaEPtWb1PU1EU/50+lI3o4GI0KasMaiShfYRX+A90cRAHSKAlJiZCHNQFXNTBgImJaSuJDOrgov8BtITXNsGIQ11tonFx0LDx8XrMfQWF99V7y3s1TbjrO/ec8zsf99z7e4QOX9Th/uMYwP/OYGgZmCgPnOva6koxoR/gOAhxMOI2QEINjBpANWKs73bvFhYTle9hgD8SgExx6AJjd4IQ0wEeUHOIKoy6SehazBmrX9T2/pNuCcDt8kDP1pY2Q4RpAD2tGt/bt8mMhe5ua/55orKpqksZwFRRH2PCXTD6VI0FyhOqxHiaNcwlFb1KADJF/RWAMRUDLcgu5QxzXHafNIBMUf8K7DWlrPbW5Wo5w+yV2S4FIF1MrhPoiozCsGQY/DFvlPqb6WsKIF1I3iOix80URfGdme/nU6UnQboDAaQLyRtE9CYK52R1MvNoPlV66yfvC0Aclds7mhn6aSPr+b4coXryhKX7HbG+ANIFfY4Is6r2opBnxsN8ypzz0u0JQExYwCqFMKTCwrMJaEmvie0DYHAB4DthWQ9HDz3LGWti8h9a3gBW9U9gXArHsLcWIvyoA3lieJaGaxdhIzdkXm4KYGo5EWctJoZWdItQBWvXRUnslWtVxhhZ9d7sSLl2UNaVAfuuA4grQzTrgPPCwNRyYpi12LKMMQLGnXclF4BMMcL6dzhvR5+sd/JHtbsPPADo7wFclYmIksyRnbetfcgZ5rXAEsooNrA4o2MxTDLjrC+gcJwXLztXI3tl4BeAU3LR1fr+NqJfKYTlfMOh3znDPB2cgaIuDYCs+kh2pLwiFHrWc7jOSwJQKaEgB8N3XrqE1JrY19HGOe+bHbkadUpJNHErx6gHiAicF/yM6zrhHmSFwVEmfq0cIAeIkCNvu0NMN7OptUPvExcAQVBp29o3ZQC2BccVQWlINbdonbTOOwkxv9toWZ2oajjAwE8wXoBwi4Azzd2SlaBKzlhLOKU9AaSLyXkCua6usqaikGPwQt4ozUgB6PgHjUCZXtVnpe/qUYT8gE7lJ6XY2/GPegEi8reBROa83gCBdyGnzjbxoX5QmvKkTZm5xkBqKy+6D0aKH5UCYDd1G/lRWV60MTsVVjt4Uhk+VKkHnPhsvjRGD+TfsZIRIlS5zo+CeFAvTUoZ2Fdg/2La0aaJISZjZ/1iOhiFxsSuT4J4WJkII2yAaQWIvWz7Tz6vVApCDFpsmEEXA3+zgj/Dqq84CSrJQnOJtVRCrRqLYt8xgCiiqqKz4zPwB2J/00Al3MY6AAAAAElFTkSuQmCC"},a9e9:function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],staticClass:"module_wrap box_border",attrs:{"element-loading-text":"数据加载中","element-loading-spinner":"el-icon-loading","element-loading-background":"transparent"}},[e("div",{staticClass:"box_title"},[t._v("公估案件处理结案排行榜")]),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.loading,expression:"!loading"}],staticStyle:{height:"100%"}},[e("div",{attrs:{id:"processing_time_bar"}})])])},a=[],o=(i("0faf"),i("b3ec"),i("6fc2"),i("ada4")),n={name:"ProcessingTime",props:{isCollapse:{type:Boolean,default:!0},navForm:{type:Object,default:{}}},watch:{isCollapse(){setTimeout(()=>{this.myChart&&this.myChart.resize()},1e3)},navForm:{deep:!0,handler(t){this.getData()}}},data(){return{topDays:[],newNumber:0,myChart:"",loading:!0}},mounted(){this.role=localStorage.getItem("role"),window.addEventListener("resize",()=>{this.myChart&&setTimeout(()=>{this.myChart.resize()},500)})},methods:{getData(){this.loading=!0,this.instance({method:"post",url:"/large/data/screen/getRiskTimeLossEstimation",data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(this.loading=!1,1==t.data.code){let e=t.data.data;e.length>0&&this.loadCharts(e)}})},loadCharts(t){var e=document.getElementById("processing_time_bar");if(!e)return;this.myChart&&this.myChart.dispose(),this.myChart=o["init"](e,null,{renderer:"svg"});let i=[],s=[],a=[];t.forEach((t,e)=>{i.push(t.name),s.push(t.caseNumRatio),a.push(t.amountOfFirstCaseFiled)});var n={color:["#BEE758","#F58FA2"],tooltip:{trigger:"axis",confine:!0,textStyle:{align:"left"}},grid:{left:"2%",right:"4%",top:"5%",bottom:"0%",containLabel:!0},xAxis:[{type:"category",data:i,axisPointer:{type:"shadow"},axisLabel:{showMaxLabel:!0,rotate:30,textStyle:{color:"#fff"}},axisTick:{alignWithLabel:!0}}],yAxis:[{type:"value",axisLabel:{showMaxLabel:!0,formatter:"{value} 天",textStyle:{color:"#fff"}},splitLine:{show:!1},axisTick:{show:!1}}],series:[{type:"bar",tooltip:{valueFormatter:function(t){return t+" 天"}},data:s},{type:"line",tooltip:{valueFormatter:function(t){return t+" 天"}},data:a}]};this.myChart.setOption(n)}},updated(){this.myChart&&this.myChart.resize()}},r=n,l=(i("394e"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"74a5096e",null);e["default"]=h.exports},aaa1:function(t,e,i){},ad18:function(t,e,i){"use strict";i("865f")},b140:function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],class:"1"==t.echartsType?"module_wrap box_border":"module_wrap module_wrap2 box_border",attrs:{"element-loading-text":"数据加载中","element-loading-spinner":"el-icon-loading","element-loading-background":"transparent"}},[e("div",{staticClass:"box_title"},[t._v("公估风险案件"+t._s("1"==t.echartsType?"":"占比")+"统计")]),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.loading,expression:"!loading"}],staticStyle:{height:"100%"}},["1"==t.echartsType?e("div",{attrs:{id:"case_number_ratio_pie"}}):e("div",{attrs:{id:"case_number_ratio_pie2"}})])])},a=[],o=(i("0faf"),i("b3ec"),i("6fc2"),i("ada4")),n={name:"CaseNumberRatio",props:{isCollapse:{type:Boolean,default:!0},navForm:{type:Object,default:{}},echartsType:{type:String,default:""}},watch:{isCollapse(){setTimeout(()=>{this.myChart&&this.myChart.resize()},600)},navForm:{deep:!0,handler(t){this.getData()}}},data(){return{topDays:[],newNumber:0,myChart:"",loading:!0}},mounted(){this.role=localStorage.getItem("role"),window.addEventListener("resize",()=>{this.myChart&&setTimeout(()=>{this.myChart.resize()},500)})},methods:{getData(){this.loading=!0,this.instance({method:"post",url:"/large/data/screen/getRiskLossEstimation",data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(this.loading=!1,1==t.data.code){let e=t.data.data;"1"==this.echartsType?this.loadCharts(e):this.loadCharts2(e)}})},loadCharts(t){this.$nextTick(()=>{var e=document.getElementById("case_number_ratio_pie");if(!e||0===e.clientWidth||0===e.clientHeight)return void console.warn("DOM元素未渲染或尺寸为0");this.myChart&&this.myChart.dispose(),this.myChart=o["init"](e,null,{renderer:"svg"});let i=[],s=[];if(t.caseRiskMoney){t.caseRiskMoney.forEach((t,e)=>{i.push(t.name),s.push(t.caseNum)});var a={tooltip:{trigger:"axis",axisPointer:{type:"none"}},xAxis:{data:i,axisTick:{show:!1},axisLabel:{color:"#fff",rotate:50}},yAxis:{splitLine:{show:!1},axisTick:{show:!1},axisLine:{show:!1},axisLabel:{show:!0,color:"#fff",formatter:"{value}"}},grid:{top:"10",bottom:"10",left:"20",right:"10",containLabel:!0},color:["#9AE193"],series:[{name:"案件数量",type:"pictorialBar",barCategoryGap:"-40%",symbol:"path://M0,10 L10,10 C5.5,10 5.5,5 5,0 C4.5,5 4.5,10 0,10 z",label:{position:"top",color:"#fff",formatter:"{c} 件"},barWidth:"80%",emphasis:{itemStyle:{opacity:1}},tooltip:{valueFormatter:function(t){return t}},data:s,z:10}]};this.myChart.setOption(a)}})},loadCharts2(t){this.$nextTick(()=>{var e=document.getElementById("case_number_ratio_pie2");if(!e||0===e.clientWidth||0===e.clientHeight)return void console.warn("DOM元素未渲染或尺寸为0");this.myChart&&this.myChart.dispose(),this.myChart=o["init"](e,null,{renderer:"svg"});let i=[],s=[];if(t.caseRiskNum){t.caseRiskNum.forEach((t,e)=>{i.push(t.name),s.push(t.caseNumRatio)});var a={tooltip:{trigger:"axis",axisPointer:{type:"none"}},xAxis:{data:i,axisTick:{show:!1},axisLabel:{color:"#fff",rotate:50}},yAxis:{splitLine:{show:!1},axisTick:{show:!1},axisLine:{show:!1},axisLabel:{show:!0,color:"#fff",formatter:"{value} %"}},grid:{top:"10",bottom:"10",left:"20",right:"10",containLabel:!0},color:["#87E5BC"],series:[{name:"风险案件占比",type:"pictorialBar",barCategoryGap:"-40%",symbol:"path://M0,10 L10,10 C5.5,10 5.5,5 5,0 C4.5,5 4.5,10 0,10 z",label:{position:"top",color:"#fff",formatter:"{c}%"},tooltip:{valueFormatter:function(t){return t+" %"}},barWidth:"80%",emphasis:{itemStyle:{opacity:1}},data:s,z:10}]};this.myChart.setOption(a)}})},updated(){this.myChart&&this.myChart.resize()}}},r=n,l=(i("df37"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"48a988d1",null);e["default"]=h.exports},b147:function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{staticClass:"wrap bigScreen"},[e("el-carousel",{attrs:{"indicator-position":"none",interval:5e3,"initial-index":0,arrow:"always",autoplay:!1},on:{change:t.carouselChange}},[e("el-carousel-item",{directives:[{name:"loading",rawName:"v-loading",value:t.showloading2,expression:"showloading2"}],attrs:{"element-loading-text":"加载中","element-loading-spinner":"el-icon-loading","element-loading-background":"rgba(0, 0, 0, 0.1)"}},[e("div",{staticClass:"wrap_carousel2"},[e("div",{staticClass:"wrap_carousel_top"},[e("div",{class:{update_time1:1,left_search:"https://jiaanan.platform.sigreal.cn"!=t.pageStr}},[e("el-select",{staticClass:"time_select",attrs:{placeholder:"请选择"},on:{change:function(e){return t.timeSelectChange(2)}},model:{value:t.navForm2.type,callback:function(e){t.$set(t.navForm2,"type",e)},expression:"navForm2.type"}},t._l(t.options,(function(t){return e("el-option",{key:t.value,attrs:{label:t.label,value:t.value}})})),1),e("el-date-picker",{attrs:{type:"daterange","start-placeholder":"开始日期","end-placeholder":"结束日期","range-separator":"至","value-format":"yyyy-MM-dd",size:"mini","default-time":["00:00:00","23:59:59"]},on:{change:t.reportTime2Change},model:{value:t.reportTime2,callback:function(e){t.reportTime2=e},expression:"reportTime2"}}),"https://jiaanan.platform.sigreal.cn"!=t.pageStr?e("el-select",{staticClass:"type_select",attrs:{placeholder:"请选择保险种类",multiple:"",clearable:""},model:{value:t.navForm2.productList,callback:function(e){t.$set(t.navForm2,"productList",e)},expression:"navForm2.productList"}},t._l(t.productDictOptions,(function(t,i){return e("el-option",{key:i,attrs:{label:t,value:t}})})),1):t._e()],1),e("div",{staticClass:"home_title"},[t._v("业务质量监控")]),e("div",{staticClass:"update_time1",staticStyle:{visibility:"hidden"}},[e("p",[t._v("事故省:")]),e("el-select",{staticStyle:{width:"100px"},on:{change:t.provinceChange},model:{value:t.provinceValue,callback:function(e){t.provinceValue=e},expression:"provinceValue"}},t._l(t.provinceOption,(function(t){return e("el-option",{key:t.provinceName,attrs:{label:t.provinceName,value:t.provinceName}})})),1)],1),e("el-button",{staticClass:"download_btn",attrs:{type:"primary",loading:t.downloadFlag2},on:{click:function(e){return t.downloadData(2)}}},[t._v("下 载")])],1),t.delayLoading2?e("div",{staticClass:"wrap_parent"},[e("div",{staticClass:"wrap_carousel_top"},[e("reparations-amount",{attrs:{navForm:t.navForm2}}),e("reparations-amount-type",{attrs:{isCollapse:t.isCollapse,navForm:t.navForm2}}),e("all-reparations-amount",{attrs:{isCollapse:t.isCollapse,navForm:t.navForm2}})],1),"https://jiaanan.platform.sigreal.cn"!=t.pageStr?e("div",{staticClass:"tableBox tables_box"},[e("el-table",{staticStyle:{width:"100%"},attrs:{data:t.tableData,height:"230",border:""}},[e("el-table-column",{attrs:{prop:"insureName",label:"险种"}}),e("el-table-column",{attrs:{prop:"statisticsDayCloseAmount",label:"昨日赔款"}}),e("el-table-column",{attrs:{prop:"statisticsMonthCloseAmount",label:"当月赔款"}}),e("el-table-column",{attrs:{prop:"statisticsYearCloseAmount",label:"当年赔款"}}),e("el-table-column",{attrs:{prop:"statisticsDayUnsettledCloseAmount",label:"昨日未决"}}),e("el-table-column",{attrs:{prop:"preDayUnsettledCloseAmount",label:"前天未决"}}),e("el-table-column",{attrs:{prop:"preMonthUnsettledCloseAmount",label:"上月末未决"}}),e("el-table-column",{attrs:{prop:"preYearUnsettledCloseAmount",label:"上年末未决"}}),e("el-table-column",{attrs:{prop:"statisticsDayLossAmount",label:"昨日损失"}}),e("el-table-column",{attrs:{prop:"monthLossAmount",label:"当月损失"}}),e("el-table-column",{attrs:{prop:"yearLossAmount",label:"当年损失"}})],1)],1):t._e(),e("div",{staticClass:"wrap_carousel_bottom"},[e("delay-report",{attrs:{isCollapse:t.isCollapse,navForm:t.navForm2}}),e("passing-rate",{attrs:{isCollapse:t.isCollapse,navForm:t.navForm2}})],1),e("div",{staticClass:"wrap_carousel_bottom"},[e("assessment-deviation",{attrs:{isCollapse:t.isCollapse,navForm:t.navForm2}}),e("case-num-sum",{attrs:{isCollapse:t.isCollapse,navForm:t.navForm2}})],1)]):t._e()])]),e("el-carousel-item",[e("div",{staticClass:"wrap_carousel1"},[e("div",{staticClass:"wrap_carousel_top"},[e("div",{staticClass:"update_time1"},[e("el-select",{staticClass:"time_select",attrs:{placeholder:"请选择"},on:{change:function(e){return t.timeSelectChange(1)}},model:{value:t.navForm1.type,callback:function(e){t.$set(t.navForm1,"type",e)},expression:"navForm1.type"}},t._l(t.options,(function(t){return e("el-option",{key:t.value,attrs:{label:t.label,value:t.value}})})),1),e("el-date-picker",{attrs:{type:"daterange","start-placeholder":"开始日期","end-placeholder":"结束日期","range-separator":"至","value-format":"yyyy-MM-dd",size:"mini","default-time":["00:00:00","23:59:59"]},on:{change:t.reportTime1Change},model:{value:t.reportTime1,callback:function(e){t.reportTime1=e},expression:"reportTime1"}})],1),e("div",{staticClass:"home_title"},[t._v("作业质量监控")]),e("div",{staticClass:"home_title",staticStyle:{visibility:"hidden"}},[t._v("业务质量监控")]),e("el-button",{staticClass:"download_btn",attrs:{type:"primary",loading:t.downloadFlag1},on:{click:function(e){return t.downloadData(1)}}},[t._v("下 载")])],1),e("div",{staticClass:"wrap_parent wrap_content"},[e("div",{staticClass:"wrap_left"},[e("risk-case",{attrs:{isCollapse:t.isCollapse,navForm:t.navForm1,echartsType:"1"}}),e("risk-case",{attrs:{isCollapse:t.isCollapse,navForm:t.navForm1,echartsType:"2"}}),e("risk-case-tag",{attrs:{isCollapse:t.isCollapse,navForm:t.navForm1,echartsType:"2"}}),e("report-time",{attrs:{isCollapse:t.isCollapse,navForm:t.navForm1}})],1),e("div",{staticClass:"wrap_center"},[e("div",{directives:[{name:"show",rawName:"v-show",value:0,expression:"0"}],staticClass:"sum_num"},[e("span",[t._v("总风险案件数:"),e("countTo",{attrs:{startVal:t.riskCaseReduceAmount.riskCaseNum,endVal:t.riskCaseReduceAmount.riskCaseNum1,duration:1500}}),t._v("件")],1),e("span",[t._v("总减损金额:"),e("countTo",{attrs:{startVal:t.riskCaseReduceAmount.reduceAmountNum,endVal:t.riskCaseReduceAmount.reduceAmountNum1,duration:1500}}),t._v("万元")],1)]),e("province-risk",{attrs:{isCollapse:t.isCollapse,navForm:t.navForm1,echartsType:"1"}}),e("province-risk",{attrs:{isCollapse:t.isCollapse,navForm:t.navForm1,echartsType:"2"}}),e("province-risk-tag",{attrs:{isCollapse:t.isCollapse,navForm:t.navForm1,echartsType:"2"}}),e("depletion-sum",{attrs:{isCollapse:t.isCollapse,navForm:t.navForm1}})],1),e("div",{staticClass:"wrap_right wrap_right3"},[t._e(),e("case-number-ratio",{attrs:{isCollapse:t.isCollapse,navForm:t.navForm1,echartsType:"1"}}),e("case-number-ratio",{attrs:{isCollapse:t.isCollapse,navForm:t.navForm1,echartsType:"2"}}),e("processing-time",{attrs:{isCollapse:t.isCollapse,navForm:t.navForm1}}),e("case-7days-count",{attrs:{isCollapse:t.isCollapse,navForm:t.navForm1}})],1)])])]),e("el-carousel-item",{directives:[{name:"loading",rawName:"v-loading",value:t.showloading3,expression:"showloading3"}],staticClass:"carousel3",attrs:{"element-loading-text":"加载中","element-loading-spinner":"el-icon-loading","element-loading-background":"rgba(0, 0, 0, 0.1)"}},[e("div",{staticClass:"wrap_carousel_top"},[e("div",{staticClass:"update_time1"},[e("el-select",{staticClass:"time_select",attrs:{placeholder:"请选择"},on:{change:function(e){return t.timeSelectChange(3)}},model:{value:t.navForm3.type,callback:function(e){t.$set(t.navForm3,"type",e)},expression:"navForm3.type"}},t._l(t.options,(function(t){return e("el-option",{key:t.value,attrs:{label:t.label,value:t.value}})})),1),e("el-date-picker",{attrs:{type:"daterange","start-placeholder":"开始日期","end-placeholder":"结束日期","range-separator":"至","value-format":"yyyy-MM-dd",size:"mini","default-time":["00:00:00","23:59:59"]},on:{change:t.reportTime3Change},model:{value:t.reportTime3,callback:function(e){t.reportTime3=e},expression:"reportTime3"}})],1),e("div",{staticClass:"home_title"},[t._v("综合分析")]),e("div",{staticClass:"update_time2",staticStyle:{visibility:"hidden"}},[e("p",[t._v("事故省:")]),e("el-select",{staticStyle:{width:"100px"},on:{change:t.provinceChange},model:{value:t.provinceValue,callback:function(e){t.provinceValue=e},expression:"provinceValue"}},t._l(t.provinceOption,(function(t){return e("el-option",{key:t.provinceName,attrs:{label:t.provinceName,value:t.provinceName}})})),1)],1),e("el-button",{staticClass:"download_btn",attrs:{type:"primary",loading:t.downloadFlag3},on:{click:function(e){return t.downloadData(3)}}},[t._v("下 载")])],1),e("div",{staticClass:"wrap_carousel wrap_carousel3"},[e("div",{staticClass:"wrap_left wrap_left_40"},[e("settle-lawsuit",{attrs:{navForm:t.navForm3}}),e("risk-grade",{attrs:{isCollapse:t.isCollapse,navForm:t.navForm3}}),e("risk-point",{attrs:{isCollapse:t.isCollapse,navForm:t.navForm3}})],1),e("div",{staticClass:"wrap_center wrap_left_59"},[e("case-loss",{attrs:{isCollapse:t.isCollapse,navForm:t.navForm3}}),e("risk-number-amount",{attrs:{isCollapse:t.isCollapse,navForm:t.navForm3}})],1),t._e()])])],1)],1)},a=[],o=(i("0faf"),i("b3ec"),i("6fc2"),i("08a9"),i("5966"),i("b75d"),i("4fd9")),n=i("b36a"),r=i("49f2"),l=i("9cd9"),h=i("a06b"),d=i("dc1f"),c=i("20b9"),u=i("ff74"),p=i("fe11"),m=i("3659"),g=i("7c3f"),f=i("eaf6"),v=i("f522"),y=i("1dfa"),b=i("b140"),w=i("cb0e"),_=i("14f5"),x=i("a9e9"),C=i("8e5e"),D=i("2887"),k=i("11df"),T=i("f02d"),S=i("d30f"),A=i("69eb"),E=i("3eae"),O=i("341e"),F=i("6f90"),N=i("6282"),I=i.n(N),R={name:"bigScreen",components:{countTo:I.a,SettleLawsuit:o["default"],CaseTime:n["default"],CaseCycle:r["default"],RiskNumberAmount:l["default"],RiskGrade:h["default"],RiskPoint:d["default"],ChinaMap:c["default"],CaseRate:p["default"],CaseLoss:m["default"],LawsuitTimes:k["default"],CaseNumSum:F["default"],PassingRate:E["default"],AssessmentDeviation:O["default"],ReparationsAmountType:A["default"],DelayReport:S["default"],AllReparationsAmount:T["default"],RiskCase:g["default"],RiskCaseTag:f["default"],ProvinceRisk:v["default"],ProvinceRiskTag:y["default"],DepletionSum:_["default"],ProcessingTime:x["default"],ReparationsAmount:D["default"],CaseNumberRatio:b["default"],ChinaMap3:u["default"],ReportTime:w["default"],Case7daysCount:C["default"]},props:{isCollapse:{type:Boolean,default:!0}},data(){return{downloadFlag1:!1,downloadFlag2:!1,downloadFlag3:!1,showloading2:!0,showloading3:!0,delayLoading2:!1,delayLoading3:!1,updateTime:"",reportTime3:"",reportTime2:"",reportTime1:"",closingTime:"",navForm3:{startTime:"",endTime:"",type:"1"},navForm2:{startTime:"",endTime:"",accidentProvince:"全国",type:"1"},navForm1:{startTime:"",endTime:"",closeCaseStartTime:"",closeCaseEndTime:"",type:"1"},riskCaseReduceAmount:{reduceAmountNum:0,riskCaseNum:0,reduceAmountNum1:0,riskCaseNum1:0},timer:null,provinceValue:"全国",provinceOption:[],options:[{value:"1",label:"报案时间"},{value:"2",label:"事故时间"},{value:"3",label:"结案时间"}],carouselFlag:!1,productDictOptions:[],tableData:[],pageStr:""}},mounted(){this.pageStr=location.origin;var t=new Date;new Date(t.getTime()-26784e5);let e=new Date(t.getTime()-31536e6),i=new Date(t.getTime()-864e5);this.reportTime1=[this.dateFormatting(e,"yyyy-MM-dd"),this.dateFormatting(i,"yyyy-MM-dd")],this.reportTime2=[this.dateFormatting(e,"yyyy-MM-dd"),this.dateFormatting(i,"yyyy-MM-dd")],this.reportTime3=[this.dateFormatting(e,"yyyy-MM-dd"),this.dateFormatting(i,"yyyy-MM-dd")],this.navForm3.startTime=this.reportTime3[0],this.navForm3.endTime=this.reportTime3[1],this.navForm2.startTime=this.reportTime2[0],this.navForm2.endTime=this.reportTime2[1],this.navForm1.startTime=this.reportTime1[0],this.navForm1.endTime=this.reportTime1[1],this.showloading2=!1,this.delayLoading2=!0,this.getProductDictOptions(),this.getLossStatistics()},methods:{getLossStatistics(){let t="";this.instance.post(t+"/large/data/screen/lossStatistics",this.navForm2).then(t=>{let e=t.data;1==e.code&&(this.tableData=e.data)})},getProductDictOptions(){let t="";this.instance.post(t+"/large/data/screen/productDictMapping",{}).then(t=>{let e=t.data;if(1==e.code&&(this.productDictOptions=[],Object.keys(e.data).length>0))for(const i in e.data)this.productDictOptions.push(i)})},downloadData(t){this["downloadFlag"+t]=!0,this.instance({method:"post",url:"/large/data/screen/downloadScreenData"+t,data:this["navForm"+t],responseType:"blob"}).then(e=>{this["downloadFlag"+t]=!1;let i=window.URL.createObjectURL(new Blob([e.data])),s=document.createElement("a");s.style.display="none",s.href=i,s.setAttribute("download",decodeURIComponent(e.headers.filename)),document.body.appendChild(s),s.click()})},carouselChange(t){switch(t){case 1:this.showloading2&&(this.showloading2=!1,this.delayLoading2=!0);break;case 2:this.showloading3&&(this.showloading3=!1,this.delayLoading3=!0);break;default:break}},getProvinceName(){this.instance({method:"post",url:"/large/data/screen/getProvinceName",data:this.navForm2,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(1==t.data.code){var e={provinceName:"全国"};t.data.data.unshift(e),this.provinceOption=t.data.data}})},getRiskCaseReduceAmount(t){this.instance({method:"post",url:"/large/data/screen/riskCaseReduceAmount",data:this.navForm1,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(e=>{if(1==e.data.code){var i=e.data.data;Object.keys(i).forEach(t=>{i[t]=parseInt(i[t])}),"one"!=t&&(this.riskCaseReduceAmount.reduceAmountNum=this.riskCaseReduceAmount.reduceAmountNum1||0,this.riskCaseReduceAmount.riskCaseNum=this.riskCaseReduceAmount.riskCaseNum1||0),this.riskCaseReduceAmount.reduceAmountNum1=i.reduceAmountNum||0,this.riskCaseReduceAmount.riskCaseNum1=i.riskCaseNum||0}})},reportTime1Change(t){this.navForm1.startTime=this.reportTime1[0],this.navForm1.endTime=this.reportTime1[1]},reportTime2Change(t){let e=new Date(this.reportTime2[1]).getTime()-new Date(this.reportTime2[0]).getTime();e<5184e5?this.$message.error("抱歉,报案时间间隔需大于7天!"):(this.navForm2.startTime=this.reportTime2[0],this.navForm2.endTime=this.reportTime2[1],this.navForm2.accidentProvince="全国",this.provinceValue="全国",this.getProvinceName())},reportTime3Change(t){let e=new Date(this.reportTime3[1]).getTime()-new Date(this.reportTime3[0]).getTime();e<5184e5?this.$message.error("抱歉,报案时间间隔需大于7天!"):(this.navForm3.startTime=this.reportTime3[0],this.navForm3.endTime=this.reportTime3[1])},timeSelectChange(t){this[`reportTime${t}Change`]()},closingTimeChange(t){this.navForm1.closeCaseStartTime=this.closingTime&&this.closingTime[0]?this.closingTime[0]:null,this.navForm1.closeCaseEndTime=this.closingTime&&this.closingTime[1]?this.closingTime[1]:null},provinceChange(t){this.navForm2.accidentProvince=t},getStartDate(){var t=new Date,e=t.getFullYear(),i=t.getMonth();0==i&&(i=12,e-=1),i<10&&(i="0"+i);new Date(e,i,0);var s=e+"-"+i+"-01";return s}},destroyed(){clearInterval(this.timer)},watch:{$route:{handler:function(t){this.redirect=t.query&&t.query.redirect},immediate:!0}}},P=R,L=(i("83fa"),i("67c2"),i("1805")),M=Object(L["a"])(P,s,a,!1,null,"df0caf3a",null);e["default"]=M.exports},b1f9:function(t,e,i){"use strict";i("29ae")},b210:function(t,e,i){"use strict";var s=i("e5bf"),a=i("01e1").left,o=i("0edf"),n=i("2c8a"),r=i("1d24"),l=!r&&n>79&&n<83,h=l||!o("reduce");s({target:"Array",proto:!0,forced:h},{reduce:function(t){var e=arguments.length;return a(this,t,e,e>1?arguments[1]:void 0)}})},b2ac:function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{staticClass:"wrap"},[e("div",{staticClass:"file_box"},[t._m(0),e("el-upload",{ref:"upload",staticClass:"uploads-box",attrs:{drag:"",accept:".xls,.xlsx",action:t.baseURL+"/backstage/importInsureExpenses","show-file-list":!1,headers:t.unloaderHeader,limit:1,"on-remove":t.handleRemove,"on-success":t.handleAvatarSuccess,"before-upload":t.beforeAvatarUpload}},[e("i",{staticClass:"el-icon-upload"}),e("div",{staticClass:"el-upload__text"},[t._v("将文件拖到此处,或"),e("em",[t._v("点击上传")])])])],1)])},a=[function(){var t=this,e=t._self._c;return e("div",{staticClass:"page_title",staticStyle:{padding:"25px","border-bottom":"1px dashed #d9d9d9"}},[e("b",[t._v("包商保费上传")])])}],o=i("9839"),n=i("5f87"),r={components:{MyHeader:o["a"]},data(){return{baseURL:"",unloaderHeader:{token:""}}},mounted(){this.baseURL=this.$store.getters.baseURL},methods:{handleRemove(t,e){this.caseExcelData=[]},handleAvatarSuccess(t,e){this.fullscreenLoading.close(),this.fileName=e.name,this.uploadFile=t.data,1==t.code?(this.$message.success("文件导入成功"),this.caseExcelData=t.data):this.$message.error(t.message),this.$refs["upload"].clearFiles()},beforeAvatarUpload(t){this.unloaderHeader.Authorization="Bearer "+Object(n["c"])(),this.fullscreenLoading=this.$loading({lock:!0,text:"上传中,请稍后",spinner:"el-icon-loading",background:"rgba(0, 0, 0, 0.7)"})}}},l=r,h=(i("59e1"),i("1805")),d=Object(h["a"])(l,s,a,!1,null,"589b13e1",null);e["default"]=d.exports},b36a:function(t,e,i){"use strict";i.r(e);var s=function(){var t=this;t._self._c;return t._m(0)},a=[function(){var t=this,e=t._self._c;return e("div",{staticClass:"module_wrap box_border"},[e("div",{staticClass:"box_title"},[t._v("报案时效统计")]),e("div",{attrs:{id:"case_time_bar"}})])}],o=i("48fc"),n=o["a"],r=(i("d202"),i("1805")),l=Object(r["a"])(n,s,a,!1,null,"4a5ce382",null);e["default"]=l.exports},b75d:function(t,e,i){"use strict";var s=i("0475"),a=i("0ddb"),o=i("962d"),n=URLSearchParams.prototype,r=a(n.forEach);s&&!("size"in n)&&o(n,"size",{get:function(){var t=0;return r(this,(function(){t++})),t},configurable:!0,enumerable:!0})},bc27:function(t,e,i){},bc72:function(t,e,i){"use strict";i("09bc")},c023:function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{staticClass:"wrap"},[e("div",{staticClass:"page_title"},[e("b",[t._v(t._s(t.pageTitle))])]),e("div",{staticClass:"search_box public_box"},[e("el-form",{ref:"searchForm",attrs:{inline:!0,model:t.searchForm}},[e("el-form-item",{attrs:{label:"保单号:",prop:"policyNo"}},[e("el-input",{staticClass:"width_200",attrs:{maxlength:"20",placeholder:"请输入",clearable:""},model:{value:t.searchForm.policyNo,callback:function(e){t.$set(t.searchForm,"policyNo",e)},expression:"searchForm.policyNo"}})],1),e("el-form-item",{staticClass:"resetMarginBottom",attrs:{label:"流入时间:"}},[e("el-row",{staticStyle:{width:"350px"}},[e("el-col",{attrs:{span:11}},[e("el-form-item",{attrs:{prop:"startTime"}},[e("el-date-picker",{staticStyle:{width:"100%"},attrs:{placeholder:"请选择日期",clearable:"",type:"date","value-format":"yyyy-MM-dd"},model:{value:t.searchForm.startTime,callback:function(e){t.$set(t.searchForm,"startTime",e)},expression:"searchForm.startTime"}})],1)],1),e("el-col",{staticClass:"line",staticStyle:{"text-align":"center"},attrs:{span:2}},[t._v("至")]),e("el-col",{attrs:{span:11}},[e("el-form-item",{attrs:{prop:"endTime"}},[e("el-date-picker",{staticStyle:{width:"100%"},attrs:{placeholder:"请选择日期",clearable:"",type:"date","value-format":"yyyy-MM-dd"},model:{value:t.searchForm.endTime,callback:function(e){t.$set(t.searchForm,"endTime",e)},expression:"searchForm.endTime"}})],1)],1)],1)],1),e("el-form-item",{attrs:{label:"分公司:",prop:"searchCompanyId"}},[e("el-select",{staticClass:"width_200",attrs:{multiple:"",filterable:"",placeholder:"请选择",clearable:""},model:{value:t.searchForm.searchCompanyId,callback:function(e){t.$set(t.searchForm,"searchCompanyId",e)},expression:"searchForm.searchCompanyId"}},t._l(t.companyOptions,(function(t){return e("el-option",{key:t.id,attrs:{label:t.desc,value:t.id}})})),1)],1),e("el-form-item",{attrs:{label:"当前处理人:",prop:"handlers"}},[e("el-select",{staticClass:"width_250",attrs:{multiple:"",filterable:"",placeholder:"请选择",clearable:""},model:{value:t.searchForm.handlers,callback:function(e){t.$set(t.searchForm,"handlers",e)},expression:"searchForm.handlers"}},t._l(t.employeeListOptions,(function(t){return e("el-option",{key:t.jobNo,attrs:{label:t.name,value:t.jobNo}})})),1)],1),e("el-form-item",{attrs:{label:"被保险人身份证号:",prop:"deliveryId"}},[e("el-input",{staticClass:"width_200",attrs:{maxlength:"20",placeholder:"请输入",clearable:""},model:{value:t.searchForm.deliveryId,callback:function(e){t.$set(t.searchForm,"deliveryId",e)},expression:"searchForm.deliveryId"}})],1),e("el-form-item",{attrs:{label:"姓名:",prop:"deliveryName"}},[e("el-input",{staticClass:"width_200",attrs:{maxlength:"20",placeholder:"请输入",clearable:""},model:{value:t.searchForm.deliveryName,callback:function(e){t.$set(t.searchForm,"deliveryName",e)},expression:"searchForm.deliveryName"}})],1),e("el-form-item",[e("el-button",{staticStyle:{"margin-left":"0.2rem"},attrs:{type:"primary"},on:{click:t.searchTable}},[t._v("查询")]),e("el-button",{staticStyle:{"margin-left":"0.2rem"},attrs:{type:"warning"},on:{click:t.resetForm}},[t._v("重置")]),e("el-button",{staticStyle:{"margin-left":"0.2rem"},attrs:{type:"primary"},on:{click:t.download}},[t._v("下载")])],1)],1)],1),e("div",{staticClass:"table_box public_box"},[e("el-table",{directives:[{name:"loading",rawName:"v-loading",value:t.tableLoading,expression:"tableLoading"}],ref:"filterTable",attrs:{data:t.tableData,height:t.tableHeight}},[e("el-table-column",{attrs:{prop:"policyNo",label:"保单号",width:"200"}}),e("el-table-column",{attrs:{prop:"nameOfInsured",label:"被保人",width:"200"},scopedSlots:t._u([{key:"default",fn:function(t){return[e("overflow-txt",{attrs:{txt:t.row.nameOfInsured}})]}}])}),e("el-table-column",{attrs:{prop:"accidentProvince",label:"分公司"}}),e("el-table-column",{attrs:{prop:"accidentCity",label:"机构(城市)",width:"120"}}),e("el-table-column",{attrs:{prop:"insureTypeName",label:"险种",width:"200"},scopedSlots:t._u([{key:"default",fn:function(t){return[e("overflow-txt",{attrs:{txt:t.row.insureTypeName}})]}}])}),e("el-table-column",{attrs:{prop:"productType",label:"产品名称",width:"200"},scopedSlots:t._u([{key:"default",fn:function(t){return[e("overflow-txt",{attrs:{txt:t.row.productType}})]}}])}),e("el-table-column",{attrs:{prop:"reportTime",label:"报案时间",width:"140"}}),e("el-table-column",{attrs:{prop:"accidentTime",label:"出险时间",width:"140"}}),e("el-table-column",{attrs:{prop:"reportTime",label:"流入时间",width:"140"}}),e("el-table-column",{attrs:{prop:"durationOfClosedClaims",label:"案件总用时",width:"140"}}),e("el-table-column",{attrs:{prop:"humanInjury",label:"是否人伤"}}),e("el-table-column",{attrs:{prop:"accidentProperty",label:"损失类型"}}),e("el-table-column",{attrs:{prop:"currentStatusDesc",label:"案件状态"}}),e("el-table-column",{attrs:{prop:"predictPayAmount",label:"估损金额"}}),e("el-table-column",{attrs:{prop:"currentProcessor",label:"当前处理人",width:"140"}})],1),e("el-pagination",{attrs:{"current-page":t.searchForm.page,layout:"total, sizes, prev, pager, next, jumper","page-sizes":[10,20],"page-size":t.searchForm.size,total:t.searchForm.total},on:{"current-change":t.handleCurrentChange,"size-change":t.handleSizeChange}})],1)])},a=[],o=(i("e4c6"),i("320b"),i("08a9"),i("5966"),i("b75d"),{data(){return{tableHeight:null,pageTitle:"",searchForm:{policyNo:"",startTime:"",endTime:"",searchCompanyId:[],handlers:[],status:[],deliveryId:"",deliveryName:"",page:1,size:10,total:0},detailPageForm:{labelId:null,page:1,size:10,total:0},tagDataForm:{id:"",delDetails:[],labelName:"",typeStr:"",labelDetails:[{id:null,labelId:null,filed:"",labelItems:[{value:""}]}]},tagDataRules:{labelName:[{required:!0,message:"请输入标签名称",trigger:"blur"}],type:[{required:!0,message:"请选择标签类型",trigger:"blur"}]},tagTypeOption:[],sourceOption:[],itemOption:[],tableData:[],value:"",input:"",tableData:[],tmpTagDataForm:null,tableLoading:!1,companyOptions:[],employeeListOptions:[]}},mounted(){window.onresize=()=>{this.calcHeight()},this.calcHeight(),this.pageTitle=this.$route.meta.title,this.getTypeDic(),this.getSourceDic(),this.getTableData(),this.getItemDic(),this.getCompany(),this.getEmployeeList()},methods:{calcHeight(){let t=document.querySelector(".register_tabs")?document.querySelector(".register_tabs").clientHeight:0,e=document.querySelector(".public_box")?document.querySelector(".public_box").clientHeight:0,i=document.querySelector(".el-pagination")?document.querySelector(".el-pagination").clientHeight:0,s=0,a=175;this.tableHeight=window.innerHeight-t-e-i-s-a,this.tableHeight=this.tableHeight<200?200:this.tableHeight,this.$forceUpdate()},getCompany(){this.instance.post("/caseSearch/getCompany",{}).then(t=>{let e=t.data;1==e.code&&(this.companyOptions=e.data)})},getEmployeeList(){this.instance.post("/caseSearch/employeeList",{}).then(t=>{let e=t.data;1==e.code&&(this.employeeListOptions=e.data)})},getItemDic(){this.instance.get("/caseRiskLabel/itemDic",{params:{}}).then(t=>{let e=t.data;1==e.code&&(this.itemOption=e.data)})},getTypeDic(){this.instance.get("/caseRiskLabel/typeDic",{params:{}}).then(t=>{let e=t.data;1==e.code&&(this.tagTypeOption=e.data)})},getSourceDic(){this.instance.get("/caseRiskLabel/sourceDic",{params:{}}).then(t=>{let e=t.data;1==e.code&&(this.sourceOption=e.data)})},searchTable(){this.searchForm.page=1,this.getTableData()},resetForm(){this.$refs.searchForm&&this.$refs.searchForm.resetFields()},handleCurrentChange(t,e){this.searchForm.page=t,this.getTableData()},handleSizeChange(t,e){this.searchForm.size=t,this.searchForm.page=1,this.getTableData()},download(){let t=JSON.parse(JSON.stringify(this.searchForm));this.instance({method:"post",url:"/caseSearch/download",data:t,responseType:"blob"}).then(t=>{let e=window.URL.createObjectURL(new Blob([t.data])),i=document.createElement("a");i.style.display="none",i.href=e,i.setAttribute("download",decodeURIComponent(t.headers.filename)),document.body.appendChild(i),i.click()})},getTableData(){let t=JSON.parse(JSON.stringify(this.searchForm));this.tableLoading=!0,this.instance.post("/caseSearch/search",t).then(t=>{this.tableLoading=!1;let e=t.data;1==e.code?(this.tableData=e.data.list,this.searchForm.total=e.data.total):this.$message.error(t.message)})}}}),n=o,r=(i("580d"),i("1805")),l=Object(r["a"])(n,s,a,!1,null,"2fe8c35d",null);e["default"]=l.exports},c060:function(t,e,i){"use strict";i("0a1b")},c235:function(t,e,i){},c40d:function(t,e,i){},c614:function(t,e,i){"use strict";i("4f8c")},c7e1:function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAkxJREFUSEu1ljtMFFEUhr9/HhhM1MZmWUBKYmOr8VHZWJqYNRqMlbExiJKwVtqYyBLAR6tREzVqtNEYYmEpMbYa7dQIsltoY4gguzP3mFmFwCwwIu6Uc879v3sec86IVZ72izN5F4ZHEfvM3A7QVoFv0lfMvZX0TBY+mSrqy0oyWs6QL1m7U+0SxhHAX+0SQAzcCggvTBZVTvs2APLD0SEXu5vApgzhtHlaeD3lYvB0sWEJIFeKe5G7gtmykf0F0AFnKsWWa/O+C0JtQ9FhM3cf+FfxeU0nvIPzkdTF2gZnO5H/xmBLxi1fIhlmezP8pgPC7qQmvwGl6m2D41kpMFlB+A5zj7N8gRuVYssJtY1Yh0XRR7Ag69AaAbFH2KXcYO0sspEs8cS+RgASp5QrzY2BDjQDAPZcuVL1M9DZFIA0lQB+ABtTgHHkXU5DPau+VthqcRTvbLyQnU53l6CaAH4CG5YckMYNdzUt4lvLK5gllr+rYSSY1wu2J/V+NgF8ArqakiKYUK5UGwNrSpHr0zZfqvU7bLgZEQgNqG1kpoM4/GBmYRZkjd9B7NeibfVRkRuK7mCu578CxN3KQMuxOqB9dCYfV4P3iM2rQqRxzBKX3VnDziPcnmy6hdGcH5wrOOnBuse1ZJ6pMFUM6gMxtXCqfcDoOiAGfl+l6DcunPmQ65Gg65npSuVI8B15J8sDwcPFpmW3V70mtaAkqZDdXYqE3cPi8+VzrRMNX/hqxUpaWFFYcLj9oO6k4f78RXwDe4d5LxQGj8r9mlxJ5xc0Zg1/p29cmwAAAABJRU5ErkJggg=="},c926:function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{staticClass:"home"},[e("div",{staticClass:"main"},[e("div",{staticClass:"search_box"},[e("div",{staticClass:"search_input"},[e("el-input",{attrs:{placeholder:"请输入案件号",clearable:""},model:{value:t.searchBase,callback:function(e){t.searchBase=e},expression:"searchBase"}}),e("el-button",{attrs:{type:"primary"},on:{click:t.handleSearch}},[t._v("搜索")])],1),e("div",{staticClass:"brand_box"},[e("div",[e("p",[t._v(t._s(t.vehicleDetail.amBrandName+"-"+t.vehicleDetail.amSeriesName))]),e("span",[t._v(t._s(t.vehicleDetail.amVehicleName))])])])]),e("div",{staticClass:"result_box"},[e("div",{staticClass:"search_input search_input2"},[e("div",[e("el-input",{attrs:{placeholder:"请输入零配件名称/OE码",clearable:""},model:{value:t.searchParts,callback:function(e){t.searchParts=e},expression:"searchParts"}}),e("el-button",{attrs:{type:"primary"},on:{click:t.handleSearchParts}},[t._v("搜索")])],1),e("div",{staticClass:"city_box"},[e("span",{staticClass:"location_icon"}),e("b",{staticClass:"city_hint"},[t._v("查询城市:")]),e("el-dropdown",{staticClass:"city_dropdown",attrs:{trigger:"click"}},[e("span",{staticClass:"el-dropdown-link"},[t._v(" "+t._s(t.defaultProvince.province)+" | "+t._s(t.defaultProvince.region)+" ")]),e("el-dropdown-menu",{staticStyle:{"max-height":"4rem",overflow:"auto"}},t._l(t.provinceData,(function(i,s){return e("el-dropdown-item",{key:s,attrs:{command:i.province},nativeOn:{click:function(e){return t.clickDropdown(i)}}},[t._v(t._s(i.province))])})),1)],1)],1)]),e("div",{staticClass:"vehicle_main"},[e("el-menu",{staticClass:"el-menu-vertical-demo vehicle_menu",attrs:{"default-active":"2"}},[t._l(t.menusData,(function(i,s){return[1==i.isLeaf?e("el-menu-item",{attrs:{index:s.toString()},on:{click:function(e){return t.menusSelect(i)}}},[e("span",[t._v(t._s(i.partGroupName))])]):e("el-submenu",{attrs:{index:s.toString()}},[e("template",{slot:"title"},[e("span",[t._v(t._s(i.partGroupName))])]),t._l(i.child,(function(i,a){return[1==i.isLeaf?e("el-menu-item",{attrs:{index:s+"-"+a},on:{click:function(e){return t.menusSelect(i)}}},[e("span",{staticStyle:{"padding-left":"0.1rem !important"}},[t._v(t._s(i.partGroupName))])]):e("el-submenu",{attrs:{index:s+"-"+a}},[e("template",{slot:"title"},[e("span",{staticStyle:{"padding-left":"0.1rem !important"}},[t._v(" "+t._s(i.partGroupName)+" ")])]),t._l(i.child,(function(i,o){return e("el-menu-item",{key:o,staticStyle:{"padding-left":"0.3rem !important"},attrs:{index:s+"-"+a+"-"+o},on:{click:function(e){return t.menusSelect(i)}}},[t._v(" "+t._s(i.partGroupName)+" ")])}))],2)]}))],2)]}))],2),e("el-table",{staticClass:"vehicle_table",attrs:{data:t.tableData,size:"small",height:"4.6rem","empty-text":"暂无数据"}},[e("el-table-column",{attrs:{prop:"name",label:"零件名称"},scopedSlots:t._u([{key:"default",fn:function(s){return[e("div",{staticClass:"plus_cell"},[e("div",{directives:[{name:"show",rawName:"v-show",value:!t.checkedPartsId.includes(s.row.oeId+s.row.oeName),expression:"!checkedPartsId.includes(scope.row.oeId + scope.row.oeName)"}],on:{click:function(e){return t.clickRow(s.row,"plus")}}},[e("img",{attrs:{src:i("c7e1")}})]),e("div",{directives:[{name:"show",rawName:"v-show",value:t.checkedPartsId.includes(s.row.oeId+s.row.oeName),expression:"checkedPartsId.includes(scope.row.oeId + scope.row.oeName)"}],on:{click:function(e){return t.clickRow(s.row,"minus")}}},[e("img",{attrs:{src:i("865a")}})]),e("span",[t._v(t._s(s.row.stdPartName))])])]}}])}),e("el-table-column",{attrs:{prop:"oeName",label:"原厂零件名称"}}),e("el-table-column",{attrs:{prop:"oe",label:"零件号"}})],1)],1)]),e("div",{staticClass:"parts_box"},[e("div",{staticClass:"parts_top"},[e("p",[t._v("我的配件工单")]),e("div",{staticClass:"parts_totle"},[e("div",[t._v("您已添加配件:"+t._s(t.myPartsData.length)+"个;价格合计:"+t._s(t.totalPrice)+"元")]),e("el-button",{staticClass:"download_btn",attrs:{type:"primary",size:"mini"},on:{click:t.handleDownload}},[t._v(" 工单下载"),e("i",{staticClass:"el-icon-download el-icon--right"})]),e("el-popover",{attrs:{placement:"top",width:"400"},model:{value:t.baseParameter.visible,callback:function(e){t.$set(t.baseParameter,"visible",e)},expression:"baseParameter.visible"}},[e("p",[t._v("请输入您的宝贵建议:")]),e("el-input",{staticStyle:{margin:"10px 0"},attrs:{type:"textarea",rows:5,placeholder:"请输入内容"},model:{value:t.baseParameter.textarea,callback:function(e){t.$set(t.baseParameter,"textarea",e)},expression:"baseParameter.textarea"}}),e("div",{staticStyle:{"text-align":"right",margin:"0"}},[e("el-button",{attrs:{size:"mini",type:"text"},on:{click:function(e){t.baseParameter.visible=!1}}},[t._v("取消")]),e("el-button",{attrs:{type:"primary",size:"mini"},on:{click:t.submitMessage}},[t._v("确定")])],1),e("el-button",{attrs:{slot:"reference",size:"mini",type:"success"},slot:"reference"},[t._v("留言板")])],1)],1)]),e("div",{staticClass:"parts_middle disabled_null_border"},[e("el-table",{attrs:{data:t.myPartsData,size:"small","table-layout":"auto","empty-text":"暂无数据"},on:{"selection-change":t.handleSelectionChange}},[e("el-table-column",{attrs:{type:"selection",width:"45"}}),e("el-table-column",{attrs:{label:"零件名称"},scopedSlots:t._u([{key:"default",fn:function(i){return[i.row.oe?e("div",[t._v(t._s(i.row.stdPartName))]):e("div",{staticClass:"table_input"},[e("el-input",{attrs:{disabled:t.submitDisabled,size:"small"},model:{value:i.row.stdPartName,callback:function(e){t.$set(i.row,"stdPartName",e)},expression:"scope.row.stdPartName"}})],1)]}}])}),e("el-table-column",{attrs:{label:"原厂零件名称"},scopedSlots:t._u([{key:"default",fn:function(i){return[i.row.oe?e("div",[t._v(t._s(i.row.oeName))]):e("div",{staticClass:"table_input"},[e("el-input",{attrs:{disabled:"",size:"small"},model:{value:i.row.oeName,callback:function(e){t.$set(i.row,"oeName",e)},expression:"scope.row.oeName"}})],1)]}}])}),e("el-table-column",{attrs:{label:"零件号"},scopedSlots:t._u([{key:"default",fn:function(i){return[i.row.oe?e("div",[t._v(t._s(i.row.oe))]):e("div",{staticClass:"table_input"},[e("el-input",{attrs:{disabled:"",size:"small"},model:{value:i.row.oe,callback:function(e){t.$set(i.row,"oe",e)},expression:"scope.row.oe"}})],1)]}}])}),e("el-table-column",{attrs:{label:"零件维修/更换",width:"100"},scopedSlots:t._u([{key:"default",fn:function(i){return[e("div",[e("el-select",{staticClass:"m-2",attrs:{disabled:t.submitDisabled,placeholder:"Select",size:"default"},on:{change:function(e){return t.partsTypeChange(i.row)}},model:{value:i.row.operationType,callback:function(e){t.$set(i.row,"operationType",e)},expression:"scope.row.operationType"}},[e("el-option",{attrs:{label:"维修",value:"1"}}),e("el-option",{attrs:{label:"更换",value:"2"}})],1)],1)]}}])}),e("el-table-column",{attrs:{label:"装配数量(个)",width:"90"},scopedSlots:t._u([{key:"default",fn:function(i){return[i.row.oe?e("div",[t._v(t._s(i.row.partNum))]):e("div",{staticClass:"table_input"},[e("el-input",{attrs:{disabled:t.submitDisabled,type:"number",size:"small"},model:{value:i.row.partNum,callback:function(e){t.$set(i.row,"partNum",e)},expression:"scope.row.partNum"}})],1)]}}])}),e("el-table-column",{attrs:{label:"零件报价(元)",width:"90"},scopedSlots:t._u([{key:"default",fn:function(i){return[e("div",{staticClass:"table_input"},[e("el-input",{attrs:{disabled:!i.row.disabled||t.submitDisabled,type:"number",size:"small"},model:{value:i.row.partsOffer,callback:function(e){t.$set(i.row,"partsOffer",e)},expression:"scope.row.partsOffer"}})],1)]}}])}),e("el-table-column",{attrs:{label:"拆装报价(元)",width:"150"},scopedSlots:t._u([{key:"default",fn:function(i){return[e("div",{staticClass:"table_input"},[e("el-input",{attrs:{disabled:t.submitDisabled,type:"number",size:"small"},model:{value:i.row.installOffer,callback:function(e){t.$set(i.row,"installOffer",e)},expression:"scope.row.installOffer"}})],1)]}}])}),e("el-table-column",{attrs:{label:"修补费报价(元)",width:"150"},scopedSlots:t._u([{key:"default",fn:function(i){return[e("div",{staticClass:"table_input"},[e("el-input",{attrs:{disabled:i.row.disabled||t.submitDisabled,type:"number",size:"small"},model:{value:i.row.repairOffer,callback:function(e){t.$set(i.row,"repairOffer",e)},expression:"scope.row.repairOffer"}})],1)]}}])}),e("el-table-column",{attrs:{label:"喷漆报价(元)",width:"150"},scopedSlots:t._u([{key:"default",fn:function(i){return[e("div",{staticClass:"table_input"},[e("el-input",{attrs:{disabled:t.submitDisabled,type:"number",size:"small"},model:{value:i.row.paintingOffer,callback:function(e){t.$set(i.row,"paintingOffer",e)},expression:"scope.row.paintingOffer"}})],1)]}}])}),e("el-table-column",{attrs:{label:"报价异常提示"},scopedSlots:t._u([{key:"default",fn:function(i){return[e("div",[e("span",{staticStyle:{color:"#cc4f4f"}},[t._v(t._s(i.row.tips))])])]}}])}),e("el-table-column",{attrs:{label:"操作"},scopedSlots:t._u([{key:"default",fn:function(s){return[e("div",{staticClass:"delete_icon",on:{click:function(e){return t.handleDelete("single",s.row)}}},[e("img",{attrs:{src:i("db4d")}})])]}}])})],1)],1),e("div",{staticClass:"parts_bottom"},[e("div",[e("el-button",{attrs:{size:"mini",type:"primary",plain:"",icon:"el-icon-plus"},on:{click:t.handleAdd}},[t._v("自定义添加")]),e("el-button",{staticStyle:{"margin-left":"0.3rem"},attrs:{size:"mini",type:"danger",plain:"",icon:"el-icon-delete"},on:{click:function(e){return t.handleDelete("batch")}}},[t._v("批量删除")])],1),e("div",[e("el-button",{attrs:{disabled:t.submitDisabled,size:"mini",type:"primary",icon:"el-icon-top"},on:{click:t.checkWorkOrders}},[t._v("提交报价")])],1)])])]),e("el-dialog",{attrs:{visible:t.centerDialogVisible,"modal-append-to-body":!1,title:t.checkedPartName,width:"56%"},on:{"update:visible":function(e){t.centerDialogVisible=e}}},[e("div",[e("img",{attrs:{src:t.checkedPartImg.picUrl}})])]),e("result-modal",{attrs:{tipsNum:t.baseParameter.tipsNum,pageType:t.submitType,modalVisible:t.modalVisible},on:{handleReturn:t.handleReturn,addWorkOrders:t.addWorkOrders}})],1)},a=[],o=(i("0faf"),i("b3ec"),i("2502"),i("6fc2"),i("2130"),i("320b"),i("08a9"),i("5966"),i("b75d"),i("569d")),n=i("96b4"),r={name:"VehicleInfo",components:{ResultModal:o["default"]},data(){return{vehicleDetail:"",modalVisible:!1,partForm:{},submitType:"",checkedPartsId:[],myPartsData:[],multipleSelection:[],menusData:[],tableData:[],searchBase:"",searchParts:"",defaultProvince:{},submitDisabled:!1,basePartsPrice:[],checkedPartImg:{},checkedPartName:"选中的零件名称",centerDialogVisible:!1,baseParameter:{vin:"",textarea:"",tipsNum:0,visible:!1,channelType:"",partGroupId:"",amVehicleId:""},provinceData:[{code:"110000",province:"北京市",region:"华北区",oeRegion:"华北区"},{code:"120000",province:"天津市",region:"华北区",oeRegion:"华北区"},{code:"130000",province:"河北省",region:"华北区",oeRegion:"华北区"},{code:"140000",province:"山西省",region:"华北区",oeRegion:"华北区"},{code:"150000",province:"内蒙古",region:"华北区",oeRegion:"华北区"},{code:"210000",province:"辽宁省",region:"东北区",oeRegion:"东北区"},{code:"220000",province:"吉林省",region:"东北区",oeRegion:"东北区"},{code:"230000",province:"黑龙江省",region:"东北区",oeRegion:"东北区"},{code:"310000",province:"上海市",region:"华东区",oeRegion:"华东区"},{code:"320000",province:"江苏省",region:"华东区",oeRegion:"华东区"},{code:"330000",province:"浙江省",region:"华东区",oeRegion:"华东区"},{code:"340000",province:"安徽省",region:"华东区",oeRegion:"华东区"},{code:"350000",province:"福建省",region:"华东区",oeRegion:"华南区"},{code:"360000",province:"江西省",region:"华东区",oeRegion:"华南区"},{code:"370000",province:"山东省",region:"华东区",oeRegion:"华北区"},{code:"410000",province:"河南省",region:"华中区",oeRegion:"华北区"},{code:"420000",province:"湖北省",region:"华中区",oeRegion:"华南区"},{code:"430000",province:"湖南省",region:"华中区",oeRegion:"华南区"},{code:"440000",province:"广东省",region:"华南区",oeRegion:"华南区"},{code:"450000",province:"广西省",region:"华南区",oeRegion:"华南区"},{code:"460000",province:"海南省",region:"华南区",oeRegion:"华南区"},{code:"500000",province:"重庆市",region:"西南区",oeRegion:"西部区"},{code:"510000",province:"四川省",region:"西南区",oeRegion:"西部区"},{code:"520000",province:"贵州省",region:"西南区",oeRegion:"华南区"},{code:"530000",province:"云南省",region:"西南区",oeRegion:"西部区"},{code:"540000",province:"西藏省",region:"西南区",oeRegion:"西部区"},{code:"610000",province:"陕西省",region:"西北区",oeRegion:"西部区"},{code:"620000",province:"甘肃省",region:"西北区",oeRegion:"西部区"},{code:"630000",province:"青海省",region:"西北区",oeRegion:"西部区"},{code:"640000",province:"宁夏省",region:"西北区",oeRegion:"西部区"},{code:"650000",province:"新疆省",region:"西北区",oeRegion:"西部区"},{code:"710000",province:"台湾省",region:"华东区",oeRegion:"港澳台"},{code:"810000",province:"香港",region:"华南区",oeRegion:"港澳台"},{code:"820000",province:"澳门",region:"华南区",oeRegion:"港澳台"}]}},computed:{totalPrice(){let t=0;return this.myPartsData.length>0&&this.myPartsData.forEach((e,i)=>{t+=Number(e.partNum)*(Number(e.partsOffer)+Number(e.installOffer)+Number(e.repairOffer)+Number(e.paintingOffer))}),t}},methods:{getVehicleStructure(){this.instance({method:"post",url:"/easyepc/getVehicleStructure",data:{amVehicleId:this.baseParameter.amVehicleId},headers:{}}).then(t=>{var e=t.data;if(1==e.code){this.baseParameter.amVehicleId=e.data.amVehicleId;let t=[];e.data.vehicleStructures.length>0&&(e.data.vehicleStructures.forEach((e,i)=>{e.child=[],1==e.partGroupLevel&&t.push(e)}),e.data.vehicleStructures.forEach((e,i)=>{2==e.partGroupLevel&&t.forEach((t,i)=>{t.partGroupId==e.parentId&&t.child.push(e)})}),e.data.vehicleStructures.forEach((e,i)=>{3==e.partGroupLevel&&t.forEach((t,i)=>{for(let s=0,a=t.child.length;s{let e=t.data;1==e.code&&(e.data.partsGroup.length>0&&e.data.partsGroup.forEach((t,i)=>{t.operationType="1",t.partsOffer=0,t.installOffer=0,t.repairOffer=0,t.paintingOffer=0,t.tips="",t.vin=e.data.vin}),this.tableData=e.data.partsGroup)})},loadPartImg(t){this.checkedPartImg=[],this.checkedPartName=t.oeName,this.instance({method:"post",url:"/easyepc/getPicByOeId",data:{amVehicleId:this.baseParameter.amVehicleId,partGroupId:this.baseParameter.partGroupId,oeId:t.oeId},headers:{}}).then(t=>{let e=t.data;1==e.code?(this.checkedPartImg=e.data[0],this.centerDialogVisible=!0):this.$message.error(e.message)})},getPartsPrice(t){this.instance({method:"post",url:"/easyepc/getPartsPrice",data:{oeId:t.oeId},headers:{}}).then(t=>{let e=t.data;1==e.code&&(this.basePartsPrice.push(e.data),this.myPartsData.forEach((t,i)=>{t.oeId==e.data.oeId&&(t.guidePrice=e.data.guidePrice)}))})},getTypeByOE(){this.instance({method:"post",url:"/easyepc/getTypeByOE",data:{oe:"",amBrandId:""},headers:{}}).then(t=>{t.data.code})},getProvincePrice(t){this.instance({method:"post",url:"/easyepc/getProvincePrice",data:{oe:t.oe,brandId:t.priceBrandId,provinceCode:this.defaultProvince.code},headers:{}}).then(t=>{let e=t.data;1==e.code&&this.myPartsData.forEach((t,i)=>{t.oe==e.data.oe&&(t.marketPrice=e.data.marketPrice)})})},handleSearch(){this.$router.push({path:"/calculatorTool/carDamage",query:{vid:this.searchBase}})},handleSearchParts(){this.instance({method:"post",url:"/easyepc/getPartsByNameOrOE",data:{searchWord:this.searchParts,amVehicleId:this.baseParameter.amVehicleId,vin:this.vehicleDetail.vin},headers:{}}).then(t=>{let e=t.data;1==e.code&&(e.data.length>0&&e.data.forEach((t,e)=>{t.operationType="1",t.partsOffer=0,t.installOffer=0,t.repairOffer=0,t.paintingOffer=0,t.tips="",t.vin=this.vehicleDetail.vin}),this.tableData=e.data)})},clickRow(t,e){if(this.submitDisabled=!1,"plus"==e)t.repairChannel=this.baseParameter.channelType,t.amVehicleId=this.baseParameter.amVehicleId,t.operationType="1",t.partsOffer=0,t.installOffer=0,t.repairOffer=0,t.paintingOffer=0,this.myPartsData.push(t),this.checkedPartsId.push(t.oeId+t.oeName),this.getPartsPrice(t);else{let e=this.myPartsData.findIndex((e,i)=>e.oeId+e.oeName==t.oeId+t.oeName);this.myPartsData.splice(e,1),this.checkedPartsId.remove(t.oeId+t.oeName)}},clickDropdown(t){this.$confirm("更换城市后,将为您重新查询当前配件价格,是否继续?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(()=>{this.defaultProvince=t}).catch(()=>{})},handleSelectionChange(t){this.multipleSelection=t},partsTypeChange(t){"2"==t.operationType?(t.disabled=!0,t.repairOffer=0):(t.disabled=!1,t.partsOffer=0)},handleDelete(t,e){if("batch"==t){if(!(this.multipleSelection.length>0))return this.$message.error("抱歉,请先选择要删除的配件!"),!1;{let t=this.myPartsData.filter(t=>{let e=this.multipleSelection.map(t=>t.oeId);return!e.includes(t.oeId)});this.multipleSelection.forEach((t,e)=>{this.checkedPartsId.remove(t.oeId+t.oeName)}),this.multipleSelection=[],this.myPartsData=t}}else{let t=this.myPartsData.findIndex((t,i)=>t.oeId==e.oeId);this.myPartsData.splice(t,1),this.checkedPartsId.remove(e.oeId+e.oeName)}},handleDownload(){if(!(this.myPartsData.length>0))return this.$message.error("抱歉,请先添加配件!"),!1;var t=!0;if(this.myPartsData.forEach((e,i)=>{e.addTime||(t=!1)}),0==t)return this.$message.error("抱歉,请先提交报价,再下载工单!"),!1;this.instance({method:"post",url:"/easyepc/exportWorkOrderDetail",data:[this.myPartsData[0]],responseType:"blob",headers:{}}).then(t=>{let e=window.URL.createObjectURL(new Blob([t.data])),i=document.createElement("a");i.style.display="none",i.href=e,i.setAttribute("download","车损计算器下载工单.zip"),document.body.appendChild(i),i.click()}).catch((function(t){console.log(t)}))},handleAdd(){this.submitDisabled=!1,this.myPartsData.push({vin:this.vehicleDetail.vin,oeId:Object(n["a"])(),oeName:"",partNum:1,oe:"",stdPartName:"",tips:"",partsOffer:0,installOffer:0,repairOffer:0,paintingOffer:0,operationType:"1"})},handleReturn(){this.modalVisible=!1},checkWorkOrders(){if(this.myPartsData.length>0){let t=!0,e="";if(this.myPartsData.forEach((i,s)=>{if(i.stdPartName||(e="抱歉,请填写自定义零件名称!",t=!1),!i.partNum>0&&(e="抱歉,请填写装配数量且大于0!",t=!1),2==i.operationType&&!i.partsOffer>0&&(e="抱歉,选择零件更换时,请填写零件报价且大于0!",t=!1),i.caseNo=this.baseParameter.caseNo,i.jobNo=this.baseParameter.jobNo,i.vehiclePrice=this.vehicleDetail.price,i.amVehicleName=this.vehicleDetail.amVehicleName,i.vehicleBrand=this.vehicleDetail.amBrandName+"-"+this.vehicleDetail.amSeriesName,!i.marketPrice>0){let t=this.defaultProvince.oeRegion;this.basePartsPrice.length>0&&this.basePartsPrice.forEach((e,s)=>{e.oeId==i.oeId&&("华东区"==t?i.marketPrice=e.marketPriceHd:"东北区"==t?i.marketPrice=e.marketPriceDb:"华北区"==t?i.marketPrice=e.marketPriceHb:"西部区"==t?i.marketPrice=e.marketPriceXb:"华南区"==t&&(i.marketPrice=e.marketPriceHn))})}}),!t)return this.$message.error(e),!1;this.instance({method:"post",url:"/easyepc/checkWorkOrders",data:this.myPartsData,headers:{}}).then(t=>{let e=t.data;if(this.modalVisible=!0,1==e.code?(this.submitType="success",this.submitDisabled=!0,this.linkNewPage(e.data)):0==e.code?(this.submitType="wraning",this.submitDisabled=!1,e.data||this.$message.error(e.message)):2==e.code&&this.$message.error(e.message),e.data.damageWorkOrderList.length>0){let t=0;e.data.damageWorkOrderList.forEach((e,i)=>{e.tips.trim()&&t++,this.partsTypeChange(e)}),this.baseParameter.tipsNum=t}this.myPartsData=e.data.damageWorkOrderList})}else this.$message.error("抱歉,请先添加配件!")},addWorkOrders(){this.instance({method:"post",url:"/easyepc/addWorkOrders",data:this.myPartsData,headers:{}}).then(t=>{let e=t.data;1==e.code?(this.submitDisabled=!0,this.myPartsData=e.data.damageWorkOrderList,this.linkNewPage(e.data),this.submitType="success"):this.$message.error(e.message)})},linkNewPage(t){},submitMessage(t){this.instance({method:"post",url:"/message/addTMessageBoard",data:{messageBoard:this.baseParameter.textarea,sysUserId:this.baseParameter.userid},headers:{}}).then(t=>{let e=t.data;1==e.code&&(this.baseParameter.visible=!1,this.baseParameter.textarea=""),this.$message(e.message)})}},mounted(){this.defaultProvince=this.provinceData[0];let t=localStorage.getItem("userInfo");t&&(t=JSON.parse(t),this.baseParameter.jobNo=t.jobNo);let e=localStorage.getItem("vehicleDetail");e&&(this.vehicleDetail=JSON.parse(e)||{}),this.baseParameter.amVehicleId=this.$route.query.vid,this.baseParameter.caseNo=this.$route.query.caseNo,this.baseParameter.channelType=this.$route.query.type,this.getVehicleStructure()}},l=r,h=(i("bc72"),i("1805")),d=Object(h["a"])(l,s,a,!1,null,"244ab0c0",null);e["default"]=d.exports},ca96:function(t,e,i){"use strict";i("c235")},caa1:function(t,e,i){},cb0e:function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],staticClass:"module_wrap box_border",attrs:{"element-loading-text":"数据加载中","element-loading-spinner":"el-icon-loading","element-loading-background":"transparent"}},[e("div",{staticClass:"box_title box_title_radio"},[e("span",[t._v("报案时效统计")]),e("div",{directives:[{name:"show",rawName:"v-show",value:0,expression:"0"}],staticClass:"radio_group"},[e("el-radio-group",{attrs:{size:"mini"},on:{change:t.radioChange},model:{value:t.radio,callback:function(e){t.radio=e},expression:"radio"}},[e("el-radio-button",{attrs:{label:"骑手报案"}}),e("el-radio-button",{attrs:{label:"保司报案"}})],1)],1)]),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.loading,expression:"!loading"}],staticStyle:{height:"100%"}},[e("div",{attrs:{id:"distribution_pie"}})])])},a=[],o=(i("0faf"),i("b3ec"),i("6fc2"),i("ada4")),n={name:"ReportTime",props:{isCollapse:{type:Boolean,default:!0},navForm:{type:Object,default:{}}},watch:{isCollapse(){setTimeout(()=>{this.myChart&&this.myChart.resize()},600)},navForm:{deep:!0,handler(t){this.getData()}}},data(){return{topDays:[],newNumber:0,radio:"骑手报案",xAxisData:[],seriesData1:[],seriesData2:[],option:"",myChart:"",loading:!0}},mounted(){this.role=localStorage.getItem("role"),window.addEventListener("resize",()=>{this.myChart&&setTimeout(()=>{this.myChart.resize()},500)})},methods:{getData(){this.loading=!0,this.instance({method:"post",url:"/large/data/screen/getReportRiskCase",data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(this.loading=!1,1==t.data.code){let e=t.data.data;this.loadCharts(e)}})},radioChange(){this.option&&("骑手报案"==this.radio?this.option.series[0].data=this.seriesData1:this.option.series[0].data=this.seriesData2,setTimeout(()=>{this.myChart.setOption(this.option)},100))},loadCharts(t){var e=document.getElementById("distribution_pie");e&&(this.myChart&&this.myChart.dispose(),this.myChart=o["init"](e,null,{renderer:"svg"}),this.xAxisData=[],this.seriesData1=[],this.seriesData2=[],t.caseRiskMoney.forEach((t,e)=>{this.seriesData1.push(t.amountCaseFiled),this.seriesData2.push(t.caseNumRatio),this.seriesData1.push(t.amountOfFirstCaseFiled),this.seriesData2.push(t.totalPayAmount)}),this.option={tooltip:{trigger:"axis",axisPointer:{type:"cross",crossStyle:{color:"#999"}}},grid:{top:30,left:"10",right:"10",bottom:"15",containLabel:!0},color:["#EFBD71","#DBEF69"],legend:{data:["首次报案时间","每次报案时间"],itemWidth:12,itemHeight:12,textStyle:{color:"#fff"},left:"center"},xAxis:[{type:"category",data:["24h报案率","48h报案率"],axisPointer:{type:"shadow"},axisLabel:{showMaxLabel:!0,textStyle:{color:"#fff"},width:60,overflow:"truncate",ellipsis:"..."}}],yAxis:[{type:"value",splitLine:{show:!1},axisLabel:{showMaxLabel:!0,textStyle:{color:"#fff"}}},{type:"value",splitLine:{show:!1}}],series:[{name:"首次报案时间",type:"bar",tooltip:{valueFormatter:function(t){return t+" %"}},data:this.seriesData1},{name:"每次报案时间",type:"bar",tooltip:{valueFormatter:function(t){return t+" %"}},data:this.seriesData2}]},this.myChart.setOption(this.option))}},updated(){this.myChart&&this.myChart.resize()}},r=n,l=(i("e5b2"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"590682f8",null);e["default"]=h.exports},cf9b:function(t,e,i){"use strict";i("e039")},d188:function(t,e,i){t.exports=i.p+"img/null.71fc0223.png"},d1a8:function(t,e,i){},d202:function(t,e,i){"use strict";i("1870")},d2e8:function(t,e,i){},d30f:function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],staticClass:"module_wrap box_border",attrs:{"element-loading-text":"数据加载中","element-loading-spinner":"el-icon-loading","element-loading-background":"transparent"}},[e("div",{staticClass:"box_title box_title_radio"},[e("span",[t._v(t._s("全国"==t.province?"全国车物损案均金额排行榜":"车物损案均金额统计"))])]),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.loading,expression:"!loading"}],staticStyle:{height:"55%"}},[e("div",{directives:[{name:"show",rawName:"v-show",value:"全国"==t.province,expression:"province == '全国'"}],attrs:{id:"delay_report_bar"}}),e("div",{directives:[{name:"show",rawName:"v-show",value:"全国"!=t.province,expression:"province != '全国'"}],attrs:{id:"delay_report_bar2"}}),t.tableData.length>0?e("div",{staticClass:"tables_box"},[e("el-table",{attrs:{data:[t.tableData[0]],"max-height":"200"}},t._l(t.tableData,(function(i,s){return e("el-table-column",{key:s,attrs:{label:i.accItem,width:String(i.accAmount).length>5?"100":""},scopedSlots:t._u([{key:"default",fn:function(e){return[t._e(),t._v(" "+t._s(i.accAmount?i.accAmount:"--")+" 元 ")]}}],null,!0)})})),1)],1):t._e()])])},a=[],o=(i("0faf"),i("b3ec"),i("6fc2"),i("2130"),i("ada4")),n={name:"DelayReport",props:{isCollapse:{type:Boolean,default:!0},navForm:{type:Object,default:{}}},watch:{isCollapse(){setTimeout(()=>{this.myChart&&this.myChart.resize()},600)},navForm:{immediate:!0,deep:!0,handler(t){this.province=t.accidentProvince,this.getData()}}},data(){return{topDays:[],newNumber:0,myChart:"",myChart2:"",option:"",province:"",radio:"数量",tableData:[],loading:!0}},mounted(){this.role=localStorage.getItem("role"),window.addEventListener("resize",()=>{this.myChart&&setTimeout(()=>{this.myChart.resize()},500)})},methods:{getData(){this.loading=!0,this.instance({method:"post",url:"/large/data/screen/vehicleItemRanking",data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(1==t.data.code){this.loading=!1;let e=t.data.data;if(e.length>0){e=e.splice(0,20);const t=e.map(t=>({...t,accItem:this.$$abbreviateCity(t.accItem)}));this.loadCharts(t)}}})},loadCharts2(t){var e=document.getElementById("delay_report_bar2");if(!e)return;this.myChart2&&this.myChart2.dispose(),this.myChart2=o["init"](e,null,{renderer:"svg"});let i=[],s=[],a=[];t.forEach((t,e)=>{i.push(t.accItem),s.push(t.prvAmount),a.push(t.accAmount)}),this.tableData=t,this.$forceUpdate();let n={tooltip:{confine:!0,formatter:"{a}
{b}: {c}元",axisPointer:{type:"shadow"}},legend:{data:[this.province,"全国"],itemWidth:12,itemHeight:12,itemGap:20,textStyle:{color:"#fff"},left:"center"},grid:{top:25,left:"10",right:"10",bottom:"10",containLabel:!0},xAxis:{type:"category",splitLine:{show:!1},axisTick:{show:!0,alignWithLabel:!0},axisLabel:{showMaxLabel:!0,rotate:30,color:"#fff",width:70,overflow:"truncate",ellipsis:"..."},data:i},yAxis:{splitLine:{show:!1},axisTick:{show:!1},axisLabel:{color:"#fff",formatter:"{value} 元"}},series:[{type:"bar",itemStyle:{color:"#037B89"},stack:"total",emphasis:{focus:"series"},barMaxWidth:"40%",data:s},{name:"全国",type:"bar",itemStyle:{color:"#58AFC3"},emphasis:{focus:"series"},stack:"total",barMaxWidth:"35%",data:a}]};this.myChart2.setOption(n)},loadCharts(t){var e=document.getElementById("delay_report_bar");if(!e)return;this.myChart=o["init"](e,null,{renderer:"svg"});let i=[],s=[];t.forEach((t,e)=>{i.push(t.accItem),s.push(t.accAmount)}),this.tableData=t;var a={tooltip:{formatter:"{b0} : {c0}元",show:!0},grid:{top:20,left:"10",right:"10",bottom:"10",containLabel:!0},xAxis:{type:"category",axisLabel:{showMaxLabel:!0,rotate:40,color:"#fff",width:60,overflow:"truncate",ellipsis:"..."},axisTick:{alignWithLabel:!0},data:i},yAxis:{type:"value",axisLabel:{color:"#fff",formatter:"{value} 元"},splitLine:{show:!1},axisTick:{show:!1}},series:[{type:"bar",barWidth:"40%",data:s,label:{show:!1,position:"top",color:"#fff",formatter:"{c} %"},itemStyle:{color:new o["graphic"].LinearGradient(0,0,0,1,[{offset:0,color:"#FFFFFF"},{offset:1,color:"#F2B95D"}])}}]};this.myChart.setOption(a)}},updated(){this.myChart&&this.myChart.resize()}},r=n,l=(i("f678"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"4ee1be08",null);e["default"]=h.exports},d4e4:function(t,e,i){},d70a:function(t,e,i){},d786:function(t,e,i){},d8bb:function(t,e,i){"use strict";i("1403")},db4d:function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA4AAAAOCAYAAAAfSC3RAAAAAXNSR0IArs4c6QAAAX9JREFUOE+V0r9Lw0AUB/DvpS1V1KE4FEV0cFAcpLRVRAUR/ImYdxR0EfSfcHXyD3AUugiugUBSqpMiDiqaSNHJRcFBF7XUirXW5EkLSgyF4k13X+7De/c4Ac+yUqkO4Tg5Btq9OYCScN3pRCZz9pML74WclMMO81bCMMa8uU2UBnCaMIydP9AmsqoBAy0C6AJw44UM9AjgDcBzNQ+WShO1iudSxhTm4wAwVxHi3dfm71Fh3g8wr8bi8YPfVi2i/Adz97hpFi9UdesuHF5f1jTHknKjzXG2+zKZJ4voXmEeiZvmQ11oEb0gGo0m0+mKLWUupCipQV2//R8kOm0OBFIDuv5oqepaK6D3m2axYcWrhYXIYDab97+7IbxU1U4WotcLFSGuG0JbygSYR3ww2xBeEk25QszXoOsywuHNpKYV6kKb6PC1UJiZPDr6Ollaam4qlyM1FwxyUtcfq/u60PfdFgGs/GQusDtkGHtemAUw+2d6Qhx+hkI0qmkl/1S/AfA874ZszYD0AAAAAElFTkSuQmCC"},dc1f:function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],staticClass:"module_wrap box_border",attrs:{"element-loading-text":"数据加载中","element-loading-spinner":"el-icon-loading","element-loading-background":"transparent"}},[t._m(0),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.loading,expression:"!loading"}],staticStyle:{height:"55%"}},[e("div",{attrs:{id:"risk_point_pie"}})])])},a=[function(){var t=this,e=t._self._c;return e("div",{staticClass:"box_title"},[e("b",[t._v("案件风险占比分布")]),e("span",[t._v("(D级为最高风险)")])])}],o=(i("0faf"),i("b3ec"),i("6fc2"),i("ada4")),n={name:"RiskPoint",props:{isCollapse:{type:Boolean,default:!0},navForm:{type:Object,default:{}}},watch:{isCollapse(){setTimeout(()=>{this.myChart&&this.myChart.resize()},600)},navForm:{deep:!0,handler(t){this.province=t.accidentProvince,this.getData()}}},data(){return{topDays:[],newNumber:0,myChart:"",loading:!0}},mounted(){this.role=localStorage.getItem("role"),this.getData(),window.addEventListener("resize",()=>{this.myChart&&setTimeout(()=>{this.myChart.resize()},500)})},methods:{getData(){this.loading=!0,this.instance({method:"post",url:"/large/data/screen/caseLevelNum",data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(this.loading=!1,1==t.data.code){let e=t.data.data;e.length>0&&this.loadCharts(e)}})},loadCharts(t){var e=document.getElementById("risk_point_pie");if(!e)return;this.myChart&&this.myChart.dispose(),this.myChart=o["init"](e,null,{renderer:"svg"});let i=[];t.forEach((t,e)=>{let s={value:t.caseLevelNum,name:t.caseLevel};i.push(s)});var s={color:["#8B5CF6","#EC4899","#FFB95A","#75E6E0"],tooltip:{trigger:"item",formatter:"{b}: {c}件 ({d}%)",confine:!0},legend:{bottom:"5%",itemWidth:12,itemHeight:12,textStyle:{color:"#fff"},left:"center"},series:[{type:"pie",radius:["35%","60%"],center:["50%","40%"],avoidLabelOverlap:!1,label:{show:!1,position:"center"},labelLine:{show:!1},data:i}]};this.myChart.setOption(s,!0)}},updated(){this.myChart&&this.myChart.resize()}},r=n,l=(i("7906"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"7b3091b9",null);e["default"]=h.exports},df37:function(t,e,i){"use strict";i("2473")},e039:function(t,e,i){},e27e:function(t,e,i){"use strict";i("3b0c")},e2b4:function(t,e,i){"use strict";i("d70a")},e5b2:function(t,e,i){"use strict";i("d2e8")},e94e:function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{staticClass:"case_card card_bottom-padding caseInfo"},[e("div",{staticClass:"card_content"},[e("div",{staticClass:"tab_content"},[e("div",{staticClass:"btn_group1"},[e("el-button",{attrs:{type:"primary"},on:{click:t.showUpload}},[t._v("点击上传")]),e("el-button",{attrs:{type:"primary"},on:{click:function(e){t.analyseStr=[]}}},[t._v("清除日志")])],1)])]),e("div",{staticClass:"analyseBox"},[t._l(t.analyseStr,(function(i,s){return[e("p",{key:s,class:{analyseStyle:1,errorTxt:i.indexOf("失败")>=0}},[t._v(t._s(i))])]}))],2),e("el-dialog",{staticClass:"upload_dialog",attrs:{title:"上传材料",visible:t.uploadFlag,center:"","modal-append-to-body":!1,"close-on-click-modal":!1,width:"400px"},on:{"update:visible":function(e){t.uploadFlag=e}}},[e("div",{staticClass:"dialog_content"},[e("el-form",{ref:"uploadRef",attrs:{model:t.uploadForm,rules:t.uploadRules,"label-width":"120px"}},[e("el-form-item",{attrs:{label:"文件类型:",prop:"typeCode"}},[e("el-select",{attrs:{filterable:"",placeholder:"请选择"},model:{value:t.uploadForm.typeCode,callback:function(e){t.$set(t.uploadForm,"typeCode",e)},expression:"uploadForm.typeCode"}},t._l(t.caseFileTypeOptions,(function(t){return e("el-option",{key:t.code,attrs:{label:t.name,value:t.code}})})),1)],1)],1),e("div",{staticClass:"upload_btn"},[t.selectFileFlag?e("el-button",{attrs:{size:"mini",type:"primary",disabled:""}},[t._v("选择文件")]):e("el-upload",{ref:"elUploadRef",attrs:{action:"#","http-request":e=>t.ossUpload(e),multiple:"",limit:10,"on-exceed":t.handleExceed,"on-remove":t.handleRemove,"file-list":t.fileList,"show-file-list":!1}},[e("el-button",{attrs:{size:"mini",type:"primary"},on:{click:function(e){return t.addAnalyseStrFn("选择文件 按钮")}}},[t._v("选择文件")]),t.filesLengthError?e("p",{staticClass:"errorTxt"},[t._v("最少选择一个文件")]):t._e()],1)],1),t._l(t.uploadCaseFileForm.files,(function(i,s){return e("div",{key:s,staticClass:"files_box"},[e("div",{staticStyle:{width:"75%"}},[e("overflow-txt",{attrs:{txt:i.fileName}})],1),e("div",[e("span",{staticStyle:{color:"#409eff","margin-right":"10px"}},[t._v(t._s(i.uploadProgress))]),e("i",{staticClass:"del_icon el-icon-close",on:{click:function(e){return t.delUploadFile(i,s)}}})])])}))],2),e("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[e("el-button",{attrs:{type:"primary"},on:{click:function(e){return t.entrustFn(!0)}}},[t._v("提 交")]),e("el-button",{on:{click:function(e){return t.entrustFn(!1)}}},[t._v("取 消")])],1)]),e("el-dialog",{staticClass:"preview_dialog",attrs:{title:"材料预览",visible:t.previewFlag,center:"","modal-append-to-body":!1,"close-on-click-modal":!1,width:"500px"},on:{"update:visible":function(e){t.previewFlag=e}}},[e("div",{staticClass:"preview_content"},[e("el-row",[e("el-col",{attrs:{span:4}},[t._v("文件类型:")]),e("el-col",{attrs:{span:10,offset:1}},[t._v(t._s(t.previewData.typeName))])],1),e("el-row",[e("el-col",{attrs:{span:4}},[t._v("上传人:")]),e("el-col",{attrs:{span:10,offset:1}},[t._v(t._s(t.previewData.createBy))])],1),e("el-row",[e("el-col",{attrs:{span:4}},[t._v("上传时间:")]),e("el-col",{attrs:{span:10,offset:1}},[t._v(t._s(t.previewData.createTime))])],1)],1),t.previewFlag?e("div",{staticClass:"preview_audio"},[e("audio",{attrs:{controls:""}},[e("source",{attrs:{src:t.previewData.previewPath,type:"audio/mpeg"}}),e("source",{attrs:{src:t.previewData.previewPath,type:"audio/ogg"}}),t._v(" 您的浏览器不支持该音频格式。 ")]),e("p",{staticStyle:{display:"none"}},[t._v(t._s(t.previewData.previewPath))])]):t._e()])],1)},a=[],o=(i("0faf"),i("b3ec"),i("6fc2"),i("02f7"),i("e4c6"),i("320b"),i("08a9"),i("5966"),i("b75d"),i("f1b2")),n=i.n(o),r=i("96b4"),l={name:"CaseMateria",props:{btnMenuData:{type:Object,default:null}},data(){return{caseDetailData:{id:1},analyseStr:[],loading:!1,downloadLoading:!1,filesLengthError:!1,selectFileFlag:!1,previewFlag:!1,previewData:{},editUpload:!1,uploadFlag:!1,OSSClient:null,uploadForm:{lawPlatform:""},uploadRules:{typeCode:[{required:!0,message:"请选择文件类型",trigger:"blur"}]},baseURL:"",unloaderHeader:{token:""},uploadCaseFileForm:{caseId:"",files:[]},fileList:[],materialTable:[],materialForm:{page:1,size:10,total:0},caseFileTypeOptions:[],caseFileTypeObj:{1:"沟通记录",2:"投诉通知书",3:"监管报告",99:"其他"},audioTypeList:["mp3","mp4","wav","wma","aac","flac","ogg"],fileTypeList:["tiff","jfif","bmp","webp","gif","svg","jpg","svgz","png","jpeg","ico","xbm","dib","pjp","apng","tif","pjpeg","avif"]}},mounted(){this.initOSSClient(),this.getMaterialType()},methods:{initOSSClient(){this.instance.get("/aliyunoss/access",{params:{}}).then(t=>{let e=t.data;1==e.code?this.OSSClient=new n.a({accessKeyId:e.data.accessKeyId,accessKeySecret:e.data.accessKeySecret,stsToken:e.data.securityToken,region:e.data.region,bucket:e.data.bucket}):console.log("oss初始化失败,正在重试!")}).catch(t=>{console.log("oss初始化失败-"),console.log(t)})},previewFile(t,e){this.previewData=t,-1!=this.fileTypeList.indexOf(t.fileExtension)?this.$refs["elImage"+e].clickHandler():"pdf"==t.fileExtension?this.openFileInNewTab(this.getOssFilePath(t.ossPath)):-1!=this.audioTypeList.indexOf(t.fileExtension)?this.previewFlag=!0:console.log(t.fileExtension)},getMaterialType(){this.instance.get("/complaintMaterial/getMaterialType",{params:{}}).then(t=>{let e=t.data;1==e.code&&(this.caseFileTypeOptions=e.data)})},openFileInNewTab(t){var e=document.createElement("a");e.href=t,e.target="_blank",e.click()},handleExceed(t,e){this.$message.warning(`当前限制选择 10 个文件,本次选择了 ${t.length} 个文件,共选择了 ${t.length+e.length} 个文件`)},checkUploadFileLength(){this.selectFileFlag=this.uploadCaseFileForm.files.length>=10},downloadCaseFile(){this.downloadLoading=!0,this.instance({method:"post",url:"/complaintInfo/downloadMaterial",data:{complaintId:this.caseDetailData.id},responseType:"blob",headers:{}}).then(t=>{this.downloadLoading=!1;let e=window.URL.createObjectURL(new Blob([t.data])),i=document.createElement("a");i.style.display="none",i.href=e,i.setAttribute("download",decodeURIComponent(t.headers.filename)),document.body.appendChild(i),i.click()})},editUploadFn(t){let e=JSON.parse(JSON.stringify(this.materialTable));this.tmpTableData=JSON.parse(JSON.stringify(this.materialTable)),t?(e.forEach((t,e)=>{t.loading=!1,t.edit=!0,t.typeCode=t.typeCode}),this.materialTable=e,this.editUpload=!0):(this.getCaseDetail(),this.editCaseFileForm={caseId:"",deleteFiles:[],files:[]},e.forEach((t,e)=>{t.loading=!1,t.edit=!1}),this.materialTable=e,this.editUpload=!1)},getCaseDetail(){this.$emit("getCaseDetail")},showUpload(){this.uploadFlag=!0,this.uploadCaseFileForm={caseId:"",files:[]},this.uploadForm={typeCode:"",lawPlatform:""},this.fileList=[],this.addAnalyseStrFn("点击上传 按钮")},ossUpload(t,e){let i=this,s=t.file,a="upload-file",o=(location.protocol,s.name.split("."));if(o=o[o.length-1],s.name.length>55)return void this.$message.error("文件名过长,请修改后重试!");let n=null;this.addAnalyseStrFn("开始读取文件");const l=new FileReader;l.readAsDataURL(s),l.onloadend=()=>{n=l.result,i.addAnalyseStrFn("读取文件成功")},a="complaint/"+this.caseDetailData.id+"/"+Object(r["a"])()+"."+o,a&&this.addAnalyseStrFn("生成文件存储地址成功"),a&&this.addAnalyseStrFn("文件存储地址:"+a),this.uploadCaseFileForm.files.push({uploadProgress:"0%",tmpPath:a,complaintId:i.caseDetailData.id,typeCode:i.uploadForm.typeCode,fileName:s.name,ossPath:""}),this.OSSClient&&(this.addAnalyseStrFn("上传前置条件(阿里上传对象)准备完成,开始调用文件上传方法"),this.OSSClient.multipartUpload(a,s,{progress:(t,e)=>{let s=Math.floor(100*t)+"%";this.addAnalyseStrFn("文件上传进度更新:"+s),i.uploadCaseFileForm.files.forEach(t=>{t.tmpPath==a&&(t.uploadProgress=s,i.$forceUpdate())})}}).then((function(t){i.addAnalyseStrFn("文件上传完成"),console.log(t),i.uploadCaseFileForm.files.length<10&&(i.uploadCaseFileForm.files.forEach(e=>{e.tmpPath==t.name&&(e.ossPath=t.name)}),i.filesLengthError=!1,i.checkUploadFileLength())})).catch((function(t){console.log(t)})))},handleRemove(t,e){this.fileList=e},submitUpload(){},handleFile(t,e,i){if("del"==i)this.instance.post("/complaintMaterial/delMaterial",{materialId:t.id}).then(t=>{let i=t.data;if(1==i.code){this.$message.success("删除成功!");let t=this.materialTable.splice(e,1);this.editCaseFileForm.deleteFiles.push(t[0]),this.$forceUpdate()}else this.$message.error(i.message)});else{let i=this.getOssFilePath(t.ossPath);this.downloadPdf(t,e,i)}},getOssFilePath(t){let e=this.OSSClient.signatureUrl(t);return e},downloadPdf(t,e,i){t.loading=!0;const s=document.createElement("a");fetch(i).then(t=>t.blob()).then(e=>{t.loading=!1,s.href=URL.createObjectURL(e),s.download=t.fileName,document.body.appendChild(s),s.click(),window.URL.revokeObjectURL(s.href),document.body.removeChild(s)})},handleCurrentChange(){},handleSizeChange(){},delUploadFile(t,e){this.uploadCaseFileForm.files.splice(e,1),this.fileList=this.uploadCaseFileForm.files,this.checkUploadFileLength()},entrustFn(t){if(this.addAnalyseStrFn("点击上传材料弹窗提交按钮"),t){if(this.uploadCaseFileForm.files.length<1)return void(this.filesLengthError=!0);this.addAnalyseStrFn("校验上传材料弹窗完成"),this.$refs.uploadRef.validate(t=>{t?(this.addAnalyseStrFn("上传材料弹窗校验通过"),this.uploadCaseFileForm.files.forEach(t=>{t.typeCode=this.uploadForm.typeCode,t.typeName=this.caseFileTypeObj[this.uploadForm.lawPlatform]}),this.addCaseFile()):this.addAnalyseStrFn("上传材料弹窗校验失败")})}else this.cancelUpload()},cancelUpload(){this.uploadFlag=!1,this.uploadForm.lawPlatform="",this.fileList=[],this.uploadCaseFileForm.files=[],this.checkUploadFileLength(),this.$refs.elUploadRef&&this.$refs.elUploadRef[0]?this.$refs.elUploadRef[0].clearFiles():this.$refs.elUploadRef&&this.$refs.elUploadRef.clearFiles()},addCaseFile(){this.addAnalyseStrFn("调用弹窗提交方法");let t=!0;if(this.addAnalyseStrFn("开始校验文件进度"),this.uploadCaseFileForm.files.some((e,i)=>"100%"!=e.uploadProgress&&(t=!1,!0)),this.addAnalyseStrFn("校验文件进度完成"),!t)return this.addAnalyseStrFn("校验文件失败"),void this.$message.error("还有文件未上传完成,请检查后提交!");this.addAnalyseStrFn("开始调用提交接口"),this.instance.post("/complaintMaterial/addMaterialTest",this.uploadCaseFileForm.files).then(t=>{this.addAnalyseStrFn("接口调用成功");let e=t.data;1==e.code?(this.addAnalyseStrFn("材料上传成功!"),this.$message.success("材料上传成功!"),this.$emit("getCaseDetail"),this.cancelUpload()):(this.addAnalyseStrFn("材料上传失败!"),this.$message.error(e.message))})},initCaseMaterial(t){let e=JSON.parse(JSON.stringify(t));e.forEach((t,e)=>{t.loading=!1;let i=t.fileName.split("."),s=i[i.length-1];s=s.toLowerCase(),(99!=t.typeCode||this.fileTypeList.indexOf(s)>=0)&&(t.isPreview=!0,t.fileExtension=s,t.previewPath=this.getOssFilePath(t.ossPath))}),this.materialTable=e},addAnalyseStrFn(t){t=`${t}: ${this.getCurrentDateTime()}`,this.analyseStr.push(t)},getCurrentDateTime(){const t=new Date,e=t.getFullYear(),i=String(t.getMonth()+1).padStart(2,"0"),s=String(t.getDate()).padStart(2,"0"),a=String(t.getHours()).padStart(2,"0"),o=String(t.getMinutes()).padStart(2,"0"),n=String(t.getSeconds()).padStart(2,"0");return`${e}-${i}-${s} ${a}:${o}:${n}`}},watch:{caseDetailData:{handler(t){},immediate:!0}}},h=l,d=(i("6b0b"),i("1805")),c=Object(d["a"])(h,s,a,!1,null,"1981a3b4",null);e["default"]=c.exports},ea38:function(t,e,i){"use strict";i("5942")},eaf6:function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],class:"1"==t.echartsType?"module_wrap box_border":"module_wrap module_wrap2 box_border",attrs:{"element-loading-text":"数据加载中","element-loading-spinner":"el-icon-loading","element-loading-background":"transparent"}},[t._m(0),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.loading,expression:"!loading"}],staticStyle:{height:"100%"}},[e("div",{attrs:{id:"risk_case_bar_tag"}})])])},a=[function(){var t=this,e=t._self._c;return e("div",{staticClass:"box_title box_title_radio"},[e("span",[t._v("分包商风险案件标签排行榜")])])}],o=(i("0faf"),i("b3ec"),i("6fc2"),i("ada4")),n={name:"RiskCaseTag",props:{isCollapse:{type:Boolean,default:!0},navForm:{type:Object,default:{}},echartsType:{type:String,default:""}},watch:{isCollapse(){setTimeout(()=>{this.myChart&&this.myChart.resize()},600)},navForm:{deep:!0,handler(t){this.getData()}}},data(){return{loading:!0,topDays:[],radio:"数量",newNumber:0,xAxisData1:[],xAxisData2:[],sumSeriesData1:[],sumSeriesData2:[],numSeriesData1:[],numSeriesData2:[],option:"",myChart:null}},mounted(){this.role=localStorage.getItem("role"),window.addEventListener("resize",()=>{this.myChart&&this.myChart.resize()}),window.onresize=()=>{this.myChart&&this.myChart.resize()}},methods:{getData(){if(this.echartsType){this.loading=!0;let t=null;switch(this.echartsType){case"1":t="/large/data/screen/getSubcontractorCasesLabelTopTen";break;case"2":t="/large/data/screen/getSubcontractorCasesLabelTopTen";break;default:break}t&&this.instance({method:"post",url:t,data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(this.loading=!1,1==t.data.code){let e=t.data.data;this.loadCharts(e)}})}},radioChange(){this.option&&("数量"==this.radio?(this.option.xAxis[0].data=this.xAxisData1,this.option.series[0].data=this.numSeriesData1,this.option.series[1].data=this.numSeriesData2):(this.option.xAxis[0].data=this.xAxisData2,this.option.series[0].data=this.sumSeriesData1,this.option.series[1].data=this.sumSeriesData2),setTimeout(()=>{this.myChart.setOption(this.option)},100))},loadCharts(t){var e=document.getElementById("risk_case_bar_tag");e&&(this.myChart&&this.myChart.dispose(),this.myChart=o["init"](e,null,{renderer:"svg"}),this.xAxisData1=[],this.sumSeriesData1=[],this.sumSeriesData2=[],this.xAxisData2=[],this.numSeriesData1=[],this.numSeriesData2=[],t&&t.caseRiskNum.forEach((t,e)=>{this.xAxisData1.push(t.name),this.numSeriesData1.push(t.caseNumRatio),this.numSeriesData2.push(t.caseNum)}),t&&t.caseRiskMoney&&t.caseRiskMoney.length>0&&t.caseRiskMoney.forEach((t,e)=>{this.xAxisData2.push(t.name),this.sumSeriesData1.push(t.caseNum),this.sumSeriesData2.push(t.caseNum)}),this.option={color:["#EEEC8C","#09d5d6"],tooltip:{trigger:"axis",confine:!0,textStyle:{align:"left"}},grid:{top:"5",left:"10",right:"10",bottom:"15",containLabel:!0},legend:{name:"",data:["案件数量","赔款金额"],itemWidth:12,itemHeight:12,textStyle:{color:"#fff"},left:"center"},xAxis:[{type:"category",data:this.xAxisData1,axisPointer:{type:"shadow"},axisLabel:{showMaxLabel:!0,rotate:50,textStyle:{color:"#fff"},width:60,overflow:"truncate",ellipsis:"..."},axisTick:{alignWithLabel:!0}}],yAxis:[{type:"value",axisLabel:{showMaxLabel:!0,formatter:"{value} %",textStyle:{color:"#fff"}},splitLine:{show:!1},axisTick:{show:!1}},{type:"value",axisLabel:{showMaxLabel:!0,formatter:"{value} 万",textStyle:{color:"#fff"}},splitLine:{show:!1},axisTick:{show:!1}}],series:[{name:"风险标签案件占比",type:"bar",tooltip:{valueFormatter:function(t){return t+" %"}},data:this.numSeriesData1}]},this.myChart.setOption(this.option))}},updated(){this.myChart&&this.myChart.resize()}},r=n,l=(i("593c"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"86fabe3e",null);e["default"]=h.exports},efff:function(t,e,i){},f02d:function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],staticClass:"module_wrap box_border",attrs:{"element-loading-text":"数据加载中","element-loading-spinner":"el-icon-loading","element-loading-background":"transparent"}},[e("div",{staticClass:"box_title box_title_radio"},[e("span",[t._v("总赔款金额变换趋势")]),e("div",{staticClass:"radio_group"},[e("el-radio-group",{attrs:{size:"mini"},on:{change:t.radioChange},model:{value:t.radio,callback:function(e){t.radio=e},expression:"radio"}},[e("el-radio-button",{attrs:{label:"同比"}}),e("el-radio-button",{attrs:{label:"环比"}})],1)],1)]),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.loading,expression:"!loading"}],staticStyle:{height:"100%"}},[e("div",{attrs:{id:"all_reparations_amount_bar"}})])])},a=[],o=(i("0faf"),i("b3ec"),i("6fc2"),i("ada4")),n={name:"AllReparationsAmount",props:{isCollapse:{type:Boolean,default:!0},navForm:{type:Object,default:{}}},watch:{isCollapse(){setTimeout(()=>{this.myChart&&this.myChart.resize()},600)},navForm:{immediate:!0,deep:!0,handler(t){this.getData()}}},data(){return{topDays:[],radio:"同比",newNumber:0,xAxisData1:[],xAxisData2:[],sumSeriesData1:[],sumSeriesData2:[],ratioSeriesData1:[],ratioSeriesData2:[],option:"",myChart:"",loading:!0}},mounted(){this.role=localStorage.getItem("role"),window.addEventListener("resize",()=>{this.myChart&&setTimeout(()=>{this.myChart.resize()},500)})},methods:{getData(){this.loading=!0,this.instance({method:"post",url:"/large/data/screen/getTotalCaseRatio",data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(this.loading=!1,1==t.data.code){let e=t.data.data;this.loadCharts(e)}})},radioChange(){"同比"==this.radio?(this.option.legend.data=["总赔款金额","同比增长率"],this.option.xAxis.data=this.xAxisData1,this.option.series[0].data=this.ratioSeriesData1,this.option.series[1].data=this.ratioSeriesData2,this.option.series[1].name="同比增长率"):(this.option.legend.data=["总赔款金额","环比增长率"],this.option.xAxis.data=this.xAxisData2,this.option.series[0].data=this.sumSeriesData1,this.option.series[1].data=this.sumSeriesData2,this.option.series[1].name="环比增长率"),setTimeout(()=>{this.myChart.setOption(this.option)},100)},loadCharts(t){var e=document.getElementById("all_reparations_amount_bar");e&&(this.myChart&&this.myChart.dispose(),this.myChart=o["init"](e,null,{renderer:"svg"}),this.xAxisData1=[],this.sumSeriesData1=[],this.sumSeriesData2=[],this.xAxisData2=[],this.ratioSeriesData1=[],this.ratioSeriesData2=[],t.caseRiskMoney.forEach((t,e)=>{this.xAxisData1.push(t.name),this.sumSeriesData1.push((t.totalPayAmount/1e4).toFixed(2)),this.sumSeriesData2.push(t.caseNumRatio)}),t.caseRiskNum.forEach((t,e)=>{this.xAxisData2.push(t.name),this.ratioSeriesData1.push((t.totalPayAmount/1e4).toFixed(2)),this.ratioSeriesData2.push(t.caseNumRatio)}),this.option={color:["#96b4d8","#09d5d6"],tooltip:{trigger:"axis"},grid:{top:30,left:"10",right:"4%",bottom:"15",containLabel:!0},legend:{data:["总赔款金额","同比增长率"],itemWidth:12,itemHeight:12,textStyle:{color:"#fff"},left:"center"},xAxis:[{type:"category",data:this.xAxisData1,axisPointer:{type:"shadow"},axisLabel:{show:!1,showMaxLabel:!0,rotate:20,textStyle:{color:"#fff"}},axisTick:{show:!1}}],yAxis:[{type:"value",axisLabel:{showMaxLabel:!0,formatter:"{value} 万",textStyle:{color:"#fff"}},splitLine:{show:!1},axisTick:{show:!1}},{type:"value",axisLabel:{showMaxLabel:!0,formatter:"{value} %",textStyle:{color:"#fff"}},splitLine:{show:!1},axisTick:{show:!1}}],series:[{name:"总赔款金额",type:"bar",barWidth:"40%",tooltip:{valueFormatter:function(t){return t+" 万元"}},data:this.sumSeriesData1},{name:"同比增长率",type:"line",yAxisIndex:1,tooltip:{valueFormatter:function(t){return(t?t.toFixed(0):0)+" %"}},smooth:!0,showSymbol:!1,data:this.sumSeriesData2}]},this.myChart.setOption(this.option),this.radioChange())}},updated(){this.myChart&&this.myChart.resize()}},r=n,l=(i("9b9e"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"40bb7555",null);e["default"]=h.exports},f522:function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],class:"1"==t.echartsType?"module_wrap box_border":"module_wrap module_wrap2 box_border",attrs:{"element-loading-text":"数据加载中","element-loading-spinner":"el-icon-loading","element-loading-background":"transparent"}},[e("div",{staticClass:"box_title box_title_radio"},[e("span",[t._v("事故省风险案件"+t._s("1"==t.echartsType?"":"数量占比")+"排行榜")]),"1"==t.echartsType?e("div",{staticClass:"radio_group"},[e("span",{staticStyle:{"margin-right":"10px"}},[e("el-radio-group",{attrs:{size:"mini"},on:{change:t.radioChange},model:{value:t.radio,callback:function(e){t.radio=e},expression:"radio"}},[e("el-radio-button",{attrs:{label:"数量"}}),e("el-radio-button",{attrs:{label:"金额"}})],1)],1),e("span",[e("el-radio-group",{attrs:{size:"mini"},on:{change:t.radioChange1},model:{value:t.radio1,callback:function(e){t.radio1=e},expression:"radio1"}},[e("el-radio-button",{attrs:{label:"全国"}}),e("el-radio-button",{attrs:{label:"前15"}})],1)],1)]):t._e()]),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.loading,expression:"!loading"}],staticStyle:{height:"100%"}},["1"==t.echartsType?e("div",{attrs:{id:"case_bar"}}):e("div",{attrs:{id:"case_bar2"}})])])},a=[],o=(i("0faf"),i("b3ec"),i("6fc2"),i("e4c6"),i("320b"),i("ada4")),n={name:"ProvinceRisk",props:{isCollapse:{type:Boolean,default:!0},navForm:{type:Object,default:{}},echartsType:{type:String,default:""}},watch:{isCollapse(){setTimeout(()=>{this.myChart&&this.myChart.resize()},600)},navForm:{deep:!0,handler(t){this.getData()}}},data(){return{topDays:[],newNumber:0,myChart:null,yAxisData1:[],yAxisData2:[],sumSeriesData1:[],sumSeriesData2:[],numSeriesData1:[],numSeriesData2:[],option:"",radio:"数量",radio1:"前15",tmpCasesNumTopTen:null,loading:!0}},mounted(){this.role=localStorage.getItem("role"),window.addEventListener("resize",()=>{this.myChart&&this.myChart.resize()})},methods:{getData(){this.loading=!0;let t=null;switch(this.echartsType){case"1":t="/large/data/screen/getProvinceCasesNumTopTen";break;case"2":t="/large/data/screen/getProvinceCasesRatioTopTen";break;default:break}t&&this.instance({method:"post",url:t,data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(this.loading=!1,1==t.data.code){let e=t.data.data;this.tmpCasesNumTopTen=e,1==this.echartsType?this.loadCharts(e):this.loadCharts2(e)}})},radioChange(){this.option&&("数量"==this.radio?(this.option.yAxis.data=this.yAxisData1,this.option.series[0].data=this.numSeriesData1,this.option.series[0].name="风险案件数量"):(this.option.yAxis.data=this.yAxisData2,this.option.series[0].data=this.sumSeriesData1,this.option.series[0].name="风险案件金额"),setTimeout(()=>{this.myChart.setOption(this.option)},100))},radioChange1(){let t=JSON.parse(JSON.stringify(this.numSeriesData1)),e=JSON.parse(JSON.stringify(this.sumSeriesData1)),i=JSON.parse(JSON.stringify(this.yAxisData1)),s=JSON.parse(JSON.stringify(this.yAxisData2));"前15"==this.radio1?"数量"==this.radio?(this.option.xAxis[0].data=i.slice(0,15),this.option.yAxis.data=i.slice(0,15),this.option.series[0].data=t.slice(0,15),this.option.series[0].name="风险案件数量"):(this.option.xAxis[0].data=i.slice(0,15),this.option.yAxis.data=s.slice(0,15),this.option.series[0].data=e.slice(0,15),this.option.series[0].name="风险案件金额"):"数量"==this.radio?(this.option.xAxis[0].data=i,this.option.yAxis.data=i,this.option.series[0].data=t,this.option.series[0].name="风险案件数量"):(this.option.xAxis[0].data=i,this.option.yAxis.data=s,this.option.series[0].data=e,this.option.series[0].name="风险案件金额"),setTimeout(()=>{this.myChart.setOption(this.option)},100)},loadCharts(t){let e=this;var i=document.getElementById("case_bar");i&&(this.myChart&&this.myChart.dispose(),this.myChart=o["init"](i,null,{renderer:"svg"}),this.yAxisData1=[],this.sumSeriesData1=[],this.sumSeriesData2=[],this.yAxisData2=[],this.numSeriesData1=[],this.numSeriesData2=[],t.caseRiskNum.forEach((t,e)=>{this.yAxisData1.push(t.name),this.numSeriesData1.push(t.caseNum),this.numSeriesData2.push(t.totalCaseNum)}),t.caseRiskMoney.forEach((t,e)=>{this.yAxisData2.push(t.name),this.sumSeriesData1.push(t.amountCaseFiled),this.sumSeriesData2.push(t.totalPayAmount)}),this.option={tooltip:{trigger:"axis",confine:!0,formatter(i){let s="",a="",o="";return"数量"==e.radio?(t.caseRiskNum.forEach((t,e)=>{i[0].name==t.name&&(s=t.name,a=t.caseNum,o=t.totalCaseNum)}),s+"
风险案件数量:"+a+"
总案件数量:"+o):(t.caseRiskMoney.forEach((t,e)=>{i[0].name==t.name&&(s=t.name,a=t.amountCaseFiled,o=t.totalPayAmount)}),s+"
风险案件金额:"+a+"
总案件金额:"+o)},axisPointer:{type:"shadow"}},grid:{left:"2%",right:"4%",top:"4%",bottom:"4%",containLabel:!0},xAxis:[{type:"category",axisTick:{alignWithLabel:!0},axisLabel:{showMaxLabel:!0,rotate:40,textStyle:{color:"#fff"},width:60,overflow:"truncate",ellipsis:"..."},data:this.yAxisData1}],yAxis:[{type:"value",splitLine:{show:!1},axisLabel:{showMaxLabel:!0,textStyle:{color:"#fff"}},data:this.yAxisData1}],series:[{name:"风险案件数量",type:"bar",itemStyle:{color:"1"==this.echartsType?new o["graphic"].LinearGradient(0,0,1,0,[{offset:0,color:"#FFFFFF"},{offset:1,color:"#ED86C7"}]):new o["graphic"].LinearGradient(0,0,1,0,[{offset:0,color:"#FFFFFF"},{offset:1,color:"#A574F3"}])},stack:"total",barMaxWidth:"40%",data:this.numSeriesData1}]},this.myChart.setOption(this.option),this.radioChange1())},loadCharts2(t){var e=document.getElementById("case_bar2");e&&(this.myChart=o["init"](e,null,{renderer:"svg"}),this.yAxisData1=[],this.sumSeriesData1=[],this.sumSeriesData2=[],this.yAxisData2=[],this.numSeriesData1=[],this.numSeriesData2=[],t.caseRiskNum.forEach((t,e)=>{this.yAxisData1.push(t.name),this.numSeriesData1.push(t.caseNumRatio),this.numSeriesData2.push(t.totalCaseNum)}),this.option={tooltip:{trigger:"axis",axisPointer:{type:"shadow"}},grid:{left:"2%",right:"4%",top:"15%",bottom:"4%",containLabel:!0},xAxis:[{type:"category",axisTick:{alignWithLabel:!0},axisLabel:{showMaxLabel:!0,rotate:40,textStyle:{color:"#fff"},width:60,overflow:"truncate",ellipsis:"..."},data:this.yAxisData1}],yAxis:[{type:"value",splitLine:{show:!1},axisLabel:{showMaxLabel:!0,textStyle:{color:"#fff"},formatter:"{value} %"},data:this.yAxisData1}],series:[{name:"风险案件数量占比",type:"bar",itemStyle:{color:new o["graphic"].LinearGradient(0,0,1,0,[{offset:0,color:"#FFFFFF"},{offset:1,color:"#D473EC"}])},tooltip:{valueFormatter:function(t){return t+" %"}},stack:"total",barMaxWidth:"40%",data:this.numSeriesData1}]},this.myChart.setOption(this.option))}},updated(){this.myChart&&this.myChart.resize()}},r=n,l=(i("848b"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"3e403f86",null);e["default"]=h.exports},f678:function(t,e,i){"use strict";i("6d87")},f7e8:function(t,e,i){},f8ab:function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{staticClass:"home"},[e("div",{staticClass:"main"},[e("div",{staticClass:"search_box"},[e("div",{staticClass:"search_input"},[e("el-input",{attrs:{placeholder:"请输入案件号",clearable:""},model:{value:t.search,callback:function(e){t.search=e},expression:"search"}}),t.isValid?e("el-button",{attrs:{type:"primary"},on:{click:t.getVehicleData}},[t._v("搜索")]):t._e()],1),t._m(0),t.isValid?t._e():e("div",{staticStyle:{"margin-top":"0.3rem"}},[e("div",{staticClass:"search_input"},[e("el-input",{attrs:{placeholder:"请输入VIN码",clearable:""},model:{value:t.vin,callback:function(e){t.vin=e},expression:"vin"}}),e("el-button",{attrs:{type:"primary"},on:{click:function(e){return t.getVehicleData(2)}}},[t._v("搜索")])],1),t._m(1)])]),t.tableData.length>0?e("div",{staticClass:"result_box"},[e("p",{staticClass:"small_title"},[t._v("查询结果")]),e("div",{staticClass:"brand_box"},[e("div",{staticClass:"brand_detail"},[e("p",[t._v(t._s(t.tableData[0].amBrandName+"-"+t.tableData[0].amSeriesName))]),e("ul",[e("li",[t._v("VIN年份:"+t._s(t.tableData[0].amVinYear))]),e("li",[t._v("一级分类:"+t._s(t.tableData[0].vehCateOneNames))]),e("li",[t._v("二级分类:"+t._s(t.tableData[0].vehCateTwoNames))]),e("li",[t._v("厂商类型:"+t._s(t.tableData[0].importFlag))]),e("li",[t._v("国别:"+t._s(t.tableData[0].countriesName))]),e("li",[t._v("变速箱:"+t._s(t.tableData[0].gearboxType))]),e("li",[t._v("排量:"+t._s(t.tableData[0].engineDesc))]),e("li",[t._v("驱动形式:"+t._s(t.tableData[0].drivenType))])])])]),e("el-table",{staticStyle:{width:"100%"},attrs:{data:t.tableData,size:"small","empty-text":"暂无数据"},on:{"row-click":t.clickRow}},[e("el-table-column",{attrs:{align:"center",prop:"amVehicleName",label:"销售车型名称"}}),e("el-table-column",{attrs:{align:"center",prop:"amBrandName",label:"品牌"}}),e("el-table-column",{attrs:{align:"center",prop:"amSeriesName",label:"车系"}}),e("el-table-column",{attrs:{align:"center",prop:"drivenType",label:"驱动形式"}}),e("el-table-column",{attrs:{align:"center",label:"厂家指导价"},scopedSlots:t._u([{key:"default",fn:function(i){return[e("div",[t._v(t._s(i.row.price)+"元")])]}}],null,!1,3084909748)})],1)],1):e("div",{staticClass:"empty_box"},[t._m(2),e("p",[t._v("请输入案件号")])])]),e("el-dialog",{attrs:{visible:t.modalVisible,"modal-append-to-body":!1,"close-on-click-modal":!1,"before-close":t.beforeClose,title:"请选择维修渠道",width:"5.4rem",center:"",top:"25vh"},on:{"update:visible":function(e){t.modalVisible=e}}},[e("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[e("el-button",{attrs:{type:"primary"},on:{click:function(e){return t.handleDialogBtn(1)}}},[t._v("修理厂维修")]),e("el-button",{attrs:{type:"primary"},on:{click:function(e){return t.handleDialogBtn(2)}}},[t._v("4S店维修")])],1)])],1)},a=[function(){var t=this,e=t._self._c;return e("div",{staticClass:"demo_num"},[e("div",[e("img",{attrs:{src:i("8524")}})]),e("span",[t._v("示例案件号:812020080703202208051000193")])])},function(){var t=this,e=t._self._c;return e("div",{staticClass:"demo_num"},[e("div",[e("img",{attrs:{src:i("8524")}})]),e("span",[t._v("示例VIN码:LGBH12E20HY420076")])])},function(){var t=this,e=t._self._c;return e("div",{staticClass:"empty_img"},[e("img",{attrs:{src:i("d188")}})])}],o=(i("0faf"),i("e4c6"),i("320b"),{name:"carDamage",components:{},data(){return{caseNo:"",iframeSrc:"",isValid:!0,modalVisible:!1,checkedRow:{},tableData:[],jobNo:"",role:"",search:"",vin:""}},methods:{getVehicleData(t){return this.search?2!=t||this.vin?(this.tableData=[],void this.instance({method:"post",url:"/easyepc/analysisVinByCaseNo",data:{searchWord:this.search,jobNo:this.jobNo,role:this.role,vin:this.vin},headers:{}}).then(t=>{1==t.data.code?this.tableData=t.data.data:0==t.data.code?this.$message.error(t.data.message):2==t.data.code&&(this.$message.error(t.data.message),this.isValid=!1)})):(this.$message.error("抱歉,请输入VIN码!"),!1):(this.$message.error("抱歉,请输入案件号!"),!1)},clickRow(t){1==t.reportedOrNot&&this.$notify({title:"警告",message:"当前车辆已被报价",duration:0,type:"warning"}),this.modalVisible=!0,this.checkedRow=t},beforeClose(){this.modalVisible=!1,this.$notify.closeAll()},handleDialogBtn(t){this.modalVisible=!1,this.$notify.closeAll(),localStorage.setItem("vehicleDetail",JSON.stringify(this.checkedRow)),this.$router.push({path:"/calculatorTool/carDamageDetail",query:{vid:this.checkedRow.amVehicleId,caseNo:this.search,type:t,jobNo:this.jobNo}})}},mounted(){this.caseNo=this.$route.query.caseNo,this.caseNo&&(this.search=this.caseNo,this.getVehicleData());var t=localStorage.getItem("userInfo");t&&(t=JSON.parse(t),this.jobNo=t.jobNo,this.role=t.role);let e=this.$route.query.vid;e&&(this.search=e,this.getVehicleData())}}),n=o,r=(i("0a11"),i("1805")),l=Object(r["a"])(n,s,a,!1,null,"beb15554",null);e["default"]=l.exports},f9a0:function(t,e,i){"use strict";i("5b8b")},fc27:function(t,e,i){t.exports=i.p+"img/wraning_icon.b1a63a56.png"},fe11:function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],staticClass:"module_wrap box_border",attrs:{"element-loading-text":"数据加载中","element-loading-spinner":"el-icon-loading","element-loading-background":"transparent"}},[e("div",{staticClass:"box_title"},[t._v("公估公司接案量统计")]),e("div",{directives:[{name:"show",rawName:"v-show",value:!t.loading,expression:"!loading"}],staticStyle:{height:"100%"}},[e("div",{attrs:{id:"rate_pie"}}),t.tableData.length>0?e("div",{staticClass:"tables_box"},[e("el-table",{attrs:{data:[t.tableData[0]],"max-height":"200"}},t._l(t.tableData,(function(i,s){return e("el-table-column",{key:s,attrs:{label:i.assessor,width:"全国"==t.province?"":"100"},scopedSlots:t._u([{key:"default",fn:function(s){return[t._e(),e("p",[t._v(t._s(i.assessorRatio?i.assessorRatio:"0")+" %")]),e("p",[t._v(t._s(i.assessorCaseNum?i.assessorCaseNum:"0")+" 件")])]}}],null,!0)})})),1)],1):t._e()])])},a=[],o=(i("0faf"),i("b3ec"),i("6fc2"),i("ada4")),n={name:"CaseRate",props:{isCollapse:{type:Boolean,default:!0},navForm:{type:Object,default:{}}},watch:{isCollapse(){setTimeout(()=>{this.myChart&&this.myChart.resize()},600)},navForm:{deep:!0,handler(t){this.province=t.accidentProvince,this.getData()}}},data(){return{topDays:[],newNumber:0,myChart:"",tableData:[],loading:!0,province:""}},mounted(){this.role=localStorage.getItem("role"),this.getData(),window.addEventListener("resize",()=>{this.myChart&&setTimeout(()=>{this.myChart.resize()},500)})},methods:{getData(){this.loading=!0,this.instance({method:"post",url:"/large/data/screen/meituanAssessorCaseNum",data:this.navForm,headers:{"Content-Type":"application/json;charset=UTF-8"}}).then(t=>{if(this.loading=!1,1==t.data.code){let e=t.data.data;e.length>0&&this.loadCharts(e)}})},loadCharts(t){var e=document.getElementById("rate_pie");if(!e)return;this.myChart&&this.myChart.dispose(),this.myChart=o["init"](e,null,{renderer:"svg"});let i=[],s=[];t.forEach((t,e)=>{i.push(t.assessor),s.push(t.assessorRatio)}),this.tableData=t;var a={tooltip:{trigger:"axis",axisPointer:{type:"none"},formatter:function(e){let i=e[0].dataIndex;return e[0].name+"
接案率:"+e[0].value+"%
接案案件量:"+t[i].assessorCaseNum+"件"}},xAxis:{data:i,axisTick:{show:!1},axisLine:{show:!1},axisLabel:{color:"#fff",rotate:30}},yAxis:{splitLine:{show:!1},axisTick:{show:!1},axisLine:{show:!1},axisLabel:{show:!0,color:"#fff",formatter:"{value} %"}},grid:{top:"20",bottom:"0",left:"10",right:"10",containLabel:!0},color:["#5FB3D7"],series:[{name:"hill",type:"pictorialBar",barCategoryGap:"-40%",label:{position:"top",color:"#fff",formatter:"{c}%"},symbol:"path://M0,10 L10,10 C5.5,10 5.5,5 5,0 C4.5,5 4.5,10 0,10 z",itemStyle:{},barWidth:"80%",emphasis:{itemStyle:{opacity:1}},data:s,z:10}]};this.myChart.setOption(a)}},updated(){this.myChart&&this.myChart.resize()}},r=n,l=(i("9a65"),i("1805")),h=Object(l["a"])(r,s,a,!1,null,"517a1927",null);e["default"]=h.exports},ff74:function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{staticClass:"content"},[e("el-radio-group",{staticClass:"map_tab",staticStyle:{"margin-bottom":"30px"},on:{change:t.tabsChange},model:{value:t.radio,callback:function(e){t.radio=e},expression:"radio"}},[e("el-radio-button",{attrs:{label:"1"}},[t._v("风险案件分布")]),e("el-radio-button",{attrs:{label:"2"}},[t._v("报案时效性分布")])],1),e("div",{attrs:{id:"container3",tabindex:"0"}})],1)},a=[],o=(i("0faf"),i("b3ec"),i("6fc2"),i("2130"),i("e4c6"),i("320b"),i("ada4")),n=i("6032"),r={name:"ChinaMap3",props:{isCollapse:{type:Boolean,default:!0},navForm:{type:Object,default:{}}},watch:{isCollapse:{handler(t){t&&this.listenResize(),this.initChartsMap()},immediate:!0},navForm:{deep:!0,handler(t){this.getData()}}},data(){return{map:"",loca:"",chart:null,origin:"",checkedPoint:[],mapData:{},radio:"1",tabsActive:1,myChartMap:"",provinceCount:[],realTimeData:[],cityCount:[],nowVehicleData:{}}},mounted(){this,this.origin=window.location.origin,this.role=localStorage.getItem("role"),this.userInfo=JSON.parse(localStorage.getItem("userInfo")),window.addEventListener("resize",this.listenResize)},beforeDestroy(){window.removeEventListener("resize",this.listenResize)},methods:{listenResize(){this.myChartMap&&setTimeout(()=>{this.myChartMap.resize()},600)},linkVehicleMap(t){if(this.userInfo.batchId||0==this.role)return!1;let e=this.$router.resolve({path:"/VehicleMap",query:{deviceNumber:t.deviceNumber,startTime:t.tripStartTime,endTime:t.tripEndTime}});window.open(e.href,"_blank")},getLatestTrip(){this.realTimeData=[],this.instance.get("/homepage/getLatestTrip",{params:{companyId:this.userInfo.company}}).then(t=>{1==t.data.code&&this.initRouteData(t.data.data)})},getLatestTripByProvince(t){this.realTimeData=[],this.instance.get("/homepage/getLatestTripByProvince",{params:{companyId:this.userInfo.company,provinceName:t}}).then(t=>{1==t.data.code&&this.initRouteData(t.data.data)})},initRouteData(t){var e=t.length;if(e>0){for(var i=0;i{this.mapData=t.data.data;var e=[],i=[];this.mapData.cityDatas.length>0&&(this.mapData.cityDatas.forEach((t,i)=>{var s={name:t.cityName,parent:t.provinceName,value:t.caseNum,durationTime:t.durationTime,level:1,avgRiskValue:t.avgRiskValue,insuredNo:t.insuredNo,riskPointsNo:t.riskPointsNo};e.push(s)}),this.cityCount=e),this.mapData.provinceDatas.length>0&&(this.mapData.provinceDatas.forEach((t,e)=>{var s={name:t.cityName,parent:t.provinceName,value:t.caseNum,level:1,durationTime:t.durationTime,avgRiskValue:t.avgRiskValue,insuredNo:t.insuredNo,riskPointsNo:t.riskPointsNo};i.push(s)}),this.provinceCount=i),this.initChartsMap()})},createMap(t,e){var i=this;o["extendsMap"]=function(t,e){i.chart=o["init"](document.getElementById(t),null,{renderer:"svg"});var s={},a={mapName:"china",goDown:!1,bgColor:"#404a59",activeArea:[],data:[],callback:function(t,e,i){}};e&&(e=o["util"].extend(a,e));var r=[e.mapName],l=0,h={leftPlus:115,leftCur:150,left:198,top:240},d=[[0,0],[8,11],[0,22]],c={font:'18px "Microsoft YaHei", sans-serif',textColor:"#30FBFE",lineColor:"#30FBFE"},u={resetOption:function(t,i,s){var a=this.createBreadcrumb(s),o=r.indexOf(s),n=i.graphic.length;if(o<0){if(i.graphic.push(a),i.graphic[0].children[0].shape.x2=145,i.graphic[0].children[1].shape.x2=145,i.graphic.length>2){for(var d,c=[],p=0;pe.name==t.name);return-1!=o?"城市:"+a[o].name+"
案件数:"+a[o].value+"万件
案均时差:"+a[o].durationTime+"分":t.name}return 1==i.radio?"城市:"+t.data.name+"
案件数:"+t.data.num+"件":"城市:"+t.data.name+"
案均时差:"+t.data.durationTime+"天"}},label:{show:!0,color:"#fff"},itemStyle:{borderColor:"#2ff7fb",borderWidth:1,opacity:1,areaColor:{type:"radial",x:.5,y:.5,r:.8,colorStops:[{offset:0,color:"RGBA(0, 36, 109, 0.5)"},{offset:1,color:"RGBA(0, 36, 109, 0.7)"}],globalCoord:!1}},emphasis:{itemStyle:{areaColor:"rgba(0, 69, 109, 0.8)",borderWidth:0},label:{color:"#fff"}}},series:[{type:"effectScatter",coordinateSystem:"geo",showEffectOn:"emphasis",rippleEffect:{period:5,scale:2.5},itemStyle:{opacity:.9,color:"#E29550",shadowBlur:10,shadowColor:"#333"},symbolSize(t,i){var s=t[2],a=e.data[0].value,o=6;return o=s<.4*a?6:s<.7*a?8:10,o},zlevel:1,data:u.initSeriesData(e.data)}]};return i.chart.setOption(p),i.chart.on("click",(function(t){var a="china"==r[l]?"中国":r[l],h=this;if(e.goDown&&t.name!==a&&n["a"][t.name]){var d=n["a"][t.name];i.$axios.get(i.origin+"/"+d).then(e=>{s=e.data,o["registerMap"](t.name,s),u.resetOption(h,p,t.name)})}"中国"!=a&&u.resetOption(i.chart,p,"china")})),i.chart.setMap=function(t){var e=this;t.indexOf("市")<0&&(t+="市");var a=n["a"][t];if(a){var r=a;i.$axios.get(r).then(i=>{s=i.data,o["registerMap"](t,s),u.resetOption(e,p,t)})}},i.chart},i.myChartMap=o["extendsMap"](t,e)},initChartsMap(){var t=this;t.$axios.get("/map/data-china.json").then(e=>{o["registerMap"]("china",e.data),t.chart&&t.chart.dispose(),t.createMap("container3",{bgColor:"transparent",mapName:"china",goDown:!1,callback:function(t,e,i){},data:t.cityCount})})},appendScript(t){var e=document.createElement("script");e.charset="utf-8",e.src=t,document.head.appendChild(e)}}},l=r,h=(i("385f"),i("1805")),d=Object(h["a"])(l,s,a,!1,null,"78a29d92",null);e["default"]=d.exports},ffb0:function(t,e,i){(function(t){ /** * vis-network * https://visjs.github.io/vis-network/ * * A dynamic, browser-based visualization library. * * @version 9.1.13 * @date 2025-06-28T12:44:34.651Z * * @copyright (c) 2011-2017 Almende B.V, http://almende.com * @copyright (c) 2017-2019 visjs contributors, https://github.com/visjs * * @license * vis.js is dual licensed under both * * 1. The Apache 2.0 License * http://www.apache.org/licenses/LICENSE-2.0 * * and * * 2. The MIT License * http://opensource.org/licenses/MIT * * vis.js may be distributed under either license. */ !function(t,i){i(e)}(0,(function(e){"use strict";var i="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof t?t:"undefined"!=typeof self?self:{};function s(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var a=function(t){return t&&t.Math===Math&&t},o=a("object"==typeof globalThis&&globalThis)||a("object"==typeof window&&window)||a("object"==typeof self&&self)||a("object"==typeof i&&i)||function(){return this}()||i||Function("return this")(),n=function(t){try{return!!t()}catch(t){return!0}},r=!n((function(){var t=function(){}.bind();return"function"!=typeof t||t.hasOwnProperty("prototype")})),l=r,h=Function.prototype,d=h.apply,c=h.call,u="object"==typeof Reflect&&Reflect.apply||(l?c.bind(d):function(){return c.apply(d,arguments)}),p=r,m=Function.prototype,g=m.call,f=p&&m.bind.bind(g,g),v=p?f:function(t){return function(){return g.apply(t,arguments)}},y=v,b=y({}.toString),w=y("".slice),_=function(t){return w(b(t),8,-1)},x=_,C=v,D=function(t){if("Function"===x(t))return C(t)},k="object"==typeof document&&document.all,T={all:k,IS_HTMLDDA:void 0===k&&void 0!==k},S=T.all,A=T.IS_HTMLDDA?function(t){return"function"==typeof t||t===S}:function(t){return"function"==typeof t},E={},O=!n((function(){return 7!==Object.defineProperty({},1,{get:function(){return 7}})[1]})),F=r,N=Function.prototype.call,I=F?N.bind(N):function(){return N.apply(N,arguments)},R={},P={}.propertyIsEnumerable,L=Object.getOwnPropertyDescriptor,M=L&&!P.call({1:2},1);R.f=M?function(t){var e=L(this,t);return!!e&&e.enumerable}:P;var z,B,j=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}},V=n,H=_,W=Object,U=v("".split),$=V((function(){return!W("z").propertyIsEnumerable(0)}))?function(t){return"String"===H(t)?U(t,""):W(t)}:W,q=function(t){return null==t},Y=q,G=TypeError,X=function(t){if(Y(t))throw new G("Can't call method on "+t);return t},K=$,J=X,Q=function(t){return K(J(t))},Z=A,tt=T.all,et=T.IS_HTMLDDA?function(t){return"object"==typeof t?null!==t:Z(t)||t===tt}:function(t){return"object"==typeof t?null!==t:Z(t)},it={},st=it,at=o,ot=A,nt=function(t){return ot(t)?t:void 0},rt=function(t,e){return arguments.length<2?nt(st[t])||nt(at[t]):st[t]&&st[t][e]||at[t]&&at[t][e]},lt=v({}.isPrototypeOf),ht="undefined"!=typeof navigator&&String(navigator.userAgent)||"",dt=o,ct=ht,ut=dt.process,pt=dt.Deno,mt=ut&&ut.versions||pt&&pt.version,gt=mt&&mt.v8;gt&&(B=(z=gt.split("."))[0]>0&&z[0]<4?1:+(z[0]+z[1])),!B&&ct&&(!(z=ct.match(/Edge\/(\d+)/))||z[1]>=74)&&(z=ct.match(/Chrome\/(\d+)/))&&(B=+z[1]);var ft=B,vt=ft,yt=n,bt=o.String,wt=!!Object.getOwnPropertySymbols&&!yt((function(){var t=Symbol("symbol detection");return!bt(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&vt&&vt<41})),_t=wt&&!Symbol.sham&&"symbol"==typeof Symbol.iterator,xt=rt,Ct=A,Dt=lt,kt=Object,Tt=_t?function(t){return"symbol"==typeof t}:function(t){var e=xt("Symbol");return Ct(e)&&Dt(e.prototype,kt(t))},St=String,At=function(t){try{return St(t)}catch(t){return"Object"}},Et=A,Ot=At,Ft=TypeError,Nt=function(t){if(Et(t))return t;throw new Ft(Ot(t)+" is not a function")},It=Nt,Rt=q,Pt=function(t,e){var i=t[e];return Rt(i)?void 0:It(i)},Lt=I,Mt=A,zt=et,Bt=TypeError,jt={exports:{}},Vt=o,Ht=Object.defineProperty,Wt=function(t,e){try{Ht(Vt,t,{value:e,configurable:!0,writable:!0})}catch(s){Vt[t]=e}return e},Ut="__core-js_shared__",$t=o[Ut]||Wt(Ut,{}),qt=$t;(jt.exports=function(t,e){return qt[t]||(qt[t]=void 0!==e?e:{})})("versions",[]).push({version:"3.33.0",mode:"pure",copyright:"© 2014-2023 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.33.0/LICENSE",source:"https://github.com/zloirock/core-js"});var Yt=jt.exports,Gt=X,Xt=Object,Kt=function(t){return Xt(Gt(t))},Jt=Kt,Qt=v({}.hasOwnProperty),Zt=Object.hasOwn||function(t,e){return Qt(Jt(t),e)},te=v,ee=0,ie=Math.random(),se=te(1..toString),ae=function(t){return"Symbol("+(void 0===t?"":t)+")_"+se(++ee+ie,36)},oe=Yt,ne=Zt,re=ae,le=wt,he=_t,de=o.Symbol,ce=oe("wks"),ue=he?de.for||de:de&&de.withoutSetter||re,pe=function(t){return ne(ce,t)||(ce[t]=le&&ne(de,t)?de[t]:ue("Symbol."+t)),ce[t]},me=I,ge=et,fe=Tt,ve=Pt,ye=function(t,e){var i,s;if("string"===e&&Mt(i=t.toString)&&!zt(s=Lt(i,t)))return s;if(Mt(i=t.valueOf)&&!zt(s=Lt(i,t)))return s;if("string"!==e&&Mt(i=t.toString)&&!zt(s=Lt(i,t)))return s;throw new Bt("Can't convert object to primitive value")},be=TypeError,we=pe("toPrimitive"),_e=function(t,e){if(!ge(t)||fe(t))return t;var i,s=ve(t,we);if(s){if(void 0===e&&(e="default"),i=me(s,t,e),!ge(i)||fe(i))return i;throw new be("Can't convert object to primitive value")}return void 0===e&&(e="number"),ye(t,e)},xe=Tt,Ce=function(t){var e=_e(t,"string");return xe(e)?e:e+""},De=et,ke=o.document,Te=De(ke)&&De(ke.createElement),Se=function(t){return Te?ke.createElement(t):{}},Ae=Se,Ee=!O&&!n((function(){return 7!==Object.defineProperty(Ae("div"),"a",{get:function(){return 7}}).a})),Oe=O,Fe=I,Ne=R,Ie=j,Re=Q,Pe=Ce,Le=Zt,Me=Ee,ze=Object.getOwnPropertyDescriptor;E.f=Oe?ze:function(t,e){if(t=Re(t),e=Pe(e),Me)try{return ze(t,e)}catch(t){}if(Le(t,e))return Ie(!Fe(Ne.f,t,e),t[e])};var Be=n,je=A,Ve=/#|\.prototype\./,He=function(t,e){var i=Ue[We(t)];return i===qe||i!==$e&&(je(e)?Be(e):!!e)},We=He.normalize=function(t){return String(t).replace(Ve,".").toLowerCase()},Ue=He.data={},$e=He.NATIVE="N",qe=He.POLYFILL="P",Ye=He,Ge=Nt,Xe=r,Ke=D(D.bind),Je=function(t,e){return Ge(t),void 0===e?t:Xe?Ke(t,e):function(){return t.apply(e,arguments)}},Qe={},Ze=O&&n((function(){return 42!==Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype})),ti=et,ei=String,ii=TypeError,si=function(t){if(ti(t))return t;throw new ii(ei(t)+" is not an object")},ai=O,oi=Ee,ni=Ze,ri=si,li=Ce,hi=TypeError,di=Object.defineProperty,ci=Object.getOwnPropertyDescriptor,ui="enumerable",pi="configurable",mi="writable";Qe.f=ai?ni?function(t,e,i){if(ri(t),e=li(e),ri(i),"function"==typeof t&&"prototype"===e&&"value"in i&&mi in i&&!i[mi]){var s=ci(t,e);s&&s[mi]&&(t[e]=i.value,i={configurable:pi in i?i[pi]:s[pi],enumerable:ui in i?i[ui]:s[ui],writable:!1})}return di(t,e,i)}:di:function(t,e,i){if(ri(t),e=li(e),ri(i),oi)try{return di(t,e,i)}catch(t){}if("get"in i||"set"in i)throw new hi("Accessors not supported");return"value"in i&&(t[e]=i.value),t};var gi=Qe,fi=j,vi=O?function(t,e,i){return gi.f(t,e,fi(1,i))}:function(t,e,i){return t[e]=i,t},yi=o,bi=u,wi=D,_i=A,xi=E.f,Ci=Ye,Di=it,ki=Je,Ti=vi,Si=Zt,Ai=function(t){var e=function(i,s,a){if(this instanceof e){switch(arguments.length){case 0:return new t;case 1:return new t(i);case 2:return new t(i,s)}return new t(i,s,a)}return bi(t,this,arguments)};return e.prototype=t.prototype,e},Ei=function(t,e){var i,s,a,o,n,r,l,h,d,c=t.target,u=t.global,p=t.stat,m=t.proto,g=u?yi:p?yi[c]:(yi[c]||{}).prototype,f=u?Di:Di[c]||Ti(Di,c,{})[c],v=f.prototype;for(o in e)s=!(i=Ci(u?o:c+(p?".":"#")+o,t.forced))&&g&&Si(g,o),r=f[o],s&&(l=t.dontCallGetSet?(d=xi(g,o))&&d.value:g[o]),n=s&&l?l:e[o],s&&typeof r==typeof n||(h=t.bind&&s?ki(n,yi):t.wrap&&s?Ai(n):m&&_i(n)?wi(n):n,(t.sham||n&&n.sham||r&&r.sham)&&Ti(h,"sham",!0),Ti(f,o,h),m&&(Si(Di,a=c+"Prototype")||Ti(Di,a,{}),Ti(Di[a],o,n),t.real&&v&&(i||!v[o])&&Ti(v,o,n)))},Oi=Math.ceil,Fi=Math.floor,Ni=Math.trunc||function(t){var e=+t;return(e>0?Fi:Oi)(e)},Ii=function(t){var e=+t;return e!=e||0===e?0:Ni(e)},Ri=Ii,Pi=Math.max,Li=Math.min,Mi=function(t,e){var i=Ri(t);return i<0?Pi(i+e,0):Li(i,e)},zi=Ii,Bi=Math.min,ji=function(t){return t>0?Bi(zi(t),9007199254740991):0},Vi=function(t){return ji(t.length)},Hi=Q,Wi=Mi,Ui=Vi,$i=function(t){return function(e,i,s){var a,o=Hi(e),n=Ui(o),r=Wi(s,n);if(t&&i!=i){for(;n>r;)if((a=o[r++])!=a)return!0}else for(;n>r;r++)if((t||r in o)&&o[r]===i)return t||r||0;return!t&&-1}},qi={includes:$i(!0),indexOf:$i(!1)},Yi={},Gi=Zt,Xi=Q,Ki=qi.indexOf,Ji=Yi,Qi=v([].push),Zi=function(t,e){var i,s=Xi(t),a=0,o=[];for(i in s)!Gi(Ji,i)&&Gi(s,i)&&Qi(o,i);for(;e.length>a;)Gi(s,i=e[a++])&&(~Ki(o,i)||Qi(o,i));return o},ts=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],es=Zi,is=ts,ss=Object.keys||function(t){return es(t,is)},as={};as.f=Object.getOwnPropertySymbols;var os=O,ns=v,rs=I,ls=n,hs=ss,ds=as,cs=R,us=Kt,ps=$,ms=Object.assign,gs=Object.defineProperty,fs=ns([].concat),vs=!ms||ls((function(){if(os&&1!==ms({b:1},ms(gs({},"a",{enumerable:!0,get:function(){gs(this,"b",{value:3,enumerable:!1})}}),{b:2})).b)return!0;var t={},e={},i=Symbol("assign detection"),s="abcdefghijklmnopqrst";return t[i]=7,s.split("").forEach((function(t){e[t]=t})),7!==ms({},t)[i]||hs(ms({},e)).join("")!==s}))?function(t,e){for(var i=us(t),s=arguments.length,a=1,o=ds.f,n=cs.f;s>a;)for(var r,l=ps(arguments[a++]),h=o?fs(hs(l),o(l)):hs(l),d=h.length,c=0;d>c;)r=h[c++],os&&!rs(n,l,r)||(i[r]=l[r]);return i}:ms,ys=vs;Ei({target:"Object",stat:!0,arity:2,forced:Object.assign!==ys},{assign:ys});var bs=s(it.Object.assign),ws=v([].slice),_s=v,xs=Nt,Cs=et,Ds=Zt,ks=ws,Ts=r,Ss=Function,As=_s([].concat),Es=_s([].join),Os={},Fs=Ts?Ss.bind:function(t){var e=xs(this),i=e.prototype,s=ks(arguments,1),a=function(){var i=As(s,ks(arguments));return this instanceof a?function(t,e,i){if(!Ds(Os,e)){for(var s=[],a=0;a=.1;)m=+o[c++%n],m>d&&(m=d),p=Math.sqrt(m*m/(1+h*h)),p=r<0?-p:p,e+=p,i+=h*p,!0===u?t.lineTo(e,i):t.moveTo(e,i),d-=m,u=!u}const qs={circle:Vs,dashedLine:$s,database:Us,diamond:function(t,e,i,s){t.beginPath(),t.lineTo(e,i+s),t.lineTo(e+s,i),t.lineTo(e,i-s),t.lineTo(e-s,i),t.closePath()},ellipse:Ws,ellipse_vis:Ws,hexagon:function(t,e,i,s){t.beginPath();const a=2*Math.PI/6;t.moveTo(e+s,i);for(let o=1;o<6;o++)t.lineTo(e+s*Math.cos(a*o),i+s*Math.sin(a*o));t.closePath()},roundRect:Hs,square:function(t,e,i,s){t.beginPath(),t.rect(e-s,i-s,2*s,2*s),t.closePath()},star:function(t,e,i,s){t.beginPath(),i+=.1*(s*=.82);for(let a=0;a<10;a++){const o=a%2==0?1.3*s:.5*s;t.lineTo(e+o*Math.sin(2*a*Math.PI/10),i-o*Math.cos(2*a*Math.PI/10))}t.closePath()},triangle:function(t,e,i,s){t.beginPath(),i+=.275*(s*=1.15);const a=2*s,o=a/2,n=Math.sqrt(3)/6*a,r=Math.sqrt(a*a-o*o);t.moveTo(e,i-(r-n)),t.lineTo(e+o,i+n),t.lineTo(e-o,i+n),t.lineTo(e,i-(r-n)),t.closePath()},triangleDown:function(t,e,i,s){t.beginPath(),i-=.275*(s*=1.15);const a=2*s,o=a/2,n=Math.sqrt(3)/6*a,r=Math.sqrt(a*a-o*o);t.moveTo(e,i+(r-n)),t.lineTo(e+o,i-n),t.lineTo(e-o,i-n),t.lineTo(e,i+(r-n)),t.closePath()}};var Ys={exports:{}};!function(t){function e(t){if(t)return function(t){for(var i in e.prototype)t[i]=e.prototype[i];return t}(t)}t.exports=e,e.prototype.on=e.prototype.addEventListener=function(t,e){return this._callbacks=this._callbacks||{},(this._callbacks["$"+t]=this._callbacks["$"+t]||[]).push(e),this},e.prototype.once=function(t,e){function i(){this.off(t,i),e.apply(this,arguments)}return i.fn=e,this.on(t,i),this},e.prototype.off=e.prototype.removeListener=e.prototype.removeAllListeners=e.prototype.removeEventListener=function(t,e){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var i,s=this._callbacks["$"+t];if(!s)return this;if(1==arguments.length)return delete this._callbacks["$"+t],this;for(var a=0;a9007199254740991)throw Js("Maximum allowed index exceeded");return t},Zs=Ce,ta=Qe,ea=j,ia=function(t,e,i){var s=Zs(e);s in t?ta.f(t,s,ea(0,i)):t[s]=i},sa={};sa[pe("toStringTag")]="z";var aa="[object z]"===String(sa),oa=aa,na=A,ra=_,la=pe("toStringTag"),ha=Object,da="Arguments"===ra(function(){return arguments}()),ca=oa?ra:function(t){var e,i,s;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(i=function(t,e){try{return t[e]}catch(t){}}(e=ha(t),la))?i:da?ra(e):"Object"===(s=ra(e))&&na(e.callee)?"Arguments":s},ua=A,pa=$t,ma=v(Function.toString);ua(pa.inspectSource)||(pa.inspectSource=function(t){return ma(t)});var ga=pa.inspectSource,fa=v,va=n,ya=A,ba=ca,wa=ga,_a=function(){},xa=[],Ca=rt("Reflect","construct"),Da=/^\s*(?:class|function)\b/,ka=fa(Da.exec),Ta=!Da.test(_a),Sa=function(t){if(!ya(t))return!1;try{return Ca(_a,xa,t),!0}catch(t){return!1}},Aa=function(t){if(!ya(t))return!1;switch(ba(t)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return Ta||!!ka(Da,wa(t))}catch(t){return!0}};Aa.sham=!0;var Ea=!Ca||va((function(){var t;return Sa(Sa.call)||!Sa(Object)||!Sa((function(){t=!0}))||t}))?Aa:Sa,Oa=Ks,Fa=Ea,Na=et,Ia=pe("species"),Ra=Array,Pa=function(t){var e;return Oa(t)&&(e=t.constructor,(Fa(e)&&(e===Ra||Oa(e.prototype))||Na(e)&&null===(e=e[Ia]))&&(e=void 0)),void 0===e?Ra:e},La=function(t,e){return new(Pa(t))(0===e?0:e)},Ma=n,za=ft,Ba=pe("species"),ja=function(t){return za>=51||!Ma((function(){var e=[];return(e.constructor={})[Ba]=function(){return{foo:1}},1!==e[t](Boolean).foo}))},Va=Ei,Ha=n,Wa=Ks,Ua=et,$a=Kt,qa=Vi,Ya=Qs,Ga=ia,Xa=La,Ka=ja,Ja=ft,Qa=pe("isConcatSpreadable"),Za=Ja>=51||!Ha((function(){var t=[];return t[Qa]=!1,t.concat()[0]!==t})),to=function(t){if(!Ua(t))return!1;var e=t[Qa];return void 0!==e?!!e:Wa(t)};Va({target:"Array",proto:!0,arity:1,forced:!Za||!Ka("concat")},{concat:function(t){var e,i,s,a,o,n=$a(this),r=Xa(n,0),l=0;for(e=-1,s=arguments.length;en;)ro.f(t,i=a[n++],s[i]);return t};var uo,po=rt("document","documentElement"),mo=ae,go=Yt("keys"),fo=function(t){return go[t]||(go[t]=mo(t))},vo=si,yo=ao,bo=ts,wo=Yi,_o=po,xo=Se,Co="prototype",Do="script",ko=fo("IE_PROTO"),To=function(){},So=function(t){return"<"+Do+">"+t+""},Ao=function(t){t.write(So("")),t.close();var e=t.parentWindow.Object;return t=null,e},Eo=function(){try{uo=new ActiveXObject("htmlfile")}catch(t){}var t,e,i;Eo="undefined"!=typeof document?document.domain&&uo?Ao(uo):(e=xo("iframe"),i="java"+Do+":",e.style.display="none",_o.appendChild(e),e.src=String(i),(t=e.contentWindow.document).open(),t.write(So("document.F=Object")),t.close(),t.F):Ao(uo);for(var s=bo.length;s--;)delete Eo[Co][bo[s]];return Eo()};wo[ko]=!0;var Oo=Object.create||function(t,e){var i;return null!==t?(To[Co]=vo(t),i=new To,To[Co]=null,i[ko]=t):i=Eo(),void 0===e?i:yo.f(i,e)},Fo={},No=Zi,Io=ts.concat("length","prototype");Fo.f=Object.getOwnPropertyNames||function(t){return No(t,Io)};var Ro={},Po=Mi,Lo=Vi,Mo=ia,zo=Array,Bo=Math.max,jo=function(t,e,i){for(var s=Lo(t),a=Po(e,s),o=Po(void 0===i?s:i,s),n=zo(Bo(o-a,0)),r=0;ay;y++)if((r||y in g)&&(p=f(u=g[y],y,m),t))if(e)w[y]=p;else if(p)switch(t){case 3:return!0;case 5:return u;case 6:return y;case 2:Wn(w,u)}else switch(t){case 4:return!1;case 7:Wn(w,u)}return o?-1:s||a?a:w}},$n={forEach:Un(0),map:Un(1),filter:Un(2),some:Un(3),every:Un(4),find:Un(5),findIndex:Un(6),filterReject:Un(7)},qn=Ei,Yn=o,Gn=I,Xn=v,Kn=O,Jn=wt,Qn=n,Zn=Zt,tr=lt,er=si,ir=Q,sr=Ce,ar=so,or=j,nr=Oo,rr=ss,lr=Fo,hr=Ro,dr=as,cr=E,ur=Qe,pr=ao,mr=R,gr=Yo,fr=Xo,vr=Yt,yr=Yi,br=ae,wr=pe,_r=Ko,xr=nn,Cr=cn,Dr=wn,kr=Mn,Tr=$n.forEach,Sr=fo("hidden"),Ar="Symbol",Er="prototype",Or=kr.set,Fr=kr.getterFor(Ar),Nr=Object[Er],Ir=Yn.Symbol,Rr=Ir&&Ir[Er],Pr=Yn.RangeError,Lr=Yn.TypeError,Mr=Yn.QObject,zr=cr.f,Br=ur.f,jr=hr.f,Vr=mr.f,Hr=Xn([].push),Wr=vr("symbols"),Ur=vr("op-symbols"),$r=vr("wks"),qr=!Mr||!Mr[Er]||!Mr[Er].findChild,Yr=function(t,e,i){var s=zr(Nr,e);s&&delete Nr[e],Br(t,e,i),s&&t!==Nr&&Br(Nr,e,s)},Gr=Kn&&Qn((function(){return 7!==nr(Br({},"a",{get:function(){return Br(this,"a",{value:7}).a}})).a}))?Yr:Br,Xr=function(t,e){var i=Wr[t]=nr(Rr);return Or(i,{type:Ar,tag:t,description:e}),Kn||(i.description=e),i},Kr=function(t,e,i){t===Nr&&Kr(Ur,e,i),er(t);var s=sr(e);return er(i),Zn(Wr,s)?(i.enumerable?(Zn(t,Sr)&&t[Sr][s]&&(t[Sr][s]=!1),i=nr(i,{enumerable:or(0,!1)})):(Zn(t,Sr)||Br(t,Sr,or(1,{})),t[Sr][s]=!0),Gr(t,s,i)):Br(t,s,i)},Jr=function(t,e){er(t);var i=ir(e),s=rr(i).concat(el(i));return Tr(s,(function(e){Kn&&!Gn(Qr,i,e)||Kr(t,e,i[e])})),t},Qr=function(t){var e=sr(t),i=Gn(Vr,this,e);return!(this===Nr&&Zn(Wr,e)&&!Zn(Ur,e))&&(!(i||!Zn(this,e)||!Zn(Wr,e)||Zn(this,Sr)&&this[Sr][e])||i)},Zr=function(t,e){var i=ir(t),s=sr(e);if(i!==Nr||!Zn(Wr,s)||Zn(Ur,s)){var a=zr(i,s);return!a||!Zn(Wr,s)||Zn(i,Sr)&&i[Sr][s]||(a.enumerable=!0),a}},tl=function(t){var e=jr(ir(t)),i=[];return Tr(e,(function(t){Zn(Wr,t)||Zn(yr,t)||Hr(i,t)})),i},el=function(t){var e=t===Nr,i=jr(e?Ur:ir(t)),s=[];return Tr(i,(function(t){!Zn(Wr,t)||e&&!Zn(Nr,t)||Hr(s,Wr[t])})),s};Jn||(Ir=function(){if(tr(Rr,this))throw new Lr("Symbol is not a constructor");var t=arguments.length&&void 0!==arguments[0]?ar(arguments[0]):void 0,e=br(t),i=function(t){this===Nr&&Gn(i,Ur,t),Zn(this,Sr)&&Zn(this[Sr],e)&&(this[Sr][e]=!1);var s=or(1,t);try{Gr(this,e,s)}catch(t){if(!(t instanceof Pr))throw t;Yr(this,e,s)}};return Kn&&qr&&Gr(Nr,e,{configurable:!0,set:i}),Xr(e,t)},gr(Rr=Ir[Er],"toString",(function(){return Fr(this).tag})),gr(Ir,"withoutSetter",(function(t){return Xr(br(t),t)})),mr.f=Qr,ur.f=Kr,pr.f=Jr,cr.f=Zr,lr.f=hr.f=tl,dr.f=el,_r.f=function(t){return Xr(wr(t),t)},Kn&&fr(Rr,"description",{configurable:!0,get:function(){return Fr(this).description}})),qn({global:!0,constructor:!0,wrap:!0,forced:!Jn,sham:!Jn},{Symbol:Ir}),Tr(rr($r),(function(t){xr(t)})),qn({target:Ar,stat:!0,forced:!Jn},{useSetter:function(){qr=!0},useSimple:function(){qr=!1}}),qn({target:"Object",stat:!0,forced:!Jn,sham:!Kn},{create:function(t,e){return void 0===e?nr(t):Jr(nr(t),e)},defineProperty:Kr,defineProperties:Jr,getOwnPropertyDescriptor:Zr}),qn({target:"Object",stat:!0,forced:!Jn},{getOwnPropertyNames:tl}),Cr(),Dr(Ir,Ar),yr[Sr]=!0;var il=wt&&!!Symbol.for&&!!Symbol.keyFor,sl=Ei,al=rt,ol=Zt,nl=so,rl=Yt,ll=il,hl=rl("string-to-symbol-registry"),dl=rl("symbol-to-string-registry");sl({target:"Symbol",stat:!0,forced:!ll},{for:function(t){var e=nl(t);if(ol(hl,e))return hl[e];var i=al("Symbol")(e);return hl[e]=i,dl[i]=e,i}});var cl=Ei,ul=Zt,pl=Tt,ml=At,gl=il,fl=Yt("symbol-to-string-registry");cl({target:"Symbol",stat:!0,forced:!gl},{keyFor:function(t){if(!pl(t))throw new TypeError(ml(t)+" is not a symbol");if(ul(fl,t))return fl[t]}});var vl=Ks,yl=A,bl=_,wl=so,_l=v([].push),xl=Ei,Cl=rt,Dl=u,kl=I,Tl=v,Sl=n,Al=A,El=Tt,Ol=ws,Fl=function(t){if(yl(t))return t;if(vl(t)){for(var e=t.length,i=[],s=0;s=e.length)return t.target=void 0,id(void 0,!0);switch(i){case"keys":return id(s,!1);case"values":return id(e[s],!1)}return id([s,e[s]],!1)}),"values"),Zh.Arguments=Zh.Array;var nd={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0},rd=o,ld=ca,hd=vi,dd=ih,cd=pe("toStringTag");for(var ud in nd){var pd=rd[ud],md=pd&&pd.prototype;md&&ld(md)!==cd&&hd(md,cd,ud),dd[ud]=dd.Array}var gd=eh,fd=s(gd),vd=Ei,yd=Ks,bd=Ea,wd=et,_d=Mi,xd=Vi,Cd=Q,Dd=ia,kd=pe,Td=ws,Sd=ja("slice"),Ad=kd("species"),Ed=Array,Od=Math.max;vd({target:"Array",proto:!0,forced:!Sd},{slice:function(t,e){var i,s,a,o=Cd(this),n=xd(o),r=_d(t,n),l=_d(void 0===e?n:e,n);if(yd(o)&&(i=o.constructor,(bd(i)&&(i===Ed||yd(i.prototype))||wd(i)&&null===(i=i[Ad]))&&(i=void 0),i===Ed||void 0===i))return Td(o,r,l);for(s=new(void 0===i?Ed:i)(Od(l-r,0)),a=0;r1?arguments[1]:void 0)}});var qd=Rs("Array").map,Yd=lt,Gd=qd,Xd=Array.prototype,Kd=function(t){var e=t.map;return t===Xd||Yd(Xd,t)&&e===Xd.map?Gd:e},Jd=s(Kd),Qd=Kt,Zd=ss;Ei({target:"Object",stat:!0,forced:n((function(){Zd(1)}))},{keys:function(t){return Zd(Qd(t))}});var tc=s(it.Object.keys),ec=Ei,ic=Date,sc=v(ic.prototype.getTime);ec({target:"Date",stat:!0},{now:function(){return sc(new ic)}});var ac=s(it.Date.now),oc=n,nc=function(t,e){var i=[][t];return!!i&&oc((function(){i.call(null,e||function(){return 1},1)}))},rc=$n.forEach,lc=nc("forEach")?[].forEach:function(t){return rc(this,t,arguments.length>1?arguments[1]:void 0)};Ei({target:"Array",proto:!0,forced:[].forEach!==lc},{forEach:lc});var hc=Rs("Array").forEach,dc=ca,cc=Zt,uc=lt,pc=hc,mc=Array.prototype,gc={DOMTokenList:!0,NodeList:!0},fc=function(t){var e=t.forEach;return t===mc||uc(mc,t)&&e===mc.forEach||cc(gc,dc(t))?pc:e},vc=s(fc),yc=Ei,bc=Ks,wc=v([].reverse),_c=[1,2];yc({target:"Array",proto:!0,forced:String(_c)===String(_c.reverse())},{reverse:function(){return bc(this)&&(this.length=this.length),wc(this)}});var xc=Rs("Array").reverse,Cc=lt,Dc=xc,kc=Array.prototype,Tc=function(t){var e=t.reverse;return t===kc||Cc(kc,t)&&e===kc.reverse?Dc:e},Sc=s(Tc),Ac=O,Ec=Ks,Oc=TypeError,Fc=Object.getOwnPropertyDescriptor,Nc=Ac&&!function(){if(void 0!==this)return!0;try{Object.defineProperty([],"length",{writable:!1}).length=1}catch(e){return e instanceof TypeError}}(),Ic=At,Rc=TypeError,Pc=function(t,e){if(!delete t[e])throw new Rc("Cannot delete property "+Ic(e)+" of "+Ic(t))},Lc=Ei,Mc=Kt,zc=Mi,Bc=Ii,jc=Vi,Vc=Nc?function(t,e){if(Ec(t)&&!Fc(t,"length").writable)throw new Oc("Cannot set read only .length");return t.length=e}:function(t,e){return t.length=e},Hc=Qs,Wc=La,Uc=ia,$c=Pc,qc=ja("splice"),Yc=Math.max,Gc=Math.min;Lc({target:"Array",proto:!0,forced:!qc},{splice:function(t,e){var i,s,a,o,n,r,l=Mc(this),h=jc(l),d=zc(t,h),c=arguments.length;for(0===c?i=s=0:1===c?(i=0,s=h-d):(i=c-2,s=Gc(Yc(Bc(e),0),h-d)),Hc(h+i-s),a=Wc(l,s),o=0;oh-s+i;o--)$c(l,o-1)}else if(i>s)for(o=h-s;o>d;o--)r=o+i-1,(n=o+s-1)in l?l[r]=l[n]:$c(l,r);for(o=0;o1?arguments[1]:void 0)}});var iu=Rs("Array").includes,su=et,au=_,ou=pe("match"),nu=function(t){var e;return su(t)&&(void 0!==(e=t[ou])?!!e:"RegExp"===au(t))},ru=TypeError,lu=pe("match"),hu=Ei,du=function(t){if(nu(t))throw new ru("The method doesn't accept regular expressions");return t},cu=X,uu=so,pu=function(t){var e=/./;try{"/./"[t](e)}catch(s){try{return e[lu]=!1,"/./"[t](e)}catch(t){}}return!1},mu=v("".indexOf);hu({target:"String",proto:!0,forced:!pu("includes")},{includes:function(t){return!!~mu(uu(cu(this)),uu(du(t)),arguments.length>1?arguments[1]:void 0)}});var gu=Rs("String").includes,fu=lt,vu=iu,yu=gu,bu=Array.prototype,wu=String.prototype,_u=function(t){var e=t.includes;return t===bu||fu(bu,t)&&e===bu.includes?vu:"string"==typeof t||t===wu||fu(wu,t)&&e===wu.includes?yu:e},xu=s(_u),Cu=Kt,Du=vh,ku=hh;Ei({target:"Object",stat:!0,forced:n((function(){Du(1)})),sham:!ku},{getPrototypeOf:function(t){return Du(Cu(t))}});var Tu=s(it.Object.getPrototypeOf),Su=Rs("Array").concat,Au=lt,Eu=Su,Ou=Array.prototype,Fu=function(t){var e=t.concat;return t===Ou||Au(Ou,t)&&e===Ou.concat?Eu:e},Nu=s(Fu),Iu=$n.filter;Ei({target:"Array",proto:!0,forced:!ja("filter")},{filter:function(t){return Iu(this,t,arguments.length>1?arguments[1]:void 0)}});var Ru=Rs("Array").filter,Pu=lt,Lu=Ru,Mu=Array.prototype,zu=function(t){var e=t.filter;return t===Mu||Pu(Mu,t)&&e===Mu.filter?Lu:e},Bu=s(zu),ju=O,Vu=n,Hu=v,Wu=vh,Uu=ss,$u=Q,qu=Hu(R.f),Yu=Hu([].push),Gu=ju&&Vu((function(){var t=Object.create(null);return t[2]=2,!qu(t,2)})),Xu=function(t){return function(e){for(var i,s=$u(e),a=Uu(s),o=Gu&&null===Wu(s),n=a.length,r=0,l=[];n>r;)i=a[r++],ju&&!(o?i in s:qu(s,i))||Yu(l,t?[i,s[i]]:s[i]);return l}},Ku={entries:Xu(!0),values:Xu(!1)},Ju=Ku.values;Ei({target:"Object",stat:!0},{values:function(t){return Ju(t)}});var Qu=s(it.Object.values),Zu="\t\n\v\f\r                 \u2028\u2029\ufeff",tp=X,ep=so,ip=Zu,sp=v("".replace),ap=RegExp("^["+ip+"]+"),op=RegExp("(^|[^"+ip+"])["+ip+"]+$"),np=function(t){return function(e){var i=ep(tp(e));return 1&t&&(i=sp(i,ap,"")),2&t&&(i=sp(i,op,"$1")),i}},rp={start:np(1),end:np(2),trim:np(3)},lp=o,hp=n,dp=v,cp=so,up=rp.trim,pp=Zu,mp=lp.parseInt,gp=lp.Symbol,fp=gp&&gp.iterator,vp=/^[+-]?0x/i,yp=dp(vp.exec),bp=8!==mp(pp+"08")||22!==mp(pp+"0x16")||fp&&!hp((function(){mp(Object(fp))}))?function(t,e){var i=up(cp(t));return mp(i,e>>>0||(yp(vp,i)?16:10))}:mp;Ei({global:!0,forced:parseInt!==bp},{parseInt:bp});var wp=s(it.parseInt),_p=Ei,xp=qi.indexOf,Cp=nc,Dp=D([].indexOf),kp=!!Dp&&1/Dp([1],1,-0)<0;_p({target:"Array",proto:!0,forced:kp||!Cp("indexOf")},{indexOf:function(t){var e=arguments.length>1?arguments[1]:void 0;return kp?Dp(this,t,e)||0:xp(this,t,e)}});var Tp=Rs("Array").indexOf,Sp=lt,Ap=Tp,Ep=Array.prototype,Op=function(t){var e=t.indexOf;return t===Ep||Sp(Ep,t)&&e===Ep.indexOf?Ap:e},Fp=s(Op),Np=Ku.entries;Ei({target:"Object",stat:!0},{entries:function(t){return Np(t)}});var Ip=s(it.Object.entries);Ei({target:"Object",stat:!0,sham:!O},{create:Oo});var Rp=it.Object,Pp=s((function(t,e){return Rp.create(t,e)})),Lp=it,Mp=u;Lp.JSON||(Lp.JSON={stringify:JSON.stringify});var zp=function(t,e,i){return Mp(Lp.JSON.stringify,null,arguments)},Bp=s(zp),jp="function"==typeof Bun&&Bun&&"string"==typeof Bun.version,Vp=TypeError,Hp=o,Wp=u,Up=A,$p=jp,qp=ht,Yp=ws,Gp=function(t,e){if(ti,n=Up(s)?s:Xp(s),r=o?Yp(arguments,i):[],l=o?function(){Wp(n,this,r)}:n;return e?t(l,a):t(l)}:t},Qp=Ei,Zp=o,tm=Jp(Zp.setInterval,!0);Qp({global:!0,bind:!0,forced:Zp.setInterval!==tm},{setInterval:tm});var em=Ei,im=o,sm=Jp(im.setTimeout,!0);em({global:!0,bind:!0,forced:im.setTimeout!==sm},{setTimeout:sm});var am=s(it.setTimeout),om=Kt,nm=Mi,rm=Vi,lm=function(t){for(var e=om(this),i=rm(e),s=arguments.length,a=nm(s>1?arguments[1]:void 0,i),o=s>2?arguments[2]:void 0,n=void 0===o?i:nm(o,i);n>a;)e[a++]=t;return e};Ei({target:"Array",proto:!0},{fill:lm});var hm,dm=Rs("Array").fill,cm=lt,um=dm,pm=Array.prototype,mm=function(t){var e=t.fill;return t===pm||cm(pm,t)&&e===pm.fill?um:e},gm=s(mm);function fm(){return fm=Object.assign||function(t){for(var e=1;e-1}var ag=function(){function t(t,e){this.manager=t,this.set(e)}var e=t.prototype;return e.set=function(t){t===Em&&(t=this.compute()),Am&&this.manager.element.style&&Pm[t]&&(this.manager.element.style[Sm]=t),this.actions=t.toLowerCase().trim()},e.update=function(){this.set(this.manager.options.touchAction)},e.compute=function(){var t=[];return eg(this.manager.recognizers,(function(e){ig(e.options.enable,[e])&&(t=t.concat(e.getTouchAction()))})),function(t){if(sg(t,Nm))return Nm;var e=sg(t,Im),i=sg(t,Rm);return e&&i?Nm:e||i?e?Im:Rm:sg(t,Fm)?Fm:Om}(t.join(" "))},e.preventDefaults=function(t){var e=t.srcEvent,i=t.offsetDirection;if(this.manager.session.prevented)e.preventDefault();else{var s=this.actions,a=sg(s,Nm)&&!Pm[Nm],o=sg(s,Rm)&&!Pm[Rm],n=sg(s,Im)&&!Pm[Im];if(a){var r=1===t.pointers.length,l=t.distance<2,h=t.deltaTime<250;if(r&&l&&h)return}if(!n||!o)return a||o&&i&Km||n&&i&Jm?this.preventSrc(e):void 0}},e.preventSrc=function(t){this.manager.session.prevented=!0,t.preventDefault()},t}();function og(t,e){for(;t;){if(t===e)return!0;t=t.parentNode}return!1}function ng(t){var e=t.length;if(1===e)return{x:Cm(t[0].clientX),y:Cm(t[0].clientY)};for(var i=0,s=0,a=0;a=Dm(e)?t<0?qm:Ym:e<0?Gm:Xm}function cg(t,e,i){return{x:e/t||0,y:i/t||0}}function ug(t,e){var i=t.session,s=e.pointers,a=s.length;i.firstInput||(i.firstInput=rg(e)),a>1&&!i.firstMultiple?i.firstMultiple=rg(e):1===a&&(i.firstMultiple=!1);var o=i.firstInput,n=i.firstMultiple,r=n?n.center:o.center,l=e.center=ng(s);e.timeStamp=km(),e.deltaTime=e.timeStamp-o.timeStamp,e.angle=hg(r,l),e.distance=lg(r,l),function(t,e){var i=e.center,s=t.offsetDelta||{},a=t.prevDelta||{},o=t.prevInput||{};e.eventType!==Hm&&o.eventType!==Wm||(a=t.prevDelta={x:o.deltaX||0,y:o.deltaY||0},s=t.offsetDelta={x:i.x,y:i.y}),e.deltaX=a.x+(i.x-s.x),e.deltaY=a.y+(i.y-s.y)}(i,e),e.offsetDirection=dg(e.deltaX,e.deltaY);var h,d,c=cg(e.deltaTime,e.deltaX,e.deltaY);e.overallVelocityX=c.x,e.overallVelocityY=c.y,e.overallVelocity=Dm(c.x)>Dm(c.y)?c.x:c.y,e.scale=n?(h=n.pointers,lg((d=s)[0],d[1],tg)/lg(h[0],h[1],tg)):1,e.rotation=n?function(t,e){return hg(e[1],e[0],tg)+hg(t[1],t[0],tg)}(n.pointers,s):0,e.maxPointers=i.prevInput?e.pointers.length>i.prevInput.maxPointers?e.pointers.length:i.prevInput.maxPointers:e.pointers.length,function(t,e){var i,s,a,o,n=t.lastInterval||e,r=e.timeStamp-n.timeStamp;if(e.eventType!==Um&&(r>Vm||void 0===n.velocity)){var l=e.deltaX-n.deltaX,h=e.deltaY-n.deltaY,d=cg(r,l,h);s=d.x,a=d.y,i=Dm(d.x)>Dm(d.y)?d.x:d.y,o=dg(l,h),t.lastInterval=e}else i=n.velocity,s=n.velocityX,a=n.velocityY,o=n.direction;e.velocity=i,e.velocityX=s,e.velocityY=a,e.direction=o}(i,e);var u,p=t.element,m=e.srcEvent;og(u=m.composedPath?m.composedPath()[0]:m.path?m.path[0]:m.target,p)&&(p=u),e.target=p}function pg(t,e,i){var s=i.pointers.length,a=i.changedPointers.length,o=e&Hm&&s-a==0,n=e&(Wm|Um)&&s-a==0;i.isFirst=!!o,i.isFinal=!!n,o&&(t.session={}),i.eventType=e,ug(t,i),t.emit("hammer.input",i),t.recognize(i),t.session.prevInput=i}function mg(t){return t.trim().split(/\s+/g)}function gg(t,e,i){eg(mg(e),(function(e){t.addEventListener(e,i,!1)}))}function fg(t,e,i){eg(mg(e),(function(e){t.removeEventListener(e,i,!1)}))}function vg(t){var e=t.ownerDocument||t;return e.defaultView||e.parentWindow||window}var yg=function(){function t(t,e){var i=this;this.manager=t,this.callback=e,this.element=t.element,this.target=t.options.inputTarget,this.domHandler=function(e){ig(t.options.enable,[t])&&i.handler(e)},this.init()}var e=t.prototype;return e.handler=function(){},e.init=function(){this.evEl&&gg(this.element,this.evEl,this.domHandler),this.evTarget&&gg(this.target,this.evTarget,this.domHandler),this.evWin&&gg(vg(this.element),this.evWin,this.domHandler)},e.destroy=function(){this.evEl&&fg(this.element,this.evEl,this.domHandler),this.evTarget&&fg(this.target,this.evTarget,this.domHandler),this.evWin&&fg(vg(this.element),this.evWin,this.domHandler)},t}();function bg(t,e,i){if(t.indexOf&&!i)return t.indexOf(e);for(var s=0;si[e]})):s.sort()),s}var Sg={touchstart:Hm,touchmove:2,touchend:Wm,touchcancel:Um},Ag=function(t){function e(){var i;return e.prototype.evTarget="touchstart touchmove touchend touchcancel",(i=t.apply(this,arguments)||this).targetIds={},i}return vm(e,t),e.prototype.handler=function(t){var e=Sg[t.type],i=Eg.call(this,t,e);i&&this.callback(this.manager,e,{pointers:i[0],changedPointers:i[1],pointerType:Bm,srcEvent:t})},e}(yg);function Eg(t,e){var i,s,a=kg(t.touches),o=this.targetIds;if(e&(2|Hm)&&1===a.length)return o[a[0].identifier]=!0,[a,a];var n=kg(t.changedTouches),r=[],l=this.target;if(s=a.filter((function(t){return og(t.target,l)})),e===Hm)for(i=0;i-1&&s.splice(t,1)}),Ng)}}function Rg(t,e){t&Hm?(this.primaryTouch=e.changedPointers[0].identifier,Ig.call(this,e)):t&(Wm|Um)&&Ig.call(this,e)}function Pg(t){for(var e=t.srcEvent.clientX,i=t.srcEvent.clientY,s=0;s-1&&this.requireFail.splice(e,1),this},e.hasRequireFailures=function(){return this.requireFail.length>0},e.canRecognizeWith=function(t){return!!this.simultaneous[t.id]},e.emit=function(t){var e=this,i=this.state;function s(i){e.manager.emit(i,t)}i<8&&s(e.options.event+Vg(i)),s(e.options.event),t.additionalEvent&&s(t.additionalEvent),i>=8&&s(e.options.event+Vg(i))},e.tryEmit=function(t){if(this.canEmit())return this.emit(t);this.state=zg},e.canEmit=function(){for(var t=0;te.threshold&&a&e.direction},i.attrTest=function(t){return Ug.prototype.attrTest.call(this,t)&&(2&this.state||!(2&this.state)&&this.directionTest(t))},i.emit=function(e){this.pX=e.deltaX,this.pY=e.deltaY;var i=$g(e.direction);i&&(e.additionalEvent=this.options.event+i),t.prototype.emit.call(this,e)},e}(Ug),Yg=function(t){function e(e){return void 0===e&&(e={}),t.call(this,fm({event:"swipe",threshold:10,velocity:.3,direction:Km|Jm,pointers:1},e))||this}vm(e,t);var i=e.prototype;return i.getTouchAction=function(){return qg.prototype.getTouchAction.call(this)},i.attrTest=function(e){var i,s=this.options.direction;return s&(Km|Jm)?i=e.overallVelocity:s&Km?i=e.overallVelocityX:s&Jm&&(i=e.overallVelocityY),t.prototype.attrTest.call(this,e)&&s&e.offsetDirection&&e.distance>this.options.threshold&&e.maxPointers===this.options.pointers&&Dm(i)>this.options.velocity&&e.eventType&Wm},i.emit=function(t){var e=$g(t.offsetDirection);e&&this.manager.emit(this.options.event+e,t),this.manager.emit(this.options.event,t)},e}(Ug),Gg=function(t){function e(e){return void 0===e&&(e={}),t.call(this,fm({event:"pinch",threshold:0,pointers:2},e))||this}vm(e,t);var i=e.prototype;return i.getTouchAction=function(){return[Nm]},i.attrTest=function(e){return t.prototype.attrTest.call(this,e)&&(Math.abs(e.scale-1)>this.options.threshold||2&this.state)},i.emit=function(e){if(1!==e.scale){var i=e.scale<1?"in":"out";e.additionalEvent=this.options.event+i}t.prototype.emit.call(this,e)},e}(Ug),Xg=function(t){function e(e){return void 0===e&&(e={}),t.call(this,fm({event:"rotate",threshold:0,pointers:2},e))||this}vm(e,t);var i=e.prototype;return i.getTouchAction=function(){return[Nm]},i.attrTest=function(e){return t.prototype.attrTest.call(this,e)&&(Math.abs(e.rotation)>this.options.threshold||2&this.state)},e}(Ug),Kg=function(t){function e(e){var i;return void 0===e&&(e={}),(i=t.call(this,fm({event:"press",pointers:1,time:251,threshold:9},e))||this)._timer=null,i._input=null,i}vm(e,t);var i=e.prototype;return i.getTouchAction=function(){return[Om]},i.process=function(t){var e=this,i=this.options,s=t.pointers.length===i.pointers,a=t.distancei.time;if(this._input=t,!a||!s||t.eventType&(Wm|Um)&&!o)this.reset();else if(t.eventType&Hm)this.reset(),this._timer=setTimeout((function(){e.state=8,e.tryEmit()}),i.time);else if(t.eventType&Wm)return 8;return zg},i.reset=function(){clearTimeout(this._timer)},i.emit=function(t){8===this.state&&(t&&t.eventType&Wm?this.manager.emit(this.options.event+"up",t):(this._input.timeStamp=km(),this.manager.emit(this.options.event,this._input)))},e}(Hg),Jg={domEvents:!1,touchAction:Em,enable:!0,inputTarget:null,inputClass:null,cssProps:{userSelect:"none",touchSelect:"none",touchCallout:"none",contentZooming:"none",userDrag:"none",tapHighlightColor:"rgba(0,0,0,0)"}},Qg=[[Xg,{enable:!1}],[Gg,{enable:!1},["rotate"]],[Yg,{direction:Km}],[qg,{direction:Km},["swipe"]],[Wg],[Wg,{event:"doubletap",taps:2},["tap"]],[Kg]];function Zg(t,e){var i,s=t.element;s.style&&(eg(t.options.cssProps,(function(a,o){i=Tm(s.style,o),e?(t.oldCssProps[i]=s.style[i],s.style[i]=a):s.style[i]=t.oldCssProps[i]||""})),e||(t.oldCssProps={}))}var tf=function(){function t(t,e){var i,s=this;this.options=wm({},Jg,e||{}),this.options.inputTarget=this.options.inputTarget||t,this.handlers={},this.session={},this.recognizers=[],this.oldCssProps={},this.element=t,this.input=new((i=this).options.inputClass||(Mm?Dg:zm?Ag:Lm?Lg:Fg))(i,pg),this.touchAction=new ag(this,this.options.touchAction),Zg(this,!0),eg(this.options.recognizers,(function(t){var e=s.add(new t[0](t[1]));t[2]&&e.recognizeWith(t[2]),t[3]&&e.requireFailure(t[3])}),this)}var e=t.prototype;return e.set=function(t){return wm(this.options,t),t.touchAction&&this.touchAction.update(),t.inputTarget&&(this.input.destroy(),this.input.target=t.inputTarget,this.input.init()),this},e.stop=function(t){this.session.stopped=t?2:1},e.recognize=function(t){var e=this.session;if(!e.stopped){var i;this.touchAction.preventDefaults(t);var s=this.recognizers,a=e.curRecognizer;(!a||a&&8&a.state)&&(e.curRecognizer=null,a=null);for(var o=0;o\s*\(/gm,"{anonymous}()@"):"Unknown Stack Trace",a=window.console&&(window.console.warn||window.console.log);return a&&a.call(window.console,s,i),t.apply(this,arguments)}}var nf=of((function(t,e,i){for(var s=Object.keys(e),a=0;a1?e-1:0),s=1;s2)return gf(mf(e[0],e[1]),...Ld(e).call(e,2));const s=e[0],a=e[1];if(s instanceof Date&&a instanceof Date)return s.setTime(a.getTime()),s;for(const o of Wd(a))Object.prototype.propertyIsEnumerable.call(a,o)&&(a[o]===uf?delete s[o]:null===s[o]||null===a[o]||"object"!=typeof s[o]||"object"!=typeof a[o]||Ud(s[o])||Ud(a[o])?s[o]=ff(a[o]):s[o]=gf(s[o],a[o]));return s}function ff(t){return Ud(t)?Jd(t).call(t,t=>ff(t)):"object"==typeof t&&null!==t?t instanceof Date?new Date(t.getTime()):gf({},t):t}function vf(t){for(const e of tc(t))t[e]===uf?delete t[e]:"object"==typeof t[e]&&null!==t[e]&&vf(t[e])}function yf(){for(var t=arguments.length,e=new Array(t),i=0;i>>0,e-=t,e*=t,t=e>>>0,e-=t,t+=4294967296*e}return 2.3283064365386963e-10*(t>>>0)}}();let e=t(" "),i=t(" "),s=t(" ");for(let a=0;a{const t=2091639*e+2.3283064365386963e-10*a;return e=i,i=s,s=t-(a=0|t)};return o.uint32=()=>4294967296*o(),o.fract53=()=>o()+11102230246251565e-32*(2097152*o()|0),o.algorithm="Alea",o.seed=t,o.version="0.9",o}(e.length?e:[ac()])}const bf="undefined"!=typeof window?window.Hammer||cf:function(){return function(){const t=()=>{};return{on:t,off:t,destroy:t,emit:t,get:()=>({set:t})}}()};function wf(t){var e;this._cleanupQueue=[],this.active=!1,this._dom={container:t,overlay:document.createElement("div")},this._dom.overlay.classList.add("vis-overlay"),this._dom.container.appendChild(this._dom.overlay),this._cleanupQueue.push(()=>{this._dom.overlay.parentNode.removeChild(this._dom.overlay)});const i=bf(this._dom.overlay);i.on("tap",js(e=this._onTapOverlay).call(e,this)),this._cleanupQueue.push(()=>{i.destroy()});const s=["tap","doubletap","press","pinch","pan","panstart","panmove","panend"];vc(s).call(s,t=>{i.on(t,t=>{t.srcEvent.stopPropagation()})}),document&&document.body&&(this._onClick=e=>{(function(t,e){for(;t;){if(t===e)return!0;t=t.parentNode}return!1})(e.target,t)||this.deactivate()},document.body.addEventListener("click",this._onClick),this._cleanupQueue.push(()=>{document.body.removeEventListener("click",this._onClick)})),this._escListener=t=>{("key"in t?"Escape"===t.key:27===t.keyCode)&&this.deactivate()}}Gs(wf.prototype),wf.current=null,wf.prototype.destroy=function(){this.deactivate();for(const i of Sc(t=tu(e=this._cleanupQueue).call(e,0)).call(t)){var t,e;i()}},wf.prototype.activate=function(){wf.current&&wf.current.deactivate(),wf.current=this,this.active=!0,this._dom.overlay.style.display="none",this._dom.container.classList.add("vis-active"),this.emit("change"),this.emit("activate"),document.body.addEventListener("keydown",this._escListener)},wf.prototype.deactivate=function(){this.active=!1,this._dom.overlay.style.display="block",this._dom.container.classList.remove("vis-active"),document.body.removeEventListener("keydown",this._escListener),this.emit("change"),this.emit("deactivate")},wf.prototype._onTapOverlay=function(t){this.activate(),t.srcEvent.stopPropagation()};const _f=/^\/?Date\((-?\d+)/i,xf=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i,Cf=/^#?([a-f\d])([a-f\d])([a-f\d])$/i,Df=/^rgb\( *(1?\d{1,2}|2[0-4]\d|25[0-5]) *, *(1?\d{1,2}|2[0-4]\d|25[0-5]) *, *(1?\d{1,2}|2[0-4]\d|25[0-5]) *\)$/i,kf=/^rgba\( *(1?\d{1,2}|2[0-4]\d|25[0-5]) *, *(1?\d{1,2}|2[0-4]\d|25[0-5]) *, *(1?\d{1,2}|2[0-4]\d|25[0-5]) *, *([01]|0?\.\d+) *\)$/i;function Tf(t){return t instanceof Number||"number"==typeof t}function Sf(t){if(t)for(;!0===t.hasChildNodes();){const e=t.firstChild;e&&(Sf(e),t.removeChild(e))}}function Af(t){return t instanceof String||"string"==typeof t}function Ef(t){return"object"==typeof t&&null!==t}function Of(t,e,i,s){let a=!1;!0===s&&(a=null===e[i]&&void 0!==t[i]),a?delete t[i]:t[i]=e[i]}function Ff(t,e){let i=arguments.length>2&&void 0!==arguments[2]&&arguments[2];for(const s in t)if(void 0!==e[s])if(null===e[s]||"object"!=typeof e[s])Of(t,e,s,i);else{const a=t[s],o=e[s];Ef(a)&&Ef(o)&&Ff(a,o,i)}}const Nf=bs;function If(t,e,i){let s=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(Ud(i))throw new TypeError("Arrays are not supported by deepExtend");for(let a=0;a3&&void 0!==arguments[3]&&arguments[3];if(Ud(i))throw new TypeError("Arrays are not supported by deepExtend");for(const a in i)if(Object.prototype.hasOwnProperty.call(i,a)&&!xu(t).call(t,a))if(i[a]&&i[a].constructor===Object)void 0===e[a]&&(e[a]={}),e[a].constructor===Object?Pf(e[a],i[a]):Of(e,i,a,s);else if(Ud(i[a])){e[a]=[];for(let t=0;t2&&void 0!==arguments[2]&&arguments[2],s=arguments.length>3&&void 0!==arguments[3]&&arguments[3];for(const o in e)if(Object.prototype.hasOwnProperty.call(e,o)||!0===i)if("object"==typeof e[o]&&null!==e[o]&&Tu(e[o])===Object.prototype)void 0===t[o]?t[o]=Pf({},e[o],i):"object"==typeof t[o]&&null!==t[o]&&Tu(t[o])===Object.prototype?Pf(t[o],e[o],i):Of(t,e,o,s);else if(Ud(e[o])){var a;t[o]=Ld(a=e[o]).call(a)}else Of(t,e,o,s);return t}function Lf(t,e){return[...t,e]}function Mf(t){return Ld(t).call(t)}function zf(t){return t.getBoundingClientRect().left}function Bf(t){return t.getBoundingClientRect().top}function jf(t,e){if(Ud(t)){const i=t.length;for(let s=0;s("function"==typeof t&&(t=t()),null!=t?0!=t:e||null),asNumber:(t,e)=>("function"==typeof t&&(t=t()),null!=t?Number(t)||e||null:e||null),asString:(t,e)=>("function"==typeof t&&(t=t()),null!=t?String(t):e||null),asSize:(t,e)=>("function"==typeof t&&(t=t()),Af(t)?t:Tf(t)?t+"px":e||null),asElement:(t,e)=>("function"==typeof t&&(t=t()),t||e||null)};function Wf(t){let e;switch(t.length){case 3:case 4:return e=Cf.exec(t),e?{r:wp(e[1]+e[1],16),g:wp(e[2]+e[2],16),b:wp(e[3]+e[3],16)}:null;case 6:case 7:return e=xf.exec(t),e?{r:wp(e[1],16),g:wp(e[2],16),b:wp(e[3],16)}:null;default:return null}}function Uf(t,e){if(xu(t).call(t,"rgba"))return t;if(xu(t).call(t,"rgb")){const i=t.substr(Fp(t).call(t,"(")+1).replace(")","").split(",");return"rgba("+i[0]+","+i[1]+","+i[2]+","+e+")"}{const i=Wf(t);return null==i?t:"rgba("+i.r+","+i.g+","+i.b+","+e+")"}}function $f(t,e,i){var s;return"#"+Ld(s=((1<<24)+(t<<16)+(e<<8)+i).toString(16)).call(s,1)}function qf(t,e){if(Af(t)){let e=t;if(Zf(e)){var i;const t=Jd(i=e.substr(4).substr(0,e.length-5).split(",")).call(i,(function(t){return wp(t)}));e=$f(t[0],t[1],t[2])}if(!0===Qf(e)){const t=Jf(e),i={h:t.h,s:.8*t.s,v:Math.min(1,1.02*t.v)},s={h:t.h,s:Math.min(1,1.25*t.s),v:.8*t.v},a=Kf(s.h,s.s,s.v),o=Kf(i.h,i.s,i.v);return{background:e,border:a,highlight:{background:o,border:a},hover:{background:o,border:a}}}return{background:e,border:e,highlight:{background:e,border:e},hover:{background:e,border:e}}}return e?{background:t.background||e.background,border:t.border||e.border,highlight:Af(t.highlight)?{border:t.highlight,background:t.highlight}:{background:t.highlight&&t.highlight.background||e.highlight.background,border:t.highlight&&t.highlight.border||e.highlight.border},hover:Af(t.hover)?{border:t.hover,background:t.hover}:{border:t.hover&&t.hover.border||e.hover.border,background:t.hover&&t.hover.background||e.hover.background}}:{background:t.background||void 0,border:t.border||void 0,highlight:Af(t.highlight)?{border:t.highlight,background:t.highlight}:{background:t.highlight&&t.highlight.background||void 0,border:t.highlight&&t.highlight.border||void 0},hover:Af(t.hover)?{border:t.hover,background:t.hover}:{border:t.hover&&t.hover.border||void 0,background:t.hover&&t.hover.background||void 0}}}function Yf(t,e,i){t/=255,e/=255,i/=255;const s=Math.min(t,Math.min(e,i)),a=Math.max(t,Math.max(e,i));return s===a?{h:0,s:0,v:s}:{h:60*((t===s?3:i===s?1:5)-(t===s?e-i:i===s?t-e:i-t)/(a-s))/360,s:(a-s)/a,v:a}}function Gf(t){const e=document.createElement("div"),i={};e.style.cssText=t;for(let s=0;s3&&void 0!==arguments[3]?arguments[3]:{};const a=function(t){return null!=t},o=function(t){return null!==t&&"object"==typeof t};if(!o(t))throw new Error("Parameter mergeTarget must be an object");if(!o(e))throw new Error("Parameter options must be an object");if(!a(i))throw new Error("Parameter option must have a value");if(!o(s))throw new Error("Parameter globalOptions must be an object");const n=e[i],r=o(s)&&!function(t){for(const e in t)if(Object.prototype.hasOwnProperty.call(t,e))return!1;return!0}(s)?s[i]:void 0,l=r?r.enabled:void 0;if(void 0===n)return;if("boolean"==typeof n)return o(t[i])||(t[i]={}),void(t[i].enabled=n);if(null===n&&!o(t[i])){if(!a(r))return;t[i]=Pp(r)}if(!o(n))return;let h=!0;void 0!==n.enabled?h=n.enabled:void 0!==l&&(h=r.enabled),function(t,e,i){o(t[i])||(t[i]={});const s=e[i],a=t[i];for(const o in s)Object.prototype.hasOwnProperty.call(s,o)&&(a[o]=s[o])}(t,e,i),t[i].enabled=h}const sv={linear:t=>t,easeInQuad:t=>t*t,easeOutQuad:t=>t*(2-t),easeInOutQuad:t=>t<.5?2*t*t:(4-2*t)*t-1,easeInCubic:t=>t*t*t,easeOutCubic:t=>--t*t*t+1,easeInOutCubic:t=>t<.5?4*t*t*t:(t-1)*(2*t-2)*(2*t-2)+1,easeInQuart:t=>t*t*t*t,easeOutQuart:t=>1- --t*t*t*t,easeInOutQuart:t=>t<.5?8*t*t*t*t:1-8*--t*t*t*t,easeInQuint:t=>t*t*t*t*t,easeOutQuint:t=>1+--t*t*t*t*t,easeInOutQuint:t=>t<.5?16*t*t*t*t*t:1+16*--t*t*t*t*t};function av(t,e){let i;Ud(e)||(e=[e]);for(const s of t)if(s){i=s[e[0]];for(let t=1;t0&&void 0!==arguments[0]?arguments[0]:1;this.pixelRatio=t,this.generated=!1,this.centerCoordinates={x:144.5,y:144.5},this.r=289*.49,this.color={r:255,g:255,b:255,a:1},this.hueCircle=void 0,this.initialColor={r:255,g:255,b:255,a:1},this.previousColor=void 0,this.applied=!1,this.updateCallback=()=>{},this.closeCallback=()=>{},this._create()}insertTo(t){void 0!==this.hammer&&(this.hammer.destroy(),this.hammer=void 0),this.container=t,this.container.appendChild(this.frame),this._bindHammer(),this._setSize()}setUpdateCallback(t){if("function"!=typeof t)throw new Error("Function attempted to set as colorPicker update callback is not a function.");this.updateCallback=t}setCloseCallback(t){if("function"!=typeof t)throw new Error("Function attempted to set as colorPicker closing callback is not a function.");this.closeCallback=t}_isColorString(t){if("string"==typeof t)return ov[t]}setColor(t){let e,i=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];if("none"===t)return;const s=this._isColorString(t);if(void 0!==s&&(t=s),!0===Af(t)){if(!0===Zf(t)){const i=t.substr(4).substr(0,t.length-5).split(",");e={r:i[0],g:i[1],b:i[2],a:1}}else if(!0===tv(t)){const i=t.substr(5).substr(0,t.length-6).split(",");e={r:i[0],g:i[1],b:i[2],a:i[3]}}else if(!0===Qf(t)){const i=Wf(t);e={r:i.r,g:i.g,b:i.b,a:1}}}else if(t instanceof Object&&void 0!==t.r&&void 0!==t.g&&void 0!==t.b){const i=void 0!==t.a?t.a:"1.0";e={r:t.r,g:t.g,b:t.b,a:i}}if(void 0===e)throw new Error("Unknown color passed to the colorPicker. Supported are strings: rgb, hex, rgba. Object: rgb ({r:r,g:g,b:b,[a:a]}). Supplied: "+Bp(t));this._setColor(e,i)}show(){void 0!==this.closeCallback&&(this.closeCallback(),this.closeCallback=void 0),this.applied=!1,this.frame.style.display="block",this._generateHueCircle()}_hide(){!0===(!(arguments.length>0&&void 0!==arguments[0])||arguments[0])&&(this.previousColor=bs({},this.color)),!0===this.applied&&this.updateCallback(this.initialColor),this.frame.style.display="none",am(()=>{void 0!==this.closeCallback&&(this.closeCallback(),this.closeCallback=void 0)},0)}_save(){this.updateCallback(this.color),this.applied=!1,this._hide()}_apply(){this.applied=!0,this.updateCallback(this.color),this._updatePicker(this.color)}_loadLast(){void 0!==this.previousColor?this.setColor(this.previousColor,!1):alert("There is no last color to load...")}_setColor(t){!0===(!(arguments.length>1&&void 0!==arguments[1])||arguments[1])&&(this.initialColor=bs({},t)),this.color=t;const e=Yf(t.r,t.g,t.b),i=2*Math.PI,s=this.r*e.s,a=this.centerCoordinates.x+s*Math.sin(i*e.h),o=this.centerCoordinates.y+s*Math.cos(i*e.h);this.colorPickerSelector.style.left=a-.5*this.colorPickerSelector.clientWidth+"px",this.colorPickerSelector.style.top=o-.5*this.colorPickerSelector.clientHeight+"px",this._updatePicker(t)}_setOpacity(t){this.color.a=t/100,this._updatePicker(this.color)}_setBrightness(t){const e=Yf(this.color.r,this.color.g,this.color.b);e.v=t/100;const i=Xf(e.h,e.s,e.v);i.a=this.color.a,this.color=i,this._updatePicker()}_updatePicker(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.color;const e=Yf(t.r,t.g,t.b),i=this.colorPickerCanvas.getContext("2d");void 0===this.pixelRation&&(this.pixelRatio=(window.devicePixelRatio||1)/(i.webkitBackingStorePixelRatio||i.mozBackingStorePixelRatio||i.msBackingStorePixelRatio||i.oBackingStorePixelRatio||i.backingStorePixelRatio||1)),i.setTransform(this.pixelRatio,0,0,this.pixelRatio,0,0);const s=this.colorPickerCanvas.clientWidth,a=this.colorPickerCanvas.clientHeight;i.clearRect(0,0,s,a),i.putImageData(this.hueCircle,0,0),i.fillStyle="rgba(0,0,0,"+(1-e.v)+")",i.circle(this.centerCoordinates.x,this.centerCoordinates.y,this.r),gm(i).call(i),this.brightnessRange.value=100*e.v,this.opacityRange.value=100*t.a,this.initialColorDiv.style.backgroundColor="rgba("+this.initialColor.r+","+this.initialColor.g+","+this.initialColor.b+","+this.initialColor.a+")",this.newColorDiv.style.backgroundColor="rgba("+this.color.r+","+this.color.g+","+this.color.b+","+this.color.a+")"}_setSize(){this.colorPickerCanvas.style.width="100%",this.colorPickerCanvas.style.height="100%",this.colorPickerCanvas.width=289*this.pixelRatio,this.colorPickerCanvas.height=289*this.pixelRatio}_create(){var t,e,i,s;if(this.frame=document.createElement("div"),this.frame.className="vis-color-picker",this.colorPickerDiv=document.createElement("div"),this.colorPickerSelector=document.createElement("div"),this.colorPickerSelector.className="vis-selector",this.colorPickerDiv.appendChild(this.colorPickerSelector),this.colorPickerCanvas=document.createElement("canvas"),this.colorPickerDiv.appendChild(this.colorPickerCanvas),this.colorPickerCanvas.getContext){const t=this.colorPickerCanvas.getContext("2d");this.pixelRatio=(window.devicePixelRatio||1)/(t.webkitBackingStorePixelRatio||t.mozBackingStorePixelRatio||t.msBackingStorePixelRatio||t.oBackingStorePixelRatio||t.backingStorePixelRatio||1),this.colorPickerCanvas.getContext("2d").setTransform(this.pixelRatio,0,0,this.pixelRatio,0,0)}else{const t=document.createElement("DIV");t.style.color="red",t.style.fontWeight="bold",t.style.padding="10px",t.innerText="Error: your browser does not support HTML canvas",this.colorPickerCanvas.appendChild(t)}this.colorPickerDiv.className="vis-color",this.opacityDiv=document.createElement("div"),this.opacityDiv.className="vis-opacity",this.brightnessDiv=document.createElement("div"),this.brightnessDiv.className="vis-brightness",this.arrowDiv=document.createElement("div"),this.arrowDiv.className="vis-arrow",this.opacityRange=document.createElement("input");try{this.opacityRange.type="range",this.opacityRange.min="0",this.opacityRange.max="100"}catch(t){}this.opacityRange.value="100",this.opacityRange.className="vis-range",this.brightnessRange=document.createElement("input");try{this.brightnessRange.type="range",this.brightnessRange.min="0",this.brightnessRange.max="100"}catch(t){}this.brightnessRange.value="100",this.brightnessRange.className="vis-range",this.opacityDiv.appendChild(this.opacityRange),this.brightnessDiv.appendChild(this.brightnessRange);const a=this;this.opacityRange.onchange=function(){a._setOpacity(this.value)},this.opacityRange.oninput=function(){a._setOpacity(this.value)},this.brightnessRange.onchange=function(){a._setBrightness(this.value)},this.brightnessRange.oninput=function(){a._setBrightness(this.value)},this.brightnessLabel=document.createElement("div"),this.brightnessLabel.className="vis-label vis-brightness",this.brightnessLabel.innerText="brightness:",this.opacityLabel=document.createElement("div"),this.opacityLabel.className="vis-label vis-opacity",this.opacityLabel.innerText="opacity:",this.newColorDiv=document.createElement("div"),this.newColorDiv.className="vis-new-color",this.newColorDiv.innerText="new",this.initialColorDiv=document.createElement("div"),this.initialColorDiv.className="vis-initial-color",this.initialColorDiv.innerText="initial",this.cancelButton=document.createElement("div"),this.cancelButton.className="vis-button vis-cancel",this.cancelButton.innerText="cancel",this.cancelButton.onclick=js(t=this._hide).call(t,this,!1),this.applyButton=document.createElement("div"),this.applyButton.className="vis-button vis-apply",this.applyButton.innerText="apply",this.applyButton.onclick=js(e=this._apply).call(e,this),this.saveButton=document.createElement("div"),this.saveButton.className="vis-button vis-save",this.saveButton.innerText="save",this.saveButton.onclick=js(i=this._save).call(i,this),this.loadButton=document.createElement("div"),this.loadButton.className="vis-button vis-load",this.loadButton.innerText="load last",this.loadButton.onclick=js(s=this._loadLast).call(s,this),this.frame.appendChild(this.colorPickerDiv),this.frame.appendChild(this.arrowDiv),this.frame.appendChild(this.brightnessLabel),this.frame.appendChild(this.brightnessDiv),this.frame.appendChild(this.opacityLabel),this.frame.appendChild(this.opacityDiv),this.frame.appendChild(this.newColorDiv),this.frame.appendChild(this.initialColorDiv),this.frame.appendChild(this.cancelButton),this.frame.appendChild(this.applyButton),this.frame.appendChild(this.saveButton),this.frame.appendChild(this.loadButton)}_bindHammer(){this.drag={},this.pinch={},this.hammer=new bf(this.colorPickerCanvas),this.hammer.get("pinch").set({enable:!0}),this.hammer.on("hammer.input",t=>{t.isFirst&&this._moveSelector(t)}),this.hammer.on("tap",t=>{this._moveSelector(t)}),this.hammer.on("panstart",t=>{this._moveSelector(t)}),this.hammer.on("panmove",t=>{this._moveSelector(t)}),this.hammer.on("panend",t=>{this._moveSelector(t)})}_generateHueCircle(){if(!1===this.generated){const t=this.colorPickerCanvas.getContext("2d");void 0===this.pixelRation&&(this.pixelRatio=(window.devicePixelRatio||1)/(t.webkitBackingStorePixelRatio||t.mozBackingStorePixelRatio||t.msBackingStorePixelRatio||t.oBackingStorePixelRatio||t.backingStorePixelRatio||1)),t.setTransform(this.pixelRatio,0,0,this.pixelRatio,0,0);const e=this.colorPickerCanvas.clientWidth,i=this.colorPickerCanvas.clientHeight;let s,a,o,n;t.clearRect(0,0,e,i),this.centerCoordinates={x:.5*e,y:.5*i},this.r=.49*e;const r=2*Math.PI/360,l=1/360,h=1/this.r;let d;for(o=0;o<360;o++)for(n=0;n3&&void 0!==arguments[3]?arguments[3]:1,a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:()=>!1;this.parent=t,this.changedOptions=[],this.container=e,this.allowCreation=!1,this.hideOption=a,this.options={},this.initialized=!1,this.popupCounter=0,this.defaultOptions={enabled:!1,filter:!0,container:void 0,showButton:!0},bs(this.options,this.defaultOptions),this.configureOptions=i,this.moduleOptions={},this.domElements=[],this.popupDiv={},this.popupLimit=5,this.popupHistory={},this.colorPicker=new nv(s),this.wrapper=void 0}setOptions(t){if(void 0!==t){this.popupHistory={},this._removePopup();let e=!0;if("string"==typeof t)this.options.filter=t;else if(Ud(t))this.options.filter=t.join();else if("object"==typeof t){if(null==t)throw new TypeError("options cannot be null");void 0!==t.container&&(this.options.container=t.container),void 0!==Bu(t)&&(this.options.filter=Bu(t)),void 0!==t.showButton&&(this.options.showButton=t.showButton),void 0!==t.enabled&&(e=t.enabled)}else"boolean"==typeof t?(this.options.filter=!0,e=t):"function"==typeof t&&(this.options.filter=t,e=!0);!1===Bu(this.options)&&(e=!1),this.options.enabled=e}this._clean()}setModuleOptions(t){this.moduleOptions=t,!0===this.options.enabled&&(this._clean(),void 0!==this.options.container&&(this.container=this.options.container),this._create())}_create(){this._clean(),this.changedOptions=[];const t=Bu(this.options);let e=0,i=!1;for(const s in this.configureOptions)Object.prototype.hasOwnProperty.call(this.configureOptions,s)&&(this.allowCreation=!1,i=!1,"function"==typeof t?(i=t(s,[]),i=i||this._handleObject(this.configureOptions[s],[s],!0)):!0!==t&&-1===Fp(t).call(t,s)||(i=!0),!1!==i&&(this.allowCreation=!0,e>0&&this._makeItem([]),this._makeHeader(s),this._handleObject(this.configureOptions[s],[s])),e++);this._makeButton(),this._push()}_push(){this.wrapper=document.createElement("div"),this.wrapper.className="vis-configuration-wrapper",this.container.appendChild(this.wrapper);for(let t=0;t1?e-1:0),s=1;s{a.appendChild(t)}),this.domElements.push(a),this.domElements.length}return 0}_makeHeader(t){const e=document.createElement("div");e.className="vis-configuration vis-config-header",e.innerText=t,this._makeItem([],e)}_makeLabel(t,e){let i=arguments.length>2&&void 0!==arguments[2]&&arguments[2];const s=document.createElement("div");if(s.className="vis-configuration vis-config-label vis-config-s"+e.length,!0===i){for(;s.firstChild;)s.removeChild(s.firstChild);s.appendChild(rv("i","b",t))}else s.innerText=t+":";return s}_makeDropdown(t,e,i){const s=document.createElement("select");s.className="vis-configuration vis-config-select";let a=0;void 0!==e&&-1!==Fp(t).call(t,e)&&(a=Fp(t).call(t,e));for(let r=0;ro&&1!==o&&(r.max=Math.ceil(e*t),h=r.max,l="range increased"),r.value=e}else r.value=s;const d=document.createElement("input");d.className="vis-configuration vis-config-rangeinput",d.value=r.value;const c=this;r.onchange=function(){d.value=this.value,c._update(Number(this.value),i)},r.oninput=function(){d.value=this.value};const u=this._makeLabel(i[i.length-1],i),p=this._makeItem(i,u,r,d);""!==l&&this.popupHistory[p]!==h&&(this.popupHistory[p]=h,this._setupPopup(l,p))}_makeButton(){if(!0===this.options.showButton){const t=document.createElement("div");t.className="vis-configuration vis-config-button",t.innerText="generate options",t.onclick=()=>{this._printOptions()},t.onmouseover=()=>{t.className="vis-configuration vis-config-button hover"},t.onmouseout=()=>{t.className="vis-configuration vis-config-button"},this.optionsContainer=document.createElement("div"),this.optionsContainer.className="vis-configuration vis-config-option-container",this.domElements.push(this.optionsContainer),this.domElements.push(t)}}_setupPopup(t,e){if(!0===this.initialized&&!0===this.allowCreation&&this.popupCounter{this._removePopup()},this.popupCounter+=1,this.popupDiv={html:i,index:e}}}_removePopup(){void 0!==this.popupDiv.html&&(this.popupDiv.html.parentNode.removeChild(this.popupDiv.html),clearTimeout(this.popupDiv.hideTimeout),clearTimeout(this.popupDiv.deleteTimeout),this.popupDiv={})}_showPopupIfNeeded(){if(void 0!==this.popupDiv.html){const t=this.domElements[this.popupDiv.index].getBoundingClientRect();this.popupDiv.html.style.left=t.left+"px",this.popupDiv.html.style.top=t.top-30+"px",document.body.appendChild(this.popupDiv.html),this.popupDiv.hideTimeout=am(()=>{this.popupDiv.html.style.opacity=0},1500),this.popupDiv.deleteTimeout=am(()=>{this._removePopup()},1800)}}_makeCheckbox(t,e,i){const s=document.createElement("input");s.type="checkbox",s.className="vis-configuration vis-config-checkbox",s.checked=t,void 0!==e&&(s.checked=e,e!==t&&("object"==typeof t?e!==t.enabled&&this.changedOptions.push({path:i,value:e}):this.changedOptions.push({path:i,value:e})));const a=this;s.onchange=function(){a._update(this.checked,i)};const o=this._makeLabel(i[i.length-1],i);this._makeItem(i,o,s)}_makeTextInput(t,e,i){const s=document.createElement("input");s.type="text",s.className="vis-configuration vis-config-text",s.value=e,e!==t&&this.changedOptions.push({path:i,value:e});const a=this;s.onchange=function(){a._update(this.value,i)};const o=this._makeLabel(i[i.length-1],i);this._makeItem(i,o,s)}_makeColorField(t,e,i){const s=t[1],a=document.createElement("div");"none"!==(e=void 0===e?s:e)?(a.className="vis-configuration vis-config-colorBlock",a.style.backgroundColor=e):a.className="vis-configuration vis-config-colorBlock none",e=void 0===e?s:e,a.onclick=()=>{this._showColorPicker(e,a,i)};const o=this._makeLabel(i[i.length-1],i);this._makeItem(i,o,a)}_showColorPicker(t,e,i){e.onclick=function(){},this.colorPicker.insertTo(e),this.colorPicker.show(),this.colorPicker.setColor(t),this.colorPicker.setUpdateCallback(t=>{const s="rgba("+t.r+","+t.g+","+t.b+","+t.a+")";e.style.backgroundColor=s,this._update(s,i)}),this.colorPicker.setCloseCallback(()=>{e.onclick=()=>{this._showColorPicker(t,e,i)}})}_handleObject(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],i=arguments.length>2&&void 0!==arguments[2]&&arguments[2],s=!1;const a=Bu(this.options);let o=!1;for(const n in t)if(Object.prototype.hasOwnProperty.call(t,n)){s=!0;const r=t[n],l=Lf(e,n);if("function"==typeof a&&(s=a(n,e),!1===s&&!Ud(r)&&"string"!=typeof r&&"boolean"!=typeof r&&r instanceof Object&&(this.allowCreation=!1,s=this._handleObject(r,l,!0),this.allowCreation=!1===i)),!1!==s){o=!0;const t=this._getValue(l);if(Ud(r))this._handleArray(r,t,l);else if("string"==typeof r)this._makeTextInput(r,t,l);else if("boolean"==typeof r)this._makeCheckbox(r,t,l);else if(r instanceof Object){if(!this.hideOption(e,n,this.moduleOptions))if(void 0!==r.enabled){const t=Lf(l,"enabled"),e=this._getValue(t);if(!0===e){const t=this._makeLabel(n,l,!0);this._makeItem(l,t),o=this._handleObject(r,l)||o}else this._makeCheckbox(r,e,l)}else{const t=this._makeLabel(n,l,!0);this._makeItem(l,t),o=this._handleObject(r,l)||o}}else console.error("dont know how to handle",r,n,l)}}return o}_handleArray(t,e,i){"string"==typeof t[0]&&"color"===t[0]?(this._makeColorField(t,e,i),t[1]!==e&&this.changedOptions.push({path:i,value:e})):"string"==typeof t[0]?(this._makeDropdown(t,e,i),t[0]!==e&&this.changedOptions.push({path:i,value:e})):"number"==typeof t[0]&&(this._makeRange(t,e,i),t[0]!==e&&this.changedOptions.push({path:i,value:Number(e)}))}_update(t,e){const i=this._constructOptions(t,e);this.parent.body&&this.parent.body.emitter&&this.parent.body.emitter.emit&&this.parent.body.emitter.emit("configChange",i),this.initialized=!0,this.parent.setOptions(i)}_constructOptions(t,e){let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},s=i;t="false"!==(t="true"===t||t)&&t;for(let a=0;as-this.padding&&(i=!0),a=i?this.x-e:this.x,o=n?this.y-t:this.y}else o=this.y-t,o+t+this.padding>i&&(o=i-t-this.padding),os&&(a=s-e-this.padding),ao.distance?" in "+t.printLocation(a.path,e,"")+"Perhaps it was misplaced? Matching option found at: "+t.printLocation(o.path,o.closestMatch,""):a.distance<=8?'. Did you mean "'+a.closestMatch+'"?'+t.printLocation(a.path,e):". Did you mean one of these: "+t.print(tc(i))+t.printLocation(s,e),console.error('%cUnknown option detected: "'+e+'"'+n,dv),hv=!0}static findInOptions(e,i,s){let a=arguments.length>3&&void 0!==arguments[3]&&arguments[3],o=1e9,n="",r=[];const l=e.toLowerCase();let h;for(const c in i){let u;if(void 0!==i[c].__type__&&!0===a){const a=t.findInOptions(e,i[c],Lf(s,c));o>a.distance&&(n=a.closestMatch,r=a.path,o=a.distance,h=a.indexMatch)}else{var d;-1!==Fp(d=c.toLowerCase()).call(d,l)&&(h=c),u=t.levenshteinDistance(e,c),o>u&&(n=c,r=Mf(s),o=u)}}return{closestMatch:n,path:r,distance:o,indexMatch:h}}static printLocation(t,e){let i="\n\n"+(arguments.length>2&&void 0!==arguments[2]?arguments[2]:"Problem value found at: \n")+"options = {\n";for(let s=0;s0)return"before"==s?Math.max(0,l-1):l;if(a(n,e)<0&&a(r,e)>0)return"before"==s?l:Math.min(t.length-1,l+1);a(n,e)<0?d=l+1:c=l-1,h++}return-1},bridgeObject:ev,copyAndExtendArray:Lf,copyArray:Mf,deepExtend:Pf,deepObjectAssign:mf,easingFunctions:sv,equalArray:function(t,e){if(t.length!==e.length)return!1;for(let i=0,s=t.length;i0&&void 0!==arguments[0]?arguments[0]:window.event,e=null;return t&&(t.target?e=t.target:t.srcElement&&(e=t.srcElement)),e instanceof Element&&(null==e.nodeType||3!=e.nodeType||(e=e.parentNode,e instanceof Element))?e:null},getType:function(t){const e=typeof t;return"object"===e?null===t?"null":t instanceof Boolean?"Boolean":t instanceof Number?"Number":t instanceof String?"String":Ud(t)?"Array":t instanceof Date?"Date":"Object":"number"===e?"Number":"boolean"===e?"Boolean":"string"===e?"String":void 0===e?"undefined":e},hasParent:function(t,e){let i=t;for(;i;){if(i===e)return!0;if(!i.parentNode)return!1;i=i.parentNode}return!1},hexToHSV:Jf,hexToRGB:Wf,insertSort:function(t,e){for(let i=0;i0&&e(s,t[a-1])<0;a--)t[a]=t[a-1];t[a]=s}return t},isDate:function(t){if(t instanceof Date)return!0;if(Af(t)){if(_f.exec(t))return!0;if(!isNaN(Date.parse(t)))return!0}return!1},isNumber:Tf,isObject:Ef,isString:Af,isValidHex:Qf,isValidRGB:Zf,isValidRGBA:tv,mergeOptions:iv,option:Hf,overrideOpacity:Uf,parseColor:qf,preventDefault:function(t){t||(t=window.event),t&&(t.preventDefault?t.preventDefault():t.returnValue=!1)},pureDeepObjectAssign:pf,recursiveDOMDelete:Sf,removeClassName:function(t,e){let i=t.className.split(" ");const s=e.split(" ");i=Bu(i).call(i,(function(t){return!xu(s).call(s,t)})),t.className=i.join(" ")},removeCssText:function(t,e){const i=Gf(e);for(const s of tc(i))t.style.removeProperty(s)},selectiveBridgeObject:function(t,e){if(null!==e&&"object"==typeof e){const i=Pp(e);for(let s=0;s2?i-2:0),a=2;a{e||(e=!0,requestAnimationFrame(()=>{e=!1,t()}))}},toArray:Vf,topMost:av,updateProperty:function(t,e,i){return t[e]!==i&&(t[e]=i,!0)}});function bv(t){return Dv=t,function(){var t={};if(kv=0,Tv=Dv.charAt(0),Mv(),"strict"===Sv&&(t.strict=!0,Mv()),"graph"!==Sv&&"digraph"!==Sv||(t.type=Sv,Mv()),Av===xv.IDENTIFIER&&(t.id=Sv,Mv()),"{"!=Sv)throw Wv("Angle bracket { expected");if(Mv(),zv(t),"}"!=Sv)throw Wv("Angle bracket } expected");if(Mv(),""!==Sv)throw Wv("End of file expected");return Mv(),delete t.node,delete t.edge,delete t.graph,t}()}var wv={fontsize:"font.size",fontcolor:"font.color",labelfontcolor:"font.color",fontname:"font.face",color:["color.border","color.background"],fillcolor:"color.background",tooltip:"title",labeltooltip:"title"},_v=Pp(wv);_v.color="color.color",_v.style="dashes";var xv={NULL:0,DELIMITER:1,IDENTIFIER:2,UNKNOWN:3},Cv={"{":!0,"}":!0,"[":!0,"]":!0,";":!0,"=":!0,",":!0,"->":!0,"--":!0},Dv="",kv=0,Tv="",Sv="",Av=xv.NULL;function Ev(){kv++,Tv=Dv.charAt(kv)}function Ov(){return Dv.charAt(kv+1)}function Fv(t){var e=t.charCodeAt(0);return e<47?35===e||46===e:e<59?e>47:e<91?e>64:e<96?95===e:e<123&&e>96}function Nv(t,e){if(t||(t={}),e)for(var i in e)e.hasOwnProperty(i)&&(t[i]=e[i]);return t}function Iv(t,e,i){for(var s=e.split("."),a=t;s.length;){var o=s.shift();s.length?(a[o]||(a[o]={}),a=a[o]):a[o]=i}}function Rv(t,e){for(var i,s,a=null,o=[t],n=t;n.parent;)o.push(n.parent),n=n.parent;if(n.nodes)for(i=0,s=n.nodes.length;i=0;i--){var r,l=o[i];l.nodes||(l.nodes=[]),-1===Fp(r=l.nodes).call(r,a)&&l.nodes.push(a)}e.attr&&(a.attr=Nv(a.attr,e.attr))}function Pv(t,e){if(t.edges||(t.edges=[]),t.edges.push(e),t.edge){var i=Nv({},t.edge);e.attr=Nv(i,e.attr)}}function Lv(t,e,i,s,a){var o={from:e,to:i,type:s};return t.edge&&(o.attr=Nv({},t.edge)),o.attr=Nv(o.attr||{},a),null!=a&&a.hasOwnProperty("arrows")&&null!=a.arrows&&(o.arrows={to:{enabled:!0,type:a.arrows.type}},a.arrows=null),o}function Mv(){for(Av=xv.NULL,Sv="";" "===Tv||"\t"===Tv||"\n"===Tv||"\r"===Tv;)Ev();do{var t=!1;if("#"===Tv){for(var e=kv-1;" "===Dv.charAt(e)||"\t"===Dv.charAt(e);)e--;if("\n"===Dv.charAt(e)||""===Dv.charAt(e)){for(;""!=Tv&&"\n"!=Tv;)Ev();t=!0}}if("/"===Tv&&"/"===Ov()){for(;""!=Tv&&"\n"!=Tv;)Ev();t=!0}if("/"===Tv&&"*"===Ov()){for(;""!=Tv;){if("*"===Tv&&"/"===Ov()){Ev(),Ev();break}Ev()}t=!0}for(;" "===Tv||"\t"===Tv||"\n"===Tv||"\r"===Tv;)Ev()}while(t);if(""!==Tv){var i=Tv+Ov();if(Cv[i])return Av=xv.DELIMITER,Sv=i,Ev(),void Ev();if(Cv[Tv])return Av=xv.DELIMITER,Sv=Tv,void Ev();if(Fv(Tv)||"-"===Tv){for(Sv+=Tv,Ev();Fv(Tv);)Sv+=Tv,Ev();return"false"===Sv?Sv=!1:"true"===Sv?Sv=!0:isNaN(Number(Sv))||(Sv=Number(Sv)),void(Av=xv.IDENTIFIER)}if('"'===Tv){for(Ev();""!=Tv&&('"'!=Tv||'"'===Tv&&'"'===Ov());)'"'===Tv?(Sv+=Tv,Ev()):"\\"===Tv&&"n"===Ov()?(Sv+="\n",Ev()):Sv+=Tv,Ev();if('"'!=Tv)throw Wv('End of string " expected');return Ev(),void(Av=xv.IDENTIFIER)}for(Av=xv.UNKNOWN;""!=Tv;)Sv+=Tv,Ev();throw new SyntaxError('Syntax error in part "'+Uv(Sv,30)+'"')}Av=xv.DELIMITER}function zv(t){for(;""!==Sv&&"}"!=Sv;)Bv(t),";"===Sv&&Mv()}function Bv(t){var e=jv(t);if(e)Vv(t,e);else{var i=function(t){return"node"===Sv?(Mv(),t.node=Hv(),"node"):"edge"===Sv?(Mv(),t.edge=Hv(),"edge"):"graph"===Sv?(Mv(),t.graph=Hv(),"graph"):null}(t);if(!i){if(Av!=xv.IDENTIFIER)throw Wv("Identifier expected");var s=Sv;if(Mv(),"="===Sv){if(Mv(),Av!=xv.IDENTIFIER)throw Wv("Identifier expected");t[s]=Sv,Mv()}else!function(t,e){var i={id:e},s=Hv();s&&(i.attr=s),Rv(t,i),Vv(t,e)}(t,s)}}}function jv(t){var e=null;if("subgraph"===Sv&&((e={}).type="subgraph",Mv(),Av===xv.IDENTIFIER&&(e.id=Sv,Mv())),"{"===Sv){if(Mv(),e||(e={}),e.parent=t,e.node=t.node,e.edge=t.edge,e.graph=t.graph,zv(e),"}"!=Sv)throw Wv("Angle bracket } expected");Mv(),delete e.node,delete e.edge,delete e.graph,delete e.parent,t.subgraphs||(t.subgraphs=[]),t.subgraphs.push(e)}return e}function Vv(t,e){for(;"->"===Sv||"--"===Sv;){var i,s=Sv;Mv();var a=jv(t);if(a)i=a;else{if(Av!=xv.IDENTIFIER)throw Wv("Identifier or subgraph expected");Rv(t,{id:i=Sv}),Mv()}Pv(t,Lv(t,e,i,s,Hv())),e=i}}function Hv(){for(var t,e,i=null,s={dashed:!0,solid:!1,dotted:[1,5]},a={dot:"circle",box:"box",crow:"crow",curve:"curve",icurve:"inv_curve",normal:"triangle",inv:"inv_triangle",diamond:"diamond",tee:"bar",vee:"vee"},o=new Array,n=new Array;"["===Sv;){for(Mv(),i={};""!==Sv&&"]"!=Sv;){if(Av!=xv.IDENTIFIER)throw Wv("Attribute name expected");var r=Sv;if(Mv(),"="!=Sv)throw Wv("Equal sign = expected");if(Mv(),Av!=xv.IDENTIFIER)throw Wv("Attribute value expected");var l=Sv;"style"===r&&(l=s[l]),"arrowhead"===r&&(r="arrows",l={to:{enabled:!0,type:a[l]}}),"arrowtail"===r&&(r="arrows",l={from:{enabled:!0,type:a[l]}}),o.push({attr:i,name:r,value:l}),n.push(r),Mv(),","==Sv&&Mv()}if("]"!=Sv)throw Wv("Bracket ] expected");Mv()}if(xu(n).call(n,"dir")){var h={arrows:{}};for(t=0;t"===t.type&&(e.arrows="to"),e};vc(a=i.edges).call(a,(function(t){var e,i,a,n,r,l,h;e=t.from instanceof Object?t.from.nodes:{id:t.from},i=t.to instanceof Object?t.to.nodes:{id:t.to},t.from instanceof Object&&t.from.edges&&vc(a=t.from.edges).call(a,(function(t){var e=o(t);s.edges.push(e)})),r=i,l=function(e,i){var a=Lv(s,e.id,i.id,t.type,t.attr),n=o(a);s.edges.push(n)},Ud(n=e)?vc(n).call(n,(function(t){Ud(r)?vc(r).call(r,(function(e){l(t,e)})):l(t,r)})):Ud(r)?vc(r).call(r,(function(t){l(n,t)})):l(n,r),t.to instanceof Object&&t.to.edges&&vc(h=t.to.edges).call(h,(function(t){var e=o(t);s.edges.push(e)}))}))}return i.attr&&(s.options=i.attr),s}var Gv=Object.freeze({__proto__:null,DOTToGraph:Yv,parseDOT:bv});function Xv(t,e){var i;const s={edges:{inheritColor:!1},nodes:{fixed:!1,parseColor:!1}};null!=e&&(null!=e.fixed&&(s.nodes.fixed=e.fixed),null!=e.parseColor&&(s.nodes.parseColor=e.parseColor),null!=e.inheritColor&&(s.edges.inheritColor=e.inheritColor));const a=t.edges,o=Jd(a).call(a,t=>{const e={from:t.source,id:t.id,to:t.target};return null!=t.attributes&&(e.attributes=t.attributes),null!=t.label&&(e.label=t.label),null!=t.attributes&&null!=t.attributes.title&&(e.title=t.attributes.title),"Directed"===t.type&&(e.arrows="to"),t.color&&!1===s.edges.inheritColor&&(e.color=t.color),e});return{nodes:Jd(i=t.nodes).call(i,t=>{const e={id:t.id,fixed:s.nodes.fixed&&null!=t.x&&null!=t.y};return null!=t.attributes&&(e.attributes=t.attributes),null!=t.label&&(e.label=t.label),null!=t.size&&(e.size=t.size),null!=t.attributes&&null!=t.attributes.title&&(e.title=t.attributes.title),null!=t.title&&(e.title=t.title),null!=t.x&&(e.x=t.x),null!=t.y&&(e.y=t.y),null!=t.color&&(!0===s.nodes.parseColor?e.color=t.color:e.color={background:t.color,border:t.color,highlight:{background:t.color,border:t.color},hover:{background:t.color,border:t.color}}),e}),edges:o}}var Kv=Object.freeze({__proto__:null,parseGephi:Xv}),Jv=Object.freeze({__proto__:null,cn:{addDescription:"单击空白处放置新节点。",addEdge:"添加连接线",addNode:"添加节点",back:"返回",close:"關閉",createEdgeError:"无法将连接线连接到群集。",del:"删除选定",deleteClusterError:"无法删除群集。",edgeDescription:"单击某个节点并将该连接线拖动到另一个节点以连接它们。",edit:"编辑",editClusterError:"无法编辑群集。",editEdge:"编辑连接线",editEdgeDescription:"单击控制节点并将它们拖到节点上连接。",editNode:"编辑节点"},cs:{addDescription:"Kluknutím do prázdného prostoru můžete přidat nový vrchol.",addEdge:"Přidat hranu",addNode:"Přidat vrchol",back:"Zpět",close:"Zavřít",createEdgeError:"Nelze připojit hranu ke shluku.",del:"Smazat výběr",deleteClusterError:"Nelze mazat shluky.",edgeDescription:"Přetažením z jednoho vrcholu do druhého můžete spojit tyto vrcholy novou hranou.",edit:"Upravit",editClusterError:"Nelze upravovat shluky.",editEdge:"Upravit hranu",editEdgeDescription:"Přetažením kontrolního vrcholu hrany ji můžete připojit k jinému vrcholu.",editNode:"Upravit vrchol"},de:{addDescription:"Klicke auf eine freie Stelle, um einen neuen Knoten zu plazieren.",addEdge:"Kante hinzufügen",addNode:"Knoten hinzufügen",back:"Zurück",close:"Schließen",createEdgeError:"Es ist nicht möglich, Kanten mit Clustern zu verbinden.",del:"Lösche Auswahl",deleteClusterError:"Cluster können nicht gelöscht werden.",edgeDescription:"Klicke auf einen Knoten und ziehe die Kante zu einem anderen Knoten, um diese zu verbinden.",edit:"Editieren",editClusterError:"Cluster können nicht editiert werden.",editEdge:"Kante editieren",editEdgeDescription:"Klicke auf die Verbindungspunkte und ziehe diese auf einen Knoten, um sie zu verbinden.",editNode:"Knoten editieren"},en:{addDescription:"Click in an empty space to place a new node.",addEdge:"Add Edge",addNode:"Add Node",back:"Back",close:"Close",createEdgeError:"Cannot link edges to a cluster.",del:"Delete selected",deleteClusterError:"Clusters cannot be deleted.",edgeDescription:"Click on a node and drag the edge to another node to connect them.",edit:"Edit",editClusterError:"Clusters cannot be edited.",editEdge:"Edit Edge",editEdgeDescription:"Click on the control points and drag them to a node to connect to it.",editNode:"Edit Node"},es:{addDescription:"Haga clic en un lugar vacío para colocar un nuevo nodo.",addEdge:"Añadir arista",addNode:"Añadir nodo",back:"Atrás",close:"Cerrar",createEdgeError:"No se puede conectar una arista a un grupo.",del:"Eliminar selección",deleteClusterError:"No es posible eliminar grupos.",edgeDescription:"Haga clic en un nodo y arrastre la arista hacia otro nodo para conectarlos.",edit:"Editar",editClusterError:"No es posible editar grupos.",editEdge:"Editar arista",editEdgeDescription:"Haga clic en un punto de control y arrastrelo a un nodo para conectarlo.",editNode:"Editar nodo"},fr:{addDescription:"Cliquez dans un endroit vide pour placer un nœud.",addEdge:"Ajouter un lien",addNode:"Ajouter un nœud",back:"Retour",close:"Fermer",createEdgeError:"Impossible de créer un lien vers un cluster.",del:"Effacer la sélection",deleteClusterError:"Les clusters ne peuvent pas être effacés.",edgeDescription:"Cliquez sur un nœud et glissez le lien vers un autre nœud pour les connecter.",edit:"Éditer",editClusterError:"Les clusters ne peuvent pas être édités.",editEdge:"Éditer le lien",editEdgeDescription:"Cliquez sur les points de contrôle et glissez-les pour connecter un nœud.",editNode:"Éditer le nœud"},it:{addDescription:"Clicca per aggiungere un nuovo nodo",addEdge:"Aggiungi un vertice",addNode:"Aggiungi un nodo",back:"Indietro",close:"Chiudere",createEdgeError:"Non si possono collegare vertici ad un cluster",del:"Cancella la selezione",deleteClusterError:"I cluster non possono essere cancellati",edgeDescription:"Clicca su un nodo e trascinalo ad un altro nodo per connetterli.",edit:"Modifica",editClusterError:"I clusters non possono essere modificati.",editEdge:"Modifica il vertice",editEdgeDescription:"Clicca sui Punti di controllo e trascinali ad un nodo per connetterli.",editNode:"Modifica il nodo"},nl:{addDescription:"Klik op een leeg gebied om een nieuwe node te maken.",addEdge:"Link toevoegen",addNode:"Node toevoegen",back:"Terug",close:"Sluiten",createEdgeError:"Kan geen link maken naar een cluster.",del:"Selectie verwijderen",deleteClusterError:"Clusters kunnen niet worden verwijderd.",edgeDescription:"Klik op een node en sleep de link naar een andere node om ze te verbinden.",edit:"Wijzigen",editClusterError:"Clusters kunnen niet worden aangepast.",editEdge:"Link wijzigen",editEdgeDescription:"Klik op de verbindingspunten en sleep ze naar een node om daarmee te verbinden.",editNode:"Node wijzigen"},pt:{addDescription:"Clique em um espaço em branco para adicionar um novo nó",addEdge:"Adicionar aresta",addNode:"Adicionar nó",back:"Voltar",close:"Fechar",createEdgeError:"Não foi possível linkar arestas a um cluster.",del:"Remover selecionado",deleteClusterError:"Clusters não puderam ser removidos.",edgeDescription:"Clique em um nó e arraste a aresta até outro nó para conectá-los",edit:"Editar",editClusterError:"Clusters não puderam ser editados.",editEdge:"Editar aresta",editEdgeDescription:"Clique nos pontos de controle e os arraste para um nó para conectá-los",editNode:"Editar nó"},ru:{addDescription:"Кликните в свободное место, чтобы добавить новый узел.",addEdge:"Добавить ребро",addNode:"Добавить узел",back:"Назад",close:"Закрывать",createEdgeError:"Невозможно соединить ребра в кластер.",del:"Удалить выбранное",deleteClusterError:"Кластеры не могут быть удалены",edgeDescription:"Кликните на узел и протяните ребро к другому узлу, чтобы соединить их.",edit:"Редактировать",editClusterError:"Кластеры недоступны для редактирования.",editEdge:"Редактировать ребро",editEdgeDescription:"Кликните на контрольные точки и перетащите их в узел, чтобы подключиться к нему.",editNode:"Редактировать узел"},uk:{addDescription:"Kлікніть на вільне місце, щоб додати новий вузол.",addEdge:"Додати край",addNode:"Додати вузол",back:"Назад",close:"Закрити",createEdgeError:"Не можливо об'єднати краї в групу.",del:"Видалити обране",deleteClusterError:"Групи не можуть бути видалені.",edgeDescription:"Клікніть на вузол і перетягніть край до іншого вузла, щоб їх з'єднати.",edit:"Редагувати",editClusterError:"Групи недоступні для редагування.",editEdge:"Редагувати край",editEdgeDescription:"Клікніть на контрольні точки і перетягніть їх у вузол, щоб підключитися до нього.",editNode:"Редагувати вузол"}});class Qv{constructor(){this.NUM_ITERATIONS=4,this.image=new Image,this.canvas=document.createElement("canvas")}init(){if(this.initialized())return;this.src=this.image.src;const t=this.image.width,e=this.image.height;this.width=t,this.height=e;const i=Math.floor(e/2),s=Math.floor(e/4),a=Math.floor(e/8),o=Math.floor(e/16),n=Math.floor(t/2),r=Math.floor(t/4),l=Math.floor(t/8),h=Math.floor(t/16);this.canvas.width=3*r,this.canvas.height=i,this.coordinates=[[0,0,n,i],[n,0,r,s],[n,s,l,a],[5*l,s,h,o]],this._fillMipMap()}initialized(){return void 0!==this.coordinates}_fillMipMap(){const t=this.canvas.getContext("2d"),e=this.coordinates[0];t.drawImage(this.image,e[0],e[1],e[2],e[3]);for(let i=1;i2){e*=.5;let n=0;for(;e>2&&n=this.NUM_ITERATIONS&&(n=this.NUM_ITERATIONS-1);const r=this.coordinates[n];t.drawImage(this.canvas,r[0],r[1],r[2],r[3],i,s,a,o)}else t.drawImage(this.image,i,s,a,o)}}class Zv{constructor(t){this.images={},this.imageBroken={},this.callback=t}_tryloadBrokenUrl(t,e,i){void 0!==t&&void 0!==i&&(void 0!==e?(i.image.onerror=()=>{console.error("Could not load brokenImage:",e)},i.image.src=e):console.warn("No broken url image defined"))}_redrawWithImage(t){this.callback&&this.callback(t)}load(t,e){const i=this.images[t];if(i)return i;const s=new Qv;return this.images[t]=s,s.image.onload=()=>{this._fixImageCoordinates(s.image),s.init(),this._redrawWithImage(s)},s.image.onerror=()=>{console.error("Could not load image:",t),this._tryloadBrokenUrl(t,e,s)},s.image.src=t,s}_fixImageCoordinates(t){0===t.width&&(document.body.appendChild(t),t.width=t.offsetWidth,t.height=t.offsetHeight,document.body.removeChild(t))}}var ty={exports:{}},ey=n((function(){if("function"==typeof ArrayBuffer){var t=new ArrayBuffer(8);Object.isExtensible(t)&&Object.defineProperty(t,"a",{value:8})}})),iy=n,sy=et,ay=_,oy=ey,ny=Object.isExtensible,ry=iy((function(){ny(1)}))||oy?function(t){return!!sy(t)&&(!oy||"ArrayBuffer"!==ay(t))&&(!ny||ny(t))}:ny,ly=!n((function(){return Object.isExtensible(Object.preventExtensions({}))})),hy=Ei,dy=v,cy=Yi,uy=et,py=Zt,my=Qe.f,gy=Fo,fy=Ro,vy=ry,yy=ly,by=!1,wy=ae("meta"),_y=0,xy=function(t){my(t,wy,{value:{objectID:"O"+_y++,weakData:{}}})},Cy=ty.exports={enable:function(){Cy.enable=function(){},by=!0;var t=gy.f,e=dy([].splice),i={};i[wy]=1,t(i).length&&(gy.f=function(i){for(var s=t(i),a=0,o=s.length;ao;o++)if((r=v(t[o]))&&Ky(ib,r))return r;return new eb(!1)}s=Jy(t,a)}for(l=u?t.next:s.next;!(h=$y(l,s)).done;){try{r=v(h.value)}catch(t){Zy(s,"throw",t)}if("object"==typeof r&&r&&Ky(ib,r))return r}return new eb(!1)},ab=lt,ob=TypeError,nb=function(t,e){if(ab(e,t))return t;throw new ob("Incorrect invocation")},rb=Ei,lb=o,hb=Dy,db=n,cb=vi,ub=sb,pb=nb,mb=A,gb=et,fb=q,vb=wn,yb=Qe.f,bb=$n.forEach,wb=O,_b=Mn.set,xb=Mn.getterFor,Cb=function(t,e,i){var s,a=-1!==t.indexOf("Map"),o=-1!==t.indexOf("Weak"),n=a?"set":"add",r=lb[t],l=r&&r.prototype,h={};if(wb&&mb(r)&&(o||l.forEach&&!db((function(){(new r).entries().next()})))){var d=(s=e((function(e,i){_b(pb(e,d),{type:t,collection:new r}),fb(i)||ub(i,e[n],{that:e,AS_ENTRIES:a})}))).prototype,c=xb(t);bb(["add","clear","delete","forEach","get","has","set","keys","values","entries"],(function(t){var e="add"===t||"set"===t;!(t in l)||o&&"clear"===t||cb(d,t,(function(i,s){var a=c(this).collection;if(!e&&o&&!gb(i))return"get"===t&&void 0;var n=a[t](0===i?0:i,s);return e?this:n}))})),o||yb(d,"size",{configurable:!0,get:function(){return c(this).collection.size}})}else s=i.getConstructor(e,t,a,n),hb.enable();return vb(s,t,!1,!0),h[t]=s,rb({global:!0,forced:!0},h),o||i.setStrong(s,t,a),s},Db=Yo,kb=function(t,e,i){for(var s in e)i&&i.unsafe&&t[s]?t[s]=e[s]:Db(t,s,e[s],i);return t},Tb=rt,Sb=Xo,Ab=O,Eb=pe("species"),Ob=Oo,Fb=Xo,Nb=kb,Ib=Je,Rb=nb,Pb=q,Lb=sb,Mb=Kh,zb=Jh,Bb=function(t){var e=Tb(t);Ab&&e&&!e[Eb]&&Sb(e,Eb,{configurable:!0,get:function(){return this}})},jb=O,Vb=Dy.fastKey,Hb=Mn.set,Wb=Mn.getterFor,Ub={getConstructor:function(t,e,i,s){var a=t((function(t,a){Rb(t,o),Hb(t,{type:e,index:Ob(null),first:void 0,last:void 0,size:0}),jb||(t.size=0),Pb(a)||Lb(a,t[s],{that:t,AS_ENTRIES:i})})),o=a.prototype,n=Wb(e),r=function(t,e,i){var s,a,o=n(t),r=l(t,e);return r?r.value=i:(o.last=r={index:a=Vb(e,!0),key:e,value:i,previous:s=o.last,next:void 0,removed:!1},o.first||(o.first=r),s&&(s.next=r),jb?o.size++:t.size++,"F"!==a&&(o.index[a]=r)),t},l=function(t,e){var i,s=n(t),a=Vb(e);if("F"!==a)return s.index[a];for(i=s.first;i;i=i.next)if(i.key===e)return i};return Nb(o,{clear:function(){for(var t=n(this),e=t.index,i=t.first;i;)i.removed=!0,i.previous&&(i.previous=i.previous.next=void 0),delete e[i.index],i=i.next;t.first=t.last=void 0,jb?t.size=0:this.size=0},delete:function(t){var e=this,i=n(e),s=l(e,t);if(s){var a=s.next,o=s.previous;delete i.index[s.index],s.removed=!0,o&&(o.next=a),a&&(a.previous=o),i.first===s&&(i.first=a),i.last===s&&(i.last=o),jb?i.size--:e.size--}return!!s},forEach:function(t){for(var e,i=n(this),s=Ib(t,arguments.length>1?arguments[1]:void 0);e=e?e.next:i.first;)for(s(e.value,e.key,this);e&&e.removed;)e=e.previous},has:function(t){return!!l(this,t)}}),Nb(o,i?{get:function(t){var e=l(this,t);return e&&e.value},set:function(t,e){return r(this,0===t?0:t,e)}}:{add:function(t){return r(this,t=0===t?0:t,t)}}),jb&&Fb(o,"size",{configurable:!0,get:function(){return n(this).size}}),a},setStrong:function(t,e,i){var s=e+" Iterator",a=Wb(e),o=Wb(s);Mb(t,e,(function(t,e){Hb(this,{type:s,target:t,state:a(t),kind:e,last:void 0})}),(function(){for(var t=o(this),e=t.kind,i=t.last;i&&i.removed;)i=i.previous;return t.target&&(t.last=i=i?i.next:t.state.first)?zb("keys"===e?i.key:"values"===e?i.value:[i.key,i.value],!1):(t.target=void 0,zb(void 0,!0))}),i?"entries":"values",!i,!0),Bb(e)}};Cb("Map",(function(t){return function(){return t(this,arguments.length?arguments[0]:void 0)}}),Ub);var $b=v,qb=Ii,Yb=so,Gb=X,Xb=$b("".charAt),Kb=$b("".charCodeAt),Jb=$b("".slice),Qb=function(t){return function(e,i){var s,a,o=Yb(Gb(e)),n=qb(i),r=o.length;return n<0||n>=r?t?"":void 0:(s=Kb(o,n))<55296||s>56319||n+1===r||(a=Kb(o,n+1))<56320||a>57343?t?Xb(o,n):s:t?Jb(o,n,n+2):a-56320+(s-55296<<10)+65536}},Zb={codeAt:Qb(!1),charAt:Qb(!0)}.charAt,tw=so,ew=Mn,iw=Kh,sw=Jh,aw="String Iterator",ow=ew.set,nw=ew.getterFor(aw);iw(String,"String",(function(t){ow(this,{type:aw,string:tw(t),index:0})}),(function(){var t,e=nw(this),i=e.string,s=e.index;return s>=i.length?sw(void 0,!0):(t=Zb(i,s),e.index+=t.length,sw(t,!1))}));var rw=s(it.Map);class lw{constructor(){this.clear(),this._defaultIndex=0,this._groupIndex=0,this._defaultGroups=[{border:"#2B7CE9",background:"#97C2FC",highlight:{border:"#2B7CE9",background:"#D2E5FF"},hover:{border:"#2B7CE9",background:"#D2E5FF"}},{border:"#FFA500",background:"#FFFF00",highlight:{border:"#FFA500",background:"#FFFFA3"},hover:{border:"#FFA500",background:"#FFFFA3"}},{border:"#FA0A10",background:"#FB7E81",highlight:{border:"#FA0A10",background:"#FFAFB1"},hover:{border:"#FA0A10",background:"#FFAFB1"}},{border:"#41A906",background:"#7BE141",highlight:{border:"#41A906",background:"#A1EC76"},hover:{border:"#41A906",background:"#A1EC76"}},{border:"#E129F0",background:"#EB7DF4",highlight:{border:"#E129F0",background:"#F0B3F5"},hover:{border:"#E129F0",background:"#F0B3F5"}},{border:"#7C29F0",background:"#AD85E4",highlight:{border:"#7C29F0",background:"#D3BDF0"},hover:{border:"#7C29F0",background:"#D3BDF0"}},{border:"#C37F00",background:"#FFA807",highlight:{border:"#C37F00",background:"#FFCA66"},hover:{border:"#C37F00",background:"#FFCA66"}},{border:"#4220FB",background:"#6E6EFD",highlight:{border:"#4220FB",background:"#9B9BFD"},hover:{border:"#4220FB",background:"#9B9BFD"}},{border:"#FD5A77",background:"#FFC0CB",highlight:{border:"#FD5A77",background:"#FFD1D9"},hover:{border:"#FD5A77",background:"#FFD1D9"}},{border:"#4AD63A",background:"#C2FABC",highlight:{border:"#4AD63A",background:"#E6FFE3"},hover:{border:"#4AD63A",background:"#E6FFE3"}},{border:"#990000",background:"#EE0000",highlight:{border:"#BB0000",background:"#FF3333"},hover:{border:"#BB0000",background:"#FF3333"}},{border:"#FF6000",background:"#FF6000",highlight:{border:"#FF6000",background:"#FF6000"},hover:{border:"#FF6000",background:"#FF6000"}},{border:"#97C2FC",background:"#2B7CE9",highlight:{border:"#D2E5FF",background:"#2B7CE9"},hover:{border:"#D2E5FF",background:"#2B7CE9"}},{border:"#399605",background:"#255C03",highlight:{border:"#399605",background:"#255C03"},hover:{border:"#399605",background:"#255C03"}},{border:"#B70054",background:"#FF007E",highlight:{border:"#B70054",background:"#FF007E"},hover:{border:"#B70054",background:"#FF007E"}},{border:"#AD85E4",background:"#7C29F0",highlight:{border:"#D3BDF0",background:"#7C29F0"},hover:{border:"#D3BDF0",background:"#7C29F0"}},{border:"#4557FA",background:"#000EA1",highlight:{border:"#6E6EFD",background:"#000EA1"},hover:{border:"#6E6EFD",background:"#000EA1"}},{border:"#FFC0CB",background:"#FD5A77",highlight:{border:"#FFD1D9",background:"#FD5A77"},hover:{border:"#FFD1D9",background:"#FD5A77"}},{border:"#C2FABC",background:"#74D66A",highlight:{border:"#E6FFE3",background:"#74D66A"},hover:{border:"#E6FFE3",background:"#74D66A"}},{border:"#EE0000",background:"#990000",highlight:{border:"#FF3333",background:"#BB0000"},hover:{border:"#FF3333",background:"#BB0000"}}],this.options={},this.defaultOptions={useDefaultGroups:!0},bs(this.options,this.defaultOptions)}setOptions(t){const e=["useDefaultGroups"];if(void 0!==t)for(const i in t)if(Object.prototype.hasOwnProperty.call(t,i)&&-1===Fp(e).call(e,i)){const e=t[i];this.add(i,e)}}clear(){this._groups=new rw,this._groupNames=[]}get(t){let e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=this._groups.get(t);if(void 0===i&&e)if(!1===this.options.useDefaultGroups&&this._groupNames.length>0){const e=this._groupIndex%this._groupNames.length;++this._groupIndex,i={},i.color=this._groups.get(this._groupNames[e]),this._groups.set(t,i)}else{const e=this._defaultIndex%this._defaultGroups.length;this._defaultIndex++,i={},i.color=this._defaultGroups[e],this._groups.set(t,i)}return i}add(t,e){return this._groups.has(t)||this._groupNames.push(t),this._groups.set(t,e),e}}Ei({target:"Number",stat:!0},{isNaN:function(t){return t!=t}});var hw=s(it.Number.isNaN),dw=o.isFinite,cw=Number.isFinite||function(t){return"number"==typeof t&&dw(t)};Ei({target:"Number",stat:!0},{isFinite:cw});var uw=s(it.Number.isFinite),pw=$n.some;Ei({target:"Array",proto:!0,forced:!nc("some")},{some:function(t){return pw(this,t,arguments.length>1?arguments[1]:void 0)}});var mw=Rs("Array").some,gw=lt,fw=mw,vw=Array.prototype,yw=function(t){var e=t.some;return t===vw||gw(vw,t)&&e===vw.some?fw:e},bw=s(yw),ww=s(it.Object.getOwnPropertySymbols),_w={exports:{}},xw=Ei,Cw=n,Dw=Q,kw=E.f,Tw=O;xw({target:"Object",stat:!0,forced:!Tw||Cw((function(){kw(1)})),sham:!Tw},{getOwnPropertyDescriptor:function(t,e){return kw(Dw(t),e)}});var Sw=it.Object,Aw=_w.exports=function(t,e){return Sw.getOwnPropertyDescriptor(t,e)};Sw.getOwnPropertyDescriptor.sham&&(Aw.sham=!0);var Ew=s(_w.exports),Ow=Hd,Fw=Q,Nw=E,Iw=ia;Ei({target:"Object",stat:!0,sham:!O},{getOwnPropertyDescriptors:function(t){for(var e,i,s=Fw(t),a=Nw.f,o=Ow(s),n={},r=0;o.length>r;)void 0!==(i=a(s,e=o[r++]))&&Iw(n,e,i);return n}});var Rw=s(it.Object.getOwnPropertyDescriptors),Pw={exports:{}},Lw=Ei,Mw=O,zw=ao.f;Lw({target:"Object",stat:!0,forced:Object.defineProperties!==zw,sham:!Mw},{defineProperties:zw});var Bw=it.Object,jw=Pw.exports=function(t,e){return Bw.defineProperties(t,e)};Bw.defineProperties.sham&&(jw.sham=!0);var Vw=s(Pw.exports),Hw={exports:{}},Ww=Ei,Uw=O,$w=Qe.f;Ww({target:"Object",stat:!0,forced:Object.defineProperty!==$w,sham:!Uw},{defineProperty:$w});var qw=it.Object,Yw=Hw.exports=function(t,e,i){return qw.defineProperty(t,e,i)};qw.defineProperty.sham&&(Yw.sham=!0);var Gw=Hw.exports,Xw=s(Gw),Kw=pe,Jw=Qe.f,Qw=Kw("metadata"),Zw=Function.prototype;void 0===Zw[Qw]&&Jw(Zw,Qw,{value:null}),nn("asyncDispose"),nn("dispose"),nn("metadata");var t_=gd,e_=v,i_=rt("Symbol"),s_=i_.keyFor,a_=e_(i_.prototype.valueOf),o_=i_.isRegisteredSymbol||function(t){try{return void 0!==s_(a_(t))}catch(t){return!1}};Ei({target:"Symbol",stat:!0},{isRegisteredSymbol:o_});for(var n_=Yt,r_=rt,l_=v,h_=Tt,d_=pe,c_=r_("Symbol"),u_=c_.isWellKnownSymbol,p_=r_("Object","getOwnPropertyNames"),m_=l_(c_.prototype.valueOf),g_=n_("wks"),f_=0,v_=p_(c_),y_=v_.length;f_=0:r>l;l+=h)l in n&&(a=i(a,n[l],l,o));return a}},R_={left:I_(!1),right:I_(!0)},P_="process"===_(o.process),L_=R_.left;Ei({target:"Array",proto:!0,forced:!P_&&ft>79&&ft<83||!nc("reduce")},{reduce:function(t){var e=arguments.length;return L_(this,t,e,e>1?arguments[1]:void 0)}});var M_=Rs("Array").reduce,z_=lt,B_=M_,j_=Array.prototype,V_=function(t){var e=t.reduce;return t===j_||z_(j_,t)&&e===j_.reduce?B_:e},H_=s(V_),W_=Ks,U_=Vi,$_=Qs,q_=Je,Y_=function(t,e,i,s,a,o,n,r){for(var l,h,d=a,c=0,u=!!n&&q_(n,r);c0&&W_(l)?(h=U_(l),d=Y_(t,e,l,h,d,o-1)-1):($_(d+1),t[d]=l),d++),c++;return d},G_=Y_,X_=Nt,K_=Kt,J_=Vi,Q_=La;Ei({target:"Array",proto:!0},{flatMap:function(t){var e,i=K_(this),s=J_(i);return X_(t),(e=Q_(i,0)).length=G_(e,i,i,s,0,1,t,arguments.length>1?arguments[1]:void 0),e}});var Z_=Rs("Array").flatMap,tx=lt,ex=Z_,ix=Array.prototype,sx=function(t){var e=t.flatMap;return t===ix||tx(ix,t)&&e===ix.flatMap?ex:e},ax=s(sx),ox=s(x_);Cb("Set",(function(t){return function(){return t(this,arguments.length?arguments[0]:void 0)}}),Ub);var nx=s(it.Set),rx=s(jy),lx=jo,hx=Math.floor,dx=function(t,e){var i=t.length,s=hx(i/2);return i<8?cx(t,e):ux(t,dx(lx(t,0,s),e),dx(lx(t,s),e),e)},cx=function(t,e){for(var i,s,a=t.length,o=1;o0;)t[s]=t[--s];s!==o++&&(t[s]=i)}return t},ux=function(t,e,i,s){for(var a=e.length,o=i.length,n=0,r=0;n3)){if(Ox)return!0;if(Nx)return Nx<603;var t,e,i,s,a="";for(t=65;t<76;t++){switch(e=String.fromCharCode(t),t){case 66:case 69:case 70:case 72:i=3;break;case 68:case 71:i=4;break;default:i=2}for(s=0;s<47;s++)Ix.push({k:e+s,v:i})}for(Ix.sort((function(t,e){return e.v-t.v})),s=0;skx(i)?1:-1}}(t)),i=Cx(a),s=0;se(t),t)}_add(t,e){null!=e&&this._target.add(this._transformItems(this._source.get(e.items)))}_update(t,e){null!=e&&this._target.update(this._transformItems(this._source.get(e.items)))}_remove(t,e){null!=e&&this._target.remove(this._transformItems(e.oldData))}}class EC{constructor(t){S_(this,"_source",void 0),S_(this,"_transformers",[]),this._source=t}filter(t){return this._transformers.push(e=>Bu(e).call(e,t)),this}map(t){return this._transformers.push(e=>Jd(e).call(e,t)),this}flatMap(t){return this._transformers.push(e=>ax(e).call(e,t)),this}to(t){return new AC(this._source,this._transformers,t)}}function OC(t){return"string"==typeof t||"number"==typeof t}class FC{constructor(t){S_(this,"delay",void 0),S_(this,"max",void 0),S_(this,"_queue",[]),S_(this,"_timeout",null),S_(this,"_extended",null),this.delay=null,this.max=1/0,this.setOptions(t)}setOptions(t){t&&void 0!==t.delay&&(this.delay=t.delay),t&&void 0!==t.max&&(this.max=t.max),this._flushIfNeeded()}static extend(t,e){const i=new FC(e);if(void 0!==t.flush)throw new Error("Target object already has a property flush");t.flush=()=>{i.flush()};const s=[{name:"flush",original:void 0}];if(e&&e.replace)for(let a=0;athis.max&&this.flush(),null!=this._timeout&&(clearTimeout(this._timeout),this._timeout=null),this.queue.length>0&&"number"==typeof this.delay&&(this._timeout=am(()=>{this.flush()},this.delay))}flush(){var t,e;vc(t=tu(e=this._queue).call(e,0)).call(t,t=>{t.fn.apply(t.context||t.fn,t.args||[])})}}class NC{constructor(){S_(this,"_subscribers",{"*":[],add:[],remove:[],update:[]}),S_(this,"subscribe",NC.prototype.on),S_(this,"unsubscribe",NC.prototype.off)}_trigger(t,e,i){var s;if("*"===t)throw new Error("Cannot trigger event *");vc(s=[...this._subscribers[t],...this._subscribers["*"]]).call(s,s=>{s(t,e,null!=i?i:null)})}on(t,e){"function"==typeof e&&this._subscribers[t].push(e)}off(t,e){var i;this._subscribers[t]=Bu(i=this._subscribers[t]).call(i,t=>t!==e)}}class IC{constructor(t){S_(this,"_pairs",void 0),this._pairs=t}*[ox](){for(const[t,e]of this._pairs)yield[t,e]}*entries(){for(const[t,e]of this._pairs)yield[t,e]}*keys(){for(const[t]of this._pairs)yield t}*values(){for(const[,t]of this._pairs)yield t}toIdArray(){var t;return Jd(t=[...this._pairs]).call(t,t=>t[0])}toItemArray(){var t;return Jd(t=[...this._pairs]).call(t,t=>t[1])}toEntryArray(){return[...this._pairs]}toObjectMap(){const t=Pp(null);for(const[e,i]of this._pairs)t[e]=i;return t}toMap(){return new rw(this._pairs)}toIdSet(){return new nx(this.toIdArray())}toItemSet(){return new nx(this.toItemArray())}cache(){return new IC([...this._pairs])}distinct(t){const e=new nx;for(const[i,s]of this._pairs)e.add(t(s,i));return e}filter(t){const e=this._pairs;return new IC({*[ox](){for(const[i,s]of e)t(s,i)&&(yield[i,s])}})}forEach(t){for(const[e,i]of this._pairs)t(i,e)}map(t){const e=this._pairs;return new IC({*[ox](){for(const[i,s]of e)yield[i,t(s,i)]}})}max(t){const e=rx(this._pairs);let i=e.next();if(i.done)return null;let s=i.value[1],a=t(i.value[1],i.value[0]);for(;!(i=e.next()).done;){const[e,o]=i.value,n=t(o,e);n>a&&(a=n,s=o)}return s}min(t){const e=rx(this._pairs);let i=e.next();if(i.done)return null;let s=i.value[1],a=t(i.value[1],i.value[0]);for(;!(i=e.next()).done;){const[e,o]=i.value,n=t(o,e);n{var e;return rx($x(e=[...this._pairs]).call(e,(e,i)=>{let[s,a]=e,[o,n]=i;return t(a,n,s,o)}))}})}}class RC extends NC{get idProp(){return this._idProp}constructor(t,e){super(),S_(this,"flush",void 0),S_(this,"length",void 0),S_(this,"_options",void 0),S_(this,"_data",void 0),S_(this,"_idProp",void 0),S_(this,"_queue",null),t&&!Ud(t)&&(e=t,t=[]),this._options=e||{},this._data=new rw,this.length=0,this._idProp=this._options.fieldId||"id",t&&t.length&&this.add(t),this.setOptions(e)}setOptions(t){t&&void 0!==t.queue&&(!1===t.queue?this._queue&&(this._queue.destroy(),this._queue=null):(this._queue||(this._queue=FC.extend(this,{replace:["add","update","remove"]})),t.queue&&"object"==typeof t.queue&&this._queue.setOptions(t.queue)))}add(t,e){const i=[];let s;if(Ud(t)){const e=Jd(t).call(t,t=>t[this._idProp]);if(bw(e).call(e,t=>this._data.has(t)))throw new Error("A duplicate id was found in the parameter array.");for(let a=0,o=t.length;a{const e=t[n];if(null!=e&&this._data.has(e)){const i=t,n=bs({},this._data.get(e)),r=this._updateItem(i);s.push(r),o.push(i),a.push(n)}else{const e=this._addItem(t);i.push(e)}};if(Ud(t))for(let l=0,h=t.length;l{const e=this._data.get(t[this._idProp]);if(null==e)throw new Error("Updating non-existent items is not allowed.");return{oldData:e,update:t}})).call(i,t=>{let{oldData:e,update:i}=t;const s=e[this._idProp],a=pf(e,i);return this._data.set(s,a),{id:s,oldData:e,updatedData:a}});if(s.length){const t={items:Jd(s).call(s,t=>t.id),oldData:Jd(s).call(s,t=>t.oldData),data:Jd(s).call(s,t=>t.updatedData)};return this._trigger("update",t,e),t.items}return[]}get(t,e){let i,s,a;OC(t)?(i=t,a=e):Ud(t)?(s=t,a=e):a=t;const o=a&&"Object"===a.returnType?"Object":"Array",n=a&&Bu(a),r=[];let l,h,d;if(null!=i)l=this._data.get(i),l&&n&&!n(l)&&(l=void 0);else if(null!=s)for(let p=0,m=s.length;p(e[i]=t[i],e),{}):t}_sort(t,e){if("string"==typeof e){const i=e;$x(t).call(t,(t,e)=>{const s=t[i],a=e[i];return s>a?1:si)&&(e=a,i=o)}return e||null}min(t){let e=null,i=null;for(const a of hC(s=this._data).call(s)){var s;const o=a[t];"number"==typeof o&&(null==i||oo(t)&&n(t)),null==s?this._data.get(a):this._data.get(s,a)}getIds(t){if(this._data.length){const e=Bu(this._options),i=null!=t?Bu(t):null;let s;return s=i?e?t=>e(t)&&i(t):i:e,this._data.getIds({filter:s,order:t&&t.order})}return[]}forEach(t,e){if(this._data){var i;const s=Bu(this._options),a=e&&Bu(e);let o;o=a?s?function(t){return s(t)&&a(t)}:a:s,vc(i=this._data).call(i,t,{filter:o,order:e&&e.order})}}map(t,e){if(this._data){var i;const s=Bu(this._options),a=e&&Bu(e);let o;return o=a?s?t=>s(t)&&a(t):a:s,Jd(i=this._data).call(i,t,{filter:o,order:e&&e.order})}return[]}getDataSet(){return this._data.getDataSet()}stream(t){var e;return this._data.stream(t||{[ox]:js(e=tC(this._ids)).call(e,this._ids)})}dispose(){var t;null!==(t=this._data)&&void 0!==t&&t.off&&this._data.off("*",this._listener);const e="This data view has already been disposed of.",i={get:()=>{throw new Error(e)},set:()=>{throw new Error(e)},configurable:!1};for(const s of Wd(PC.prototype))bC(this,s,i)}_onEvent(t,e,i){if(!e||!e.items||!this._data)return;const s=e.items,a=[],o=[],n=[],r=[],l=[],h=[];switch(t){case"add":for(let t=0,e=s.length;te.x&&t.tope.y}function aD(t){return"string"==typeof t&&""!==t}function oD(t,e,i,s){let a=s.x,o=s.y;if("function"==typeof s.distanceToBorder){const i=s.distanceToBorder(t,e),n=Math.sin(e)*i,r=Math.cos(e)*i;r===i?(a+=i,o=s.y):n===i?(a=s.x,o-=i):(a+=r,o-=n)}else s.shape.width>s.shape.height?(a=s.x+.5*s.shape.width,o=s.y-i):(a=s.x+i,o=s.y-.5*s.shape.height);return{x:a,y:o}}class nD{constructor(t){this.measureText=t,this.current=0,this.width=0,this.height=0,this.lines=[]}_add(t,e){let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"normal";void 0===this.lines[t]&&(this.lines[t]={width:0,height:0,blocks:[]});let s=e;void 0!==e&&""!==e||(s=" ");const a=this.measureText(s,i),o=bs({},hC(a));o.text=e,o.width=a.width,o.mod=i,void 0!==e&&""!==e||(o.width=0),this.lines[t].blocks.push(o),this.lines[t].width+=o.width}curWidth(){const t=this.lines[this.current];return void 0===t?0:t.width}append(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"normal";this._add(this.current,t,e)}newLine(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"normal";this._add(this.current,t,e),this.current++}determineLineHeights(){for(let t=0;tt&&(t=s.width),e+=s.height}this.width=t,this.height=e}removeEmptyBlocks(){const t=[];for(let e=0;e"://,""://,""://,"":/<\/b>/,"":/<\/i>/,"":/<\/code>/,"*":/\*/,_:/_/,"`":/`/,afterBold:/[^*]/,afterItal:/[^_]/,afterMono:/[^`]/};class lD{constructor(t){this.text=t,this.bold=!1,this.ital=!1,this.mono=!1,this.spacing=!1,this.position=0,this.buffer="",this.modStack=[],this.blocks=[]}mod(){return 0===this.modStack.length?"normal":this.modStack[0]}modName(){return 0===this.modStack.length?"normal":"mono"===this.modStack[0]?"mono":this.bold&&this.ital?"boldital":this.bold?"bold":this.ital?"ital":void 0}emitBlock(){this.spacing&&(this.add(" "),this.spacing=!1),this.buffer.length>0&&(this.blocks.push({text:this.buffer,mod:this.modName()}),this.buffer="")}add(t){" "===t&&(this.spacing=!0),this.spacing&&(this.buffer+=" ",this.spacing=!1)," "!=t&&(this.buffer+=t)}parseWS(t){return!!/[ \t]/.test(t)&&(this.mono?this.add(t):this.spacing=!0,!0)}setTag(t){this.emitBlock(),this[t]=!0,this.modStack.unshift(t)}unsetTag(t){this.emitBlock(),this[t]=!1,this.modStack.shift()}parseStartTag(t,e){return!(this.mono||this[t]||!this.match(e))&&(this.setTag(t),!0)}match(t){let e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];const[i,s]=this.prepareRegExp(t),a=i.test(this.text.substr(this.position,s));return a&&e&&(this.position+=s-1),a}parseEndTag(t,e,i){let s=this.mod()===t;return s="mono"===t?s&&this.mono:s&&!this.mono,!(!s||!this.match(e))&&(void 0!==i?(this.position===this.text.length-1||this.match(i,!1))&&this.unsetTag(t):this.unsetTag(t),!0)}replace(t,e){return!!this.match(t)&&(this.add(e),this.position+=length-1,!0)}prepareRegExp(t){let e,i;if(t instanceof RegExp)i=t,e=1;else{const s=rD[t];i=void 0!==s?s:new RegExp(t),e=t.length}return[i,e]}}class hD{constructor(t,e,i,s){this.ctx=t,this.parent=e,this.selected=i,this.hover=s,this.lines=new nD((e,a)=>{if(void 0===e)return 0;const o=this.parent.getFormattingValues(t,i,s,a);let n=0;return""!==e&&(n=this.ctx.measureText(e).width),{width:n,values:o}})}process(t){if(!aD(t))return this.lines.finalize();const e=this.parent.fontOptions;t=(t=t.replace(/\r\n/g,"\n")).replace(/\r/g,"\n");const i=String(t).split("\n"),s=i.length;if(e.multi)for(let a=0;a0)for(let e=0;e0)for(let a=0;a!!/&/.test(t)&&(e.replace(e.text,"<","<")||e.replace(e.text,"&","&")||e.add("&"),!0);for(;e.position")||e.parseStartTag("ital","")||e.parseStartTag("mono","")||e.parseEndTag("bold","")||e.parseEndTag("ital","")||e.parseEndTag("mono",""))||i(t)||e.add(t),e.position++}return e.emitBlock(),e.blocks}splitMarkdownBlocks(t){const e=new lD(t);let i=!0;const s=t=>!!/\\/.test(t)&&(e.positionthis.parent.fontOptions.maxWdt}getLongestFit(t){let e="",i=0;for(;i1&&void 0!==arguments[1]?arguments[1]:"normal",i=arguments.length>2&&void 0!==arguments[2]&&arguments[2];this.parent.getFormattingValues(this.ctx,this.selected,this.hover,e);let s=(t=(t=t.replace(/^( +)/g,"$1\r")).replace(/([^\r][^ ]*)( +)/g,"$1\r$2\r")).split("\r");for(;s.length>0;){let t=this.getLongestFit(s);if(0===t){const t=s[0],i=this.getLongestFitWord(t);this.lines.newLine(Ld(t).call(t,0,i),e),s[0]=Ld(t).call(t,i)}else{let a=t;" "===s[t-1]?t--:" "===s[a]&&a++;const o=Ld(s).call(s,0,t).join("");t==s.length&&i?this.lines.append(o,e):this.lines.newLine(o,e),s=Ld(s).call(s,a)}}}}const dD=["bold","ital","boldital","mono"];class cD{constructor(t,e){let i=arguments.length>2&&void 0!==arguments[2]&&arguments[2];this.body=t,this.pointToSelf=!1,this.baseSize=void 0,this.fontOptions={},this.setOptions(e),this.size={top:0,left:0,width:0,height:0,yLine:0},this.isEdgeLabel=i}setOptions(t){if(this.elementOptions=t,this.initFontOptions(t.font),aD(t.label)?this.labelDirty=!0:t.label=void 0,void 0!==t.font&&null!==t.font)if("string"==typeof t.font)this.baseSize=this.fontOptions.size;else if("object"==typeof t.font){const e=t.font.size;void 0!==e&&(this.baseSize=e)}}initFontOptions(t){jf(dD,t=>{this.fontOptions[t]={}}),cD.parseFontString(this.fontOptions,t)?this.fontOptions.vadjust=0:jf(t,(t,e)=>{null!=t&&"object"!=typeof t&&(this.fontOptions[e]=t)})}static parseFontString(t,e){if(!e||"string"!=typeof e)return!1;const i=e.split(" ");return t.size=+i[0].replace("px",""),t.face=i[1],t.color=i[2],!0}constrain(t){const e={constrainWidth:!1,maxWdt:-1,minWdt:-1,constrainHeight:!1,minHgt:-1,valign:"middle"},i=av(t,"widthConstraint");if("number"==typeof i)e.maxWdt=Number(i),e.minWdt=Number(i);else if("object"==typeof i){const i=av(t,["widthConstraint","maximum"]);"number"==typeof i&&(e.maxWdt=Number(i));const s=av(t,["widthConstraint","minimum"]);"number"==typeof s&&(e.minWdt=Number(s))}const s=av(t,"heightConstraint");if("number"==typeof s)e.minHgt=Number(s);else if("object"==typeof s){const i=av(t,["heightConstraint","minimum"]);"number"==typeof i&&(e.minHgt=Number(i));const s=av(t,["heightConstraint","valign"]);"string"==typeof s&&("top"!==s&&"bottom"!==s||(e.valign=s))}return e}update(t,e){this.setOptions(t,!0),this.propagateFonts(e),Pf(this.fontOptions,this.constrain(e)),this.fontOptions.chooser=iD("label",e)}adjustSizes(t){const e=t?t.right+t.left:0;this.fontOptions.constrainWidth&&(this.fontOptions.maxWdt-=e,this.fontOptions.minWdt-=e);const i=t?t.top+t.bottom:0;this.fontOptions.constrainHeight&&(this.fontOptions.minHgt-=i)}addFontOptionsToPile(t,e){for(let i=0;i{void 0!==t&&(Object.prototype.hasOwnProperty.call(e,i)||(-1!==Fp(dD).call(dD,i)?e[i]={}:e[i]=t))})}return e}getFontOption(t,e,i){let s;for(let a=0;a{s[e]=t}),s.size=Number(s.size),s.vadjust=Number(s.vadjust)}}draw(t,e,i,s,a){let o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:"middle";if(void 0===this.elementOptions.label)return;let n=this.fontOptions.size*this.body.view.scale;this.elementOptions.label&&n=this.elementOptions.scaling.label.maxVisible&&(n=Number(this.elementOptions.scaling.label.maxVisible)/this.body.view.scale),this.calculateLabelSize(t,s,a,e,i,o),this._drawBackground(t),this._drawText(t,e,this.size.yLine,o,n))}_drawBackground(t){if(void 0!==this.fontOptions.background&&"none"!==this.fontOptions.background){t.fillStyle=this.fontOptions.background;const e=this.getSize();t.fillRect(e.left,e.top,e.width,e.height)}}_drawText(t,e,i){let s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"middle",a=arguments.length>4?arguments[4]:void 0;[e,i]=this._setAlignment(t,e,i,s),t.textAlign="left",e-=this.size.width/2,this.fontOptions.valign&&this.size.height>this.size.labelHeight&&("top"===this.fontOptions.valign&&(i-=(this.size.height-this.size.labelHeight)/2),"bottom"===this.fontOptions.valign&&(i+=(this.size.height-this.size.labelHeight)/2));for(let o=0;o0&&(t.lineWidth=r.strokeWidth,t.strokeStyle=h,t.lineJoin="round"),t.fillStyle=l,r.strokeWidth>0&&t.strokeText(r.text,e+o,i+r.vadjust),t.fillText(r.text,e+o,i+r.vadjust),o+=r.width}i+=s.height}}}_setAlignment(t,e,i,s){if(this.isEdgeLabel&&"horizontal"!==this.fontOptions.align&&!1===this.pointToSelf){e=0,i=0;const s=2;"top"===this.fontOptions.align?(t.textBaseline="alphabetic",i-=2*s):"bottom"===this.fontOptions.align?(t.textBaseline="hanging",i+=2*s):t.textBaseline="middle"}else t.textBaseline=s;return[e,i]}_getColor(t,e,i){let s=t||"#000000",a=i||"#ffffff";if(e<=this.elementOptions.scaling.label.drawThreshold){const t=Math.max(0,Math.min(1,1-(this.elementOptions.scaling.label.drawThreshold-e)));s=Uf(s,t),a=Uf(a,t)}return[s,a]}getTextSize(t){let e=arguments.length>1&&void 0!==arguments[1]&&arguments[1],i=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return this._processLabel(t,e,i),{width:this.size.width,height:this.size.height,lineCount:this.lineCount}}getSize(){let t=this.size.left,e=this.size.top-1;if(this.isEdgeLabel){const i=.5*-this.size.width;switch(this.fontOptions.align){case"middle":t=i,e=.5*-this.size.height;break;case"top":t=i,e=-(this.size.height+2);break;case"bottom":t=i,e=2}}return{left:t,top:e,width:this.size.width,height:this.size.height}}calculateLabelSize(t,e,i){let s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0,o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:"middle";this._processLabel(t,e,i),this.size.left=s-.5*this.size.width,this.size.top=a-.5*this.size.height,this.size.yLine=a+.5*(1-this.lineCount)*this.fontOptions.size,"hanging"===o&&(this.size.top+=.5*this.fontOptions.size,this.size.top+=4,this.size.yLine+=4)}getFormattingValues(t,e,i,s){const a=function(t,e,i){return"normal"===e?"mod"===i?"":t[i]:void 0!==t[e][i]?t[e][i]:t[i]},o={color:a(this.fontOptions,s,"color"),size:a(this.fontOptions,s,"size"),face:a(this.fontOptions,s,"face"),mod:a(this.fontOptions,s,"mod"),vadjust:a(this.fontOptions,s,"vadjust"),strokeWidth:this.fontOptions.strokeWidth,strokeColor:this.fontOptions.strokeColor};(e||i)&&("normal"===s&&!0===this.fontOptions.chooser&&this.elementOptions.labelHighlightBold?o.mod="bold":"function"==typeof this.fontOptions.chooser&&this.fontOptions.chooser(o,this.elementOptions.id,e,i));let n="";return void 0!==o.mod&&""!==o.mod&&(n+=o.mod+" "),n+=o.size+"px "+o.face,t.font=n.replace(/"/g,""),o.font=t.font,o.height=o.size,o}differentState(t,e){return t!==this.selectedState||e!==this.hoverState}_processLabelText(t,e,i,s){return new hD(t,this,e,i).process(s)}_processLabel(t,e,i){if(!1===this.labelDirty&&!this.differentState(e,i))return;const s=this._processLabelText(t,e,i,this.elementOptions.label);this.fontOptions.minWdt>0&&s.width0&&s.height0&&(this.enableBorderDashes(t,e),t.stroke(),this.disableBorderDashes(t,e)),t.restore()}performFill(t,e){t.save(),t.fillStyle=e.color,this.enableShadow(t,e),gm(t).call(t),this.disableShadow(t,e),t.restore(),this.performStroke(t,e)}_addBoundingBoxMargin(t){this.boundingBox.left-=t,this.boundingBox.top-=t,this.boundingBox.bottom+=t,this.boundingBox.right+=t}_updateBoundingBox(t,e,i,s,a){void 0!==i&&this.resize(i,s,a),this.left=t-this.width/2,this.top=e-this.height/2,this.boundingBox.left=this.left,this.boundingBox.top=this.top,this.boundingBox.bottom=this.top+this.height,this.boundingBox.right=this.left+this.width}updateBoundingBox(t,e,i,s,a){this._updateBoundingBox(t,e,i,s,a)}getDimensionsFromLabel(t,e,i){this.textSize=this.labelModule.getTextSize(t,e,i);let s=this.textSize.width,a=this.textSize.height;return 0===s&&(s=14,a=14),{width:s,height:a}}}let pD=class extends uD{constructor(t,e,i){super(t,e,i),this._setMargins(i)}resize(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.selected,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.hover;if(this.needsRefresh(e,i)){const s=this.getDimensionsFromLabel(t,e,i);this.width=s.width+this.margin.right+this.margin.left,this.height=s.height+this.margin.top+this.margin.bottom,this.radius=this.width/2}}draw(t,e,i,s,a,o){this.resize(t,s,a),this.left=e-this.width/2,this.top=i-this.height/2,this.initContextForDraw(t,o),Hs(t,this.left,this.top,this.width,this.height,o.borderRadius),this.performFill(t,o),this.updateBoundingBox(e,i,t,s,a),this.labelModule.draw(t,this.left+this.textSize.width/2+this.margin.left,this.top+this.textSize.height/2+this.margin.top,s,a)}updateBoundingBox(t,e,i,s,a){this._updateBoundingBox(t,e,i,s,a);const o=this.options.shapeProperties.borderRadius;this._addBoundingBoxMargin(o)}distanceToBorder(t,e){t&&this.resize(t);const i=this.options.borderWidth;return Math.min(Math.abs(this.width/2/Math.cos(e)),Math.abs(this.height/2/Math.sin(e)))+i}};class mD extends uD{constructor(t,e,i){super(t,e,i),this.labelOffset=0,this.selected=!1}setOptions(t,e,i){this.options=t,void 0===e&&void 0===i||this.setImages(e,i)}setImages(t,e){e&&this.selected?(this.imageObj=e,this.imageObjAlt=t):(this.imageObj=t,this.imageObjAlt=e)}switchImages(t){const e=t&&!this.selected||!t&&this.selected;if(this.selected=t,void 0!==this.imageObjAlt&&e){const t=this.imageObj;this.imageObj=this.imageObjAlt,this.imageObjAlt=t}}_getImagePadding(){const t={top:0,right:0,bottom:0,left:0};if(this.options.imagePadding){const e=this.options.imagePadding;"object"==typeof e?(t.top=e.top,t.right=e.right,t.bottom=e.bottom,t.left=e.left):(t.top=e,t.right=e,t.bottom=e,t.left=e)}return t}_resizeImage(){let t,e;if(!1===this.options.shapeProperties.useImageSize){let i=1,s=1;this.imageObj.width&&this.imageObj.height&&(this.imageObj.width>this.imageObj.height?i=this.imageObj.width/this.imageObj.height:s=this.imageObj.height/this.imageObj.width),t=2*this.options.size*i,e=2*this.options.size*s}else{const i=this._getImagePadding();t=this.imageObj.width+i.left+i.right,e=this.imageObj.height+i.top+i.bottom}this.width=t,this.height=e,this.radius=.5*this.width}_drawRawCircle(t,e,i,s){this.initContextForDraw(t,s),Vs(t,e,i,s.size),this.performFill(t,s)}_drawImageAtPosition(t,e){if(0!=this.imageObj.width){t.globalAlpha=void 0!==e.opacity?e.opacity:1,this.enableShadow(t,e);let i=1;!0===this.options.shapeProperties.interpolation&&(i=this.imageObj.width/this.width/this.body.view.scale);const s=this._getImagePadding(),a=this.left+s.left,o=this.top+s.top,n=this.width-s.left-s.right,r=this.height-s.top-s.bottom;this.imageObj.drawImageAtPosition(t,i,a,o,n,r),this.disableShadow(t,e)}}_drawImageLabel(t,e,i,s,a){let o=0;if(void 0!==this.height){o=.5*this.height;const e=this.labelModule.getTextSize(t,s,a);e.lineCount>=1&&(o+=e.height/2)}const n=i+o;this.options.label&&(this.labelOffset=o),this.labelModule.draw(t,e,n,s,a,"hanging")}}let gD=class extends mD{constructor(t,e,i){super(t,e,i),this._setMargins(i)}resize(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.selected,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.hover;if(this.needsRefresh(e,i)){const s=this.getDimensionsFromLabel(t,e,i),a=Math.max(s.width+this.margin.right+this.margin.left,s.height+this.margin.top+this.margin.bottom);this.options.size=a/2,this.width=a,this.height=a,this.radius=this.width/2}}draw(t,e,i,s,a,o){this.resize(t,s,a),this.left=e-this.width/2,this.top=i-this.height/2,this._drawRawCircle(t,e,i,o),this.updateBoundingBox(e,i),this.labelModule.draw(t,this.left+this.textSize.width/2+this.margin.left,i,s,a)}updateBoundingBox(t,e){this.boundingBox.top=e-this.options.size,this.boundingBox.left=t-this.options.size,this.boundingBox.right=t+this.options.size,this.boundingBox.bottom=e+this.options.size}distanceToBorder(t){return t&&this.resize(t),.5*this.width}};class fD extends mD{constructor(t,e,i,s,a){super(t,e,i),this.setImages(s,a)}resize(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.selected,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.hover;if(void 0===this.imageObj.src||void 0===this.imageObj.width||void 0===this.imageObj.height){const t=2*this.options.size;return this.width=t,this.height=t,void(this.radius=.5*this.width)}this.needsRefresh(e,i)&&this._resizeImage()}draw(t,e,i,s,a,o){this.switchImages(s),this.resize();let n=e,r=i;"top-left"===this.options.shapeProperties.coordinateOrigin?(this.left=e,this.top=i,n+=this.width/2,r+=this.height/2):(this.left=e-this.width/2,this.top=i-this.height/2),this._drawRawCircle(t,n,r,o),t.save(),t.clip(),this._drawImageAtPosition(t,o),t.restore(),this._drawImageLabel(t,n,r,s,a),this.updateBoundingBox(e,i)}updateBoundingBox(t,e){"top-left"===this.options.shapeProperties.coordinateOrigin?(this.boundingBox.top=e,this.boundingBox.left=t,this.boundingBox.right=t+2*this.options.size,this.boundingBox.bottom=e+2*this.options.size):(this.boundingBox.top=e-this.options.size,this.boundingBox.left=t-this.options.size,this.boundingBox.right=t+this.options.size,this.boundingBox.bottom=e+this.options.size),this.boundingBox.left=Math.min(this.boundingBox.left,this.labelModule.size.left),this.boundingBox.right=Math.max(this.boundingBox.right,this.labelModule.size.left+this.labelModule.size.width),this.boundingBox.bottom=Math.max(this.boundingBox.bottom,this.boundingBox.bottom+this.labelOffset)}distanceToBorder(t){return t&&this.resize(t),.5*this.width}}class vD extends uD{constructor(t,e,i){super(t,e,i)}resize(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.selected,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.hover,s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{size:this.options.size};if(this.needsRefresh(e,i)){var a,o;this.labelModule.getTextSize(t,e,i);const n=2*s.size;this.width=null!==(a=this.customSizeWidth)&&void 0!==a?a:n,this.height=null!==(o=this.customSizeHeight)&&void 0!==o?o:n,this.radius=.5*this.width}}_drawShape(t,e,i,s,a,o,n,r){var l;return this.resize(t,o,n,r),this.left=s-this.width/2,this.top=a-this.height/2,this.initContextForDraw(t,r),(l=e,Object.prototype.hasOwnProperty.call(qs,l)?qs[l]:function(t){for(var e=arguments.length,i=new Array(e>1?e-1:0),s=1;s{if(void 0!==this.options.label){this.labelModule.calculateLabelSize(t,o,n,s,a,"hanging");const e=a+.5*this.height+.5*this.labelModule.size.height;this.labelModule.draw(t,s,e,o,n,"hanging")}this.updateBoundingBox(s,a)}}}updateBoundingBox(t,e){this.boundingBox.top=e-this.options.size,this.boundingBox.left=t-this.options.size,this.boundingBox.right=t+this.options.size,this.boundingBox.bottom=e+this.options.size,void 0!==this.options.label&&this.labelModule.size.width>0&&(this.boundingBox.left=Math.min(this.boundingBox.left,this.labelModule.size.left),this.boundingBox.right=Math.max(this.boundingBox.right,this.labelModule.size.left+this.labelModule.size.width),this.boundingBox.bottom=Math.max(this.boundingBox.bottom,this.boundingBox.bottom+this.labelModule.size.height))}}function yD(t,e){var i=tc(t);if(ww){var s=ww(t);e&&(s=Bu(s).call(s,(function(e){return Ew(t,e).enumerable}))),i.push.apply(i,s)}return i}function bD(t){for(var e=1;e{t.save(),e(),t.restore()}}return n.nodeDimensions&&(this.customSizeWidth=n.nodeDimensions.width,this.customSizeHeight=n.nodeDimensions.height),n}distanceToBorder(t,e){return this._distanceToBorder(t,e)}}class _D extends uD{constructor(t,e,i){super(t,e,i),this._setMargins(i)}resize(t,e,i){if(this.needsRefresh(e,i)){const s=this.getDimensionsFromLabel(t,e,i).width+this.margin.right+this.margin.left;this.width=s,this.height=s,this.radius=this.width/2}}draw(t,e,i,s,a,o){this.resize(t,s,a),this.left=e-this.width/2,this.top=i-this.height/2,this.initContextForDraw(t,o),Us(t,e-this.width/2,i-this.height/2,this.width,this.height),this.performFill(t,o),this.updateBoundingBox(e,i,t,s,a),this.labelModule.draw(t,this.left+this.textSize.width/2+this.margin.left,this.top+this.textSize.height/2+this.margin.top,s,a)}distanceToBorder(t,e){return this._distanceToBorder(t,e)}}let xD=class extends vD{constructor(t,e,i){super(t,e,i)}draw(t,e,i,s,a,o){return this._drawShape(t,"diamond",4,e,i,s,a,o)}distanceToBorder(t,e){return this._distanceToBorder(t,e)}};class CD extends vD{constructor(t,e,i){super(t,e,i)}draw(t,e,i,s,a,o){return this._drawShape(t,"circle",2,e,i,s,a,o)}distanceToBorder(t){return t&&this.resize(t),this.options.size}}class DD extends uD{constructor(t,e,i){super(t,e,i)}resize(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.selected,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.hover;if(this.needsRefresh(e,i)){const s=this.getDimensionsFromLabel(t,e,i);this.height=2*s.height,this.width=s.width+s.height,this.radius=.5*this.width}}draw(t,e,i,s,a,o){this.resize(t,s,a),this.left=e-.5*this.width,this.top=i-.5*this.height,this.initContextForDraw(t,o),Ws(t,this.left,this.top,this.width,this.height),this.performFill(t,o),this.updateBoundingBox(e,i,t,s,a),this.labelModule.draw(t,e,i,s,a)}distanceToBorder(t,e){t&&this.resize(t);const i=.5*this.width,s=.5*this.height,a=Math.sin(e)*i,o=Math.cos(e)*s;return i*s/Math.sqrt(a*a+o*o)}}class kD extends uD{constructor(t,e,i){super(t,e,i),this._setMargins(i)}resize(t,e,i){this.needsRefresh(e,i)&&(this.iconSize={width:Number(this.options.icon.size),height:Number(this.options.icon.size)},this.width=this.iconSize.width+this.margin.right+this.margin.left,this.height=this.iconSize.height+this.margin.top+this.margin.bottom,this.radius=.5*this.width)}draw(t,e,i,s,a,o){return this.resize(t,s,a),this.options.icon.size=this.options.icon.size||50,this.left=e-this.width/2,this.top=i-this.height/2,this._icon(t,e,i,s,a,o),{drawExternalLabel:()=>{if(void 0!==this.options.label){const e=5;this.labelModule.draw(t,this.left+this.iconSize.width/2+this.margin.left,i+this.height/2+e,s)}this.updateBoundingBox(e,i)}}}updateBoundingBox(t,e){if(this.boundingBox.top=e-.5*this.options.icon.size,this.boundingBox.left=t-.5*this.options.icon.size,this.boundingBox.right=t+.5*this.options.icon.size,this.boundingBox.bottom=e+.5*this.options.icon.size,void 0!==this.options.label&&this.labelModule.size.width>0){const t=5;this.boundingBox.left=Math.min(this.boundingBox.left,this.labelModule.size.left),this.boundingBox.right=Math.max(this.boundingBox.right,this.labelModule.size.left+this.labelModule.size.width),this.boundingBox.bottom=Math.max(this.boundingBox.bottom,this.boundingBox.bottom+this.labelModule.size.height+t)}}_icon(t,e,i,s,a,o){const n=Number(this.options.icon.size);void 0!==this.options.icon.code?(t.font=[null!=this.options.icon.weight?this.options.icon.weight:s?"bold":"",(null!=this.options.icon.weight&&s?5:0)+n+"px",this.options.icon.face].join(" "),t.fillStyle=this.options.icon.color||"black",t.textAlign="center",t.textBaseline="middle",this.enableShadow(t,o),t.fillText(this.options.icon.code,e,i),this.disableShadow(t,o)):console.error("When using the icon shape, you need to define the code in the icon options object. This can be done per node or globally.")}distanceToBorder(t,e){return this._distanceToBorder(t,e)}}let TD=class extends mD{constructor(t,e,i,s,a){super(t,e,i),this.setImages(s,a)}resize(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.selected,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.hover;if(void 0===this.imageObj.src||void 0===this.imageObj.width||void 0===this.imageObj.height){const t=2*this.options.size;return this.width=t,void(this.height=t)}this.needsRefresh(e,i)&&this._resizeImage()}draw(t,e,i,s,a,o){t.save(),this.switchImages(s),this.resize();let n=e,r=i;if("top-left"===this.options.shapeProperties.coordinateOrigin?(this.left=e,this.top=i,n+=this.width/2,r+=this.height/2):(this.left=e-this.width/2,this.top=i-this.height/2),!0===this.options.shapeProperties.useBorderWithImage){const e=this.options.borderWidth,i=this.options.borderWidthSelected||2*this.options.borderWidth,n=(s?i:e)/this.body.view.scale;t.lineWidth=Math.min(this.width,n),t.beginPath();let r=s?this.options.color.highlight.border:a?this.options.color.hover.border:this.options.color.border,l=s?this.options.color.highlight.background:a?this.options.color.hover.background:this.options.color.background;void 0!==o.opacity&&(r=Uf(r,o.opacity),l=Uf(l,o.opacity)),t.strokeStyle=r,t.fillStyle=l,t.rect(this.left-.5*t.lineWidth,this.top-.5*t.lineWidth,this.width+t.lineWidth,this.height+t.lineWidth),gm(t).call(t),this.performStroke(t,o),t.closePath()}this._drawImageAtPosition(t,o),this._drawImageLabel(t,n,r,s,a),this.updateBoundingBox(e,i),t.restore()}updateBoundingBox(t,e){this.resize(),"top-left"===this.options.shapeProperties.coordinateOrigin?(this.left=t,this.top=e):(this.left=t-this.width/2,this.top=e-this.height/2),this.boundingBox.left=this.left,this.boundingBox.top=this.top,this.boundingBox.bottom=this.top+this.height,this.boundingBox.right=this.left+this.width,void 0!==this.options.label&&this.labelModule.size.width>0&&(this.boundingBox.left=Math.min(this.boundingBox.left,this.labelModule.size.left),this.boundingBox.right=Math.max(this.boundingBox.right,this.labelModule.size.left+this.labelModule.size.width),this.boundingBox.bottom=Math.max(this.boundingBox.bottom,this.boundingBox.bottom+this.labelOffset))}distanceToBorder(t,e){return this._distanceToBorder(t,e)}};class SD extends vD{constructor(t,e,i){super(t,e,i)}draw(t,e,i,s,a,o){return this._drawShape(t,"square",2,e,i,s,a,o)}distanceToBorder(t,e){return this._distanceToBorder(t,e)}}class AD extends vD{constructor(t,e,i){super(t,e,i)}draw(t,e,i,s,a,o){return this._drawShape(t,"hexagon",4,e,i,s,a,o)}distanceToBorder(t,e){return this._distanceToBorder(t,e)}}class ED extends vD{constructor(t,e,i){super(t,e,i)}draw(t,e,i,s,a,o){return this._drawShape(t,"star",4,e,i,s,a,o)}distanceToBorder(t,e){return this._distanceToBorder(t,e)}}class OD extends uD{constructor(t,e,i){super(t,e,i),this._setMargins(i)}resize(t,e,i){this.needsRefresh(e,i)&&(this.textSize=this.labelModule.getTextSize(t,e,i),this.width=this.textSize.width+this.margin.right+this.margin.left,this.height=this.textSize.height+this.margin.top+this.margin.bottom,this.radius=.5*this.width)}draw(t,e,i,s,a,o){this.resize(t,s,a),this.left=e-this.width/2,this.top=i-this.height/2,this.enableShadow(t,o),this.labelModule.draw(t,this.left+this.textSize.width/2+this.margin.left,this.top+this.textSize.height/2+this.margin.top,s,a),this.disableShadow(t,o),this.updateBoundingBox(e,i,t,s,a)}distanceToBorder(t,e){return this._distanceToBorder(t,e)}}let FD=class extends vD{constructor(t,e,i){super(t,e,i)}draw(t,e,i,s,a,o){return this._drawShape(t,"triangle",3,e,i,s,a,o)}distanceToBorder(t,e){return this._distanceToBorder(t,e)}};class ND extends vD{constructor(t,e,i){super(t,e,i)}draw(t,e,i,s,a,o){return this._drawShape(t,"triangleDown",3,e,i,s,a,o)}distanceToBorder(t,e){return this._distanceToBorder(t,e)}}function ID(t,e){var i=tc(t);if(ww){var s=ww(t);e&&(s=Bu(s).call(s,(function(e){return Ew(t,e).enumerable}))),i.push.apply(i,s)}return i}function RD(t){for(var e=1;enull!=e[t]);n.push("font"),Rf(n,t,o),t.color=qf(t.color)}static parseOptions(t,e){let i=arguments.length>2&&void 0!==arguments[2]&&arguments[2],s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},a=arguments.length>4?arguments[4]:void 0;if(Rf(["color","fixed","shadow"],t,e,i),PD.checkMass(e),void 0!==t.opacity&&(PD.checkOpacity(t.opacity)||(console.error("Invalid option for node opacity. Value must be between 0 and 1, found: "+t.opacity),t.opacity=void 0)),void 0!==e.opacity&&(PD.checkOpacity(e.opacity)||(console.error("Invalid option for node opacity. Value must be between 0 and 1, found: "+e.opacity),e.opacity=void 0)),e.shapeProperties&&!PD.checkCoordinateOrigin(e.shapeProperties.coordinateOrigin)&&console.error("Invalid option for node coordinateOrigin, found: "+e.shapeProperties.coordinateOrigin),iv(t,e,"shadow",s),void 0!==e.color&&null!==e.color){const i=qf(e.color);Ff(t.color,i)}else!0===i&&null===e.color&&(t.color=ev(s.color));void 0!==e.fixed&&null!==e.fixed&&("boolean"==typeof e.fixed?(t.fixed.x=e.fixed,t.fixed.y=e.fixed):(void 0!==e.fixed.x&&"boolean"==typeof e.fixed.x&&(t.fixed.x=e.fixed.x),void 0!==e.fixed.y&&"boolean"==typeof e.fixed.y&&(t.fixed.y=e.fixed.y))),!0===i&&null===e.font&&(t.font=ev(s.font)),PD.updateGroupOptions(t,e,a),void 0!==e.scaling&&iv(t.scaling,e.scaling,"label",s.scaling)}getFormattingValues(){const t={color:this.options.color.background,opacity:this.options.opacity,borderWidth:this.options.borderWidth,borderColor:this.options.color.border,size:this.options.size,borderDashes:this.options.shapeProperties.borderDashes,borderRadius:this.options.shapeProperties.borderRadius,shadow:this.options.shadow.enabled,shadowColor:this.options.shadow.color,shadowSize:this.options.shadow.size,shadowX:this.options.shadow.x,shadowY:this.options.shadow.y};if(this.selected||this.hover?!0===this.chooser?this.selected?(null!=this.options.borderWidthSelected?t.borderWidth=this.options.borderWidthSelected:t.borderWidth*=2,t.color=this.options.color.highlight.background,t.borderColor=this.options.color.highlight.border,t.shadow=this.options.shadow.enabled):this.hover&&(t.color=this.options.color.hover.background,t.borderColor=this.options.color.hover.border,t.shadow=this.options.shadow.enabled):"function"==typeof this.chooser&&(this.chooser(t,this.options.id,this.selected,this.hover),!1===t.shadow&&(t.shadowColor===this.options.shadow.color&&t.shadowSize===this.options.shadow.size&&t.shadowX===this.options.shadow.x&&t.shadowY===this.options.shadow.y||(t.shadow=!0))):t.shadow=this.options.shadow.enabled,void 0!==this.options.opacity){const e=this.options.opacity;t.borderColor=Uf(t.borderColor,e),t.color=Uf(t.color,e),t.shadowColor=Uf(t.shadowColor,e)}return t}updateLabelModule(t){void 0!==this.options.label&&null!==this.options.label||(this.options.label=""),PD.updateGroupOptions(this.options,RD(RD({},t),{},{color:t&&t.color||this._localColor||void 0}),this.grouplist);const e=this.grouplist.get(this.options.group,!1),i=[t,this.options,e,this.globalOptions,this.defaultOptions];this.labelModule.update(this.options,i),void 0!==this.labelModule.baseSize&&(this.baseFontSize=this.labelModule.baseSize)}updateShape(t){if(t===this.options.shape&&this.shape)this.shape.setOptions(this.options,this.imageObj,this.imageObjAlt);else switch(this.options.shape){case"box":this.shape=new pD(this.options,this.body,this.labelModule);break;case"circle":this.shape=new gD(this.options,this.body,this.labelModule);break;case"circularImage":this.shape=new fD(this.options,this.body,this.labelModule,this.imageObj,this.imageObjAlt);break;case"custom":this.shape=new wD(this.options,this.body,this.labelModule,this.options.ctxRenderer);break;case"database":this.shape=new _D(this.options,this.body,this.labelModule);break;case"diamond":this.shape=new xD(this.options,this.body,this.labelModule);break;case"dot":this.shape=new CD(this.options,this.body,this.labelModule);break;case"ellipse":default:this.shape=new DD(this.options,this.body,this.labelModule);break;case"icon":this.shape=new kD(this.options,this.body,this.labelModule);break;case"image":this.shape=new TD(this.options,this.body,this.labelModule,this.imageObj,this.imageObjAlt);break;case"square":this.shape=new SD(this.options,this.body,this.labelModule);break;case"hexagon":this.shape=new AD(this.options,this.body,this.labelModule);break;case"star":this.shape=new ED(this.options,this.body,this.labelModule);break;case"text":this.shape=new OD(this.options,this.body,this.labelModule);break;case"triangle":this.shape=new FD(this.options,this.body,this.labelModule);break;case"triangleDown":this.shape=new ND(this.options,this.body,this.labelModule)}this.needsRefresh()}select(){this.selected=!0,this.needsRefresh()}unselect(){this.selected=!1,this.needsRefresh()}needsRefresh(){this.shape.refreshNeeded=!0}getTitle(){return this.options.title}distanceToBorder(t,e){return this.shape.distanceToBorder(t,e)}isFixed(){return this.options.fixed.x&&this.options.fixed.y}isSelected(){return this.selected}getValue(){return this.options.value}getLabelSize(){return this.labelModule.size()}setValueRange(t,e,i){if(void 0!==this.options.value){const s=this.options.scaling.customScalingFunction(t,e,i,this.options.value),a=this.options.scaling.max-this.options.scaling.min;if(!0===this.options.scaling.label.enabled){const t=this.options.scaling.label.max-this.options.scaling.label.min;this.options.font.size=this.options.scaling.label.min+s*t}this.options.size=this.options.scaling.min+s*a}else this.options.size=this.baseSize,this.options.font.size=this.baseFontSize;this.updateLabelModule()}draw(t){const e=this.getFormattingValues();return this.shape.draw(t,this.x,this.y,this.selected,this.hover,e)||{}}updateBoundingBox(t){this.shape.updateBoundingBox(this.x,this.y,t)}resize(t){const e=this.getFormattingValues();this.shape.resize(t,this.selected,this.hover,e)}getItemsOnPoint(t){const e=[];return this.labelModule.visible()&&sD(this.labelModule.getSize(),t)&&e.push({nodeId:this.id,labelId:0}),sD(this.shape.boundingBox,t)&&e.push({nodeId:this.id}),e}isOverlappingWith(t){return this.shape.leftt.left&&this.shape.topt.top}isBoundingBoxOverlappingWith(t){return this.shape.boundingBox.leftt.left&&this.shape.boundingBox.topt.top}static checkMass(t,e){if(void 0!==t.mass&&t.mass<=0){let i="";void 0!==e&&(i=" in node id: "+e),console.error("%cNegative or zero mass disallowed"+i+", setting mass to 1.",fv),t.mass=1}}}class LD{constructor(t,e,i,s){var a;if(this.body=t,this.images=e,this.groups=i,this.layoutEngine=s,this.body.functions.createNode=js(a=this.create).call(a,this),this.nodesListeners={add:(t,e)=>{this.add(e.items)},update:(t,e)=>{this.update(e.items,e.data,e.oldData)},remove:(t,e)=>{this.remove(e.items)}},this.defaultOptions={borderWidth:1,borderWidthSelected:void 0,brokenImage:void 0,color:{border:"#2B7CE9",background:"#97C2FC",highlight:{border:"#2B7CE9",background:"#D2E5FF"},hover:{border:"#2B7CE9",background:"#D2E5FF"}},opacity:void 0,fixed:{x:!1,y:!1},font:{color:"#343434",size:14,face:"arial",background:"none",strokeWidth:0,strokeColor:"#ffffff",align:"center",vadjust:0,multi:!1,bold:{mod:"bold"},boldital:{mod:"bold italic"},ital:{mod:"italic"},mono:{mod:"",size:15,face:"monospace",vadjust:2}},group:void 0,hidden:!1,icon:{face:"FontAwesome",code:void 0,size:50,color:"#2B7CE9"},image:void 0,imagePadding:{top:0,right:0,bottom:0,left:0},label:void 0,labelHighlightBold:!0,level:void 0,margin:{top:5,right:5,bottom:5,left:5},mass:1,physics:!0,scaling:{min:10,max:30,label:{enabled:!1,min:14,max:30,maxVisible:30,drawThreshold:5},customScalingFunction:function(t,e,i,s){if(e===t)return.5;{const i=1/(e-t);return Math.max(0,(s-t)*i)}}},shadow:{enabled:!1,color:"rgba(0,0,0,0.5)",size:10,x:5,y:5},shape:"ellipse",shapeProperties:{borderDashes:!1,borderRadius:6,interpolation:!0,useImageSize:!1,useBorderWithImage:!1,coordinateOrigin:"center"},size:25,title:void 0,value:void 0,x:void 0,y:void 0},this.defaultOptions.mass<=0)throw"Internal error: mass in defaultOptions of NodesHandler may not be zero or negative";this.options=ev(this.defaultOptions),this.bindEventListeners()}bindEventListeners(){var t,e;this.body.emitter.on("refreshNodes",js(t=this.refresh).call(t,this)),this.body.emitter.on("refresh",js(e=this.refresh).call(e,this)),this.body.emitter.on("destroy",()=>{jf(this.nodesListeners,(t,e)=>{this.body.data.nodes&&this.body.data.nodes.off(e,t)}),delete this.body.functions.createNode,delete this.nodesListeners.add,delete this.nodesListeners.update,delete this.nodesListeners.remove,delete this.nodesListeners})}setOptions(t){if(void 0!==t){if(PD.parseOptions(this.options,t),void 0!==t.opacity&&(hw(t.opacity)||!uw(t.opacity)||t.opacity<0||t.opacity>1?console.error("Invalid option for node opacity. Value must be between 0 and 1, found: "+t.opacity):this.options.opacity=t.opacity),void 0!==t.shape)for(const t in this.body.nodes)Object.prototype.hasOwnProperty.call(this.body.nodes,t)&&this.body.nodes[t].updateShape();if(void 0!==t.font||void 0!==t.widthConstraint||void 0!==t.heightConstraint)for(const t of tc(this.body.nodes))this.body.nodes[t].updateLabelModule(),this.body.nodes[t].needsRefresh();if(void 0!==t.size)for(const t in this.body.nodes)Object.prototype.hasOwnProperty.call(this.body.nodes,t)&&this.body.nodes[t].needsRefresh();void 0===t.hidden&&void 0===t.physics||this.body.emitter.emit("_dataChanged")}}setData(t){let e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];const i=this.body.data.nodes;if(MC("id",t))this.body.data.nodes=t;else if(Ud(t))this.body.data.nodes=new RC,this.body.data.nodes.add(t);else{if(t)throw new TypeError("Array or DataSet expected");this.body.data.nodes=new RC}if(i&&jf(this.nodesListeners,(function(t,e){i.off(e,t)})),this.body.nodes={},this.body.data.nodes){const t=this;jf(this.nodesListeners,(function(e,i){t.body.data.nodes.on(i,e)}));const e=this.body.data.nodes.getIds();this.add(e,!0)}!1===e&&this.body.emitter.emit("_dataChanged")}add(t){let e,i=arguments.length>1&&void 0!==arguments[1]&&arguments[1];const s=[];for(let a=0;a1&&void 0!==arguments[1]?arguments[1]:PD)(t,this.body,this.images,this.groups,this.options,this.defaultOptions)}refresh(){let t=arguments.length>0&&void 0!==arguments[0]&&arguments[0];jf(this.body.nodes,(e,i)=>{const s=this.body.data.nodes.get(i);void 0!==s&&(!0===t&&e.setOptions({x:null,y:null}),e.setOptions({fixed:!1}),e.setOptions(s))})}getPositions(t){const e={};if(void 0!==t){if(!0===Ud(t)){for(let i=0;i{this.body.emitter.emit("startSimulation")},0)):console.error("Node id supplied to moveNode does not exist. Provided: ",t)}}var MD=Ei,zD=Math.hypot,BD=Math.abs,jD=Math.sqrt;MD({target:"Math",stat:!0,arity:2,forced:!!zD&&zD(1/0,NaN)!==1/0},{hypot:function(t,e){for(var i,s,a=0,o=0,n=arguments.length,r=0;o0?(s=i/r)*s:i;return r===1/0?1/0:r*jD(a)}});var VD=s(it.Math.hypot);class HD{static transform(t,e){Ud(t)||(t=[t]);const i=e.point.x,s=e.point.y,a=e.angle,o=e.length;for(let n=0;n4&&void 0!==arguments[4]?arguments[4]:this.getViaNode();t.strokeStyle=this.getColor(t,e),t.lineWidth=e.width,!1!==e.dashes?this._drawDashedLine(t,e,a):this._drawLine(t,e,a)}_drawLine(t,e,i,s,a){if(this.from!=this.to)this._line(t,e,i,s,a);else{const[i,s,a]=this._getCircleData(t);this._circle(t,e,i,s,a)}}_drawDashedLine(t,e,i,s,a){t.lineCap="round";const o=Ud(e.dashes)?e.dashes:[5,5];if(void 0!==t.setLineDash){if(t.save(),t.setLineDash(o),t.lineDashOffset=0,this.from!=this.to)this._line(t,e,i);else{const[i,s,a]=this._getCircleData(t);this._circle(t,e,i,s,a)}t.setLineDash([0]),t.lineDashOffset=0,t.restore()}else{if(this.from!=this.to)$s(t,this.from.x,this.from.y,this.to.x,this.to.y,o);else{const[i,s,a]=this._getCircleData(t);this._circle(t,e,i,s,a)}this.enableShadow(t,e),t.stroke(),this.disableShadow(t,e)}}findBorderPosition(t,e,i){return this.from!=this.to?this._findBorderPosition(t,e,i):this._findBorderPositionCircle(t,e,i)}findBorderPositions(t){if(this.from!=this.to)return{from:this._findBorderPosition(this.from,t),to:this._findBorderPosition(this.to,t)};{var e;const[i,s]=Ld(e=this._getCircleData(t)).call(e,0,2);return{from:this._findBorderPositionCircle(this.from,t,{x:i,y:s,low:.25,high:.6,direction:-1}),to:this._findBorderPositionCircle(this.from,t,{x:i,y:s,low:.6,high:.8,direction:1})}}}_getCircleData(t){const e=this.options.selfReference.size;void 0!==t&&void 0===this.from.shape.width&&this.from.shape.resize(t);const i=oD(t,this.options.selfReference.angle,e,this.from);return[i.x,i.y,e]}_pointOnCircle(t,e,i,s){const a=2*s*Math.PI;return{x:t+i*Math.cos(a),y:e-i*Math.sin(a)}}_findBorderPositionCircle(t,e,i){const s=i.x,a=i.y;let o=i.low,n=i.high;const r=i.direction,l=this.options.selfReference.size;let h,d=.5*(o+n),c=0;!0===this.options.arrowStrikethrough&&(-1===r?c=this.options.endPointOffset.from:1===r&&(c=this.options.endPointOffset.to));let u=0;do{d=.5*(o+n),h=this._pointOnCircle(s,a,l,d);const i=Math.atan2(t.y-h.y,t.x-h.x),p=t.distanceToBorder(e,i)+c-Math.sqrt(Math.pow(h.x-t.x,2)+Math.pow(h.y-t.y,2));if(Math.abs(p)<.05)break;p>0?r>0?o=d:n=d:r>0?n=d:o=d,++u}while(o<=n&&u<10);return sk(sk({},h),{},{t:d})}getLineWidth(t,e){return!0===t?Math.max(this.selectionWidth,.3/this._body.view.scale):!0===e?Math.max(this.hoverWidth,.3/this._body.view.scale):Math.max(this.options.width,.3/this._body.view.scale)}getColor(t,e){if(!1!==e.inheritsColor){if("both"===e.inheritsColor&&this.from.id!==this.to.id){const i=t.createLinearGradient(this.from.x,this.from.y,this.to.x,this.to.y);let s=this.from.options.color.highlight.border,a=this.to.options.color.highlight.border;return!1===this.from.selected&&!1===this.to.selected?(s=Uf(this.from.options.color.border,e.opacity),a=Uf(this.to.options.color.border,e.opacity)):!0===this.from.selected&&!1===this.to.selected?a=this.to.options.color.border:!1===this.from.selected&&!0===this.to.selected&&(s=this.from.options.color.border),i.addColorStop(0,s),i.addColorStop(1,a),i}return"to"===e.inheritsColor?Uf(this.to.options.color.border,e.opacity):Uf(this.from.options.color.border,e.opacity)}return Uf(e.color,e.opacity)}_circle(t,e,i,s,a){this.enableShadow(t,e);let o=0,n=2*Math.PI;if(!this.options.selfReference.renderBehindTheNode){const e=this.options.selfReference.angle,a=this.options.selfReference.angle+Math.PI,r=this._findBorderPositionCircle(this.from,t,{x:i,y:s,low:e,high:a,direction:-1}),l=this._findBorderPositionCircle(this.from,t,{x:i,y:s,low:e,high:a,direction:1});o=Math.atan2(r.y-s,r.x-i),n=Math.atan2(l.y-s,l.x-i)}t.beginPath(),t.arc(i,s,a,o,n,!1),t.stroke(),this.disableShadow(t,e)}getDistanceToEdge(t,e,i,s,a,o){if(this.from!=this.to)return this._getDistanceToEdge(t,e,i,s,a,o);{const[t,e,i]=this._getCircleData(void 0),s=t-a,n=e-o;return Math.abs(Math.sqrt(s*s+n*n)-i)}}_getDistanceToLine(t,e,i,s,a,o){const n=i-t,r=s-e;let l=((a-t)*n+(o-e)*r)/(n*n+r*r);l>1?l=1:l<0&&(l=0);const h=t+l*n-a,d=e+l*r-o;return Math.sqrt(h*h+d*d)}getArrowData(t,e,i,s,a,o){let n,r,l,h,d,c,u;const p=o.width;"from"===e?(l=this.from,h=this.to,d=o.fromArrowScale<0,c=Math.abs(o.fromArrowScale),u=o.fromArrowType):"to"===e?(l=this.to,h=this.from,d=o.toArrowScale<0,c=Math.abs(o.toArrowScale),u=o.toArrowType):(l=this.to,h=this.from,d=o.middleArrowScale<0,c=Math.abs(o.middleArrowScale),u=o.middleArrowType);const m=15*c+3*p;if(l!=h){const s=m/VD(l.x-h.x,l.y-h.y);if("middle"!==e)if(!0===this.options.smooth.enabled){const a=this._findBorderPosition(l,t,{via:i}),o=this.getPoint(a.t+s*("from"===e?1:-1),i);n=Math.atan2(a.y-o.y,a.x-o.x),r=a}else n=Math.atan2(l.y-h.y,l.x-h.x),r=this._findBorderPosition(l,t);else{const t=(d?-s:s)/2,e=this.getPoint(.5+t,i),a=this.getPoint(.5-t,i);n=Math.atan2(e.y-a.y,e.x-a.x),r=this.getPoint(.5,i)}}else{const[i,s,a]=this._getCircleData(t);if("from"===e){const e=this.options.selfReference.angle,a=this.options.selfReference.angle+Math.PI,o=this._findBorderPositionCircle(this.from,t,{x:i,y:s,low:e,high:a,direction:-1});n=-2*o.t*Math.PI+1.5*Math.PI+.1*Math.PI,r=o}else if("to"===e){const e=this.options.selfReference.angle,a=this.options.selfReference.angle+Math.PI,o=this._findBorderPositionCircle(this.from,t,{x:i,y:s,low:e,high:a,direction:1});n=-2*o.t*Math.PI+1.5*Math.PI-1.1*Math.PI,r=o}else{const t=this.options.selfReference.angle/(2*Math.PI);r=this._pointOnCircle(i,s,a,t),n=-2*t*Math.PI+1.5*Math.PI+.1*Math.PI}}return{point:r,core:{x:r.x-.9*m*Math.cos(n),y:r.y-.9*m*Math.sin(n)},angle:n,length:m,type:u}}drawArrowHead(t,e,i,s,a){t.strokeStyle=this.getColor(t,e),t.fillStyle=t.strokeStyle,t.lineWidth=e.width,ek.draw(t,a)&&(this.enableShadow(t,e),gm(t).call(t),this.disableShadow(t,e))}enableShadow(t,e){!0===e.shadow&&(t.shadowColor=e.shadowColor,t.shadowBlur=e.shadowSize,t.shadowOffsetX=e.shadowX,t.shadowOffsetY=e.shadowY)}disableShadow(t,e){!0===e.shadow&&(t.shadowColor="rgba(0,0,0,0)",t.shadowBlur=0,t.shadowOffsetX=0,t.shadowOffsetY=0)}drawBackground(t,e){if(!1!==e.background){const i={strokeStyle:t.strokeStyle,lineWidth:t.lineWidth,dashes:t.dashes};t.strokeStyle=e.backgroundColor,t.lineWidth=e.backgroundSize,this.setStrokeDashed(t,e.backgroundDashes),t.stroke(),t.strokeStyle=i.strokeStyle,t.lineWidth=i.lineWidth,t.dashes=i.dashes,this.setStrokeDashed(t,e.dashes)}}setStrokeDashed(t,e){if(!1!==e)if(void 0!==t.setLineDash){const i=Ud(e)?e:[5,5];t.setLineDash(i)}else console.warn("setLineDash is not supported in this browser. The dashed stroke cannot be used.");else void 0!==t.setLineDash?t.setLineDash([]):console.warn("setLineDash is not supported in this browser. The dashed stroke cannot be used.")}}function ok(t,e){var i=tc(t);if(ww){var s=ww(t);e&&(s=Bu(s).call(s,(function(e){return Ew(t,e).enumerable}))),i.push.apply(i,s)}return i}function nk(t){for(var e=1;e2&&void 0!==arguments[2]?arguments[2]:this._getViaCoordinates(),o=!1,n=1,r=0,l=this.to,h=this.options.endPointOffset?this.options.endPointOffset.to:0;t.id===this.from.id&&(l=this.from,o=!0,h=this.options.endPointOffset?this.options.endPointOffset.from:0),!1===this.options.arrowStrikethrough&&(h=0);let d=0;do{s=.5*(r+n),i=this.getPoint(s,a);const t=Math.atan2(l.y-i.y,l.x-i.x),c=l.distanceToBorder(e,t)+h-Math.sqrt(Math.pow(i.x-l.x,2)+Math.pow(i.y-l.y,2));if(Math.abs(c)<.2)break;c<0?!1===o?r=s:n=s:!1===o?n=s:r=s,++d}while(r<=n&&d<10);return nk(nk({},i),{},{t:s})}_getDistanceToBezierEdge(t,e,i,s,a,o,n){let r,l,h,d,c,u=1e9,p=t,m=e;for(l=1;l<10;l++)h=.1*l,d=Math.pow(1-h,2)*t+2*h*(1-h)*n.x+Math.pow(h,2)*i,c=Math.pow(1-h,2)*e+2*h*(1-h)*n.y+Math.pow(h,2)*s,l>0&&(r=this._getDistanceToLine(p,m,d,c,a,o),u=r{this.positionBezierNode()},this._body.emitter.on("_repositionBezierNodes",this._boundFunction)}setOptions(t){super.setOptions(t);let e=!1;this.options.physics!==t.physics&&(e=!0),this.options=t,this.id=this.options.id,this.from=this._body.nodes[this.options.from],this.to=this._body.nodes[this.options.to],this.setupSupportNode(),this.connect(),!0===e&&(this.via.setOptions({physics:this.options.physics}),this.positionBezierNode())}connect(){this.from=this._body.nodes[this.options.from],this.to=this._body.nodes[this.options.to],void 0===this.from||void 0===this.to||!1===this.options.physics||this.from.id===this.to.id?this.via.setOptions({physics:!1}):this.via.setOptions({physics:!0})}cleanup(){return this._body.emitter.off("_repositionBezierNodes",this._boundFunction),void 0!==this.via&&(delete this._body.nodes[this.via.id],this.via=void 0,!0)}setupSupportNode(){if(void 0===this.via){const t="edgeId:"+this.id,e=this._body.functions.createNode({id:t,shape:"circle",physics:!0,hidden:!0});this._body.nodes[t]=e,this.via=e,this.via.parentEdgeId=this.id,this.positionBezierNode()}}positionBezierNode(){void 0!==this.via&&void 0!==this.from&&void 0!==this.to?(this.via.x=.5*(this.from.x+this.to.x),this.via.y=.5*(this.from.y+this.to.y)):void 0!==this.via&&(this.via.x=0,this.via.y=0)}_line(t,e,i){this._bezierCurve(t,e,i)}_getViaCoordinates(){return this.via}getViaNode(){return this.via}getPoint(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.via;if(this.from===this.to){const[e,i,s]=this._getCircleData(),a=2*Math.PI*(1-t);return{x:e+s*Math.sin(a),y:i+s-s*(1-Math.cos(a))}}return{x:Math.pow(1-t,2)*this.fromPoint.x+2*t*(1-t)*e.x+Math.pow(t,2)*this.toPoint.x,y:Math.pow(1-t,2)*this.fromPoint.y+2*t*(1-t)*e.y+Math.pow(t,2)*this.toPoint.y}}_findBorderPosition(t,e){return this._findBorderPositionBezier(t,e,this.via)}_getDistanceToEdge(t,e,i,s,a,o){return this._getDistanceToBezierEdge(t,e,i,s,a,o,this.via)}}class hk extends rk{constructor(t,e,i){super(t,e,i)}_line(t,e,i){this._bezierCurve(t,e,i)}getViaNode(){return this._getViaCoordinates()}_getViaCoordinates(){const t=this.options.smooth.roundness,e=this.options.smooth.type;let i=Math.abs(this.from.x-this.to.x),s=Math.abs(this.from.y-this.to.y);if("discrete"===e||"diagonalCross"===e){let a,o;a=o=i<=s?t*s:t*i,this.from.x>this.to.x&&(a=-a),this.from.y>=this.to.y&&(o=-o);let n=this.from.x+a,r=this.from.y+o;return"discrete"===e&&(i<=s?n=ithis.to.x&&(e=-e),this.from.y>=this.to.y&&(a=-a);let o=this.from.x+e,n=this.from.y+a;return i<=s?o=this.from.x<=this.to.x?this.to.xo?this.to.x:o:n=this.from.y>=this.to.y?this.to.y>n?this.to.y:n:this.to.y2&&void 0!==arguments[2]?arguments[2]:{};return this._findBorderPositionBezier(t,e,i.via)}_getDistanceToEdge(t,e,i,s,a,o){let n=arguments.length>6&&void 0!==arguments[6]?arguments[6]:this._getViaCoordinates();return this._getDistanceToBezierEdge(t,e,i,s,a,o,n)}getPoint(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this._getViaCoordinates();const i=t;return{x:Math.pow(1-i,2)*this.fromPoint.x+2*i*(1-i)*e.x+Math.pow(i,2)*this.toPoint.x,y:Math.pow(1-i,2)*this.fromPoint.y+2*i*(1-i)*e.y+Math.pow(i,2)*this.toPoint.y}}}class dk extends rk{constructor(t,e,i){super(t,e,i)}_getDistanceToBezierEdge2(t,e,i,s,a,o,n,r){let l=1e9,h=t,d=e;const c=[0,0,0,0];for(let u=1;u<10;u++){const p=.1*u;c[0]=Math.pow(1-p,3),c[1]=3*p*Math.pow(1-p,2),c[2]=3*Math.pow(p,2)*(1-p),c[3]=Math.pow(p,3);const m=c[0]*t+c[1]*n.x+c[2]*r.x+c[3]*i,g=c[0]*e+c[1]*n.y+c[2]*r.y+c[3]*s;if(u>0){const t=this._getDistanceToLine(h,d,m,g,a,o);l=tMath.abs(e)||!0===this.options.smooth.forceDirection||"horizontal"===this.options.smooth.forceDirection)&&"vertical"!==this.options.smooth.forceDirection?(s=this.from.y,o=this.to.y,i=this.from.x-n*t,a=this.to.x+n*t):(s=this.from.y-n*e,o=this.to.y+n*e,i=this.from.x,a=this.to.x),[{x:i,y:s},{x:a,y:o}]}getViaNode(){return this._getViaCoordinates()}_findBorderPosition(t,e){return this._findBorderPositionBezier(t,e)}_getDistanceToEdge(t,e,i,s,a,o){let[n,r]=arguments.length>6&&void 0!==arguments[6]?arguments[6]:this._getViaCoordinates();return this._getDistanceToBezierEdge2(t,e,i,s,a,o,n,r)}getPoint(t){let[e,i]=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this._getViaCoordinates();const s=t,a=[Math.pow(1-s,3),3*s*Math.pow(1-s,2),3*Math.pow(s,2)*(1-s),Math.pow(s,3)];return{x:a[0]*this.fromPoint.x+a[1]*e.x+a[2]*i.x+a[3]*this.toPoint.x,y:a[0]*this.fromPoint.y+a[1]*e.y+a[2]*i.y+a[3]*this.toPoint.y}}}class uk extends ak{constructor(t,e,i){super(t,e,i)}_line(t,e){t.beginPath(),t.moveTo(this.fromPoint.x,this.fromPoint.y),t.lineTo(this.toPoint.x,this.toPoint.y),this.enableShadow(t,e),t.stroke(),this.disableShadow(t,e)}getViaNode(){}getPoint(t){return{x:(1-t)*this.fromPoint.x+t*this.toPoint.x,y:(1-t)*this.fromPoint.y+t*this.toPoint.y}}_findBorderPosition(t,e){let i=this.to,s=this.from;t.id===this.from.id&&(i=this.from,s=this.to);const a=Math.atan2(i.y-s.y,i.x-s.x),o=i.x-s.x,n=i.y-s.y,r=Math.sqrt(o*o+n*n),l=(r-t.distanceToBorder(e,a))/r;return{x:(1-l)*s.x+l*i.x,y:(1-l)*s.y+l*i.y,t:0}}_getDistanceToEdge(t,e,i,s,a,o){return this._getDistanceToLine(t,e,i,s,a,o)}}class pk{constructor(t,e,i,s,a){if(void 0===e)throw new Error("No body provided");this.options=ev(s),this.globalOptions=s,this.defaultOptions=a,this.body=e,this.imagelist=i,this.id=void 0,this.fromId=void 0,this.toId=void 0,this.selected=!1,this.hover=!1,this.labelDirty=!0,this.baseWidth=this.options.width,this.baseFontSize=this.options.font.size,this.from=void 0,this.to=void 0,this.edgeType=void 0,this.connected=!1,this.labelModule=new cD(this.body,this.options,!0),this.setOptions(t)}setOptions(t){if(!t)return;let e=void 0!==t.physics&&this.options.physics!==t.physics||void 0!==t.hidden&&(this.options.hidden||!1)!==(t.hidden||!1)||void 0!==t.from&&this.options.from!==t.from||void 0!==t.to&&this.options.to!==t.to;pk.parseOptions(this.options,t,!0,this.globalOptions),void 0!==t.id&&(this.id=t.id),void 0!==t.from&&(this.fromId=t.from),void 0!==t.to&&(this.toId=t.to),void 0!==t.title&&(this.title=t.title),void 0!==t.value&&(t.value=XC(t.value));const i=[t,this.options,this.defaultOptions];return this.chooser=iD("edge",i),this.updateLabelModule(t),e=this.updateEdgeType()||e,this._setInteractionWidths(),this.connect(),e}static parseOptions(t,e){let i=arguments.length>2&&void 0!==arguments[2]&&arguments[2],s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},a=arguments.length>4&&void 0!==arguments[4]&&arguments[4];if(If(["endPointOffset","arrowStrikethrough","id","from","hidden","hoverWidth","labelHighlightBold","length","line","opacity","physics","scaling","selectionWidth","selfReferenceSize","selfReference","to","title","value","width","font","chosen","widthConstraint"],t,e,i),void 0!==e.endPointOffset&&void 0!==e.endPointOffset.from&&(uw(e.endPointOffset.from)?t.endPointOffset.from=e.endPointOffset.from:(t.endPointOffset.from=void 0!==s.endPointOffset.from?s.endPointOffset.from:0,console.error("endPointOffset.from is not a valid number"))),void 0!==e.endPointOffset&&void 0!==e.endPointOffset.to&&(uw(e.endPointOffset.to)?t.endPointOffset.to=e.endPointOffset.to:(t.endPointOffset.to=void 0!==s.endPointOffset.to?s.endPointOffset.to:0,console.error("endPointOffset.to is not a valid number"))),aD(e.label)?t.label=e.label:aD(t.label)||(t.label=void 0),iv(t,e,"smooth",s),iv(t,e,"shadow",s),iv(t,e,"background",s),void 0!==e.dashes&&null!==e.dashes?t.dashes=e.dashes:!0===i&&null===e.dashes&&(t.dashes=Pp(s.dashes)),void 0!==e.scaling&&null!==e.scaling?(void 0!==e.scaling.min&&(t.scaling.min=e.scaling.min),void 0!==e.scaling.max&&(t.scaling.max=e.scaling.max),iv(t.scaling,e.scaling,"label",s.scaling)):!0===i&&null===e.scaling&&(t.scaling=Pp(s.scaling)),void 0!==e.arrows&&null!==e.arrows)if("string"==typeof e.arrows){const i=e.arrows.toLowerCase();t.arrows.to.enabled=-1!=Fp(i).call(i,"to"),t.arrows.middle.enabled=-1!=Fp(i).call(i,"middle"),t.arrows.from.enabled=-1!=Fp(i).call(i,"from")}else{if("object"!=typeof e.arrows)throw new Error("The arrow newOptions can only be an object or a string. Refer to the documentation. You used:"+Bp(e.arrows));iv(t.arrows,e.arrows,"to",s.arrows),iv(t.arrows,e.arrows,"middle",s.arrows),iv(t.arrows,e.arrows,"from",s.arrows)}else!0===i&&null===e.arrows&&(t.arrows=Pp(s.arrows));if(void 0!==e.color&&null!==e.color){const o=Af(e.color)?{color:e.color,highlight:e.color,hover:e.color,inherit:!1,opacity:1}:e.color,n=t.color;if(a)Pf(n,s.color,!1,i);else for(const t in n)Object.prototype.hasOwnProperty.call(n,t)&&delete n[t];if(Af(n))n.color=n,n.highlight=n,n.hover=n,n.inherit=!1,void 0===o.opacity&&(n.opacity=1);else{let t=!1;void 0!==o.color&&(n.color=o.color,t=!0),void 0!==o.highlight&&(n.highlight=o.highlight,t=!0),void 0!==o.hover&&(n.hover=o.hover,t=!0),void 0!==o.inherit&&(n.inherit=o.inherit),void 0!==o.opacity&&(n.opacity=Math.min(1,Math.max(0,o.opacity))),!0===t?n.inherit=!1:void 0===n.inherit&&(n.inherit="from")}}else!0===i&&null===e.color&&(t.color=ev(s.color));!0===i&&null===e.font&&(t.font=ev(s.font)),Object.prototype.hasOwnProperty.call(e,"selfReferenceSize")&&(console.warn("The selfReferenceSize property has been deprecated. Please use selfReference property instead. The selfReference can be set like thise selfReference:{size:30, angle:Math.PI / 4}"),t.selfReference.size=e.selfReferenceSize)}getFormattingValues(){const t=!0===this.options.arrows.to||!0===this.options.arrows.to.enabled,e=!0===this.options.arrows.from||!0===this.options.arrows.from.enabled,i=!0===this.options.arrows.middle||!0===this.options.arrows.middle.enabled,s=this.options.color.inherit,a={toArrow:t,toArrowScale:this.options.arrows.to.scaleFactor,toArrowType:this.options.arrows.to.type,toArrowSrc:this.options.arrows.to.src,toArrowImageWidth:this.options.arrows.to.imageWidth,toArrowImageHeight:this.options.arrows.to.imageHeight,middleArrow:i,middleArrowScale:this.options.arrows.middle.scaleFactor,middleArrowType:this.options.arrows.middle.type,middleArrowSrc:this.options.arrows.middle.src,middleArrowImageWidth:this.options.arrows.middle.imageWidth,middleArrowImageHeight:this.options.arrows.middle.imageHeight,fromArrow:e,fromArrowScale:this.options.arrows.from.scaleFactor,fromArrowType:this.options.arrows.from.type,fromArrowSrc:this.options.arrows.from.src,fromArrowImageWidth:this.options.arrows.from.imageWidth,fromArrowImageHeight:this.options.arrows.from.imageHeight,arrowStrikethrough:this.options.arrowStrikethrough,color:s?void 0:this.options.color.color,inheritsColor:s,opacity:this.options.color.opacity,hidden:this.options.hidden,length:this.options.length,shadow:this.options.shadow.enabled,shadowColor:this.options.shadow.color,shadowSize:this.options.shadow.size,shadowX:this.options.shadow.x,shadowY:this.options.shadow.y,dashes:this.options.dashes,width:this.options.width,background:this.options.background.enabled,backgroundColor:this.options.background.color,backgroundSize:this.options.background.size,backgroundDashes:this.options.background.dashes};if(this.selected||this.hover)if(!0===this.chooser){if(this.selected){const t=this.options.selectionWidth;"function"==typeof t?a.width=t(a.width):"number"==typeof t&&(a.width+=t),a.width=Math.max(a.width,.3/this.body.view.scale),a.color=this.options.color.highlight,a.shadow=this.options.shadow.enabled}else if(this.hover){const t=this.options.hoverWidth;"function"==typeof t?a.width=t(a.width):"number"==typeof t&&(a.width+=t),a.width=Math.max(a.width,.3/this.body.view.scale),a.color=this.options.color.hover,a.shadow=this.options.shadow.enabled}}else"function"==typeof this.chooser&&(this.chooser(a,this.options.id,this.selected,this.hover),void 0!==a.color&&(a.inheritsColor=!1),!1===a.shadow&&(a.shadowColor===this.options.shadow.color&&a.shadowSize===this.options.shadow.size&&a.shadowX===this.options.shadow.x&&a.shadowY===this.options.shadow.y||(a.shadow=!0)));else a.shadow=this.options.shadow.enabled,a.width=Math.max(a.width,.3/this.body.view.scale);return a}updateLabelModule(t){const e=[t,this.options,this.globalOptions,this.defaultOptions];this.labelModule.update(this.options,e),void 0!==this.labelModule.baseSize&&(this.baseFontSize=this.labelModule.baseSize)}updateEdgeType(){const t=this.options.smooth;let e=!1,i=!0;return void 0!==this.edgeType&&((this.edgeType instanceof lk&&!0===t.enabled&&"dynamic"===t.type||this.edgeType instanceof ck&&!0===t.enabled&&"cubicBezier"===t.type||this.edgeType instanceof hk&&!0===t.enabled&&"dynamic"!==t.type&&"cubicBezier"!==t.type||this.edgeType instanceof uk&&!1===t.type.enabled)&&(i=!1),!0===i&&(e=this.cleanup())),!0===i?!0===t.enabled?"dynamic"===t.type?(e=!0,this.edgeType=new lk(this.options,this.body,this.labelModule)):"cubicBezier"===t.type?this.edgeType=new ck(this.options,this.body,this.labelModule):this.edgeType=new hk(this.options,this.body,this.labelModule):this.edgeType=new uk(this.options,this.body,this.labelModule):this.edgeType.setOptions(this.options),e}connect(){this.disconnect(),this.from=this.body.nodes[this.fromId]||void 0,this.to=this.body.nodes[this.toId]||void 0,this.connected=void 0!==this.from&&void 0!==this.to,!0===this.connected?(this.from.attachEdge(this),this.to.attachEdge(this)):(this.from&&this.from.detachEdge(this),this.to&&this.to.detachEdge(this)),this.edgeType.connect()}disconnect(){this.from&&(this.from.detachEdge(this),this.from=void 0),this.to&&(this.to.detachEdge(this),this.to=void 0),this.connected=!1}getTitle(){return this.title}isSelected(){return this.selected}getValue(){return this.options.value}setValueRange(t,e,i){if(void 0!==this.options.value){const s=this.options.scaling.customScalingFunction(t,e,i,this.options.value),a=this.options.scaling.max-this.options.scaling.min;if(!0===this.options.scaling.label.enabled){const t=this.options.scaling.label.max-this.options.scaling.label.min;this.options.font.size=this.options.scaling.label.min+s*t}this.options.width=this.options.scaling.min+s*a}else this.options.width=this.baseWidth,this.options.font.size=this.baseFontSize;this._setInteractionWidths(),this.updateLabelModule()}_setInteractionWidths(){"function"==typeof this.options.hoverWidth?this.edgeType.hoverWidth=this.options.hoverWidth(this.options.width):this.edgeType.hoverWidth=this.options.hoverWidth+this.options.width,"function"==typeof this.options.selectionWidth?this.edgeType.selectionWidth=this.options.selectionWidth(this.options.width):this.edgeType.selectionWidth=this.options.selectionWidth+this.options.width}draw(t){const e=this.getFormattingValues();if(e.hidden)return;const i=this.edgeType.getViaNode();this.edgeType.drawLine(t,e,this.selected,this.hover,i),this.drawLabel(t,i)}drawArrows(t){const e=this.getFormattingValues();if(e.hidden)return;const i=this.edgeType.getViaNode(),s={};this.edgeType.fromPoint=this.edgeType.from,this.edgeType.toPoint=this.edgeType.to,e.fromArrow&&(s.from=this.edgeType.getArrowData(t,"from",i,this.selected,this.hover,e),!1===e.arrowStrikethrough&&(this.edgeType.fromPoint=s.from.core),e.fromArrowSrc&&(s.from.image=this.imagelist.load(e.fromArrowSrc)),e.fromArrowImageWidth&&(s.from.imageWidth=e.fromArrowImageWidth),e.fromArrowImageHeight&&(s.from.imageHeight=e.fromArrowImageHeight)),e.toArrow&&(s.to=this.edgeType.getArrowData(t,"to",i,this.selected,this.hover,e),!1===e.arrowStrikethrough&&(this.edgeType.toPoint=s.to.core),e.toArrowSrc&&(s.to.image=this.imagelist.load(e.toArrowSrc)),e.toArrowImageWidth&&(s.to.imageWidth=e.toArrowImageWidth),e.toArrowImageHeight&&(s.to.imageHeight=e.toArrowImageHeight)),e.middleArrow&&(s.middle=this.edgeType.getArrowData(t,"middle",i,this.selected,this.hover,e),e.middleArrowSrc&&(s.middle.image=this.imagelist.load(e.middleArrowSrc)),e.middleArrowImageWidth&&(s.middle.imageWidth=e.middleArrowImageWidth),e.middleArrowImageHeight&&(s.middle.imageHeight=e.middleArrowImageHeight)),e.fromArrow&&this.edgeType.drawArrowHead(t,e,this.selected,this.hover,s.from),e.middleArrow&&this.edgeType.drawArrowHead(t,e,this.selected,this.hover,s.middle),e.toArrow&&this.edgeType.drawArrowHead(t,e,this.selected,this.hover,s.to)}drawLabel(t,e){if(void 0!==this.options.label){const i=this.from,s=this.to;let a;if(this.labelModule.differentState(this.selected,this.hover)&&this.labelModule.getTextSize(t,this.selected,this.hover),i.id!=s.id){this.labelModule.pointToSelf=!1,a=this.edgeType.getPoint(.5,e),t.save();const i=this._getRotation(t);0!=i.angle&&(t.translate(i.x,i.y),t.rotate(i.angle)),this.labelModule.draw(t,a.x,a.y,this.selected,this.hover),t.restore()}else{this.labelModule.pointToSelf=!0;const e=oD(t,this.options.selfReference.angle,this.options.selfReference.size,i);a=this._pointOnCircle(e.x,e.y,this.options.selfReference.size,this.options.selfReference.angle),this.labelModule.draw(t,a.x,a.y,this.selected,this.hover)}}}getItemsOnPoint(t){const e=[];if(this.labelModule.visible()){const i=this._getRotation();sD(this.labelModule.getSize(),t,i)&&e.push({edgeId:this.id,labelId:0})}const i={left:t.x,top:t.y};return this.isOverlappingWith(i)&&e.push({edgeId:this.id}),e}isOverlappingWith(t){if(this.connected){const e=10,i=this.from.x,s=this.from.y,a=this.to.x,o=this.to.y,n=t.left,r=t.top;return this.edgeType.getDistanceToEdge(i,s,a,o,n,r)0&&o<0)&&(n+=Math.PI),s.angle=n,s}_pointOnCircle(t,e,i,s){return{x:t+i*Math.cos(s),y:e-i*Math.sin(s)}}select(){this.selected=!0}unselect(){this.selected=!1}cleanup(){return this.edgeType.cleanup()}remove(){this.cleanup(),this.disconnect(),delete this.body.edges[this.id]}endPointsValid(){return void 0!==this.body.nodes[this.fromId]&&void 0!==this.body.nodes[this.toId]}}class mk{constructor(t,e,i){var s;this.body=t,this.images=e,this.groups=i,this.body.functions.createEdge=js(s=this.create).call(s,this),this.edgesListeners={add:(t,e)=>{this.add(e.items)},update:(t,e)=>{this.update(e.items)},remove:(t,e)=>{this.remove(e.items)}},this.options={},this.defaultOptions={arrows:{to:{enabled:!1,scaleFactor:1,type:"arrow"},middle:{enabled:!1,scaleFactor:1,type:"arrow"},from:{enabled:!1,scaleFactor:1,type:"arrow"}},endPointOffset:{from:0,to:0},arrowStrikethrough:!0,color:{color:"#848484",highlight:"#848484",hover:"#848484",inherit:"from",opacity:1},dashes:!1,font:{color:"#343434",size:14,face:"arial",background:"none",strokeWidth:2,strokeColor:"#ffffff",align:"horizontal",multi:!1,vadjust:0,bold:{mod:"bold"},boldital:{mod:"bold italic"},ital:{mod:"italic"},mono:{mod:"",size:15,face:"courier new",vadjust:2}},hidden:!1,hoverWidth:1.5,label:void 0,labelHighlightBold:!0,length:void 0,physics:!0,scaling:{min:1,max:15,label:{enabled:!0,min:14,max:30,maxVisible:30,drawThreshold:5},customScalingFunction:function(t,e,i,s){if(e===t)return.5;{const i=1/(e-t);return Math.max(0,(s-t)*i)}}},selectionWidth:1.5,selfReference:{size:20,angle:Math.PI/4,renderBehindTheNode:!0},shadow:{enabled:!1,color:"rgba(0,0,0,0.5)",size:10,x:5,y:5},background:{enabled:!1,color:"rgba(111,111,111,1)",size:10,dashes:!1},smooth:{enabled:!0,type:"dynamic",forceDirection:"none",roundness:.5},title:void 0,width:1,value:void 0},Pf(this.options,this.defaultOptions),this.bindEventListeners()}bindEventListeners(){var t,e,i=this;this.body.emitter.on("_forceDisableDynamicCurves",(function(t){let e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];"dynamic"===t&&(t="continuous");let s=!1;for(const a in i.body.edges)if(Object.prototype.hasOwnProperty.call(i.body.edges,a)){const e=i.body.edges[a],o=i.body.data.edges.get(a);if(null!=o){const i=o.smooth;void 0!==i&&!0===i.enabled&&"dynamic"===i.type&&(void 0===t?e.setOptions({smooth:!1}):e.setOptions({smooth:{type:t}}),s=!0)}}!0===e&&!0===s&&i.body.emitter.emit("_dataChanged")})),this.body.emitter.on("_dataUpdated",()=>{this.reconnectEdges()}),this.body.emitter.on("refreshEdges",js(t=this.refresh).call(t,this)),this.body.emitter.on("refresh",js(e=this.refresh).call(e,this)),this.body.emitter.on("destroy",()=>{jf(this.edgesListeners,(t,e)=>{this.body.data.edges&&this.body.data.edges.off(e,t)}),delete this.body.functions.createEdge,delete this.edgesListeners.add,delete this.edgesListeners.update,delete this.edgesListeners.remove,delete this.edgesListeners})}setOptions(t){if(void 0!==t){pk.parseOptions(this.options,t,!0,this.defaultOptions,!0);let e=!1;if(void 0!==t.smooth)for(const t in this.body.edges)Object.prototype.hasOwnProperty.call(this.body.edges,t)&&(e=this.body.edges[t].updateEdgeType()||e);if(void 0!==t.font)for(const t in this.body.edges)Object.prototype.hasOwnProperty.call(this.body.edges,t)&&this.body.edges[t].updateLabelModule();void 0===t.hidden&&void 0===t.physics&&!0!==e||this.body.emitter.emit("_dataChanged")}}setData(t){let e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];const i=this.body.data.edges;if(MC("id",t))this.body.data.edges=t;else if(Ud(t))this.body.data.edges=new RC,this.body.data.edges.add(t);else{if(t)throw new TypeError("Array or DataSet expected");this.body.data.edges=new RC}if(i&&jf(this.edgesListeners,(t,e)=>{i.off(e,t)}),this.body.edges={},this.body.data.edges){jf(this.edgesListeners,(t,e)=>{this.body.data.edges.on(e,t)});const t=this.body.data.edges.getIds();this.add(t,!0)}this.body.emitter.emit("_adjustEdgesForHierarchicalLayout"),!1===e&&this.body.emitter.emit("_dataChanged")}add(t){let e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];const i=this.body.edges,s=this.body.data.edges;for(let a=0;a1&&void 0!==arguments[1])||arguments[1];if(0===t.length)return;const i=this.body.edges;jf(t,t=>{const e=i[t];void 0!==e&&e.remove()}),e&&this.body.emitter.emit("_dataChanged")}refresh(){jf(this.body.edges,(t,e)=>{const i=this.body.data.edges.get(e);void 0!==i&&t.setOptions(i)})}create(t){return new pk(t,this.body,this.images,this.options,this.defaultOptions)}reconnectEdges(){let t;const e=this.body.nodes,i=this.body.edges;for(t in e)Object.prototype.hasOwnProperty.call(e,t)&&(e[t].edges=[]);for(t in i)if(Object.prototype.hasOwnProperty.call(i,t)){const e=i[t];e.from=null,e.to=null,e.connect()}}getConnectedNodes(t){const e=[];if(void 0!==this.body.edges[t]){const i=this.body.edges[t];void 0!==i.fromId&&e.push(i.fromId),void 0!==i.toId&&e.push(i.toId)}return e}_updateState(){this._addMissingEdges(),this._removeInvalidEdges()}_removeInvalidEdges(){const t=[];jf(this.body.edges,(e,i)=>{const s=this.body.nodes[e.toId],a=this.body.nodes[e.fromId];void 0!==s&&!0===s.isCluster||void 0!==a&&!0===a.isCluster||void 0!==s&&void 0!==a||t.push(i)}),this.remove(t,!1)}_addMissingEdges(){const t=this.body.data.edges;if(null==t)return;const e=this.body.edges,i=[];vc(t).call(t,(t,s)=>{void 0===e[s]&&i.push(s)}),this.add(i,!0)}}class gk{constructor(t,e,i){this.body=t,this.physicsBody=e,this.barnesHutTree,this.setOptions(i),this._rng=yf("BARNES HUT SOLVER")}setOptions(t){this.options=t,this.thetaInversed=1/this.options.theta,this.overlapAvoidanceFactor=1-Math.max(0,Math.min(1,this.options.avoidOverlap))}solve(){if(0!==this.options.gravitationalConstant&&this.physicsBody.physicsNodeIndices.length>0){let t;const e=this.body.nodes,i=this.physicsBody.physicsNodeIndices,s=i.length,a=this._formBarnesHutTree(e,i);this.barnesHutTree=a;for(let o=0;o0&&this._getForceContributions(a.root,t)}}_getForceContributions(t,e){this._getForceContribution(t.children.NW,e),this._getForceContribution(t.children.NE,e),this._getForceContribution(t.children.SW,e),this._getForceContribution(t.children.SE,e)}_getForceContribution(t,e){if(t.childrenCount>0){const i=t.centerOfMass.x-e.x,s=t.centerOfMass.y-e.y,a=Math.sqrt(i*i+s*s);a*t.calcSize>this.thetaInversed?this._calculateForces(a,i,s,e,t):4===t.childrenCount?this._getForceContributions(t,e):t.children.data.id!=e.id&&this._calculateForces(a,i,s,e,t)}}_calculateForces(t,e,i,s,a){0===t&&(e=t=.1),this.overlapAvoidanceFactor<1&&s.shape.radius&&(t=Math.max(.1+this.overlapAvoidanceFactor*s.shape.radius,t-s.shape.radius));const o=this.options.gravitationalConstant*a.mass*s.options.mass/Math.pow(t,3),n=e*o,r=i*o;this.physicsBody.forces[s.id].x+=n,this.physicsBody.forces[s.id].y+=r}_formBarnesHutTree(t,e){let i;const s=e.length;let a=t[e[0]].x,o=t[e[0]].y,n=t[e[0]].x,r=t[e[0]].y;for(let m=1;m0&&(sn&&(n=s),lr&&(r=l))}const l=Math.abs(n-a)-Math.abs(r-o);l>0?(o-=.5*l,r+=.5*l):(a+=.5*l,n-=.5*l);const h=Math.max(1e-5,Math.abs(n-a)),d=.5*h,c=.5*(a+n),u=.5*(o+r),p={root:{centerOfMass:{x:0,y:0},mass:0,range:{minX:c-d,maxX:c+d,minY:u-d,maxY:u+d},size:h,calcSize:1/h,children:{data:null},maxWidth:0,level:0,childrenCount:4}};this._splitBranch(p.root);for(let m=0;m0&&this._placeInTree(p.root,i);return p}_updateBranchMass(t,e){const i=t.centerOfMass,s=t.mass+e.options.mass,a=1/s;i.x=i.x*t.mass+e.x*e.options.mass,i.x*=a,i.y=i.y*t.mass+e.y*e.options.mass,i.y*=a,t.mass=s;const o=Math.max(Math.max(e.height,e.radius),e.width);t.maxWidth=t.maxWidthe.x?s.maxY>e.y?"NW":"SW":s.maxY>e.y?"NE":"SE",this._placeInRegion(t,e,a)}_placeInRegion(t,e,i){const s=t.children[i];switch(s.childrenCount){case 0:s.children.data=e,s.childrenCount=1,this._updateBranchMass(s,e);break;case 1:s.children.data.x===e.x&&s.children.data.y===e.y?(e.x+=this._rng(),e.y+=this._rng()):(this._splitBranch(s),this._placeInTree(s,e));break;case 4:this._placeInTree(s,e)}}_splitBranch(t){let e=null;1===t.childrenCount&&(e=t.children.data,t.mass=0,t.centerOfMass.x=0,t.centerOfMass.y=0),t.childrenCount=4,t.children.data=null,this._insertRegion(t,"NW"),this._insertRegion(t,"NE"),this._insertRegion(t,"SW"),this._insertRegion(t,"SE"),null!=e&&this._placeInTree(t,e)}_insertRegion(t,e){let i,s,a,o;const n=.5*t.size;switch(e){case"NW":i=t.range.minX,s=t.range.minX+n,a=t.range.minY,o=t.range.minY+n;break;case"NE":i=t.range.minX+n,s=t.range.maxX,a=t.range.minY,o=t.range.minY+n;break;case"SW":i=t.range.minX,s=t.range.minX+n,a=t.range.minY+n,o=t.range.maxY;break;case"SE":i=t.range.minX+n,s=t.range.maxX,a=t.range.minY+n,o=t.range.maxY}t.children[e]={centerOfMass:{x:0,y:0},mass:0,range:{minX:i,maxX:s,minY:a,maxY:o},size:.5*t.size,calcSize:2*t.calcSize,children:{data:null},maxWidth:0,level:t.level+1,childrenCount:0}}_debug(t,e){void 0!==this.barnesHutTree&&(t.lineWidth=1,this._drawBranch(this.barnesHutTree.root,t,e))}_drawBranch(t,e,i){void 0===i&&(i="#FF0000"),4===t.childrenCount&&(this._drawBranch(t.children.NW,e),this._drawBranch(t.children.NE,e),this._drawBranch(t.children.SE,e),this._drawBranch(t.children.SW,e)),e.strokeStyle=i,e.beginPath(),e.moveTo(t.range.minX,t.range.minY),e.lineTo(t.range.maxX,t.range.minY),e.stroke(),e.beginPath(),e.moveTo(t.range.maxX,t.range.minY),e.lineTo(t.range.maxX,t.range.maxY),e.stroke(),e.beginPath(),e.moveTo(t.range.maxX,t.range.maxY),e.lineTo(t.range.minX,t.range.maxY),e.stroke(),e.beginPath(),e.moveTo(t.range.minX,t.range.maxY),e.lineTo(t.range.minX,t.range.minY),e.stroke()}}class fk{constructor(t,e,i){this._rng=yf("REPULSION SOLVER"),this.body=t,this.physicsBody=e,this.setOptions(i)}setOptions(t){this.options=t}solve(){let t,e,i,s,a,o,n,r;const l=this.body.nodes,h=this.physicsBody.physicsNodeIndices,d=this.physicsBody.forces,c=this.options.nodeDistance,u=-2/3/c;for(let p=0;p0){const t=a.edges.length+1,o=this.options.centralGravity*t*a.options.mass;s[a.id].x=e*o,s[a.id].y=i*o}}}class Ck{constructor(t){this.body=t,this.physicsBody={physicsNodeIndices:[],physicsEdgeIndices:[],forces:{},velocities:{}},this.physicsEnabled=!0,this.simulationInterval=1e3/60,this.requiresTimeout=!0,this.previousStates={},this.referenceState={},this.freezeCache={},this.renderTimer=void 0,this.adaptiveTimestep=!1,this.adaptiveTimestepEnabled=!1,this.adaptiveCounter=0,this.adaptiveInterval=3,this.stabilized=!1,this.startedStabilization=!1,this.stabilizationIterations=0,this.ready=!1,this.options={},this.defaultOptions={enabled:!0,barnesHut:{theta:.5,gravitationalConstant:-2e3,centralGravity:.3,springLength:95,springConstant:.04,damping:.09,avoidOverlap:0},forceAtlas2Based:{theta:.5,gravitationalConstant:-50,centralGravity:.01,springConstant:.08,springLength:100,damping:.4,avoidOverlap:0},repulsion:{centralGravity:.2,springLength:200,springConstant:.05,nodeDistance:100,damping:.09,avoidOverlap:0},hierarchicalRepulsion:{centralGravity:0,springLength:100,springConstant:.01,nodeDistance:120,damping:.09},maxVelocity:50,minVelocity:.75,solver:"barnesHut",stabilization:{enabled:!0,iterations:1e3,updateInterval:50,onlyDynamicEdges:!1,fit:!0},timestep:.5,adaptiveTimestep:!0,wind:{x:0,y:0}},bs(this.options,this.defaultOptions),this.timestep=.5,this.layoutFailed=!1,this.bindEventListeners()}bindEventListeners(){this.body.emitter.on("initPhysics",()=>{this.initPhysics()}),this.body.emitter.on("_layoutFailed",()=>{this.layoutFailed=!0}),this.body.emitter.on("resetPhysics",()=>{this.stopSimulation(),this.ready=!1}),this.body.emitter.on("disablePhysics",()=>{this.physicsEnabled=!1,this.stopSimulation()}),this.body.emitter.on("restorePhysics",()=>{this.setOptions(this.options),!0===this.ready&&this.startSimulation()}),this.body.emitter.on("startSimulation",()=>{!0===this.ready&&this.startSimulation()}),this.body.emitter.on("stopSimulation",()=>{this.stopSimulation()}),this.body.emitter.on("destroy",()=>{this.stopSimulation(!1),this.body.emitter.off()}),this.body.emitter.on("_dataChanged",()=>{this.updatePhysicsData()})}setOptions(t){if(void 0!==t)if(!1===t)this.options.enabled=!1,this.physicsEnabled=!1,this.stopSimulation();else if(!0===t)this.options.enabled=!0,this.physicsEnabled=!0,this.startSimulation();else{this.physicsEnabled=!0,Rf(["stabilization"],this.options,t),iv(this.options,t,"stabilization"),void 0===t.enabled&&(this.options.enabled=!0),!1===this.options.enabled&&(this.physicsEnabled=!1,this.stopSimulation());const e=this.options.wind;e&&(("number"!=typeof e.x||hw(e.x))&&(e.x=0),("number"!=typeof e.y||hw(e.y))&&(e.y=0)),this.timestep=this.options.timestep}this.init()}init(){let t;"forceAtlas2Based"===this.options.solver?(t=this.options.forceAtlas2Based,this.nodesSolver=new _k(this.body,this.physicsBody,t),this.edgesSolver=new yk(this.body,this.physicsBody,t),this.gravitySolver=new xk(this.body,this.physicsBody,t)):"repulsion"===this.options.solver?(t=this.options.repulsion,this.nodesSolver=new fk(this.body,this.physicsBody,t),this.edgesSolver=new yk(this.body,this.physicsBody,t),this.gravitySolver=new wk(this.body,this.physicsBody,t)):"hierarchicalRepulsion"===this.options.solver?(t=this.options.hierarchicalRepulsion,this.nodesSolver=new vk(this.body,this.physicsBody,t),this.edgesSolver=new bk(this.body,this.physicsBody,t),this.gravitySolver=new wk(this.body,this.physicsBody,t)):(t=this.options.barnesHut,this.nodesSolver=new gk(this.body,this.physicsBody,t),this.edgesSolver=new yk(this.body,this.physicsBody,t),this.gravitySolver=new wk(this.body,this.physicsBody,t)),this.modelOptions=t}initPhysics(){!0===this.physicsEnabled&&!0===this.options.enabled?!0===this.options.stabilization.enabled?this.stabilize():(this.stabilized=!1,this.ready=!0,this.body.emitter.emit("fit",{},this.layoutFailed),this.startSimulation()):(this.ready=!0,this.body.emitter.emit("fit"))}startSimulation(){var t;!0===this.physicsEnabled&&!0===this.options.enabled?(this.stabilized=!1,this.adaptiveTimestep=!1,this.body.emitter.emit("_resizeNodes"),void 0===this.viewFunction&&(this.viewFunction=js(t=this.simulationStep).call(t,this),this.body.emitter.on("initRedraw",this.viewFunction),this.body.emitter.emit("_startRendering"))):this.body.emitter.emit("_redraw")}stopSimulation(){let t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];this.stabilized=!0,!0===t&&this._emitStabilized(),void 0!==this.viewFunction&&(this.body.emitter.off("initRedraw",this.viewFunction),this.viewFunction=void 0,!0===t&&this.body.emitter.emit("_stopRendering"))}simulationStep(){const t=ac();this.physicsTick(),(ac()-t<.4*this.simulationInterval||!0===this.runDoubleSpeed)&&!1===this.stabilized&&(this.physicsTick(),this.runDoubleSpeed=!0),!0===this.stabilized&&this.stopSimulation()}_emitStabilized(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.stabilizationIterations;(this.stabilizationIterations>1||!0===this.startedStabilization)&&am(()=>{this.body.emitter.emit("stabilized",{iterations:t}),this.startedStabilization=!1,this.stabilizationIterations=0},0)}physicsStep(){this.gravitySolver.solve(),this.nodesSolver.solve(),this.edgesSolver.solve(),this.moveNodes()}adjustTimeStep(){!0===this._evaluateStepQuality()?this.timestep=1.2*this.timestep:this.timestep/1.2.3))return!1;return!0}moveNodes(){const t=this.physicsBody.physicsNodeIndices;let e=0,i=0;for(let s=0;ss&&(t=t>0?s:-s),t}_performStep(t){const e=this.body.nodes[t],i=this.physicsBody.forces[t];this.options.wind&&(i.x+=this.options.wind.x,i.y+=this.options.wind.y);const s=this.physicsBody.velocities[t];return this.previousStates[t]={x:e.x,y:e.y,vx:s.x,vy:s.y},!1===e.options.fixed.x?(s.x=this.calculateComponentVelocity(s.x,i.x,e.options.mass),e.x+=s.x*this.timestep):(i.x=0,s.x=0),!1===e.options.fixed.y?(s.y=this.calculateComponentVelocity(s.y,i.y,e.options.mass),e.y+=s.y*this.timestep):(i.y=0,s.y=0),Math.sqrt(Math.pow(s.x,2)+Math.pow(s.y,2))}_freezeNodes(){const t=this.body.nodes;for(const e in t)if(Object.prototype.hasOwnProperty.call(t,e)&&t[e].x&&t[e].y){const i=t[e].options.fixed;this.freezeCache[e]={x:i.x,y:i.y},i.x=!0,i.y=!0}}_restoreFrozenNodes(){const t=this.body.nodes;for(const e in t)Object.prototype.hasOwnProperty.call(t,e)&&void 0!==this.freezeCache[e]&&(t[e].options.fixed.x=this.freezeCache[e].x,t[e].options.fixed.y=this.freezeCache[e].y);this.freezeCache={}}stabilize(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.options.stabilization.iterations;"number"!=typeof t&&(t=this.options.stabilization.iterations,console.error("The stabilize method needs a numeric amount of iterations. Switching to default: ",t)),0!==this.physicsBody.physicsNodeIndices.length?(this.adaptiveTimestep=this.options.adaptiveTimestep,this.body.emitter.emit("_resizeNodes"),this.stopSimulation(),this.stabilized=!1,this.body.emitter.emit("_blockRedraw"),this.targetIterations=t,!0===this.options.stabilization.onlyDynamicEdges&&this._freezeNodes(),this.stabilizationIterations=0,am(()=>this._stabilizationBatch(),0)):this.ready=!0}_startStabilizing(){return!0!==this.startedStabilization&&(this.body.emitter.emit("startStabilizing"),this.startedStabilization=!0,!0)}_stabilizationBatch(){const t=()=>!1===this.stabilized&&this.stabilizationIterations{this.body.emitter.emit("stabilizationProgress",{iterations:this.stabilizationIterations,total:this.targetIterations})};this._startStabilizing()&&e();let i=0;for(;t()&&i1&&void 0!==arguments[1]?arguments[1]:[],s=1e9,a=-1e9,o=1e9,n=-1e9;if(i.length>0)for(let r=0;re.shape.boundingBox.left&&(o=e.shape.boundingBox.left),ne.shape.boundingBox.top&&(s=e.shape.boundingBox.top),a1&&void 0!==arguments[1]?arguments[1]:[],s=1e9,a=-1e9,o=1e9,n=-1e9;if(i.length>0)for(let r=0;re.x&&(o=e.x),ne.y&&(s=e.y),a{delete this.containedEdges[t.id]}),jf(e.containedNodes,(t,e)=>{this.containedNodes[e]=t}),e.containedNodes={},jf(e.containedEdges,(t,e)=>{this.containedEdges[e]=t}),e.containedEdges={},jf(e.edges,t=>{jf(this.edges,e=>{var i,s;const a=Fp(i=e.clusteringEdgeReplacingIds).call(i,t.id);-1!==a&&(jf(t.clusteringEdgeReplacingIds,t=>{e.clusteringEdgeReplacingIds.push(t),this.body.edges[t].edgeReplacedById=e.id}),tu(s=e.clusteringEdgeReplacingIds).call(s,a,1))})}),e.edges=[]}}class Tk{constructor(t){this.body=t,this.clusteredNodes={},this.clusteredEdges={},this.options={},this.defaultOptions={},bs(this.options,this.defaultOptions),this.body.emitter.on("_resetData",()=>{this.clusteredNodes={},this.clusteredEdges={}})}clusterByHubsize(t,e){void 0===t?t=this._getHubSize():"object"==typeof t&&(e=this._checkOptions(t),t=this._getHubSize());const i=[];for(let s=0;s=t&&i.push(e.id)}for(let s=0;s0&&void 0!==arguments[0]?arguments[0]:{},e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];if(void 0===t.joinCondition)throw new Error("Cannot call clusterByNodeData without a joinCondition function in the options.");t=this._checkOptions(t);const i={},s={};jf(this.body.nodes,(e,a)=>{e.options&&!0===t.joinCondition(e.options)&&(i[a]=e,jf(e.edges,t=>{void 0===this.clusteredEdges[t.id]&&(s[t.id]=t)}))}),this._cluster(i,s,t,e)}clusterByEdgeCount(t,e){let i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];e=this._checkOptions(e);const s=[],a={};let o,n,r;for(let l=0;l0&&tc(h).length>0&&!0===r){const t=function(){for(let t=0;t1&&void 0!==arguments[1])||arguments[1];this.clusterByEdgeCount(1,t,e)}clusterBridges(t){let e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];this.clusterByEdgeCount(2,t,e)}clusterByConnection(t,e){var i;let s=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];if(void 0===t)throw new Error("No nodeId supplied to clusterByConnection!");if(void 0===this.body.nodes[t])throw new Error("The nodeId given to clusterByConnection does not exist!");const a=this.body.nodes[t];void 0===(e=this._checkOptions(e,a)).clusterNodeProperties.x&&(e.clusterNodeProperties.x=a.x),void 0===e.clusterNodeProperties.y&&(e.clusterNodeProperties.y=a.y),void 0===e.clusterNodeProperties.fixed&&(e.clusterNodeProperties.fixed={},e.clusterNodeProperties.fixed.x=a.options.fixed.x,e.clusterNodeProperties.fixed.y=a.options.fixed.y);const o={},n={},r=a.id,l=Dk.cloneOptions(a);o[r]=a;for(let d=0;d-1&&(n[i.id]=i)}}this._cluster(o,n,e,s)}_createClusterEdges(t,e,i,s){let a,o,n,r,l,h;const d=tc(t),c=[];for(let m=0;m0&&void 0!==arguments[0]?arguments[0]:{};return void 0===t.clusterEdgeProperties&&(t.clusterEdgeProperties={}),void 0===t.clusterNodeProperties&&(t.clusterNodeProperties={}),t}_cluster(t,e,i){let s=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];const a=[];for(const h in t)Object.prototype.hasOwnProperty.call(t,h)&&void 0!==this.clusteredNodes[h]&&a.push(h);for(let h=0;ha?i.x:a,o=i.yn?i.y:n;return{x:.5*(s+a),y:.5*(o+n)}}openCluster(t,e){let i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];if(void 0===t)throw new Error("No clusterNodeId supplied to openCluster.");const s=this.body.nodes[t];if(void 0===s)throw new Error("The clusterNodeId supplied to openCluster does not exist.");if(!0!==s.isCluster||void 0===s.containedNodes||void 0===s.containedEdges)throw new Error("The node:"+t+" is not a valid cluster.");const a=this.findNode(t),o=Fp(a).call(a,t)-1;if(o>=0){const e=a[o];return this.body.nodes[e]._openChildCluster(t),delete this.body.nodes[t],void(!0===i&&this.body.emitter.emit("_dataChanged"))}const n=s.containedNodes,r=s.containedEdges;if(void 0!==e&&void 0!==e.releaseFunction&&"function"==typeof e.releaseFunction){const t={},i={x:s.x,y:s.y};for(const e in n)if(Object.prototype.hasOwnProperty.call(n,e)){const i=this.body.nodes[e];t[e]={x:i.x,y:i.y}}const a=e.releaseFunction(i,t);for(const e in n)if(Object.prototype.hasOwnProperty.call(n,e)){const t=this.body.nodes[e];void 0!==a[e]&&(t.x=void 0===a[e].x?s.x:a[e].x,t.y=void 0===a[e].y?s.y:a[e].y)}}else jf(n,(function(t){!1===t.options.fixed.x&&(t.x=s.x),!1===t.options.fixed.y&&(t.y=s.y)}));for(const h in n)if(Object.prototype.hasOwnProperty.call(n,h)){const t=this.body.nodes[h];t.vx=s.vx,t.vy=s.vy,t.setOptions({physics:!0}),delete this.clusteredNodes[h]}const l=[];for(let h=0;h0&&a<100;){const t=e.pop();if(void 0===t)continue;const o=this.body.edges[t];if(void 0===o)continue;a++;const n=o.clusteringEdgeReplacingIds;if(void 0===n)s.push(t);else for(let s=0;ss&&(s=a.edges.length),t+=a.edges.length,e+=Math.pow(a.edges.length,2),i+=1}t/=i,e/=i;const a=e-Math.pow(t,2),o=Math.sqrt(a);let n=Math.floor(t+2*o);return n>s&&(n=s),n}_createClusteredEdge(t,e,i,s,a){const o=Dk.cloneOptions(i,"edge");Pf(o,s),o.from=t,o.to=e,o.id="clusterEdge:"+kC(),void 0!==a&&Pf(o,a);const n=this.body.functions.createEdge(o);return n.clusteringEdgeReplacingIds=[i.id],n.connect(),this.body.edges[n.id]=n,n}_clusterEdges(t,e,i,s){if(e instanceof pk){const t=e,i={};i[t.id]=t,e=i}if(t instanceof PD){const e=t,i={};i[e.id]=e,t=i}if(null==i)throw new Error("_clusterEdges: parameter clusterNode required");void 0===s&&(s=i.clusterEdgeProperties),this._createClusterEdges(t,e,i,s);for(const a in e)if(Object.prototype.hasOwnProperty.call(e,a)&&void 0!==this.body.edges[a]){const t=this.body.edges[a];this._backupEdgeOptions(t),t.setOptions({physics:!1})}for(const a in t)Object.prototype.hasOwnProperty.call(t,a)&&(this.clusteredNodes[a]={clusterId:i.id,node:this.body.nodes[a]},this.body.nodes[a].setOptions({physics:!1}))}_getClusterNodeForNode(t){if(void 0===t)return;const e=this.clusteredNodes[t];if(void 0===e)return;const i=e.clusterId;return void 0!==i?this.body.nodes[i]:void 0}_filter(t,e){const i=[];return jf(t,t=>{e(t)&&i.push(t)}),i}_updateState(){let t;const e=[],i={},s=t=>{jf(this.body.nodes,e=>{!0===e.isCluster&&t(e)})};for(t in this.clusteredNodes)Object.prototype.hasOwnProperty.call(this.clusteredNodes,t)&&void 0===this.body.nodes[t]&&e.push(t);s((function(t){for(let i=0;i{const e=this.body.edges[t];void 0!==e&&e.endPointsValid()||(i[t]=t)}),s((function(t){jf(t.containedEdges,(t,e)=>{t.endPointsValid()||i[e]||(i[e]=e)})})),jf(this.body.edges,(t,e)=>{let s=!0;const a=t.clusteringEdgeReplacingIds;if(void 0!==a){let t=0;jf(a,e=>{const i=this.body.edges[e];void 0!==i&&i.endPointsValid()&&(t+=1)}),s=t>0}t.endPointsValid()&&s||(i[e]=e)}),s(t=>{jf(i,e=>{delete t.containedEdges[e],jf(t.edges,(s,a)=>{s.id!==e?s.clusteringEdgeReplacingIds=this._filter(s.clusteringEdgeReplacingIds,(function(t){return!i[t]})):t.edges[a]=null}),t.edges=this._filter(t.edges,(function(t){return null!==t}))})}),jf(i,t=>{delete this.clusteredEdges[t]}),jf(i,t=>{delete this.body.edges[t]}),jf(tc(this.body.edges),t=>{const e=this.body.edges[t],i=this._isClusteredNode(e.fromId)||this._isClusteredNode(e.toId);if(i!==this._isClusteredEdge(e.id))if(i){const t=this._getClusterNodeForNode(e.fromId);void 0!==t&&this._clusterEdges(this.body.nodes[e.fromId],e,t);const i=this._getClusterNodeForNode(e.toId);void 0!==i&&this._clusterEdges(this.body.nodes[e.toId],e,i)}else delete this._clusterEdges[t],this._restoreEdge(e)});let a=!1,o=!0;for(;o;){const t=[];s((function(e){const i=tc(e.containedNodes).length,s=!0===e.options.allowSingleNodeCluster;(s&&i<1||!s&&i<2)&&t.push(e.id)}));for(let e=0;e0,a=a||o}a&&this._updateState()}_isClusteredNode(t){return void 0!==this.clusteredNodes[t]}_isClusteredEdge(t){return void 0!==this.clusteredEdges[t]}}class Sk{constructor(t,e){this.body=t,this.canvas=e,this.redrawRequested=!1,this.requestAnimationFrameRequestId=void 0,this.renderingActive=!1,this.renderRequests=0,this.allowRedraw=!0,this.dragging=!1,this.zooming=!1,this.options={},this.defaultOptions={hideEdgesOnDrag:!1,hideEdgesOnZoom:!1,hideNodesOnDrag:!1},bs(this.options,this.defaultOptions),this.bindEventListeners()}bindEventListeners(){var t;this.body.emitter.on("dragStart",()=>{this.dragging=!0}),this.body.emitter.on("dragEnd",()=>{this.dragging=!1}),this.body.emitter.on("zoom",()=>{this.zooming=!0,window.clearTimeout(this.zoomTimeoutId),this.zoomTimeoutId=am(()=>{var t;this.zooming=!1,js(t=this._requestRedraw).call(t,this)()},250)}),this.body.emitter.on("_resizeNodes",()=>{this._resizeNodes()}),this.body.emitter.on("_redraw",()=>{!1===this.renderingActive&&this._redraw()}),this.body.emitter.on("_blockRedraw",()=>{this.allowRedraw=!1}),this.body.emitter.on("_allowRedraw",()=>{this.allowRedraw=!0,this.redrawRequested=!1}),this.body.emitter.on("_requestRedraw",js(t=this._requestRedraw).call(t,this)),this.body.emitter.on("_startRendering",()=>{this.renderRequests+=1,this.renderingActive=!0,this._startRendering()}),this.body.emitter.on("_stopRendering",()=>{this.renderRequests-=1,this.renderingActive=this.renderRequests>0,this.requestAnimationFrameRequestId=void 0}),this.body.emitter.on("destroy",()=>{this.renderRequests=0,this.allowRedraw=!1,this.renderingActive=!1,window.cancelAnimationFrame(this.requestAnimationFrameRequestId),this.body.emitter.off()})}setOptions(t){void 0!==t&&If(["hideEdgesOnDrag","hideEdgesOnZoom","hideNodesOnDrag"],this.options,t)}_startRendering(){var t;!0===this.renderingActive&&void 0===this.requestAnimationFrameRequestId&&(this.requestAnimationFrameRequestId=window.requestAnimationFrame(js(t=this._renderStep).call(t,this),this.simulationInterval))}_renderStep(){!0===this.renderingActive&&(this.requestAnimationFrameRequestId=void 0,this._startRendering(),this._redraw())}redraw(){this.body.emitter.emit("setSize"),this._redraw()}_requestRedraw(){!0!==this.redrawRequested&&!1===this.renderingActive&&!0===this.allowRedraw&&(this.redrawRequested=!0,window.requestAnimationFrame(()=>{this._redraw(!1)}))}_redraw(){let t=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(!0===this.allowRedraw){this.body.emitter.emit("initRedraw"),this.redrawRequested=!1;const e={drawExternalLabels:null};0!==this.canvas.frame.canvas.width&&0!==this.canvas.frame.canvas.height||this.canvas.setSize(),this.canvas.setTransform();const i=this.canvas.getContext(),s=this.canvas.frame.canvas.clientWidth,a=this.canvas.frame.canvas.clientHeight;if(i.clearRect(0,0,s,a),0===this.canvas.frame.clientWidth)return;if(i.save(),i.translate(this.body.view.translation.x,this.body.view.translation.y),i.scale(this.body.view.scale,this.body.view.scale),i.beginPath(),this.body.emitter.emit("beforeDrawing",i),i.closePath(),!1===t&&(!1===this.dragging||!0===this.dragging&&!1===this.options.hideEdgesOnDrag)&&(!1===this.zooming||!0===this.zooming&&!1===this.options.hideEdgesOnZoom)&&this._drawEdges(i),!1===this.dragging||!0===this.dragging&&!1===this.options.hideNodesOnDrag){const{drawExternalLabels:s}=this._drawNodes(i,t);e.drawExternalLabels=s}!1===t&&(!1===this.dragging||!0===this.dragging&&!1===this.options.hideEdgesOnDrag)&&(!1===this.zooming||!0===this.zooming&&!1===this.options.hideEdgesOnZoom)&&this._drawArrows(i),null!=e.drawExternalLabels&&e.drawExternalLabels(),!1===t&&this._drawSelectionBox(i),i.beginPath(),this.body.emitter.emit("afterDrawing",i),i.closePath(),i.restore(),!0===t&&i.clearRect(0,0,s,a)}}_resizeNodes(){this.canvas.setTransform();const t=this.canvas.getContext();t.save(),t.translate(this.body.view.translation.x,this.body.view.translation.y),t.scale(this.body.view.scale,this.body.view.scale);const e=this.body.nodes;let i;for(const s in e)Object.prototype.hasOwnProperty.call(e,s)&&(i=e[s],i.resize(t),i.updateBoundingBox(t,i.selected));t.restore()}_drawNodes(t){let e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];const i=this.body.nodes,s=this.body.nodeIndices;let a;const o=[],n=[],r=this.canvas.DOMtoCanvas({x:-20,y:-20}),l=this.canvas.DOMtoCanvas({x:this.canvas.frame.canvas.clientWidth+20,y:this.canvas.frame.canvas.clientHeight+20}),h={top:r.y,left:r.x,bottom:l.y,right:l.x},d=[];for(let m=0;m{for(const t of d)t()}}}_drawEdges(t){const e=this.body.edges,i=this.body.edgeIndices;for(let s=0;s{0!==t.width&&(this.body.view.translation.x=.5*t.width),0!==t.height&&(this.body.view.translation.y=.5*t.height)}),this.body.emitter.on("setSize",js(t=this.setSize).call(t,this)),this.body.emitter.on("destroy",()=>{this.hammerFrame.destroy(),this.hammer.destroy(),this._cleanUp()})}setOptions(t){if(void 0!==t&&If(["width","height","autoResize"],this.options,t),this._cleanUp(),!0===this.options.autoResize){var e;if(window.ResizeObserver){const t=new ResizeObserver(()=>{!0===this.setSize()&&this.body.emitter.emit("_requestRedraw")}),{frame:e}=this;t.observe(e),this._cleanupCallbacks.push(()=>{t.unobserve(e)})}else{const t=Ak(()=>{!0===this.setSize()&&this.body.emitter.emit("_requestRedraw")},1e3);this._cleanupCallbacks.push(()=>{clearInterval(t)})}const t=js(e=this._onResize).call(e,this);window.addEventListener("resize",t),this._cleanupCallbacks.push(()=>{window.removeEventListener("resize",t)})}}_cleanUp(){var t,e,i;vc(t=Sc(e=tu(i=this._cleanupCallbacks).call(i,0)).call(e)).call(t,t=>{try{t()}catch(t){console.error(t)}})}_onResize(){this.setSize(),this.body.emitter.emit("_redraw")}_getCameraState(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.pixelRatio;!0===this.initialized&&(this.cameraState.previousWidth=this.frame.canvas.width/t,this.cameraState.previousHeight=this.frame.canvas.height/t,this.cameraState.scale=this.body.view.scale,this.cameraState.position=this.DOMtoCanvas({x:.5*this.frame.canvas.width/t,y:.5*this.frame.canvas.height/t}))}_setCameraState(){if(void 0!==this.cameraState.scale&&0!==this.frame.canvas.clientWidth&&0!==this.frame.canvas.clientHeight&&0!==this.pixelRatio&&this.cameraState.previousWidth>0&&this.cameraState.previousHeight>0){const t=this.frame.canvas.width/this.pixelRatio/this.cameraState.previousWidth,e=this.frame.canvas.height/this.pixelRatio/this.cameraState.previousHeight;let i=this.cameraState.scale;1!=t&&1!=e?i=.5*this.cameraState.scale*(t+e):1!=t?i=this.cameraState.scale*t:1!=e&&(i=this.cameraState.scale*e),this.body.view.scale=i;const s=this.DOMtoCanvas({x:.5*this.frame.canvas.clientWidth,y:.5*this.frame.canvas.clientHeight}),a={x:s.x-this.cameraState.position.x,y:s.y-this.cameraState.position.y};this.body.view.translation.x+=a.x*this.body.view.scale,this.body.view.translation.y+=a.y*this.body.view.scale}}_prepareValue(t){if("number"==typeof t)return t+"px";if("string"==typeof t){if(-1!==Fp(t).call(t,"%")||-1!==Fp(t).call(t,"px"))return t;if(-1===Fp(t).call(t,"%"))return t+"px"}throw new Error("Could not use the value supplied for width or height:"+t)}_create(){for(;this.body.container.hasChildNodes();)this.body.container.removeChild(this.body.container.firstChild);if(this.frame=document.createElement("div"),this.frame.className="vis-network",this.frame.style.position="relative",this.frame.style.overflow="hidden",this.frame.tabIndex=0,this.frame.canvas=document.createElement("canvas"),this.frame.canvas.style.position="relative",this.frame.appendChild(this.frame.canvas),this.frame.canvas.getContext)this._setPixelRatio(),this.setTransform();else{const t=document.createElement("DIV");t.style.color="red",t.style.fontWeight="bold",t.style.padding="10px",t.innerText="Error: your browser does not support HTML canvas",this.frame.canvas.appendChild(t)}this.body.container.appendChild(this.frame),this.body.view.scale=1,this.body.view.translation={x:.5*this.frame.canvas.clientWidth,y:.5*this.frame.canvas.clientHeight},this._bindHammer()}_bindHammer(){void 0!==this.hammer&&this.hammer.destroy(),this.drag={},this.pinch={},this.hammer=new mv(this.frame.canvas),this.hammer.get("pinch").set({enable:!0}),this.hammer.get("pan").set({threshold:5,direction:mv.DIRECTION_ALL}),Ek(this.hammer,t=>{this.body.eventListeners.onTouch(t)}),this.hammer.on("tap",t=>{this.body.eventListeners.onTap(t)}),this.hammer.on("doubletap",t=>{this.body.eventListeners.onDoubleTap(t)}),this.hammer.on("press",t=>{this.body.eventListeners.onHold(t)}),this.hammer.on("panstart",t=>{this.body.eventListeners.onDragStart(t)}),this.hammer.on("panmove",t=>{this.body.eventListeners.onDrag(t)}),this.hammer.on("panend",t=>{this.body.eventListeners.onDragEnd(t)}),this.hammer.on("pinch",t=>{this.body.eventListeners.onPinch(t)}),this.frame.canvas.addEventListener("wheel",t=>{this.body.eventListeners.onMouseWheel(t)}),this.frame.canvas.addEventListener("mousemove",t=>{this.body.eventListeners.onMouseMove(t)}),this.frame.canvas.addEventListener("contextmenu",t=>{this.body.eventListeners.onContext(t)}),this.hammerFrame=new mv(this.frame),Ok(this.hammerFrame,t=>{this.body.eventListeners.onRelease(t)})}setSize(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.options.width,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.options.height;t=this._prepareValue(t),e=this._prepareValue(e);let i=!1;const s=this.frame.canvas.width,a=this.frame.canvas.height,o=this.pixelRatio;if(this._setPixelRatio(),t!=this.options.width||e!=this.options.height||this.frame.style.width!=t||this.frame.style.height!=e)this._getCameraState(o),this.frame.style.width=t,this.frame.style.height=e,this.frame.canvas.style.width="100%",this.frame.canvas.style.height="100%",this.frame.canvas.width=Math.round(this.frame.canvas.clientWidth*this.pixelRatio),this.frame.canvas.height=Math.round(this.frame.canvas.clientHeight*this.pixelRatio),this.options.width=t,this.options.height=e,this.canvasViewCenter={x:.5*this.frame.clientWidth,y:.5*this.frame.clientHeight},i=!0;else{const t=Math.round(this.frame.canvas.clientWidth*this.pixelRatio),e=Math.round(this.frame.canvas.clientHeight*this.pixelRatio);this.frame.canvas.width===t&&this.frame.canvas.height===e||this._getCameraState(o),this.frame.canvas.width!==t&&(this.frame.canvas.width=t,i=!0),this.frame.canvas.height!==e&&(this.frame.canvas.height=e,i=!0)}return!0===i&&(this.body.emitter.emit("resize",{width:Math.round(this.frame.canvas.width/this.pixelRatio),height:Math.round(this.frame.canvas.height/this.pixelRatio),oldWidth:Math.round(s/this.pixelRatio),oldHeight:Math.round(a/this.pixelRatio)}),this._setCameraState()),this.initialized=!0,i}getContext(){return this.frame.canvas.getContext("2d")}_determinePixelRatio(){const t=this.getContext();if(void 0===t)throw new Error("Could not get canvax context");let e=1;return"undefined"!=typeof window&&(e=window.devicePixelRatio||1),e/(t.webkitBackingStorePixelRatio||t.mozBackingStorePixelRatio||t.msBackingStorePixelRatio||t.oBackingStorePixelRatio||t.backingStorePixelRatio||1)}_setPixelRatio(){this.pixelRatio=this._determinePixelRatio()}setTransform(){const t=this.getContext();if(void 0===t)throw new Error("Could not get canvax context");t.setTransform(this.pixelRatio,0,0,this.pixelRatio,0,0)}_XconvertDOMtoCanvas(t){return(t-this.body.view.translation.x)/this.body.view.scale}_XconvertCanvasToDOM(t){return t*this.body.view.scale+this.body.view.translation.x}_YconvertDOMtoCanvas(t){return(t-this.body.view.translation.y)/this.body.view.scale}_YconvertCanvasToDOM(t){return t*this.body.view.scale+this.body.view.translation.y}canvasToDOM(t){return{x:this._XconvertCanvasToDOM(t.x),y:this._YconvertCanvasToDOM(t.y)}}DOMtoCanvas(t){return{x:this._XconvertDOMtoCanvas(t.x),y:this._YconvertDOMtoCanvas(t.y)}}}class Nk{constructor(t,e){var i,s;this.body=t,this.canvas=e,this.animationSpeed=1/this.renderRefreshRate,this.animationEasingFunction="easeInOutQuint",this.easingTime=0,this.sourceScale=0,this.targetScale=0,this.sourceTranslation=0,this.targetTranslation=0,this.lockedOnNodeId=void 0,this.lockedOnNodeOffset=void 0,this.touchTime=0,this.viewFunction=void 0,this.body.emitter.on("fit",js(i=this.fit).call(i,this)),this.body.emitter.on("animationFinished",()=>{this.body.emitter.emit("_stopRendering")}),this.body.emitter.on("unlockNode",js(s=this.releaseNode).call(s,this))}setOptions(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.options=t}fit(t){let e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];t=function(t,e){const i=bs({nodes:e,minZoomLevel:Number.MIN_VALUE,maxZoomLevel:1},null!=t?t:{});if(!Ud(i.nodes))throw new TypeError("Nodes has to be an array of ids.");if(0===i.nodes.length&&(i.nodes=e),!("number"==typeof i.minZoomLevel&&i.minZoomLevel>0))throw new TypeError("Min zoom level has to be a number higher than zero.");if(!("number"==typeof i.maxZoomLevel&&i.minZoomLevel<=i.maxZoomLevel))throw new TypeError("Max zoom level has to be a number higher than min zoom level.");return i}(t,this.body.nodeIndices);const i=this.canvas.frame.canvas.clientWidth,s=this.canvas.frame.canvas.clientHeight;let a,o;if(0===i||0===s)o=1,a=Dk.getRange(this.body.nodes,t.nodes);else if(!0===e){let e=0;for(const t in this.body.nodes)Object.prototype.hasOwnProperty.call(this.body.nodes,t)&&!0===this.body.nodes[t].predefinedPosition&&(e+=1);if(e>.5*this.body.nodeIndices.length)return void this.fit(t,!1);a=Dk.getRange(this.body.nodes,t.nodes),o=12.662/(this.body.nodeIndices.length+7.4147)+.0964822,o*=Math.min(i/600,s/600)}else{this.body.emitter.emit("_resizeNodes"),a=Dk.getRange(this.body.nodes,t.nodes);const e=i/(1.1*Math.abs(a.maxX-a.minX)),n=s/(1.1*Math.abs(a.maxY-a.minY));o=e<=n?e:n}o>t.maxZoomLevel?o=t.maxZoomLevel:o1&&void 0!==arguments[1]?arguments[1]:{};if(void 0!==this.body.nodes[t]){const i={x:this.body.nodes[t].x,y:this.body.nodes[t].y};e.position=i,e.lockedOnNode=t,this.moveTo(e)}else console.error("Node: "+t+" cannot be found.")}moveTo(t){if(void 0!==t){if(null!=t.offset){if(null!=t.offset.x){if(t.offset.x=+t.offset.x,!uw(t.offset.x))throw new TypeError('The option "offset.x" has to be a finite number.')}else t.offset.x=0;if(null!=t.offset.y){if(t.offset.y=+t.offset.y,!uw(t.offset.y))throw new TypeError('The option "offset.y" has to be a finite number.')}else t.offset.x=0}else t.offset={x:0,y:0};if(null!=t.position){if(null!=t.position.x){if(t.position.x=+t.position.x,!uw(t.position.x))throw new TypeError('The option "position.x" has to be a finite number.')}else t.position.x=0;if(null!=t.position.y){if(t.position.y=+t.position.y,!uw(t.position.y))throw new TypeError('The option "position.y" has to be a finite number.')}else t.position.x=0}else t.position=this.getViewPosition();if(null!=t.scale){if(t.scale=+t.scale,!(t.scale>0))throw new TypeError('The option "scale" has to be a number greater than zero.')}else t.scale=this.body.view.scale;void 0===t.animation&&(t.animation={duration:0}),!1===t.animation&&(t.animation={duration:0}),!0===t.animation&&(t.animation={}),void 0===t.animation.duration&&(t.animation.duration=1e3),void 0===t.animation.easingFunction&&(t.animation.easingFunction="easeInOutQuad"),this.animateView(t)}else t={}}animateView(t){if(void 0===t)return;this.animationEasingFunction=t.animation.easingFunction,this.releaseNode(),!0===t.locked&&(this.lockedOnNodeId=t.lockedOnNode,this.lockedOnNodeOffset=t.offset),0!=this.easingTime&&this._transitionRedraw(!0),this.sourceScale=this.body.view.scale,this.sourceTranslation=this.body.view.translation,this.targetScale=t.scale,this.body.view.scale=this.targetScale;const e=this.canvas.DOMtoCanvas({x:.5*this.canvas.frame.canvas.clientWidth,y:.5*this.canvas.frame.canvas.clientHeight}),i=e.x-t.position.x,s=e.y-t.position.y;var a,o;this.targetTranslation={x:this.sourceTranslation.x+i*this.targetScale+t.offset.x,y:this.sourceTranslation.y+s*this.targetScale+t.offset.y},0===t.animation.duration?null!=this.lockedOnNodeId?(this.viewFunction=js(a=this._lockedRedraw).call(a,this),this.body.emitter.on("initRedraw",this.viewFunction)):(this.body.view.scale=this.targetScale,this.body.view.translation=this.targetTranslation,this.body.emitter.emit("_requestRedraw")):(this.animationSpeed=1/(60*t.animation.duration*.001)||1/60,this.animationEasingFunction=t.animation.easingFunction,this.viewFunction=js(o=this._transitionRedraw).call(o,this),this.body.emitter.on("initRedraw",this.viewFunction),this.body.emitter.emit("_startRendering"))}_lockedRedraw(){const t=this.body.nodes[this.lockedOnNodeId].x,e=this.body.nodes[this.lockedOnNodeId].y,i=this.canvas.DOMtoCanvas({x:.5*this.canvas.frame.canvas.clientWidth,y:.5*this.canvas.frame.canvas.clientHeight}),s=i.x-t,a=i.y-e,o=this.body.view.translation,n={x:o.x+s*this.body.view.scale+this.lockedOnNodeOffset.x,y:o.y+a*this.body.view.scale+this.lockedOnNodeOffset.y};this.body.view.translation=n}releaseNode(){void 0!==this.lockedOnNodeId&&void 0!==this.viewFunction&&(this.body.emitter.off("initRedraw",this.viewFunction),this.lockedOnNodeId=void 0,this.lockedOnNodeOffset=void 0)}_transitionRedraw(){let t=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.easingTime+=this.animationSpeed,this.easingTime=!0===t?1:this.easingTime;const e=sv[this.animationEasingFunction](this.easingTime);var i;(this.body.view.scale=this.sourceScale+(this.targetScale-this.sourceScale)*e,this.body.view.translation={x:this.sourceTranslation.x+(this.targetTranslation.x-this.sourceTranslation.x)*e,y:this.sourceTranslation.y+(this.targetTranslation.y-this.sourceTranslation.y)*e},this.easingTime>=1)&&(this.body.emitter.off("initRedraw",this.viewFunction),this.easingTime=0,null!=this.lockedOnNodeId&&(this.viewFunction=js(i=this._lockedRedraw).call(i,this),this.body.emitter.on("initRedraw",this.viewFunction)),this.body.emitter.emit("animationFinished"))}getScale(){return this.body.view.scale}getViewPosition(){return this.canvas.DOMtoCanvas({x:.5*this.canvas.frame.canvas.clientWidth,y:.5*this.canvas.frame.canvas.clientHeight})}}function Ik(t){var e,i=t&&t.preventDefault||!1,s=t&&t.container||window,a={},o={keydown:{},keyup:{}},n={};for(e=97;e<=122;e++)n[String.fromCharCode(e)]={code:e-97+65,shift:!1};for(e=65;e<=90;e++)n[String.fromCharCode(e)]={code:e,shift:!0};for(e=0;e<=9;e++)n[""+e]={code:48+e,shift:!1};for(e=1;e<=12;e++)n["F"+e]={code:111+e,shift:!1};for(e=0;e<=9;e++)n["num"+e]={code:96+e,shift:!1};n["num*"]={code:106,shift:!1},n["num+"]={code:107,shift:!1},n["num-"]={code:109,shift:!1},n["num/"]={code:111,shift:!1},n["num."]={code:110,shift:!1},n.left={code:37,shift:!1},n.up={code:38,shift:!1},n.right={code:39,shift:!1},n.down={code:40,shift:!1},n.space={code:32,shift:!1},n.enter={code:13,shift:!1},n.shift={code:16,shift:void 0},n.esc={code:27,shift:!1},n.backspace={code:8,shift:!1},n.tab={code:9,shift:!1},n.ctrl={code:17,shift:!1},n.alt={code:18,shift:!1},n.delete={code:46,shift:!1},n.pageup={code:33,shift:!1},n.pagedown={code:34,shift:!1},n["="]={code:187,shift:!1},n["-"]={code:189,shift:!1},n["]"]={code:221,shift:!1},n["["]={code:219,shift:!1};var r=function(t){h(t,"keydown")},l=function(t){h(t,"keyup")},h=function(t,e){if(void 0!==o[e][t.keyCode]){for(var s=o[e][t.keyCode],a=0;a{this.activated=!0,this.configureKeyboardBindings()}),this.body.emitter.on("deactivate",()=>{this.activated=!1,this.configureKeyboardBindings()}),this.body.emitter.on("destroy",()=>{void 0!==this.keycharm&&this.keycharm.destroy()}),this.options={}}setOptions(t){void 0!==t&&(this.options=t,this.create())}create(){!0===this.options.navigationButtons?!1===this.iconsCreated&&this.loadNavigationElements():!0===this.iconsCreated&&this.cleanNavigation(),this.configureKeyboardBindings()}cleanNavigation(){if(0!=this.navigationHammers.length){for(let t=0;t{this._stopMovement()}),this.navigationHammers.push(a),this.iconsCreated=!0}bindToRedraw(t){var e;void 0===this.boundFunctions[t]&&(this.boundFunctions[t]=js(e=this[t]).call(e,this),this.body.emitter.on("initRedraw",this.boundFunctions[t]),this.body.emitter.emit("_startRendering"))}unbindFromRedraw(t){void 0!==this.boundFunctions[t]&&(this.body.emitter.off("initRedraw",this.boundFunctions[t]),this.body.emitter.emit("_stopRendering"),delete this.boundFunctions[t])}_fit(){(new Date).valueOf()-this.touchTime>700&&(this.body.emitter.emit("fit",{duration:700}),this.touchTime=(new Date).valueOf())}_stopMovement(){for(const t in this.boundFunctions)Object.prototype.hasOwnProperty.call(this.boundFunctions,t)&&(this.body.emitter.off("initRedraw",this.boundFunctions[t]),this.body.emitter.emit("_stopRendering"));this.boundFunctions={}}_moveUp(){this.body.view.translation.y+=this.options.keyboard.speed.y}_moveDown(){this.body.view.translation.y-=this.options.keyboard.speed.y}_moveLeft(){this.body.view.translation.x+=this.options.keyboard.speed.x}_moveRight(){this.body.view.translation.x-=this.options.keyboard.speed.x}_zoomIn(){const t=this.body.view.scale,e=this.body.view.scale*(1+this.options.keyboard.speed.zoom),i=this.body.view.translation,s=e/t,a=(1-s)*this.canvas.canvasViewCenter.x+i.x*s,o=(1-s)*this.canvas.canvasViewCenter.y+i.y*s;this.body.view.scale=e,this.body.view.translation={x:a,y:o},this.body.emitter.emit("zoom",{direction:"+",scale:this.body.view.scale,pointer:null})}_zoomOut(){const t=this.body.view.scale,e=this.body.view.scale/(1+this.options.keyboard.speed.zoom),i=this.body.view.translation,s=e/t,a=(1-s)*this.canvas.canvasViewCenter.x+i.x*s,o=(1-s)*this.canvas.canvasViewCenter.y+i.y*s;this.body.view.scale=e,this.body.view.translation={x:a,y:o},this.body.emitter.emit("zoom",{direction:"-",scale:this.body.view.scale,pointer:null})}configureKeyboardBindings(){var t,e,i,s,a,o,n,r,l,h,d,c,u,p,m,g,f,v,y,b,w,_,x,C;void 0!==this.keycharm&&this.keycharm.destroy(),!0===this.options.keyboard.enabled&&(!0===this.options.keyboard.bindToWindow?this.keycharm=Ik({container:window,preventDefault:!0}):this.keycharm=Ik({container:this.canvas.frame,preventDefault:!0}),this.keycharm.reset(),!0===this.activated&&(js(t=this.keycharm).call(t,"up",()=>{this.bindToRedraw("_moveUp")},"keydown"),js(e=this.keycharm).call(e,"down",()=>{this.bindToRedraw("_moveDown")},"keydown"),js(i=this.keycharm).call(i,"left",()=>{this.bindToRedraw("_moveLeft")},"keydown"),js(s=this.keycharm).call(s,"right",()=>{this.bindToRedraw("_moveRight")},"keydown"),js(a=this.keycharm).call(a,"=",()=>{this.bindToRedraw("_zoomIn")},"keydown"),js(o=this.keycharm).call(o,"num+",()=>{this.bindToRedraw("_zoomIn")},"keydown"),js(n=this.keycharm).call(n,"num-",()=>{this.bindToRedraw("_zoomOut")},"keydown"),js(r=this.keycharm).call(r,"-",()=>{this.bindToRedraw("_zoomOut")},"keydown"),js(l=this.keycharm).call(l,"[",()=>{this.bindToRedraw("_zoomOut")},"keydown"),js(h=this.keycharm).call(h,"]",()=>{this.bindToRedraw("_zoomIn")},"keydown"),js(d=this.keycharm).call(d,"pageup",()=>{this.bindToRedraw("_zoomIn")},"keydown"),js(c=this.keycharm).call(c,"pagedown",()=>{this.bindToRedraw("_zoomOut")},"keydown"),js(u=this.keycharm).call(u,"up",()=>{this.unbindFromRedraw("_moveUp")},"keyup"),js(p=this.keycharm).call(p,"down",()=>{this.unbindFromRedraw("_moveDown")},"keyup"),js(m=this.keycharm).call(m,"left",()=>{this.unbindFromRedraw("_moveLeft")},"keyup"),js(g=this.keycharm).call(g,"right",()=>{this.unbindFromRedraw("_moveRight")},"keyup"),js(f=this.keycharm).call(f,"=",()=>{this.unbindFromRedraw("_zoomIn")},"keyup"),js(v=this.keycharm).call(v,"num+",()=>{this.unbindFromRedraw("_zoomIn")},"keyup"),js(y=this.keycharm).call(y,"num-",()=>{this.unbindFromRedraw("_zoomOut")},"keyup"),js(b=this.keycharm).call(b,"-",()=>{this.unbindFromRedraw("_zoomOut")},"keyup"),js(w=this.keycharm).call(w,"[",()=>{this.unbindFromRedraw("_zoomOut")},"keyup"),js(_=this.keycharm).call(_,"]",()=>{this.unbindFromRedraw("_zoomIn")},"keyup"),js(x=this.keycharm).call(x,"pageup",()=>{this.unbindFromRedraw("_zoomIn")},"keyup"),js(C=this.keycharm).call(C,"pagedown",()=>{this.unbindFromRedraw("_zoomOut")},"keyup")))}}class Lk{constructor(t,e,i){var s,a,o,n,r,l,h,d,c,u,p,m,g;this.body=t,this.canvas=e,this.selectionHandler=i,this.navigationHandler=new Pk(t,e),this.body.eventListeners.onTap=js(s=this.onTap).call(s,this),this.body.eventListeners.onTouch=js(a=this.onTouch).call(a,this),this.body.eventListeners.onDoubleTap=js(o=this.onDoubleTap).call(o,this),this.body.eventListeners.onHold=js(n=this.onHold).call(n,this),this.body.eventListeners.onDragStart=js(r=this.onDragStart).call(r,this),this.body.eventListeners.onDrag=js(l=this.onDrag).call(l,this),this.body.eventListeners.onDragEnd=js(h=this.onDragEnd).call(h,this),this.body.eventListeners.onMouseWheel=js(d=this.onMouseWheel).call(d,this),this.body.eventListeners.onPinch=js(c=this.onPinch).call(c,this),this.body.eventListeners.onMouseMove=js(u=this.onMouseMove).call(u,this),this.body.eventListeners.onRelease=js(p=this.onRelease).call(p,this),this.body.eventListeners.onContext=js(m=this.onContext).call(m,this),this.touchTime=0,this.drag={},this.pinch={},this.popup=void 0,this.popupObj=void 0,this.popupTimer=void 0,this.body.functions.getPointer=js(g=this.getPointer).call(g,this),this.options={},this.defaultOptions={dragNodes:!0,dragView:!0,hover:!1,keyboard:{enabled:!1,speed:{x:10,y:10,zoom:.02},bindToWindow:!0,autoFocus:!0},navigationButtons:!1,tooltipDelay:300,zoomView:!0,zoomSpeed:1},bs(this.options,this.defaultOptions),this.bindEventListeners()}bindEventListeners(){this.body.emitter.on("destroy",()=>{clearTimeout(this.popupTimer),delete this.body.functions.getPointer})}setOptions(t){void 0!==t&&(Rf(["hideEdgesOnDrag","hideEdgesOnZoom","hideNodesOnDrag","keyboard","multiselect","selectable","selectConnectedEdges"],this.options,t),iv(this.options,t,"keyboard"),t.tooltip&&(bs(this.options.tooltip,t.tooltip),t.tooltip.color&&(this.options.tooltip.color=qf(t.tooltip.color)))),this.navigationHandler.setOptions(this.options)}getPointer(t){return{x:t.x-zf(this.canvas.frame.canvas),y:t.y-Bf(this.canvas.frame.canvas)}}onTouch(t){(new Date).valueOf()-this.touchTime>50&&(this.drag.pointer=this.getPointer(t.center),this.drag.pinched=!1,this.pinch.scale=this.body.view.scale,this.touchTime=(new Date).valueOf())}onTap(t){const e=this.getPointer(t.center),i=this.selectionHandler.options.multiselect&&(t.changedPointers[0].ctrlKey||t.changedPointers[0].metaKey);this.checkSelectionChanges(e,i),this.selectionHandler.commitAndEmit(e,t),this.selectionHandler.generateClickEvent("click",t,e)}onDoubleTap(t){const e=this.getPointer(t.center);this.selectionHandler.generateClickEvent("doubleClick",t,e)}onHold(t){const e=this.getPointer(t.center),i=this.selectionHandler.options.multiselect;this.checkSelectionChanges(e,i),this.selectionHandler.commitAndEmit(e,t),this.selectionHandler.generateClickEvent("click",t,e),this.selectionHandler.generateClickEvent("hold",t,e)}onRelease(t){if((new Date).valueOf()-this.touchTime>10){const e=this.getPointer(t.center);this.selectionHandler.generateClickEvent("release",t,e),this.touchTime=(new Date).valueOf()}}onContext(t){const e=this.getPointer({x:t.clientX,y:t.clientY});this.selectionHandler.generateClickEvent("oncontext",t,e)}checkSelectionChanges(t){!0===(arguments.length>1&&void 0!==arguments[1]&&arguments[1])?this.selectionHandler.selectAdditionalOnPoint(t):this.selectionHandler.selectOnPoint(t)}_determineDifference(t,e){const i=function(t,e){const i=[];for(let s=0;s{const e=t.node;!1===t.xFixed&&(e.x=this.canvas._XconvertDOMtoCanvas(this.canvas._XconvertCanvasToDOM(t.x)+s)),!1===t.yFixed&&(e.y=this.canvas._YconvertDOMtoCanvas(this.canvas._YconvertCanvasToDOM(t.y)+a))}),this.body.emitter.emit("startSimulation")}else{if(t.srcEvent.shiftKey){if(this.selectionHandler.generateClickEvent("dragging",t,e,void 0,!0),void 0===this.drag.pointer)return void this.onDragStart(t);this.body.selectionBox.position.end={x:this.canvas._XconvertDOMtoCanvas(e.x),y:this.canvas._YconvertDOMtoCanvas(e.y)},this.body.emitter.emit("_requestRedraw")}if(!0===this.options.dragView&&!t.srcEvent.shiftKey){if(this.selectionHandler.generateClickEvent("dragging",t,e,void 0,!0),void 0===this.drag.pointer)return void this.onDragStart(t);const i=e.x-this.drag.pointer.x,s=e.y-this.drag.pointer.y;this.body.view.translation={x:this.drag.translation.x+i,y:this.drag.translation.y+s},this.body.emitter.emit("_requestRedraw")}}}onDragEnd(t){if(this.drag.dragging=!1,this.body.selectionBox.show){var e;this.body.selectionBox.show=!1;const i=this.body.selectionBox.position,s={minX:Math.min(i.start.x,i.end.x),minY:Math.min(i.start.y,i.end.y),maxX:Math.max(i.start.x,i.end.x),maxY:Math.max(i.start.y,i.end.y)},a=Bu(e=this.body.nodeIndices).call(e,t=>{const e=this.body.nodes[t];return e.x>=s.minX&&e.x<=s.maxX&&e.y>=s.minY&&e.y<=s.maxY});vc(a).call(a,t=>this.selectionHandler.selectObject(this.body.nodes[t]));const o=this.getPointer(t.center);this.selectionHandler.commitAndEmit(o,t),this.selectionHandler.generateClickEvent("dragEnd",t,this.getPointer(t.center),void 0,!0),this.body.emitter.emit("_requestRedraw")}else{const e=this.drag.selection;e&&e.length?(vc(e).call(e,(function(t){t.node.options.fixed.x=t.xFixed,t.node.options.fixed.y=t.yFixed})),this.selectionHandler.generateClickEvent("dragEnd",t,this.getPointer(t.center)),this.body.emitter.emit("startSimulation")):(this.selectionHandler.generateClickEvent("dragEnd",t,this.getPointer(t.center),void 0,!0),this.body.emitter.emit("_requestRedraw"))}}onPinch(t){const e=this.getPointer(t.center);this.drag.pinched=!0,void 0===this.pinch.scale&&(this.pinch.scale=1);const i=this.pinch.scale*t.scale;this.zoom(i,e)}zoom(t,e){if(!0===this.options.zoomView){const i=this.body.view.scale;let s;t<1e-5&&(t=1e-5),t>10&&(t=10),void 0!==this.drag&&!0===this.drag.dragging&&(s=this.canvas.DOMtoCanvas(this.drag.pointer));const a=this.body.view.translation,o=t/i,n=(1-o)*e.x+a.x*o,r=(1-o)*e.y+a.y*o;if(this.body.view.scale=t,this.body.view.translation={x:n,y:r},null!=s){const t=this.canvas.canvasToDOM(s);this.drag.pointer.x=t.x,this.drag.pointer.y=t.y}this.body.emitter.emit("_requestRedraw"),ithis._checkShowPopup(e),this.options.tooltipDelay))),!0===this.options.hover&&this.selectionHandler.hoverObject(t,e)}_checkShowPopup(t){const e=this.canvas._XconvertDOMtoCanvas(t.x),i=this.canvas._YconvertDOMtoCanvas(t.y),s={left:e,top:i,right:e,bottom:i},a=void 0===this.popupObj?void 0:this.popupObj.id;let o=!1,n="node";if(void 0===this.popupObj){const t=this.body.nodeIndices,e=this.body.nodes;let i;const a=[];for(let n=0;n0&&(this.popupObj=e[a[a.length-1]],o=!0)}if(void 0===this.popupObj&&!1===o){const t=this.body.edgeIndices,e=this.body.edges;let i;const a=[];for(let o=0;o0&&(this.popupObj=e[a[a.length-1]],n="edge")}void 0!==this.popupObj?this.popupObj.id!==a&&(void 0===this.popup&&(this.popup=new gv(this.canvas.frame)),this.popup.popupTargetType=n,this.popup.popupTargetId=this.popupObj.id,this.popup.setPosition(t.x+3,t.y-5),this.popup.setText(this.popupObj.getTitle()),this.popup.show(),this.body.emitter.emit("showPopup",this.popupObj.id)):void 0!==this.popup&&(this.popup.hide(),this.body.emitter.emit("hidePopup"))}_checkHidePopup(t){const e=this.selectionHandler._pointerToPositionObject(t);let i=!1;if("node"===this.popup.popupTargetType){if(void 0!==this.body.nodes[this.popup.popupTargetId]&&(i=this.body.nodes[this.popup.popupTargetId].isOverlappingWith(e),!0===i)){const e=this.selectionHandler.getNodeAt(t);i=void 0!==e&&e.id===this.popup.popupTargetId}}else void 0===this.selectionHandler.getNodeAt(t)&&void 0!==this.body.edges[this.popup.popupTargetId]&&(i=this.body.edges[this.popup.popupTargetId].isOverlappingWith(e));!1===i&&(this.popupObj=void 0,this.popup.hide(),this.body.emitter.emit("hidePopup"))}}var Mk=v,zk=kb,Bk=Dy.getWeakData,jk=nb,Vk=si,Hk=q,Wk=et,Uk=sb,$k=Zt,qk=Mn.set,Yk=Mn.getterFor,Gk=$n.find,Xk=$n.findIndex,Kk=Mk([].splice),Jk=0,Qk=function(t){return t.frozen||(t.frozen=new Zk)},Zk=function(){this.entries=[]},tT=function(t,e){return Gk(t.entries,(function(t){return t[0]===e}))};Zk.prototype={get:function(t){var e=tT(this,t);if(e)return e[1]},has:function(t){return!!tT(this,t)},set:function(t,e){var i=tT(this,t);i?i[1]=e:this.entries.push([t,e])},delete:function(t){var e=Xk(this.entries,(function(e){return e[0]===t}));return~e&&Kk(this.entries,e,1),!!~e}};var eT,iT={getConstructor:function(t,e,i,s){var a=t((function(t,a){jk(t,o),qk(t,{type:e,id:Jk++,frozen:void 0}),Hk(a)||Uk(a,t[s],{that:t,AS_ENTRIES:i})})),o=a.prototype,n=Yk(e),r=function(t,e,i){var s=n(t),a=Bk(Vk(e),!0);return!0===a?Qk(s).set(e,i):a[s.id]=i,t};return zk(o,{delete:function(t){var e=n(this);if(!Wk(t))return!1;var i=Bk(t);return!0===i?Qk(e).delete(t):i&&$k(i,e.id)&&delete i[e.id]},has:function(t){var e=n(this);if(!Wk(t))return!1;var i=Bk(t);return!0===i?Qk(e).has(t):i&&$k(i,e.id)}}),zk(o,i?{get:function(t){var e=n(this);if(Wk(t)){var i=Bk(t);return!0===i?Qk(e).get(t):i?i[e.id]:void 0}},set:function(t,e){return r(this,t,e)}}:{add:function(t){return r(this,t,!0)}}),a}},sT=ly,aT=o,oT=v,nT=kb,rT=Dy,lT=Cb,hT=iT,dT=et,cT=Mn.enforce,uT=n,pT=Cn,mT=Object,gT=Array.isArray,fT=mT.isExtensible,vT=mT.isFrozen,yT=mT.isSealed,bT=mT.freeze,wT=mT.seal,_T={},xT={},CT=!aT.ActiveXObject&&"ActiveXObject"in aT,DT=function(t){return function(){return t(this,arguments.length?arguments[0]:void 0)}},kT=lT("WeakMap",DT,hT),TT=kT.prototype,ST=oT(TT.set);if(pT)if(CT){eT=hT.getConstructor(DT,"WeakMap",!0),rT.enable();var AT=oT(TT.delete),ET=oT(TT.has),OT=oT(TT.get);nT(TT,{delete:function(t){if(dT(t)&&!fT(t)){var e=cT(this);return e.frozen||(e.frozen=new eT),AT(this,t)||e.frozen.delete(t)}return AT(this,t)},has:function(t){if(dT(t)&&!fT(t)){var e=cT(this);return e.frozen||(e.frozen=new eT),ET(this,t)||e.frozen.has(t)}return ET(this,t)},get:function(t){if(dT(t)&&!fT(t)){var e=cT(this);return e.frozen||(e.frozen=new eT),ET(this,t)?OT(this,t):e.frozen.get(t)}return OT(this,t)},set:function(t,e){if(dT(t)&&!fT(t)){var i=cT(this);i.frozen||(i.frozen=new eT),ET(this,t)?ST(this,t,e):i.frozen.set(t,e)}else ST(this,t,e);return this}})}else sT&&uT((function(){var t=bT([]);return ST(new kT,t,1),!vT(t)}))&&nT(TT,{set:function(t,e){var i;return gT(t)&&(vT(t)?i=_T:yT(t)&&(i=xT)),ST(this,t,e),i===_T&&bT(t),i===xT&&wT(t),this}});var FT,NT,IT,RT,PT,LT=s(it.WeakMap);function MT(t,e,i,s){if("a"===i&&!s)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof e?t!==e||!s:!e.has(t))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===i?s:"a"===i?s.call(t):s?s.value:e.get(t)}function zT(t,e,i,s,a){if("m"===s)throw new TypeError("Private method is not writable");if("a"===s&&!a)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof e?t!==e||!a:!e.has(t))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===s?a.call(t,i):a?a.value=i:e.set(t,i),i}function BT(t,e){const i=new nx;for(const s of e)t.has(s)||i.add(s);return i}"function"==typeof SuppressedError&&SuppressedError;class jT{constructor(){FT.set(this,new nx),NT.set(this,new nx)}get size(){return MT(this,NT,"f").size}add(){for(var t=arguments.length,e=new Array(t),i=0;i0&&void 0!==arguments[0]?arguments[0]:()=>{};IT.set(this,new jT),RT.set(this,new jT),PT.set(this,void 0),zT(this,PT,t,"f")}get sizeNodes(){return MT(this,IT,"f").size}get sizeEdges(){return MT(this,RT,"f").size}getNodes(){return MT(this,IT,"f").getSelection()}getEdges(){return MT(this,RT,"f").getSelection()}addNodes(){MT(this,IT,"f").add(...arguments)}addEdges(){MT(this,RT,"f").add(...arguments)}deleteNodes(t){MT(this,IT,"f").delete(t)}deleteEdges(t){MT(this,RT,"f").delete(t)}clear(){MT(this,IT,"f").clear(),MT(this,RT,"f").clear()}commit(){const t={nodes:MT(this,IT,"f").commit(),edges:MT(this,RT,"f").commit()};for(var e=arguments.length,i=new Array(e),s=0;s{this.updateSelection()})}setOptions(t){void 0!==t&&If(["multiselect","hoverConnectedEdges","selectable","selectConnectedEdges"],this.options,t)}selectOnPoint(t){let e=!1;if(!0===this.options.selectable){const i=this.getNodeAt(t)||this.getEdgeAt(t);this.unselectAll(),void 0!==i&&(e=this.selectObject(i)),this.body.emitter.emit("_requestRedraw")}return e}selectAdditionalOnPoint(t){let e=!1;if(!0===this.options.selectable){const i=this.getNodeAt(t)||this.getEdgeAt(t);void 0!==i&&(e=!0,!0===i.isSelected()?this.deselectObject(i):this.selectObject(i),this.body.emitter.emit("_requestRedraw"))}return e}_initBaseEvent(t,e){const i={};return i.pointer={DOM:{x:e.x,y:e.y},canvas:this.canvas.DOMtoCanvas(e)},i.event=t,i}generateClickEvent(t,e,i,s){let a=arguments.length>4&&void 0!==arguments[4]&&arguments[4];const o=this._initBaseEvent(e,i);if(!0===a)o.nodes=[],o.edges=[];else{const t=this.getSelection();o.nodes=t.nodes,o.edges=t.edges}void 0!==s&&(o.previousSelection=s),"click"==t&&(o.items=this.getClickedItems(i)),void 0!==e.controlEdge&&(o.controlEdge=e.controlEdge),this.body.emitter.emit(t,o)}selectObject(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.options.selectConnectedEdges;return void 0!==t&&(t instanceof PD?(!0===e&&this._selectionAccumulator.addEdges(...t.edges),this._selectionAccumulator.addNodes(t)):this._selectionAccumulator.addEdges(t),!0)}deselectObject(t){!0===t.isSelected()&&(t.selected=!1,this._removeFromSelection(t))}_getAllNodesOverlappingWith(t){const e=[],i=this.body.nodes;for(let s=0;s1&&void 0!==arguments[1])||arguments[1];const i=this._pointerToPositionObject(t),s=this._getAllNodesOverlappingWith(i);return s.length>0?!0===e?this.body.nodes[s[s.length-1]]:s[s.length-1]:void 0}_getEdgesOverlappingWith(t,e){const i=this.body.edges;for(let s=0;s1&&void 0!==arguments[1])||arguments[1];const i=this.canvas.DOMtoCanvas(t);let s=10,a=null;const o=this.body.edges;for(let n=0;n0&&(this.generateClickEvent("deselectEdge",e,t,a),i=!0),s.nodes.deleted.length>0&&(this.generateClickEvent("deselectNode",e,t,a),i=!0),s.nodes.added.length>0&&(this.generateClickEvent("selectNode",e,t),i=!0),s.edges.added.length>0&&(this.generateClickEvent("selectEdge",e,t),i=!0),!0===i&&this.generateClickEvent("select",e,t)}getSelection(){return{nodes:this.getSelectedNodeIds(),edges:this.getSelectedEdgeIds()}}getSelectedNodes(){return this._selectionAccumulator.getNodes()}getSelectedEdges(){return this._selectionAccumulator.getEdges()}getSelectedNodeIds(){var t;return Jd(t=this._selectionAccumulator.getNodes()).call(t,t=>t.id)}getSelectedEdgeIds(){var t;return Jd(t=this._selectionAccumulator.getEdges()).call(t,t=>t.id)}setSelection(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(!t||!t.nodes&&!t.edges)throw new TypeError("Selection must be an object with nodes and/or edges properties");if((e.unselectAll||void 0===e.unselectAll)&&this.unselectAll(),t.nodes)for(const i of t.nodes){const t=this.body.nodes[i];if(!t)throw new RangeError('Node with id "'+i+'" not found');this.selectObject(t,e.highlightEdges)}if(t.edges)for(const i of t.edges){const t=this.body.edges[i];if(!t)throw new RangeError('Edge with id "'+i+'" not found');this.selectObject(t)}this.body.emitter.emit("_requestRedraw"),this._selectionAccumulator.commit()}selectNodes(t){let e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];if(!t||void 0===t.length)throw"Selection must be an array with ids";this.setSelection({nodes:t},{highlightEdges:e})}selectEdges(t){if(!t||void 0===t.length)throw"Selection must be an array with ids";this.setSelection({edges:t})}updateSelection(){for(const t in this._selectionAccumulator.getNodes())Object.prototype.hasOwnProperty.call(this.body.nodes,t.id)||this._selectionAccumulator.deleteNodes(t);for(const t in this._selectionAccumulator.getEdges())Object.prototype.hasOwnProperty.call(this.body.edges,t.id)||this._selectionAccumulator.deleteEdges(t)}getClickedItems(t){const e=this.canvas.DOMtoCanvas(t),i=[],s=this.body.nodeIndices,a=this.body.nodes;for(let r=s.length-1;r>=0;r--){const t=a[s[r]].getItemsOnPoint(e);i.push.apply(i,t)}const o=this.body.edgeIndices,n=this.body.edges;for(let r=o.length-1;r>=0;r--){const t=n[o[r]].getItemsOnPoint(e);i.push.apply(i,t)}return i}}class WT{abstract(){throw new Error("Can't instantiate abstract class!")}fake_use(){}curveType(){return this.abstract()}getPosition(t){return this.fake_use(t),this.abstract()}setPosition(t,e){let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0;this.fake_use(t,e,i),this.abstract()}getTreeSize(t){return this.fake_use(t),this.abstract()}sort(t){this.fake_use(t),this.abstract()}fix(t,e){this.fake_use(t,e),this.abstract()}shift(t,e){this.fake_use(t,e),this.abstract()}}class UT extends WT{constructor(t){super(),this.layout=t}curveType(){return"horizontal"}getPosition(t){return t.x}setPosition(t,e){let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0;void 0!==i&&this.layout.hierarchical.addToOrdering(t,i),t.x=e}getTreeSize(t){const e=this.layout.hierarchical.getTreeSize(this.layout.body.nodes,t);return{min:e.min_x,max:e.max_x}}sort(t){$x(t).call(t,(function(t,e){return t.x-e.x}))}fix(t,e){t.y=this.layout.options.hierarchical.levelSeparation*e,t.options.fixed.y=!0}shift(t,e){this.layout.body.nodes[t].x+=e}}class $T extends WT{constructor(t){super(),this.layout=t}curveType(){return"vertical"}getPosition(t){return t.y}setPosition(t,e){let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0;void 0!==i&&this.layout.hierarchical.addToOrdering(t,i),t.y=e}getTreeSize(t){const e=this.layout.hierarchical.getTreeSize(this.layout.body.nodes,t);return{min:e.min_y,max:e.max_y}}sort(t){$x(t).call(t,(function(t,e){return t.y-e.y}))}fix(t,e){t.x=this.layout.options.hierarchical.levelSeparation*e,t.options.fixed.x=!0}shift(t,e){this.layout.body.nodes[t].y+=e}}var qT=$n.every;Ei({target:"Array",proto:!0,forced:!nc("every")},{every:function(t){return qT(this,t,arguments.length>1?arguments[1]:void 0)}});var YT=Rs("Array").every,GT=lt,XT=YT,KT=Array.prototype,JT=function(t){var e=t.every;return t===KT||GT(KT,t)&&e===KT.every?XT:e},QT=s(JT);function ZT(t,e){const i=new nx;return vc(t).call(t,t=>{var e;vc(e=t.edges).call(e,t=>{t.connected&&i.add(t)})}),vc(i).call(i,t=>{const i=t.from.id,s=t.to.id;null==e[i]&&(e[i]=0),(null==e[s]||e[i]>=e[s])&&(e[s]=e[i]+1)}),e}function tS(t,e,i,s){var a;const o=Pp(null),n=H_(a=[...hC(s).call(s)]).call(a,(t,e)=>t+1+e.edges.length,0),r=i+"Id",l="to"===i?1:-1;for(const[c,u]of s){if(!s.has(c)||!t(u))continue;o[c]=0;const a=[u];let p,m=0;for(;p=a.pop();){var h,d;if(!s.has(c))continue;const t=o[p.id]+l;if(vc(h=Bu(d=p.edges).call(d,t=>t.connected&&t.to!==t.from&&t[i]!==p&&s.has(t.toId)&&s.has(t.fromId))).call(h,s=>{const n=s[r],l=o[n];(null==l||e(t,l))&&(o[n]=t,a.push(s[i]))}),m>n)return ZT(s,o);++m}}return o}class eS{constructor(){this.childrenReference={},this.parentReference={},this.trees={},this.distributionOrdering={},this.levels={},this.distributionIndex={},this.isTree=!1,this.treeIndex=-1}addRelation(t,e){void 0===this.childrenReference[t]&&(this.childrenReference[t]=[]),this.childrenReference[t].push(e),void 0===this.parentReference[e]&&(this.parentReference[e]=[]),this.parentReference[e].push(t)}checkIfTree(){for(const t in this.parentReference)if(this.parentReference[t].length>1)return void(this.isTree=!1);this.isTree=!0}numTrees(){return this.treeIndex+1}setTreeIndex(t,e){void 0!==e&&void 0===this.trees[t.id]&&(this.trees[t.id]=e,this.treeIndex=Math.max(e,this.treeIndex))}ensureLevel(t){void 0===this.levels[t]&&(this.levels[t]=0)}getMaxLevel(t){const e={},i=t=>{if(void 0!==e[t])return e[t];let s=this.levels[t];if(this.childrenReference[t]){const e=this.childrenReference[t];if(e.length>0)for(let t=0;tt-e);for(const a of s)e.set(a,i++);for(const a in this.levels)Object.prototype.hasOwnProperty.call(this.levels,a)&&(this.levels[a]=e.get(this.levels[a]))}getTreeSize(t,e){let i=1e9,s=-1e9,a=1e9,o=-1e9;for(const n in this.trees)if(Object.prototype.hasOwnProperty.call(this.trees,n)&&this.trees[n]===e){const e=t[n];i=Math.min(e.x,i),s=Math.max(e.x,s),a=Math.min(e.y,a),o=Math.max(e.y,o)}return{min_x:i,max_x:s,min_y:a,max_y:o}}hasSameParent(t,e){const i=this.parentReference[t.id],s=this.parentReference[e.id];if(void 0===i||void 0===s)return!1;for(let a=0;a{this.setupHierarchicalLayout()}),this.body.emitter.on("_dataLoaded",()=>{this.layoutNetwork()}),this.body.emitter.on("_resetHierarchicalLayout",()=>{this.setupHierarchicalLayout()}),this.body.emitter.on("_adjustEdgesForHierarchicalLayout",()=>{if(!0!==this.options.hierarchical.enabled)return;const t=this.direction.curveType();this.body.emitter.emit("_forceDisableDynamicCurves",t,!1)})}setOptions(t,e){if(void 0!==t){const i=this.options.hierarchical,s=i.enabled;if(If(["randomSeed","improvedLayout","clusterThreshold"],this.options,t),iv(this.options,t,"hierarchical"),void 0!==t.randomSeed&&this._resetRNG(t.randomSeed),!0===i.enabled)return!0===s&&this.body.emitter.emit("refresh",!0),"RL"===i.direction||"DU"===i.direction?i.levelSeparation>0&&(i.levelSeparation*=-1):i.levelSeparation<0&&(i.levelSeparation*=-1),this.setDirectionStrategy(),this.body.emitter.emit("_resetHierarchicalLayout"),this.adaptAllOptionsForHierarchicalLayout(e);if(!0===s)return this.body.emitter.emit("refresh"),Pf(e,this.optionsBackup)}return e}_resetRNG(t){this.initialRandomSeed=t,this._rng=yf(this.initialRandomSeed)}adaptAllOptionsForHierarchicalLayout(t){if(!0===this.options.hierarchical.enabled){const e=this.optionsBackup.physics;void 0===t.physics||!0===t.physics?(t.physics={enabled:void 0===e.enabled||e.enabled,solver:"hierarchicalRepulsion"},e.enabled=void 0===e.enabled||e.enabled,e.solver=e.solver||"barnesHut"):"object"==typeof t.physics?(e.enabled=void 0===t.physics.enabled||t.physics.enabled,e.solver=t.physics.solver||"barnesHut",t.physics.solver="hierarchicalRepulsion"):!1!==t.physics&&(e.solver="barnesHut",t.physics={solver:"hierarchicalRepulsion"});let i=this.direction.curveType();if(void 0===t.edges)this.optionsBackup.edges={smooth:{enabled:!0,type:"dynamic"}},t.edges={smooth:!1};else if(void 0===t.edges.smooth)this.optionsBackup.edges={smooth:{enabled:!0,type:"dynamic"}},t.edges.smooth=!1;else if("boolean"==typeof t.edges.smooth)this.optionsBackup.edges={smooth:t.edges.smooth},t.edges.smooth={enabled:t.edges.smooth,type:i};else{const e=t.edges.smooth;void 0!==e.type&&"dynamic"!==e.type&&(i=e.type),this.optionsBackup.edges={smooth:{enabled:void 0===e.enabled||e.enabled,type:void 0===e.type?"dynamic":e.type,roundness:void 0===e.roundness?.5:e.roundness,forceDirection:void 0!==e.forceDirection&&e.forceDirection}},t.edges.smooth={enabled:void 0===e.enabled||e.enabled,type:i,roundness:void 0===e.roundness?.5:e.roundness,forceDirection:void 0!==e.forceDirection&&e.forceDirection}}this.body.emitter.emit("_forceDisableDynamicCurves",i)}return t}positionInitially(t){if(!0!==this.options.hierarchical.enabled){this._resetRNG(this.initialRandomSeed);const e=t.length+50;for(let i=0;is){const o=t.length;for(;t.length>s&&i<=e;){i+=1;const e=t.length;if(i%3==0?this.body.modules.clustering.clusterBridges(a):this.body.modules.clustering.clusterOutliers(a),e==t.length&&i%3!=0)return this._declusterAll(),this.body.emitter.emit("_layoutFailed"),void console.info("This network could not be positioned by this version of the improved layout algorithm. Please disable improvedLayout for better performance.")}this.body.modules.kamadaKawai.setOptions({springLength:Math.max(150,2*o)})}i>e&&console.info("The clustering didn't succeed within the amount of interations allowed, progressing with partial result."),this.body.modules.kamadaKawai.solve(t,this.body.edgeIndices,!0),this._shiftToCenter();const o=70;for(let n=0;n0){let t,e,i=!1,s=!1;for(e in this.lastNodeOnLevel={},this.hierarchical=new eS,this.body.nodes)Object.prototype.hasOwnProperty.call(this.body.nodes,e)&&(t=this.body.nodes[e],void 0!==t.options.level?(i=!0,this.hierarchical.levels[e]=t.options.level):s=!0);if(!0===s&&!0===i)throw new Error("To use the hierarchical layout, nodes require either no predefined levels or levels have to be defined for all nodes.");{if(!0===s){const t=this.options.hierarchical.sortMethod;"hubsize"===t?this._determineLevelsByHubsize():"directed"===t?this._determineLevelsDirected():"custom"===t&&this._determineLevelsCustomCallback()}for(const e in this.body.nodes)Object.prototype.hasOwnProperty.call(this.body.nodes,e)&&this.hierarchical.ensureLevel(e);const t=this._getDistribution();this._generateMap(),this._placeNodesByHierarchy(t),this._condenseHierarchy(),this._shiftToCenter()}}}_condenseHierarchy(){var t=this;let e=!1;const i={},s=(t,e)=>{const i=this.hierarchical.trees;for(const s in i)Object.prototype.hasOwnProperty.call(i,s)&&i[s]===t&&this.direction.shift(s,e)},a=()=>{const t=[];for(let e=0;e{if(!e[t.id]&&(e[t.id]=!0,this.hierarchical.childrenReference[t.id])){const i=this.hierarchical.childrenReference[t.id];if(i.length>0)for(let t=0;t1&&void 0!==arguments[1]?arguments[1]:1e9,s=1e9,a=1e9,o=1e9,n=-1e9;for(const r in e)if(Object.prototype.hasOwnProperty.call(e,r)){const l=t.body.nodes[r],h=t.hierarchical.levels[l.id],d=t.direction.getPosition(l),[c,u]=t._getSpaceAroundNode(l,e);s=Math.min(c,s),a=Math.min(u,a),h<=i&&(o=Math.min(d,o),n=Math.max(d,n))}return[o,n,s,a]},r=(t,e)=>{const i=this.hierarchical.getMaxLevel(t.id),s=this.hierarchical.getMaxLevel(e.id);return Math.min(i,s)},l=(t,e,i)=>{const s=this.hierarchical;for(let a=0;a1)for(let e=0;e2&&void 0!==arguments[2]&&arguments[2];const l=t.direction.getPosition(i),h=t.direction.getPosition(s),d=Math.abs(h-l),c=t.options.hierarchical.nodeSpacing;if(d>c){const l={},h={};o(i,l),o(s,h);const d=r(i,s),u=n(l,d),p=n(h,d),m=u[1],g=p[0],f=p[2];if(Math.abs(m-g)>c){let i=m-g+c;i<-f+c&&(i=-f+c),i<0&&(t._shiftBlock(s.id,i),e=!0,!0===a&&t._centerParent(s))}}},d=(t,s)=>{const a=s.id,r=s.edges,l=this.hierarchical.levels[s.id],h=this.options.hierarchical.levelSeparation*this.options.hierarchical.levelSeparation,d={},c=[];for(let e=0;e{let i=0;for(let s=0;s{let i=0;for(let s=0;s{let i=this.direction.getPosition(s);const a={};for(let s=0;s{const a=this.direction.getPosition(s);if(void 0===i[s.id]){const t={};o(s,t),i[s.id]=t}const r=n(i[s.id]),l=r[2],h=r[3],d=t-a;let c=0;d>0?c=Math.min(d,h-this.options.hierarchical.nodeSpacing):d<0&&(c=-Math.min(-d,l-this.options.hierarchical.nodeSpacing)),0!=c&&(this._shiftBlock(s.id,c),e=!0)})(g),g=m(t,r),(t=>{const i=this.direction.getPosition(s),[a,o]=this._getSpaceAroundNode(s),n=t-i;let r=i;n>0?r=Math.min(i+(o-this.options.hierarchical.nodeSpacing),t):n<0&&(r=Math.max(i-(a-this.options.hierarchical.nodeSpacing),t)),r!==i&&(this.direction.setPosition(s,r),e=!0)})(g)},c=t=>{let i=this.hierarchical.getLevels();i=Sc(i).call(i);for(let s=0;s{let i=this.hierarchical.getLevels();i=Sc(i).call(i);for(let s=0;s{for(const t in this.body.nodes)Object.prototype.hasOwnProperty.call(this.body.nodes,t)&&this._centerParent(this.body.nodes[t])},m=()=>{let t=this.hierarchical.getLevels();t=Sc(t).call(t);for(let e=0;e{const t=a();let e=0;for(let i=0;i0&&Math.abs(n)0&&(n=this.direction.getPosition(s[t-1])+o),this.direction.setPosition(e,n,i),this._validatePositionAndContinue(e,i,n),a++}}}}_placeBranchNodes(t,e){var i;const s=this.hierarchical.childrenReference[t];if(void 0===s)return;const a=[];for(let n=0;ne&&void 0===this.positionedNodes[i.id]))return;{const e=this.options.hierarchical.nodeSpacing;let o;o=0===n?this.direction.getPosition(this.body.nodes[t]):this.direction.getPosition(a[n-1])+e,this.direction.setPosition(i,o,s),this._validatePositionAndContinue(i,s,o)}}const o=this._getCenterPosition(a);this.direction.setPosition(this.body.nodes[t],o,e)}_validatePositionAndContinue(t,e,i){if(this.hierarchical.isTree){if(void 0!==this.lastNodeOnLevel[e]){const s=this.direction.getPosition(this.body.nodes[this.lastNodeOnLevel[e]]);if(i-s{var i;-1!==Fp(i=this.body.edgeIndices).call(i,t.id)&&e.push(t)}),e}_getHubSizes(){const t={};jf(this.body.nodeIndices,e=>{const i=this.body.nodes[e],s=this._getActiveEdges(i).length;t[s]=!0});const e=[];return jf(t,t=>{e.push(Number(t))}),$x(e).call(e,(function(t,e){return e-t})),e}_determineLevelsByHubsize(){const t=(t,e)=>{this.hierarchical.levelDownstream(t,e)},e=this._getHubSizes();for(let i=0;i{const i=this.body.nodes[e];s===this._getActiveEdges(i).length&&this._crawlNetwork(t,e)})}}_determineLevelsCustomCallback(){this._crawlNetwork((t,e,i)=>{let s=this.hierarchical.levels[t.id];void 0===s&&(s=this.hierarchical.levels[t.id]=1e5);const a=(Dk.cloneOptions(t,"node"),Dk.cloneOptions(e,"node"),void Dk.cloneOptions(i,"edge"));this.hierarchical.levels[e.id]=s+a}),this.hierarchical.setMinLevelToZero()}_determineLevelsDirected(){var t;const e=H_(t=this.body.nodeIndices).call(t,(t,e)=>(t.set(e,this.body.nodes[e]),t),new rw);"roots"===this.options.hierarchical.shakeTowards?this.hierarchical.levels=function(t){return tS(e=>{var i,s;return QT(i=Bu(s=e.edges).call(s,e=>t.has(e.toId))).call(i,t=>t.from===e)},(t,e)=>e{var i,s;return QT(i=Bu(s=e.edges).call(s,e=>t.has(e.toId))).call(i,t=>t.to===e)},(t,e)=>e>t,"from",t)}(e),this.hierarchical.setMinLevelToZero()}_generateMap(){this._crawlNetwork((t,e)=>{this.hierarchical.levels[e.id]>this.hierarchical.levels[t.id]&&this.hierarchical.addRelation(t.id,e.id)}),this.hierarchical.checkIfTree()}_crawlNetwork(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:function(){},e=arguments.length>1?arguments[1]:void 0;const i={},s=(e,a)=>{if(void 0===i[e.id]){let o;this.hierarchical.setTreeIndex(e,a),i[e.id]=!0;const n=this._getActiveEdges(e);for(let i=0;i{if(i[t])return;i[t]=!0,this.direction.shift(t,e);const a=this.hierarchical.childrenReference[t];if(void 0!==a)for(let e=0;e{const i=this.hierarchical.parentReference[e];if(void 0!==i)for(let a=0;a{const i=this.hierarchical.parentReference[e];if(void 0!==i)for(let s=0;s{this._clean()}),this.body.emitter.on("_dataChanged",js(a=this._restore).call(a,this)),this.body.emitter.on("_resetData",js(o=this._restore).call(o,this))}_restore(){!1!==this.inMode&&(!0===this.options.initiallyActive?this.enableEditMode():this.disableEditMode())}setOptions(t,e,i){void 0!==e&&(void 0!==e.locale?this.options.locale=e.locale:this.options.locale=i.locale,void 0!==e.locales?this.options.locales=e.locales:this.options.locales=i.locales),void 0!==t&&("boolean"==typeof t?this.options.enabled=t:(this.options.enabled=!0,Pf(this.options,t)),!0===this.options.initiallyActive&&(this.editMode=!0),this._setup())}toggleEditMode(){!0===this.editMode?this.disableEditMode():this.enableEditMode()}enableEditMode(){this.editMode=!0,this._clean(),!0===this.guiEnabled&&(this.manipulationDiv.style.display="block",this.closeDiv.style.display="block",this.editModeDiv.style.display="none",this.showManipulatorToolbar())}disableEditMode(){this.editMode=!1,this._clean(),!0===this.guiEnabled&&(this.manipulationDiv.style.display="none",this.closeDiv.style.display="none",this.editModeDiv.style.display="block",this._createEditButton())}showManipulatorToolbar(){if(this._clean(),this.manipulationDOM={},!0===this.guiEnabled){var t,e;this.editMode=!0,this.manipulationDiv.style.display="block",this.closeDiv.style.display="block";const i=this.selectionHandler.getSelectedNodeCount(),s=this.selectionHandler.getSelectedEdgeCount(),a=i+s,o=this.options.locales[this.options.locale];let n=!1;!1!==this.options.addNode&&(this._createAddNodeButton(o),n=!0),!1!==this.options.addEdge&&(!0===n?this._createSeperator(1):n=!0,this._createAddEdgeButton(o)),1===i&&"function"==typeof this.options.editNode?(!0===n?this._createSeperator(2):n=!0,this._createEditNodeButton(o)):1===s&&0===i&&!1!==this.options.editEdge&&(!0===n?this._createSeperator(3):n=!0,this._createEditEdgeButton(o)),0!==a&&(i>0&&!1!==this.options.deleteNode||0===i&&!1!==this.options.deleteEdge)&&(!0===n&&this._createSeperator(4),this._createDeleteButton(o)),this._bindElementEvents(this.closeDiv,js(t=this.toggleEditMode).call(t,this)),this._temporaryBindEvent("select",js(e=this.showManipulatorToolbar).call(e,this))}this.body.emitter.emit("_redraw")}addNodeMode(){var t;if(!0!==this.editMode&&this.enableEditMode(),this._clean(),this.inMode="addNode",!0===this.guiEnabled){var e;const t=this.options.locales[this.options.locale];this.manipulationDOM={},this._createBackButton(t),this._createSeperator(),this._createDescription(t.addDescription||this.options.locales.en.addDescription),this._bindElementEvents(this.closeDiv,js(e=this.toggleEditMode).call(e,this))}this._temporaryBindEvent("click",js(t=this._performAddNode).call(t,this))}editNode(){!0!==this.editMode&&this.enableEditMode(),this._clean();const t=this.selectionHandler.getSelectedNodes()[0];if(void 0!==t){if(this.inMode="editNode","function"!=typeof this.options.editNode)throw new Error("No function has been configured to handle the editing of nodes.");if(!0!==t.isCluster){const e=Pf({},t.options,!1);if(e.x=t.x,e.y=t.y,2!==this.options.editNode.length)throw new Error("The function for edit does not support two arguments (data, callback)");this.options.editNode(e,t=>{null!=t&&"editNode"===this.inMode&&this.body.data.nodes.getDataSet().update(t),this.showManipulatorToolbar()})}else alert(this.options.locales[this.options.locale].editClusterError||this.options.locales.en.editClusterError)}else this.showManipulatorToolbar()}addEdgeMode(){var t,e,i,s,a;if(!0!==this.editMode&&this.enableEditMode(),this._clean(),this.inMode="addEdge",!0===this.guiEnabled){var o;const t=this.options.locales[this.options.locale];this.manipulationDOM={},this._createBackButton(t),this._createSeperator(),this._createDescription(t.edgeDescription||this.options.locales.en.edgeDescription),this._bindElementEvents(this.closeDiv,js(o=this.toggleEditMode).call(o,this))}this._temporaryBindUI("onTouch",js(t=this._handleConnect).call(t,this)),this._temporaryBindUI("onDragEnd",js(e=this._finishConnect).call(e,this)),this._temporaryBindUI("onDrag",js(i=this._dragControlNode).call(i,this)),this._temporaryBindUI("onRelease",js(s=this._finishConnect).call(s,this)),this._temporaryBindUI("onDragStart",js(a=this._dragStartEdge).call(a,this)),this._temporaryBindUI("onHold",()=>{})}editEdgeMode(){if(!0!==this.editMode&&this.enableEditMode(),this._clean(),this.inMode="editEdge","object"!=typeof this.options.editEdge||"function"!=typeof this.options.editEdge.editWithoutDrag||(this.edgeBeingEditedId=this.selectionHandler.getSelectedEdgeIds()[0],void 0===this.edgeBeingEditedId)){if(!0===this.guiEnabled){var t;const e=this.options.locales[this.options.locale];this.manipulationDOM={},this._createBackButton(e),this._createSeperator(),this._createDescription(e.editEdgeDescription||this.options.locales.en.editEdgeDescription),this._bindElementEvents(this.closeDiv,js(t=this.toggleEditMode).call(t,this))}if(this.edgeBeingEditedId=this.selectionHandler.getSelectedEdgeIds()[0],void 0!==this.edgeBeingEditedId){var e,i,s,a;const t=this.body.edges[this.edgeBeingEditedId],o=this._getNewTargetNode(t.from.x,t.from.y),n=this._getNewTargetNode(t.to.x,t.to.y);this.temporaryIds.nodes.push(o.id),this.temporaryIds.nodes.push(n.id),this.body.nodes[o.id]=o,this.body.nodeIndices.push(o.id),this.body.nodes[n.id]=n,this.body.nodeIndices.push(n.id),this._temporaryBindUI("onTouch",js(e=this._controlNodeTouch).call(e,this)),this._temporaryBindUI("onTap",()=>{}),this._temporaryBindUI("onHold",()=>{}),this._temporaryBindUI("onDragStart",js(i=this._controlNodeDragStart).call(i,this)),this._temporaryBindUI("onDrag",js(s=this._controlNodeDrag).call(s,this)),this._temporaryBindUI("onDragEnd",js(a=this._controlNodeDragEnd).call(a,this)),this._temporaryBindUI("onMouseMove",()=>{}),this._temporaryBindEvent("beforeDrawing",e=>{const i=t.edgeType.findBorderPositions(e);!1===o.selected&&(o.x=i.from.x,o.y=i.from.y),!1===n.selected&&(n.x=i.to.x,n.y=i.to.y)}),this.body.emitter.emit("_redraw")}else this.showManipulatorToolbar()}else{const t=this.body.edges[this.edgeBeingEditedId];this._performEditEdge(t.from.id,t.to.id)}}deleteSelected(){!0!==this.editMode&&this.enableEditMode(),this._clean(),this.inMode="delete";const t=this.selectionHandler.getSelectedNodeIds(),e=this.selectionHandler.getSelectedEdgeIds();let i;if(t.length>0){for(let e=0;e0&&"function"==typeof this.options.deleteEdge&&(i=this.options.deleteEdge);if("function"==typeof i){const s={nodes:t,edges:e};if(2!==i.length)throw new Error("The function for delete does not support two arguments (data, callback)");i(s,t=>{null!=t&&"delete"===this.inMode?(this.body.data.edges.getDataSet().remove(t.edges),this.body.data.nodes.getDataSet().remove(t.nodes),this.body.emitter.emit("startSimulation"),this.showManipulatorToolbar()):(this.body.emitter.emit("startSimulation"),this.showManipulatorToolbar())})}else this.body.data.edges.getDataSet().remove(e),this.body.data.nodes.getDataSet().remove(t),this.body.emitter.emit("startSimulation"),this.showManipulatorToolbar()}_setup(){!0===this.options.enabled?(this.guiEnabled=!0,this._createWrappers(),!1===this.editMode?this._createEditButton():this.showManipulatorToolbar()):(this._removeManipulationDOM(),this.guiEnabled=!1)}_createWrappers(){var t,e;void 0===this.manipulationDiv&&(this.manipulationDiv=document.createElement("div"),this.manipulationDiv.className="vis-manipulation",!0===this.editMode?this.manipulationDiv.style.display="block":this.manipulationDiv.style.display="none",this.canvas.frame.appendChild(this.manipulationDiv)),void 0===this.editModeDiv&&(this.editModeDiv=document.createElement("div"),this.editModeDiv.className="vis-edit-mode",!0===this.editMode?this.editModeDiv.style.display="none":this.editModeDiv.style.display="block",this.canvas.frame.appendChild(this.editModeDiv)),void 0===this.closeDiv&&(this.closeDiv=document.createElement("button"),this.closeDiv.className="vis-close",this.closeDiv.setAttribute("aria-label",null!==(t=null===(e=this.options.locales[this.options.locale])||void 0===e?void 0:e.close)&&void 0!==t?t:this.options.locales.en.close),this.closeDiv.style.display=this.manipulationDiv.style.display,this.canvas.frame.appendChild(this.closeDiv))}_getNewTargetNode(t,e){const i=Pf({},this.options.controlNodeStyle);i.id="targetNode"+kC(),i.hidden=!1,i.physics=!1,i.x=t,i.y=e;const s=this.body.functions.createNode(i);return s.shape.boundingBox={left:t,right:t,top:e,bottom:e},s}_createEditButton(){var t;this._clean(),this.manipulationDOM={},Sf(this.editModeDiv);const e=this.options.locales[this.options.locale],i=this._createButton("editMode","vis-edit vis-edit-mode",e.edit||this.options.locales.en.edit);this.editModeDiv.appendChild(i),this._bindElementEvents(i,js(t=this.toggleEditMode).call(t,this))}_clean(){this.inMode=!1,!0===this.guiEnabled&&(Sf(this.editModeDiv),Sf(this.manipulationDiv),this._cleanupDOMEventListeners()),this._cleanupTemporaryNodesAndEdges(),this._unbindTemporaryUIs(),this._unbindTemporaryEvents(),this.body.emitter.emit("restorePhysics")}_cleanupDOMEventListeners(){for(const e of tu(t=this._domEventListenerCleanupQueue).call(t,0)){var t;e()}}_removeManipulationDOM(){this._clean(),Sf(this.manipulationDiv),Sf(this.editModeDiv),Sf(this.closeDiv),this.manipulationDiv&&this.canvas.frame.removeChild(this.manipulationDiv),this.editModeDiv&&this.canvas.frame.removeChild(this.editModeDiv),this.closeDiv&&this.canvas.frame.removeChild(this.closeDiv),this.manipulationDiv=void 0,this.editModeDiv=void 0,this.closeDiv=void 0}_createSeperator(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1;this.manipulationDOM["seperatorLineDiv"+t]=document.createElement("div"),this.manipulationDOM["seperatorLineDiv"+t].className="vis-separator-line",this.manipulationDiv.appendChild(this.manipulationDOM["seperatorLineDiv"+t])}_createAddNodeButton(t){var e;const i=this._createButton("addNode","vis-add",t.addNode||this.options.locales.en.addNode);this.manipulationDiv.appendChild(i),this._bindElementEvents(i,js(e=this.addNodeMode).call(e,this))}_createAddEdgeButton(t){var e;const i=this._createButton("addEdge","vis-connect",t.addEdge||this.options.locales.en.addEdge);this.manipulationDiv.appendChild(i),this._bindElementEvents(i,js(e=this.addEdgeMode).call(e,this))}_createEditNodeButton(t){var e;const i=this._createButton("editNode","vis-edit",t.editNode||this.options.locales.en.editNode);this.manipulationDiv.appendChild(i),this._bindElementEvents(i,js(e=this.editNode).call(e,this))}_createEditEdgeButton(t){var e;const i=this._createButton("editEdge","vis-edit",t.editEdge||this.options.locales.en.editEdge);this.manipulationDiv.appendChild(i),this._bindElementEvents(i,js(e=this.editEdgeMode).call(e,this))}_createDeleteButton(t){var e;let i;i=this.options.rtl?"vis-delete-rtl":"vis-delete";const s=this._createButton("delete",i,t.del||this.options.locales.en.del);this.manipulationDiv.appendChild(s),this._bindElementEvents(s,js(e=this.deleteSelected).call(e,this))}_createBackButton(t){var e;const i=this._createButton("back","vis-back",t.back||this.options.locales.en.back);this.manipulationDiv.appendChild(i),this._bindElementEvents(i,js(e=this.showManipulatorToolbar).call(e,this))}_createButton(t,e,i){let s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"vis-label";return this.manipulationDOM[t+"Div"]=document.createElement("button"),this.manipulationDOM[t+"Div"].className="vis-button "+e,this.manipulationDOM[t+"Label"]=document.createElement("div"),this.manipulationDOM[t+"Label"].className=s,this.manipulationDOM[t+"Label"].innerText=i,this.manipulationDOM[t+"Div"].appendChild(this.manipulationDOM[t+"Label"]),this.manipulationDOM[t+"Div"]}_createDescription(t){this.manipulationDOM.descriptionLabel=document.createElement("div"),this.manipulationDOM.descriptionLabel.className="vis-none",this.manipulationDOM.descriptionLabel.innerText=t,this.manipulationDiv.appendChild(this.manipulationDOM.descriptionLabel)}_temporaryBindEvent(t,e){this.temporaryEventFunctions.push({event:t,boundFunction:e}),this.body.emitter.on(t,e)}_temporaryBindUI(t,e){if(void 0===this.body.eventListeners[t])throw new Error("This UI function does not exist. Typo? You tried: "+t+" possible are: "+Bp(tc(this.body.eventListeners)));this.temporaryUIFunctions[t]=this.body.eventListeners[t],this.body.eventListeners[t]=e}_unbindTemporaryUIs(){for(const t in this.temporaryUIFunctions)Object.prototype.hasOwnProperty.call(this.temporaryUIFunctions,t)&&(this.body.eventListeners[t]=this.temporaryUIFunctions[t],delete this.temporaryUIFunctions[t]);this.temporaryUIFunctions={}}_unbindTemporaryEvents(){for(let t=0;t{i.destroy()});const s=t=>{let{keyCode:i,key:s}=t;"Enter"!==s&&" "!==s&&13!==i&&32!==i||e()};t.addEventListener("keyup",s,!1),this._domEventListenerCleanupQueue.push(()=>{t.removeEventListener("keyup",s,!1)})}_cleanupTemporaryNodesAndEdges(){for(let a=0;a=0;n--)if(a[n]!==this.selectedControlNode.id){o=this.body.nodes[a[n]];break}if(void 0!==o&&void 0!==this.selectedControlNode)if(!0===o.isCluster)alert(this.options.locales[this.options.locale].createEdgeError||this.options.locales.en.createEdgeError);else{const t=this.body.nodes[this.temporaryIds.nodes[0]];this.selectedControlNode.id===t.id?this._performEditEdge(o.id,s.to.id):this._performEditEdge(s.from.id,o.id)}else s.updateEdgeType(),this.body.emitter.emit("restorePhysics");this.body.emitter.emit("_redraw")}_handleConnect(t){if((new Date).valueOf()-this.touchTime>100){this.lastTouch=this.body.functions.getPointer(t.center),this.lastTouch.translation=bs({},this.body.view.translation),this.interactionHandler.drag.pointer=this.lastTouch,this.interactionHandler.drag.translation=this.lastTouch.translation;const e=this.lastTouch,i=this.selectionHandler.getNodeAt(e);if(void 0!==i)if(!0===i.isCluster)alert(this.options.locales[this.options.locale].createEdgeError||this.options.locales.en.createEdgeError);else{const t=this._getNewTargetNode(i.x,i.y);this.body.nodes[t.id]=t,this.body.nodeIndices.push(t.id);const e=this.body.functions.createEdge({id:"connectionEdge"+kC(),from:i.id,to:t.id,physics:!1,smooth:{enabled:!0,type:"continuous",roundness:.5}});this.body.edges[e.id]=e,this.body.edgeIndices.push(e.id),this.temporaryIds.nodes.push(t.id),this.temporaryIds.edges.push(e.id)}this.touchTime=(new Date).valueOf()}}_dragControlNode(t){const e=this.body.functions.getPointer(t.center),i=this.selectionHandler._pointerToPositionObject(e);let s;void 0!==this.temporaryIds.edges[0]&&(s=this.body.edges[this.temporaryIds.edges[0]].fromId);const a=this.selectionHandler._getAllNodesOverlappingWith(i);let o;for(let r=a.length-1;r>=0;r--){var n;if(-1===Fp(n=this.temporaryIds.nodes).call(n,a[r])){o=this.body.nodes[a[r]];break}}if(t.controlEdge={from:s,to:o?o.id:void 0},this.selectionHandler.generateClickEvent("controlNodeDragging",t,e),void 0!==this.temporaryIds.nodes[0]){const t=this.body.nodes[this.temporaryIds.nodes[0]];t.x=this.canvas._XconvertDOMtoCanvas(e.x),t.y=this.canvas._YconvertDOMtoCanvas(e.y),this.body.emitter.emit("_redraw")}else this.interactionHandler.onDrag(t)}_finishConnect(t){const e=this.body.functions.getPointer(t.center),i=this.selectionHandler._pointerToPositionObject(e);let s;void 0!==this.temporaryIds.edges[0]&&(s=this.body.edges[this.temporaryIds.edges[0]].fromId);const a=this.selectionHandler._getAllNodesOverlappingWith(i);let o;for(let r=a.length-1;r>=0;r--){var n;if(-1===Fp(n=this.temporaryIds.nodes).call(n,a[r])){o=this.body.nodes[a[r]];break}}this._cleanupTemporaryNodesAndEdges(),void 0!==o&&(!0===o.isCluster?alert(this.options.locales[this.options.locale].createEdgeError||this.options.locales.en.createEdgeError):void 0!==this.body.nodes[s]&&void 0!==this.body.nodes[o.id]&&this._performAddEdge(s,o.id)),t.controlEdge={from:s,to:o?o.id:void 0},this.selectionHandler.generateClickEvent("controlNodeDragEnd",t,e),this.body.emitter.emit("_redraw")}_dragStartEdge(t){const e=this.lastTouch;this.selectionHandler.generateClickEvent("dragStart",t,e,void 0,!0)}_performAddNode(t){const e={id:kC(),x:t.pointer.canvas.x,y:t.pointer.canvas.y,label:"new"};if("function"==typeof this.options.addNode){if(2!==this.options.addNode.length)throw this.showManipulatorToolbar(),new Error("The function for add does not support two arguments (data,callback)");this.options.addNode(e,t=>{null!=t&&"addNode"===this.inMode&&this.body.data.nodes.getDataSet().add(t),this.showManipulatorToolbar()})}else this.body.data.nodes.getDataSet().add(e),this.showManipulatorToolbar()}_performAddEdge(t,e){const i={from:t,to:e};if("function"==typeof this.options.addEdge){if(2!==this.options.addEdge.length)throw new Error("The function for connect does not support two arguments (data,callback)");this.options.addEdge(i,t=>{null!=t&&"addEdge"===this.inMode&&(this.body.data.edges.getDataSet().add(t),this.selectionHandler.unselectAll(),this.showManipulatorToolbar())})}else this.body.data.edges.getDataSet().add(i),this.selectionHandler.unselectAll(),this.showManipulatorToolbar()}_performEditEdge(t,e){const i={id:this.edgeBeingEditedId,from:t,to:e,label:this.body.data.edges.get(this.edgeBeingEditedId).label};let s=this.options.editEdge;if("object"==typeof s&&(s=s.editWithoutDrag),"function"==typeof s){if(2!==s.length)throw new Error("The function for edit does not support two arguments (data, callback)");s(i,t=>{null==t||"editEdge"!==this.inMode?(this.body.edges[i.id].updateEdgeType(),this.body.emitter.emit("_redraw"),this.showManipulatorToolbar()):(this.body.data.edges.getDataSet().update(t),this.selectionHandler.unselectAll(),this.showManipulatorToolbar())})}else this.body.data.edges.getDataSet().update(i),this.selectionHandler.unselectAll(),this.showManipulatorToolbar()}}const aS="string",oS="boolean",nS="number",rS="array",lS="object",hS=["arrow","bar","box","circle","crow","curve","diamond","image","inv_curve","inv_triangle","triangle","vee"],dS={borderWidth:{number:nS},borderWidthSelected:{number:nS,undefined:"undefined"},brokenImage:{string:aS,undefined:"undefined"},chosen:{label:{boolean:oS,function:"function"},node:{boolean:oS,function:"function"},__type__:{object:lS,boolean:oS}},color:{border:{string:aS},background:{string:aS},highlight:{border:{string:aS},background:{string:aS},__type__:{object:lS,string:aS}},hover:{border:{string:aS},background:{string:aS},__type__:{object:lS,string:aS}},__type__:{object:lS,string:aS}},opacity:{number:nS,undefined:"undefined"},fixed:{x:{boolean:oS},y:{boolean:oS},__type__:{object:lS,boolean:oS}},font:{align:{string:aS},color:{string:aS},size:{number:nS},face:{string:aS},background:{string:aS},strokeWidth:{number:nS},strokeColor:{string:aS},vadjust:{number:nS},multi:{boolean:oS,string:aS},bold:{color:{string:aS},size:{number:nS},face:{string:aS},mod:{string:aS},vadjust:{number:nS},__type__:{object:lS,string:aS}},boldital:{color:{string:aS},size:{number:nS},face:{string:aS},mod:{string:aS},vadjust:{number:nS},__type__:{object:lS,string:aS}},ital:{color:{string:aS},size:{number:nS},face:{string:aS},mod:{string:aS},vadjust:{number:nS},__type__:{object:lS,string:aS}},mono:{color:{string:aS},size:{number:nS},face:{string:aS},mod:{string:aS},vadjust:{number:nS},__type__:{object:lS,string:aS}},__type__:{object:lS,string:aS}},group:{string:aS,number:nS,undefined:"undefined"},heightConstraint:{minimum:{number:nS},valign:{string:aS},__type__:{object:lS,boolean:oS,number:nS}},hidden:{boolean:oS},icon:{face:{string:aS},code:{string:aS},size:{number:nS},color:{string:aS},weight:{string:aS,number:nS},__type__:{object:lS}},id:{string:aS,number:nS},image:{selected:{string:aS,undefined:"undefined"},unselected:{string:aS,undefined:"undefined"},__type__:{object:lS,string:aS}},imagePadding:{top:{number:nS},right:{number:nS},bottom:{number:nS},left:{number:nS},__type__:{object:lS,number:nS}},label:{string:aS,undefined:"undefined"},labelHighlightBold:{boolean:oS},level:{number:nS,undefined:"undefined"},margin:{top:{number:nS},right:{number:nS},bottom:{number:nS},left:{number:nS},__type__:{object:lS,number:nS}},mass:{number:nS},physics:{boolean:oS},scaling:{min:{number:nS},max:{number:nS},label:{enabled:{boolean:oS},min:{number:nS},max:{number:nS},maxVisible:{number:nS},drawThreshold:{number:nS},__type__:{object:lS,boolean:oS}},customScalingFunction:{function:"function"},__type__:{object:lS}},shadow:{enabled:{boolean:oS},color:{string:aS},size:{number:nS},x:{number:nS},y:{number:nS},__type__:{object:lS,boolean:oS}},shape:{string:["custom","ellipse","circle","database","box","text","image","circularImage","diamond","dot","star","triangle","triangleDown","square","icon","hexagon"]},ctxRenderer:{function:"function"},shapeProperties:{borderDashes:{boolean:oS,array:rS},borderRadius:{number:nS},interpolation:{boolean:oS},useImageSize:{boolean:oS},useBorderWithImage:{boolean:oS},coordinateOrigin:{string:["center","top-left"]},__type__:{object:lS}},size:{number:nS},title:{string:aS,dom:"dom",undefined:"undefined"},value:{number:nS,undefined:"undefined"},widthConstraint:{minimum:{number:nS},maximum:{number:nS},__type__:{object:lS,boolean:oS,number:nS}},x:{number:nS},y:{number:nS},__type__:{object:lS}},cS={configure:{enabled:{boolean:oS},filter:{boolean:oS,string:aS,array:rS,function:"function"},container:{dom:"dom"},showButton:{boolean:oS},__type__:{object:lS,boolean:oS,string:aS,array:rS,function:"function"}},edges:{arrows:{to:{enabled:{boolean:oS},scaleFactor:{number:nS},type:{string:hS},imageHeight:{number:nS},imageWidth:{number:nS},src:{string:aS},__type__:{object:lS,boolean:oS}},middle:{enabled:{boolean:oS},scaleFactor:{number:nS},type:{string:hS},imageWidth:{number:nS},imageHeight:{number:nS},src:{string:aS},__type__:{object:lS,boolean:oS}},from:{enabled:{boolean:oS},scaleFactor:{number:nS},type:{string:hS},imageWidth:{number:nS},imageHeight:{number:nS},src:{string:aS},__type__:{object:lS,boolean:oS}},__type__:{string:["from","to","middle"],object:lS}},endPointOffset:{from:{number:nS},to:{number:nS},__type__:{object:lS,number:nS}},arrowStrikethrough:{boolean:oS},background:{enabled:{boolean:oS},color:{string:aS},size:{number:nS},dashes:{boolean:oS,array:rS},__type__:{object:lS,boolean:oS}},chosen:{label:{boolean:oS,function:"function"},edge:{boolean:oS,function:"function"},__type__:{object:lS,boolean:oS}},color:{color:{string:aS},highlight:{string:aS},hover:{string:aS},inherit:{string:["from","to","both"],boolean:oS},opacity:{number:nS},__type__:{object:lS,string:aS}},dashes:{boolean:oS,array:rS},font:{color:{string:aS},size:{number:nS},face:{string:aS},background:{string:aS},strokeWidth:{number:nS},strokeColor:{string:aS},align:{string:["horizontal","top","middle","bottom"]},vadjust:{number:nS},multi:{boolean:oS,string:aS},bold:{color:{string:aS},size:{number:nS},face:{string:aS},mod:{string:aS},vadjust:{number:nS},__type__:{object:lS,string:aS}},boldital:{color:{string:aS},size:{number:nS},face:{string:aS},mod:{string:aS},vadjust:{number:nS},__type__:{object:lS,string:aS}},ital:{color:{string:aS},size:{number:nS},face:{string:aS},mod:{string:aS},vadjust:{number:nS},__type__:{object:lS,string:aS}},mono:{color:{string:aS},size:{number:nS},face:{string:aS},mod:{string:aS},vadjust:{number:nS},__type__:{object:lS,string:aS}},__type__:{object:lS,string:aS}},hidden:{boolean:oS},hoverWidth:{function:"function",number:nS},label:{string:aS,undefined:"undefined"},labelHighlightBold:{boolean:oS},length:{number:nS,undefined:"undefined"},physics:{boolean:oS},scaling:{min:{number:nS},max:{number:nS},label:{enabled:{boolean:oS},min:{number:nS},max:{number:nS},maxVisible:{number:nS},drawThreshold:{number:nS},__type__:{object:lS,boolean:oS}},customScalingFunction:{function:"function"},__type__:{object:lS}},selectionWidth:{function:"function",number:nS},selfReferenceSize:{number:nS},selfReference:{size:{number:nS},angle:{number:nS},renderBehindTheNode:{boolean:oS},__type__:{object:lS}},shadow:{enabled:{boolean:oS},color:{string:aS},size:{number:nS},x:{number:nS},y:{number:nS},__type__:{object:lS,boolean:oS}},smooth:{enabled:{boolean:oS},type:{string:["dynamic","continuous","discrete","diagonalCross","straightCross","horizontal","vertical","curvedCW","curvedCCW","cubicBezier"]},roundness:{number:nS},forceDirection:{string:["horizontal","vertical","none"],boolean:oS},__type__:{object:lS,boolean:oS}},title:{string:aS,undefined:"undefined"},width:{number:nS},widthConstraint:{maximum:{number:nS},__type__:{object:lS,boolean:oS,number:nS}},value:{number:nS,undefined:"undefined"},__type__:{object:lS}},groups:{useDefaultGroups:{boolean:oS},__any__:dS,__type__:{object:lS}},interaction:{dragNodes:{boolean:oS},dragView:{boolean:oS},hideEdgesOnDrag:{boolean:oS},hideEdgesOnZoom:{boolean:oS},hideNodesOnDrag:{boolean:oS},hover:{boolean:oS},keyboard:{enabled:{boolean:oS},speed:{x:{number:nS},y:{number:nS},zoom:{number:nS},__type__:{object:lS}},bindToWindow:{boolean:oS},autoFocus:{boolean:oS},__type__:{object:lS,boolean:oS}},multiselect:{boolean:oS},navigationButtons:{boolean:oS},selectable:{boolean:oS},selectConnectedEdges:{boolean:oS},hoverConnectedEdges:{boolean:oS},tooltipDelay:{number:nS},zoomView:{boolean:oS},zoomSpeed:{number:nS},__type__:{object:lS}},layout:{randomSeed:{undefined:"undefined",number:nS,string:aS},improvedLayout:{boolean:oS},clusterThreshold:{number:nS},hierarchical:{enabled:{boolean:oS},levelSeparation:{number:nS},nodeSpacing:{number:nS},treeSpacing:{number:nS},blockShifting:{boolean:oS},edgeMinimization:{boolean:oS},parentCentralization:{boolean:oS},direction:{string:["UD","DU","LR","RL"]},sortMethod:{string:["hubsize","directed"]},shakeTowards:{string:["leaves","roots"]},__type__:{object:lS,boolean:oS}},__type__:{object:lS}},manipulation:{enabled:{boolean:oS},initiallyActive:{boolean:oS},addNode:{boolean:oS,function:"function"},addEdge:{boolean:oS,function:"function"},editNode:{function:"function"},editEdge:{editWithoutDrag:{function:"function"},__type__:{object:lS,boolean:oS,function:"function"}},deleteNode:{boolean:oS,function:"function"},deleteEdge:{boolean:oS,function:"function"},controlNodeStyle:dS,__type__:{object:lS,boolean:oS}},nodes:dS,physics:{enabled:{boolean:oS},barnesHut:{theta:{number:nS},gravitationalConstant:{number:nS},centralGravity:{number:nS},springLength:{number:nS},springConstant:{number:nS},damping:{number:nS},avoidOverlap:{number:nS},__type__:{object:lS}},forceAtlas2Based:{theta:{number:nS},gravitationalConstant:{number:nS},centralGravity:{number:nS},springLength:{number:nS},springConstant:{number:nS},damping:{number:nS},avoidOverlap:{number:nS},__type__:{object:lS}},repulsion:{centralGravity:{number:nS},springLength:{number:nS},springConstant:{number:nS},nodeDistance:{number:nS},damping:{number:nS},__type__:{object:lS}},hierarchicalRepulsion:{centralGravity:{number:nS},springLength:{number:nS},springConstant:{number:nS},nodeDistance:{number:nS},damping:{number:nS},avoidOverlap:{number:nS},__type__:{object:lS}},maxVelocity:{number:nS},minVelocity:{number:nS},solver:{string:["barnesHut","repulsion","hierarchicalRepulsion","forceAtlas2Based"]},stabilization:{enabled:{boolean:oS},iterations:{number:nS},updateInterval:{number:nS},onlyDynamicEdges:{boolean:oS},fit:{boolean:oS},__type__:{object:lS,boolean:oS}},timestep:{number:nS},adaptiveTimestep:{boolean:oS},wind:{x:{number:nS},y:{number:nS},__type__:{object:lS}},__type__:{object:lS,boolean:oS}},autoResize:{boolean:oS},clickToUse:{boolean:oS},locale:{string:aS},locales:{__any__:{any:"any"},__type__:{object:lS}},height:{string:aS},width:{string:aS},__type__:{object:lS}},uS={nodes:{borderWidth:[1,0,10,1],borderWidthSelected:[2,0,10,1],color:{border:["color","#2B7CE9"],background:["color","#97C2FC"],highlight:{border:["color","#2B7CE9"],background:["color","#D2E5FF"]},hover:{border:["color","#2B7CE9"],background:["color","#D2E5FF"]}},opacity:[0,0,1,.1],fixed:{x:!1,y:!1},font:{color:["color","#343434"],size:[14,0,100,1],face:["arial","verdana","tahoma"],background:["color","none"],strokeWidth:[0,0,50,1],strokeColor:["color","#ffffff"]},hidden:!1,labelHighlightBold:!0,physics:!0,scaling:{min:[10,0,200,1],max:[30,0,200,1],label:{enabled:!1,min:[14,0,200,1],max:[30,0,200,1],maxVisible:[30,0,200,1],drawThreshold:[5,0,20,1]}},shadow:{enabled:!1,color:"rgba(0,0,0,0.5)",size:[10,0,20,1],x:[5,-30,30,1],y:[5,-30,30,1]},shape:["ellipse","box","circle","database","diamond","dot","square","star","text","triangle","triangleDown","hexagon"],shapeProperties:{borderDashes:!1,borderRadius:[6,0,20,1],interpolation:!0,useImageSize:!1},size:[25,0,200,1]},edges:{arrows:{to:{enabled:!1,scaleFactor:[1,0,3,.05],type:"arrow"},middle:{enabled:!1,scaleFactor:[1,0,3,.05],type:"arrow"},from:{enabled:!1,scaleFactor:[1,0,3,.05],type:"arrow"}},endPointOffset:{from:[0,-10,10,1],to:[0,-10,10,1]},arrowStrikethrough:!0,color:{color:["color","#848484"],highlight:["color","#848484"],hover:["color","#848484"],inherit:["from","to","both",!0,!1],opacity:[1,0,1,.05]},dashes:!1,font:{color:["color","#343434"],size:[14,0,100,1],face:["arial","verdana","tahoma"],background:["color","none"],strokeWidth:[2,0,50,1],strokeColor:["color","#ffffff"],align:["horizontal","top","middle","bottom"]},hidden:!1,hoverWidth:[1.5,0,5,.1],labelHighlightBold:!0,physics:!0,scaling:{min:[1,0,100,1],max:[15,0,100,1],label:{enabled:!0,min:[14,0,200,1],max:[30,0,200,1],maxVisible:[30,0,200,1],drawThreshold:[5,0,20,1]}},selectionWidth:[1.5,0,5,.1],selfReferenceSize:[20,0,200,1],selfReference:{size:[20,0,200,1],angle:[Math.PI/2,-6*Math.PI,6*Math.PI,Math.PI/8],renderBehindTheNode:!0},shadow:{enabled:!1,color:"rgba(0,0,0,0.5)",size:[10,0,20,1],x:[5,-30,30,1],y:[5,-30,30,1]},smooth:{enabled:!0,type:["dynamic","continuous","discrete","diagonalCross","straightCross","horizontal","vertical","curvedCW","curvedCCW","cubicBezier"],forceDirection:["horizontal","vertical","none"],roundness:[.5,0,1,.05]},width:[1,0,30,1]},layout:{hierarchical:{enabled:!1,levelSeparation:[150,20,500,5],nodeSpacing:[100,20,500,5],treeSpacing:[200,20,500,5],blockShifting:!0,edgeMinimization:!0,parentCentralization:!0,direction:["UD","DU","LR","RL"],sortMethod:["hubsize","directed"],shakeTowards:["leaves","roots"]}},interaction:{dragNodes:!0,dragView:!0,hideEdgesOnDrag:!1,hideEdgesOnZoom:!1,hideNodesOnDrag:!1,hover:!1,keyboard:{enabled:!1,speed:{x:[10,0,40,1],y:[10,0,40,1],zoom:[.02,0,.1,.005]},bindToWindow:!0,autoFocus:!0},multiselect:!1,navigationButtons:!1,selectable:!0,selectConnectedEdges:!0,hoverConnectedEdges:!0,tooltipDelay:[300,0,1e3,25],zoomView:!0,zoomSpeed:[1,.1,2,.1]},manipulation:{enabled:!1,initiallyActive:!1},physics:{enabled:!0,barnesHut:{theta:[.5,.1,1,.05],gravitationalConstant:[-2e3,-3e4,0,50],centralGravity:[.3,0,10,.05],springLength:[95,0,500,5],springConstant:[.04,0,1.2,.005],damping:[.09,0,1,.01],avoidOverlap:[0,0,1,.01]},forceAtlas2Based:{theta:[.5,.1,1,.05],gravitationalConstant:[-50,-500,0,1],centralGravity:[.01,0,1,.005],springLength:[95,0,500,5],springConstant:[.08,0,1.2,.005],damping:[.4,0,1,.01],avoidOverlap:[0,0,1,.01]},repulsion:{centralGravity:[.2,0,10,.05],springLength:[200,0,500,5],springConstant:[.05,0,1.2,.005],nodeDistance:[100,0,500,5],damping:[.09,0,1,.01]},hierarchicalRepulsion:{centralGravity:[.2,0,10,.05],springLength:[100,0,500,5],springConstant:[.01,0,1.2,.005],nodeDistance:[120,0,500,5],damping:[.09,0,1,.01],avoidOverlap:[0,0,1,.01]},maxVelocity:[50,0,150,1],minVelocity:[.1,.01,.5,.01],solver:["barnesHut","forceAtlas2Based","repulsion","hierarchicalRepulsion"],timestep:[.5,.01,1,.01],wind:{x:[0,-10,10,.1],y:[0,-10,10,.1]}}},pS=(t,e,i)=>{var s;return!(!xu(t).call(t,"physics")||!xu(s=uS.physics.solver).call(s,e)||i.physics.solver===e||"wind"===e)};var mS=Object.freeze({__proto__:null,allOptions:cS,configuratorHideOption:pS,configureOptions:uS});class gS{constructor(){}getDistances(t,e,i){const s={},a=t.edges;for(let n=0;n2&&void 0!==arguments[2]&&arguments[2];const s=this.distanceSolver.getDistances(this.body,t,e);this._createL_matrix(s),this._createK_matrix(s),this._createE_matrix();let a=0;const o=Math.max(1e3,Math.min(10*this.body.nodeIndices.length,6e3));let n=1e9,r=0,l=0,h=0,d=0,c=0;for(;n>.01&&a1&&c<5;)c+=1,this._moveNode(r,l,h),[d,l,h]=this._getEnergy(r)}_getHighestEnergyNode(t){const e=this.body.nodeIndices,i=this.body.nodes;let s=0,a=e[0],o=0,n=0;for(let r=0;rthis.body.emitter.emit("_requestRedraw")),this.groups=new lw,this.canvas=new Fk(this.body),this.selectionHandler=new HT(this.body,this.canvas),this.interactionHandler=new Lk(this.body,this.canvas,this.selectionHandler),this.view=new Nk(this.body,this.canvas),this.renderer=new Sk(this.body,this.canvas),this.physics=new Ck(this.body),this.layoutEngine=new iS(this.body),this.clustering=new Tk(this.body),this.manipulation=new sS(this.body,this.canvas,this.selectionHandler,this.interactionHandler),this.nodesHandler=new LD(this.body,this.images,this.groups,this.layoutEngine),this.edgesHandler=new mk(this.body,this.images,this.groups),this.body.modules.kamadaKawai=new fS(this.body,150,.05),this.body.modules.clustering=this.clustering,this.canvas._create(),this.setOptions(i),this.setData(e)}function yS(t){for(const e in t)Object.prototype.hasOwnProperty.call(t,e)&&(t[e].redundant=t[e].used,t[e].used=[])}function bS(t){for(const e in t)if(Object.prototype.hasOwnProperty.call(t,e)&&t[e].redundant){for(let i=0;i0?(s=e[t].redundant[0],e[t].redundant.shift()):(s=document.createElementNS("http://www.w3.org/2000/svg",t),i.appendChild(s)):(s=document.createElementNS("http://www.w3.org/2000/svg",t),e[t]={used:[],redundant:[]},i.appendChild(s)),e[t].used.push(s),s}Gs(vS.prototype),vS.prototype.setOptions=function(t){if(null===t&&(t=void 0),void 0!==t){if(!0===vv.validate(t,cS)&&console.error("%cErrors have been found in the supplied options object.",fv),If(["locale","locales","clickToUse"],this.options,t),void 0!==t.locale&&(t.locale=function(t,e){try{const[s,a]=e.split(/[-_ /]/,2),o=null!=s?s.toLowerCase():null,n=null!=a?a.toUpperCase():null;if(o&&n){const e=o+"-"+n;if(Object.prototype.hasOwnProperty.call(t,e))return e;var i;console.warn(Nu(i="Unknown variant ".concat(n," of language ")).call(i,o,"."))}if(o){const e=o;if(Object.prototype.hasOwnProperty.call(t,e))return e;console.warn("Unknown language ".concat(o))}return console.warn("Unknown locale ".concat(e,", falling back to English.")),"en"}catch(t){return console.error(t),console.warn("Unexpected error while normalizing locale ".concat(e,", falling back to English.")),"en"}}(t.locales||this.options.locales,t.locale)),t=this.layoutEngine.setOptions(t.layout,t),this.canvas.setOptions(t),this.groups.setOptions(t.groups),this.nodesHandler.setOptions(t.nodes),this.edgesHandler.setOptions(t.edges),this.physics.setOptions(t.physics),this.manipulation.setOptions(t.manipulation,t,this.options),this.interactionHandler.setOptions(t.interaction),this.renderer.setOptions(t.interaction),this.selectionHandler.setOptions(t.interaction),void 0!==t.groups&&this.body.emitter.emit("refreshNodes"),"configure"in t&&(this.configurator||(this.configurator=new pv(this,this.body.container,uS,this.canvas.pixelRatio,pS)),this.configurator.setOptions(t.configure)),this.configurator&&!0===this.configurator.options.enabled){const t={nodes:{},edges:{},layout:{},interaction:{},manipulation:{},physics:{},global:{}};Pf(t.nodes,this.nodesHandler.options),Pf(t.edges,this.edgesHandler.options),Pf(t.layout,this.layoutEngine.options),Pf(t.interaction,this.selectionHandler.options),Pf(t.interaction,this.renderer.options),Pf(t.interaction,this.interactionHandler.options),Pf(t.manipulation,this.manipulation.options),Pf(t.physics,this.physics.options),Pf(t.global,this.canvas.options),Pf(t.global,this.options),this.configurator.setModuleOptions(t)}void 0!==t.clickToUse?!0===t.clickToUse?void 0===this.activator&&(this.activator=new cv(this.canvas.frame),this.activator.on("change",()=>{this.body.emitter.emit("activate")})):(void 0!==this.activator&&(this.activator.destroy(),delete this.activator),this.body.emitter.emit("activate")):this.body.emitter.emit("activate"),this.canvas.setSize(),this.body.emitter.emit("startSimulation")}},vS.prototype._updateVisibleIndices=function(){const t=this.body.nodes,e=this.body.edges;this.body.nodeIndices=[],this.body.edgeIndices=[];for(const i in t)Object.prototype.hasOwnProperty.call(t,i)&&(this.clustering._isClusteredNode(i)||!1!==t[i].options.hidden||this.body.nodeIndices.push(t[i].id));for(const i in e)if(Object.prototype.hasOwnProperty.call(e,i)){const s=e[i],a=t[s.fromId],o=t[s.toId],n=void 0!==a&&void 0!==o;!this.clustering._isClusteredEdge(i)&&!1===s.options.hidden&&n&&!1===a.options.hidden&&!1===o.options.hidden&&this.body.edgeIndices.push(s.id)}},vS.prototype.bindEventListeners=function(){this.body.emitter.on("_dataChanged",()=>{this.edgesHandler._updateState(),this.body.emitter.emit("_dataUpdated")}),this.body.emitter.on("_dataUpdated",()=>{this.clustering._updateState(),this._updateVisibleIndices(),this._updateValueRange(this.body.nodes),this._updateValueRange(this.body.edges),this.body.emitter.emit("startSimulation"),this.body.emitter.emit("_requestRedraw")})},vS.prototype.setData=function(t){if(this.body.emitter.emit("resetPhysics"),this.body.emitter.emit("_resetData"),this.selectionHandler.unselectAll(),t&&t.dot&&(t.nodes||t.edges))throw new SyntaxError('Data must contain either parameter "dot" or parameter pair "nodes" and "edges", but not both.');if(this.setOptions(t&&t.options),t&&t.dot){console.warn("The dot property has been deprecated. Please use the static convertDot method to convert DOT into vis.network format and use the normal data format with nodes and edges. This converter is used like this: var data = vis.network.convertDot(dotString);");const e=Yv(t.dot);this.setData(e)}else if(t&&t.gephi){console.warn("The gephi property has been deprecated. Please use the static convertGephi method to convert gephi into vis.network format and use the normal data format with nodes and edges. This converter is used like this: var data = vis.network.convertGephi(gephiJson);");const e=Xv(t.gephi);this.setData(e)}else this.nodesHandler.setData(t&&t.nodes,!0),this.edgesHandler.setData(t&&t.edges,!0),this.body.emitter.emit("_dataChanged"),this.body.emitter.emit("_dataLoaded"),this.body.emitter.emit("initPhysics")},vS.prototype.destroy=function(){this.body.emitter.emit("destroy"),this.body.emitter.off(),this.off(),delete this.groups,delete this.canvas,delete this.selectionHandler,delete this.interactionHandler,delete this.view,delete this.renderer,delete this.physics,delete this.layoutEngine,delete this.clustering,delete this.manipulation,delete this.nodesHandler,delete this.edgesHandler,delete this.configurator,delete this.images;for(const t in this.body.nodes)Object.prototype.hasOwnProperty.call(this.body.nodes,t)&&delete this.body.nodes[t];for(const t in this.body.edges)Object.prototype.hasOwnProperty.call(this.body.edges,t)&&delete this.body.edges[t];Sf(this.body.container)},vS.prototype._updateValueRange=function(t){let e,i,s,a=0;for(e in t)if(Object.prototype.hasOwnProperty.call(t,e)){const o=t[e].getValue();void 0!==o&&(i=void 0===i?o:Math.min(o,i),s=void 0===s?o:Math.max(o,s),a+=o)}if(void 0!==i&&void 0!==s)for(e in t)Object.prototype.hasOwnProperty.call(t,e)&&t[e].setValueRange(i,s,a)},vS.prototype.isActive=function(){return!this.activator||this.activator.active},vS.prototype.setSize=function(){return this.canvas.setSize.apply(this.canvas,arguments)},vS.prototype.canvasToDOM=function(){return this.canvas.canvasToDOM.apply(this.canvas,arguments)},vS.prototype.DOMtoCanvas=function(){return this.canvas.DOMtoCanvas.apply(this.canvas,arguments)},vS.prototype.findNode=function(){return this.clustering.findNode.apply(this.clustering,arguments)},vS.prototype.isCluster=function(){return this.clustering.isCluster.apply(this.clustering,arguments)},vS.prototype.openCluster=function(){return this.clustering.openCluster.apply(this.clustering,arguments)},vS.prototype.cluster=function(){return this.clustering.cluster.apply(this.clustering,arguments)},vS.prototype.getNodesInCluster=function(){return this.clustering.getNodesInCluster.apply(this.clustering,arguments)},vS.prototype.clusterByConnection=function(){return this.clustering.clusterByConnection.apply(this.clustering,arguments)},vS.prototype.clusterByHubsize=function(){return this.clustering.clusterByHubsize.apply(this.clustering,arguments)},vS.prototype.updateClusteredNode=function(){return this.clustering.updateClusteredNode.apply(this.clustering,arguments)},vS.prototype.getClusteredEdges=function(){return this.clustering.getClusteredEdges.apply(this.clustering,arguments)},vS.prototype.getBaseEdge=function(){return this.clustering.getBaseEdge.apply(this.clustering,arguments)},vS.prototype.getBaseEdges=function(){return this.clustering.getBaseEdges.apply(this.clustering,arguments)},vS.prototype.updateEdge=function(){return this.clustering.updateEdge.apply(this.clustering,arguments)},vS.prototype.clusterOutliers=function(){return this.clustering.clusterOutliers.apply(this.clustering,arguments)},vS.prototype.getSeed=function(){return this.layoutEngine.getSeed.apply(this.layoutEngine,arguments)},vS.prototype.enableEditMode=function(){return this.manipulation.enableEditMode.apply(this.manipulation,arguments)},vS.prototype.disableEditMode=function(){return this.manipulation.disableEditMode.apply(this.manipulation,arguments)},vS.prototype.addNodeMode=function(){return this.manipulation.addNodeMode.apply(this.manipulation,arguments)},vS.prototype.editNode=function(){return this.manipulation.editNode.apply(this.manipulation,arguments)},vS.prototype.editNodeMode=function(){return console.warn("Deprecated: Please use editNode instead of editNodeMode."),this.manipulation.editNode.apply(this.manipulation,arguments)},vS.prototype.addEdgeMode=function(){return this.manipulation.addEdgeMode.apply(this.manipulation,arguments)},vS.prototype.editEdgeMode=function(){return this.manipulation.editEdgeMode.apply(this.manipulation,arguments)},vS.prototype.deleteSelected=function(){return this.manipulation.deleteSelected.apply(this.manipulation,arguments)},vS.prototype.getPositions=function(){return this.nodesHandler.getPositions.apply(this.nodesHandler,arguments)},vS.prototype.getPosition=function(){return this.nodesHandler.getPosition.apply(this.nodesHandler,arguments)},vS.prototype.storePositions=function(){return this.nodesHandler.storePositions.apply(this.nodesHandler,arguments)},vS.prototype.moveNode=function(){return this.nodesHandler.moveNode.apply(this.nodesHandler,arguments)},vS.prototype.getBoundingBox=function(){return this.nodesHandler.getBoundingBox.apply(this.nodesHandler,arguments)},vS.prototype.getConnectedNodes=function(t){return void 0!==this.body.nodes[t]?this.nodesHandler.getConnectedNodes.apply(this.nodesHandler,arguments):this.edgesHandler.getConnectedNodes.apply(this.edgesHandler,arguments)},vS.prototype.getConnectedEdges=function(){return this.nodesHandler.getConnectedEdges.apply(this.nodesHandler,arguments)},vS.prototype.startSimulation=function(){return this.physics.startSimulation.apply(this.physics,arguments)},vS.prototype.stopSimulation=function(){return this.physics.stopSimulation.apply(this.physics,arguments)},vS.prototype.stabilize=function(){return this.physics.stabilize.apply(this.physics,arguments)},vS.prototype.getSelection=function(){return this.selectionHandler.getSelection.apply(this.selectionHandler,arguments)},vS.prototype.setSelection=function(){return this.selectionHandler.setSelection.apply(this.selectionHandler,arguments)},vS.prototype.getSelectedNodes=function(){return this.selectionHandler.getSelectedNodeIds.apply(this.selectionHandler,arguments)},vS.prototype.getSelectedEdges=function(){return this.selectionHandler.getSelectedEdgeIds.apply(this.selectionHandler,arguments)},vS.prototype.getNodeAt=function(){const t=this.selectionHandler.getNodeAt.apply(this.selectionHandler,arguments);return void 0!==t&&void 0!==t.id?t.id:t},vS.prototype.getEdgeAt=function(){const t=this.selectionHandler.getEdgeAt.apply(this.selectionHandler,arguments);return void 0!==t&&void 0!==t.id?t.id:t},vS.prototype.selectNodes=function(){return this.selectionHandler.selectNodes.apply(this.selectionHandler,arguments)},vS.prototype.selectEdges=function(){return this.selectionHandler.selectEdges.apply(this.selectionHandler,arguments)},vS.prototype.unselectAll=function(){this.selectionHandler.unselectAll.apply(this.selectionHandler,arguments),this.selectionHandler.commitWithoutEmitting.apply(this.selectionHandler),this.redraw()},vS.prototype.redraw=function(){return this.renderer.redraw.apply(this.renderer,arguments)},vS.prototype.getScale=function(){return this.view.getScale.apply(this.view,arguments)},vS.prototype.getViewPosition=function(){return this.view.getViewPosition.apply(this.view,arguments)},vS.prototype.fit=function(){return this.view.fit.apply(this.view,arguments)},vS.prototype.moveTo=function(){return this.view.moveTo.apply(this.view,arguments)},vS.prototype.focus=function(){return this.view.focus.apply(this.view,arguments)},vS.prototype.releaseNode=function(){return this.view.releaseNode.apply(this.view,arguments)},vS.prototype.getOptionsFromConfigurator=function(){let t={};return this.configurator&&(t=this.configurator.getOptions.apply(this.configurator)),t};var _S=Object.freeze({__proto__:null,cleanupElements:bS,drawBar:function(t,e,i,s,a,o,n,r){if(0!=s){s<0&&(e-=s*=-1);const l=wS("rect",o,n);l.setAttributeNS(null,"x",t-.5*i),l.setAttributeNS(null,"y",e),l.setAttributeNS(null,"width",i),l.setAttributeNS(null,"height",s),l.setAttributeNS(null,"class",a),r&&l.setAttributeNS(null,"style",r)}},drawPoint:function(t,e,i,s,a,o){let n;if("circle"==i.style?(n=wS("circle",s,a),n.setAttributeNS(null,"cx",t),n.setAttributeNS(null,"cy",e),n.setAttributeNS(null,"r",.5*i.size)):(n=wS("rect",s,a),n.setAttributeNS(null,"x",t-.5*i.size),n.setAttributeNS(null,"y",e-.5*i.size),n.setAttributeNS(null,"width",i.size),n.setAttributeNS(null,"height",i.size)),void 0!==i.styles&&n.setAttributeNS(null,"style",i.styles),n.setAttributeNS(null,"class",i.className+" vis-point"),o){const i=wS("text",s,a);o.xOffset&&(t+=o.xOffset),o.yOffset&&(e+=o.yOffset),o.content&&(i.textContent=o.content),o.className&&i.setAttributeNS(null,"class",o.className+" vis-label"),i.setAttributeNS(null,"x",t),i.setAttributeNS(null,"y",e)}return n},getDOMElement:function(t,e,i,s){let a;return Object.prototype.hasOwnProperty.call(e,t)?e[t].redundant.length>0?(a=e[t].redundant[0],e[t].redundant.shift()):(a=document.createElement(t),void 0!==s?i.insertBefore(a,s):i.appendChild(a)):(a=document.createElement(t),e[t]={used:[],redundant:[]},void 0!==s?i.insertBefore(a,s):i.appendChild(a)),e[t].used.push(a),a},getSVGElement:wS,prepareElements:yS,resetElements:function(t){yS(t),bS(t),yS(t)}});const xS={Images:Zv,dotparser:Gv,gephiParser:Kv,allOptions:mS,convertDot:Yv,convertGephi:Xv};var CS=Object.freeze({__proto__:null,DOMutil:_S,DataSet:RC,DataView:PC,Hammer:mv,Network:vS,Queue:FC,data:zC,keycharm:Rk,network:xS,util:yv});e.DOMutil=_S,e.DataSet=RC,e.DataView=PC,e.Hammer=mv,e.Network=vS,e.Queue=FC,e.data=zC,e.default=CS,e.keycharm=Rk,e.network=xS,e.util=yv,Object.defineProperty(e,"__esModule",{value:!0})}))}).call(this,i("a282"))}}]); //# sourceMappingURL=chunk-b25e7750.8f54695a9a1638c99072.js.map