System.register(["./index-legacy-BGUFxny_.js"],function(e,n){"use strict";var t,r,a,s,c,g,i,l,o,u,d,m,h,p,v,$,f,I,b,w;return{setters:[e=>{t=e.D,r=e.aK,a=e.c0,s=e.r,c=e.o,g=e.B,i=e.b9,l=e.bq,o=e.bV,u=e.N,d=e.ah,m=e.R,h=e.aI,p=e.Q,v=e.I,$=e.aw,f=e.K,I=e.cx,b=e.dE,w=e.bb}],execute:function(){const n=e("Shower",{string:e=>t(a,{get children(){return e.content}}),image:e=>t(r,{get src(){return e.content}})}),x=()=>{const e=c();s.info(e("manage.messenger-tips"));const[r,x]=g(""),[y,S]=i(()=>l.post("/admin/message/get")),[k,C]=i(()=>l.post("/admin/message/send",{message:r()})),[K,j]=o([]),q=async()=>{const e=await S();I(e,e=>{j(b(n=>n.push(e)))})},z=async()=>{const e=await C();w(e)},B=setInterval(q,1e3);return u(()=>clearInterval(B)),t(d,{spacing:"$2",h:"$full",alignItems:"start",get children(){return[t(d,{w:"$full",spacing:"$2",alignItems:"start",p:"$2",rounded:"$lg",border:"1px solid var(--hope-colors-neutral6)",get children(){return[t(a,{size:"xl",get children(){return e("manage.received_msgs")}}),t(m,{each:K,children:e=>t(h,p({get component(){return n[e.type]}},e))})]}}),t(v,{w:"$full",get value(){return r()},onInput:e=>x(e.currentTarget.value)}),t($,{spacing:"$2",get children(){return[t(f,{colorScheme:"accent",get loading(){return y()},onClick:q,get children(){return e("manage.receive")}}),t(f,{get loading(){return k()},onClick:z,get children(){return e("manage.send")}})]}})]}})};e({Messenger:x,default:x})}}});
