!function(e){var t={};function n(r){if(t[r])return t[r].exports;var s=t[r]={i:r,l:!1,exports:{}};return e[r].call(s.exports,s,s.exports,n),s.l=!0,s.exports}n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var s in e)n.d(r,s,function(t){return e[t]}.bind(null,s));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=0)}([function(e,t,n){"use strict";n.r(t);n(1);const{createElement:r,render:s,useState:i,useEffect:o,Fragment:l}=wp.element,{select:u,dispatch:a}=wp.data,d=e=>{const[t,n]=i(!0),[s,a]=i({});return o(()=>{n(!0),fetch(window.server_stats_widget.api+"/server_stats",{method:"post",body:JSON.stringify({token:u("vibebp").getToken()})}).then(e=>e.json()).then(e=>{n(!1),e.status&&a(e.data)})},[]),r("div",{className:"server_stats_widget"},t?r("div",null,r("div",{className:"widget_loader"},r("div",null),r("div",null),r("div",null),r("div",null))):r(l,null,s&&Object.keys(s)&&Object.keys(s).length?r("div",{className:"server_stats_data"},Object.keys(s).map(e=>r("div",null,r("div",null,window.server_stats_widget.translations[e]),r("div",null,s[e])))):""))};document.addEventListener("server_stats_widget",e=>{document.querySelectorAll(".server_stats_widget").forEach(t=>{s(r(d,{settings:e.detail.widget.options}),t)})})},function(e,t,n){}]);