(window["webpackJsonptrueChart"]=window["webpackJsonptrueChart"]||[]).push([[34],{695:function(t,e,n){"use strict";n.r(e);n.d(e,"checkIds",(function(){return checkIds}));n.d(e,"checkStacks",(function(){return checkStacks}));n.d(e,"runIntegrationTests",(function(){return runIntegrationTests}));var r=n(1);var i=n(9);var a=n(766);var c=n(158);function checkIds(t){var e=[t.LayoutDefinition.rootCell.guid];var n=[t.LayoutDefinition.rootCell.id];Object(i["e"])(t.LayoutDefinition.rootCell,"instanceOf",[],"Grid").forEach((function(t){t.cellContainers.forEach((function(t){t.cells.forEach((function(t){e.push(t.guid);n.push(t.id)}))}))}));var c=r["b"].DataObjects.CommentRepo.getLoadedCommentsByExtension(t.getId())||[];for(var o=0,u=c;o<u.length;o++){var s=u[o];if(!s.currContent){continue}for(var f=0,l=s.currContent.grid;f<l.length;f++){var d=l[f];for(var h=0,v=d;h<v.length;h++){var g=v[h];n.push(g.created_in_chart)}}}var k=n.filter((function(t,e){return n.indexOf(t,e+1)!==-1}));if(k.length){window.console.warn({duplicateIds:k,allIds:n});a["a"].warning("IDs are not unique",t.getTitle(),{preventDuplicates:true,timeOut:2e3})}var p=n.filter((function(t,n){return e.indexOf(t,n+1)!==-1}));if(p.length){window.console.warn({duplicateGuids:p,allGuids:e});a["a"].warning("GUIDs are not unique",t.getTitle(),{preventDuplicates:true,timeOut:2e3})}}function checkStacks(t){var e=["TimeChart","StructureChart"];var isChart=function(t){return e.indexOf(t.content.instanceOf)!==-1};Object(c["j"])(t.LayoutDefinition.rootCell,(function(e){if(isChart(e)){var n=[];if(e.content.doStack){for(var r=0,i=e.content.measures;r<i.length;r++){var c=i[r];if(c.stackOrder>=0){n.push(c.stackOrder)}}n.sort((function(t,e){return t-e}));for(var o=0;o<n.length;o++){if(n[o]!==o){a["a"].warning("Stack is in incorrect order",t.getTitle(),{preventDuplicates:true,timeOut:2e3});break}}}}}))}function runIntegrationTests(t){if(true&&!t){return}var e=r["b"].DataObjects.DocumentDO.getAllExtensions();for(var n=0,i=e;n<i.length;n++){var a=i[n];checkIds(a);checkStacks(a)}}},766:function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var r=n(457);r["a"].initialize({defaultTitle:"TRUECHART"});var i=r["a"]}}]);