/**
 * Minified by jsDelivr using Terser v5.37.0.
 * Original file: /npm/@jspreadsheet/orgchart@1.0.1/dist/index.js
 *
 * Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files
 */
if(!organogram&&"function"==typeof require)var organogram=require("@jsuites/organogram");!function(e,n){"object"==typeof exports&&"undefined"!=typeof module?module.exports=n():"function"==typeof define&&define.amd?define(n):e.orgchart=n()}(this,(function(){return function(e){let n={},o=null,t=null,r=null;const i=function(){this.resetSelection(),e.worksheets[0].table.style.display="none",o.style.display=""},l=function(){e.worksheets[0].table.style.display="",o.style.display="none"};return n.init=function(e){if(o||"organogram"!==e.options.role)"roles"===e.options.role&&(r=e.options.data,t&&t.setRoles(r));else{o=document.createElement("div"),e.content.appendChild(o);let n={width:800,height:600,data:e.options.data,vertical:!1};r&&(n.roles=r),o.style.borderTop="1px solid #ccc",o.style.display="none",t=organogram(o,n)}},n.onevent=function(e){t&&("onafterchanges"===e?t.refresh():"onbeforeselection"===e&&l())},n.toolbar=function(n){let t=e.worksheets[0];return n.items.push({content:"group",onclick:function(n,o,r){e.openWorksheet(0),"group"===r.children[0].innerText?(i.call(t),r.children[0].innerText="group_off"):(l.call(t),r.children[0].innerText="group")},tooltip:"Toggle organogram",updateState:function(e,n,t){o&&(o.offsetHeight?t.children[0].innerText="group_off":t.children[0].innerText="group")}}),n},n}}));
//# sourceMappingURL=/sm/0678263009d0f6984bb73f882739f9de212b36509c4ec7936c5a7d874bd7b7bc.map