phanpy/assets/compose-sBS7hMqP.js
Lim Chee Aun 296ef9214b Imported from 2023.12.31.8aa0542.tar.gz.
SHA256:17ea8854a3504752a8ae4540ecb09e62f6f8aa260221d3619fda46f66b2ec43f
2024-01-06 12:29:42 +00:00

3 lines
987 B
JavaScript

import{W as u,G as p}from"./useTitle-zvzl1Hla.js";import{h as w,p as f,a as e,G as m}from"./vendor--8C7Txey.js";window.opener&&(console=window.opener.console);function S(){var s,a;const[t,i]=w("default"),{editStatus:n,replyToStatus:o,draftStatus:d}=window.__COMPOSE__||{};return u(n?"Editing source status":o?`Replying to @${((s=o.account)==null?void 0:s.acct)||((a=o.account)==null?void 0:a.username)}`:"Compose"),f(()=>{if(t==="closed"){try{window.opener.focus()}catch{}window.close()}},[t]),t==="closed"?e("div",{class:"box",children:[e("p",{children:"You may close this page now."}),e("p",{children:e("button",{onClick:()=>{window.close()},children:"Close window"})})]}):e(p,{editStatus:n,replyToStatus:o,draftStatus:d,standalone:!0,hasOpener:window.opener,onClose:c=>{const{newStatus:r,fn:l=()=>{}}=c||{};try{r&&window.opener.__STATES__.reloadStatusPage++,l(),i("closed")}catch{}}})}m(e(S,{}),document.getElementById("app-standalone"));
//# sourceMappingURL=compose-sBS7hMqP.js.map