PageSourceSearch

https://doloplanet.com/_next/static/chunks/1881-fd55a45912fc27ac.js?dpl=dpl_5tk5aDwd5CjCujgSTfYvw2pVeKcp

js doloplanet.com collected 2026-10-02 00:48:58 UTC 64,655 bytes, 1 lines download raw bytes

1!function(){try{var t="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new t.Error).stack;n&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[n]="7bc99b9c-1332-4674-9a43-c27d777d4605",t._sentryDebugIdIdentifier="sentry-dbid-7bc99b9c-1332-4674-9a43-c27d777d4605")}catch(t){}}();"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1881],{148:(t,n,a)=>{a.d(n,{Ay:()=>h,CD:()=>v,DH:()=>m,MB:()=>g,Rs:()=>s,YX:()=>o,aC:()=>e,gG:()=>y,iw:()=>d,kV:()=>p,oE:()=>l,oO:()=>u,pl:()=>c,sQ:()=>i,sk:()=>r,vT:()=>f});let e=30,o=500,c=500;function r(t){return t>=3?t:t+1}function i(t){return t<=0?0:t-1}function s(t){return t}function u(t){let n=[];for(let a=0;a<t;a+=1){let e=t-a;n.push({index:a,top:-(30*e),scale:1-.03*e,opacity:.5-(e-1)*.1})}return n}function l(t){let n=o-t.length;return{label:"".concat(n,"/").concat(o),overLimit:n<0}}function d(t,n){return"".concat(t.length,"/").concat(n)}function p(t){return t.trim().length>0?"continue":"skip"}function f(t){var n;let a=null!==(n=null==t?void 0:t.onboarding)&&void 0!==n?n:{},e=(t,n)=>{let e=[];for(let o=1;o<=n;o+=1){let n=a["".concat(t).concat(o)];"string"==typeof n&&n.length>0&&e.push(n)}return e};return{prologueVideos:e("prologue",2),waitingVideos:e("waiting",3)}}function v(t,n){return 0===t.waitingVideos.length?null:t.waitingVideos[n%t.waitingVideos.length]}function h(t,n){var a;return null!==(a=t.prologueVideos[n])&&void 0!==a?a:null}function y(t){var n,a;return null!==(a=null!==(n=t.description)&&void 0!==n?n:t.nickname)&&void 0!==a?a:""}function m(t){var n;return null!==(n=t.nickname)&&void 0!==n?n:"Unknown"}function g(t){let n={};return null!==t.worry&&t.worry.length>0&&(n.worry=t.worry),t.userName.length>0&&(n.userNickname=t.userName),t.appearance.length>0&&(n.userDescription=t.appearance),n}},20603:(t,n,a)=>{a.d(n,{H:()=>e});let e="https://api.doloplanet.com"},21030:(t,n,a)=>{function e(t){var n,a;return null!==(a=null!==(n=t.characterName)&&void 0!==n?n:t.worldCharacterName)&&void 0!==a?a:"Unknown"}function o(t){return"LOCKED"===t.state?"locked":"COMPLETED"===t.state?"completed":"playable"}function c(t){return{active:t.filter(t=>"COMPLETED"!==t.state),completed:t.filter(t=>"COMPLETED"===t.state)}}function r(t){var n;return"locked"===o(t)&&!!t.conditions&&!((n=t.conditions).hasRequiredParticipants&&n.hasRequiredLikeability&&n.hasExactParticipantMatch&&n.hasCompletedPrior&&n.hasNotBeenPlayed&&!n.isCorrectLocation)}a.d(n,{DC:()=>l,G_:()=>f,Gr:()=>y,OW:()=>c,QG:()=>i,Ri:()=>r,SR:()=>b,UR:()=>H,Wk:()=>e,Z2:()=>g,b0:()=>u,bs:()=>P,ds:()=>p,h6:()=>m,jC:()=>o,k5:()=>w,p3:()=>s,pS:()=>S,qR:()=>h,ww:()=>d,xx:()=>v});function i(t){var n;let a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},o=null===(n=a.interactive)||void 0===n||n,c=t.conditions;if(!c)return[];let r=[];if(t.participants.length>0||!c.hasExactParticipantMatch){let n,a,i=t.participants.map(e).join(", "),s=!c.hasRequiredParticipants,u=!c.hasExactParticipantMatch,l=c.extraParticipants.map(t=>t.name).join(", "),d=c.missingParticipants.map(t=>t.name).join(", ");s&&u&&c.extraParticipants.length>0?(n="requiredAndExclude",a={exclude:l,include:i}):s&&u?(n="requiredAndExcludeUnknown",a={include:d}):u&&c.extraParticipants.length>0?(n="onlyExclude",a={names:l}):u?(n="excludeExtra",a={}):s?(n="required",a={names:d}):(n="required",a={names:i});let p=c.hasRequiredParticipants&&c.hasExactParticipantMatch;r.push({key:"participants",icon:"participants",messageKey:n,values:a,isMet:p,isPrerequisite:!1,action:p||!o?null:{type:"participants",participants:t.participants}})}for(let n of t.participants){let t=n.requiredLikeability;if(null===t||t<=0)continue;let a=!c.insufficientLikeabilityParticipants.some(t=>t.id===n.worldAiCharacterId),i=!c.hasRequiredParticipants||c.missingParticipants.some(t=>t.id===n.worldAiCharacterId);r.push({key:"likeability:".concat(n.worldAiCharacterId),icon:"likeability",messageKey:"likeability",values:{name:e(n),required:String(t)},isMet:a,isPrerequisite:i,action:a||i||!o?null:{type:"likeability",participant:n}})}return null!==t.priorEpisodeId&&null!==c.priorEpisodeTitle&&r.push({key:"prior",icon:"prior",messageKey:"prior",values:{title:c.priorEpisodeTitle},isMet:c.hasCompletedPrior,isPrerequisite:!1,action:c.hasCompletedPrior||!o?null:{type:"priorEpisode",episodeId:t.priorEpisodeId}}),r.map((t,n)=>
1({item:t,index:n,priority:t.isMet?3:t.isPrerequisite||null===t.action?t.isPrerequisite?2:3:1})).filter(t=>t.priority<3).sort((t,n)=>t.priority-n.priority||t.index-n.index).map(t=>t.item)}function s(t){let n=[],a=!1;for(let e of t)"COMPLETED"!==e.state||a||(n.push({kind:"divider"}),a=!0),n.push({kind:"episode",episode:e});return n}let u="8d5714df-236d-4633-b67f-caba776bab28";function l(t,n){if(null===n)return null;let a=t.find(t=>t.id===n&&"PLAYABLE"===t.state);if(a)return{kind:"unlocked",episode:a};let e=t.filter(t=>"LOCKED"===t.state&&void 0!==t.conditions);if(0===e.length)return null;let o=e.find(t=>t.id===n);if(o)return{kind:"conditions",episode:o};let c=null,r=999;for(let t of e){let n=t.conditions;if(!n)continue;let a=function(t){let n=0;return!t.hasRequiredParticipants&&n++,!t.hasRequiredLikeability&&n++,!t.hasExactParticipantMatch&&n++,!t.isCorrectLocation&&n++,n}(n);a<r&&(r=a,c=t)}return c?{kind:"conditions",episode:c}:null}let d=30,p=200,f=200,v=10;function h(t){return""===t.title.trim()?"nameRequired":""===t.seed.trim()?"storyRequired":null===t.locationId?"locationRequired":0===t.characterIds.length?"charactersMinRequired":t.characterIds.length>v?"charactersMaxExceeded":null}function y(t,n,a){let e=t=>null!==n&&t.creatorUserId===n?0:null!==t.creatorUserId?1:2;return t.filter(t=>t.id!==a).map((t,n)=>({episode:t,index:n,rank:e(t)})).sort((t,n)=>t.rank-n.rank||t.index-n.index).map(t=>t.episode)}function m(t){let n=Number.parseInt(t,10);return Number.isNaN(n)||n<1||n>100?"invalid":n}function g(t){return"/chat/".concat(t,"/episode/new")}function S(t,n){return"/chat/".concat(t,"/episode/").concat(n,"/edit")}function H(t,n){return"/chat/".concat(t,"/episode/").concat(n)}function w(t){return Object.fromEntries(Object.entries(t).filter(t=>{let[,n]=t;return null!=n}))}function P(t){let{isExperienced:n,alreadyShown:a}=t;return!n&&!a}function b(t){return(null==t?void 0:t.state)==="PLAYABLE"}},21367:(t,n,a)=>{a.d(n,{hDB:()=>g,aGI:()=>nR,Pbe:()=>nA,Xrf:()=>oe,Mrp:()=>ty,BGX:()=>tr,NIl:()=>eI,_5p:()=>eu,UBs:()=>aO,VN6:()=>w,fmo:()=>tz,gO$:()=>aj,Vui:()=>nb,GxI:()=>aV,hZP:()=>tq,KHC:()=>t3,P59:()=>aX,l9_:()=>am,cc2:()=>n7,lfc:()=>x,Urm:()=>z,Wft:()=>q,DmH:()=>oo,z7C:()=>an,gur:()=>aW,o9W:()=>nV,Sai:()=>nW,KnE:()=>nm,D2f:()=>tM,Gen:()=>tt,f3R:()=>j,LNh:()=>np,mdm:()=>eY,wFP:()=>eM,O6_:()=>aw,gVp:()=>nc,Tpy:()=>e$,cDF:()=>a_,n2r:()=>n1,_8D:()=>tp,AdJ:()=>nw,X0W:()=>eO,VwV:()=>nz,PCM:()=>aJ,NwI:()=>eo,lnw:()=>ev,Hii:()=>eP,hq9:()=>e9,woF:()=>aY,QD2:()=>nk,hvY:()=>nK,va9:()=>n$,PHl:()=>nS,YV7:()=>t1,aiE:()=>tD,VJJ:()=>t9,wt3:()=>nv,ngl:()=>eA,hw5:()=>ab,bmZ:()=>ni,QCO:()=>n3,VI5:()=>tv,r4$:()=>t2,e$S:()=>tm,IbI:()=>nC,EZm:()=>aN,IRY:()=>nF,m0K:()=>ey,ixb:()=>ew,whY:()=>G,yrv:()=>ex,f44:()=>ap,eQV:()=>X,XVT:()=>tI,aKP:()=>nx,LWG:()=>tC,Zqd:()=>tR,_Yx:()=>tO,_K$:()=>nN,Ood:()=>ez,xOv:()=>ao,q12:()=>ae,ca0:()=>ai,DBw:()=>au,s8v:()=>nt,YJG:()=>az,sjK:()=>aC,Rjw:()=>ed,bw$:()=>nP,X6u:()=>ny,vZx:()=>Y,eN7:()=>aq,Blc:()=>tQ,tFh:()=>t$,VRg:()=>aM,wqS:()=>tB,sG_:()=>tZ,VHj:()=>tc,APM:()=>Z,Edv:()=>t7,zqR:()=>$,KdB:()=>nd,hYT:()=>eg,vBY:()=>eW,FVX:()=>n5,BfH:()=>eG,$Vu:()=>eB,wkD:()=>aa,gLN:()=>at,yKg:()=>aG,jK9:()=>a2,VXX:()=>a4,ake:()=>a3,Bqo:()=>a0,aPi:()=>aK,Vb:()=>ah,UW:()=>oc,hp4:()=>eD,_3r:()=>eR,u0P:()=>a6,i3U:()=>tE,Cke:()=>nE,yHZ:()=>nI,G96:()=>eq,Ijs:()=>ej,dSO:()=>aH,ggx:()=>ak,BK$:()=>no,y$4:()=>aL,aOr:()=>tg,S3r:()=>aT,nIB:()=>ax,_O9:()=>aE,anw:()=>aI,$1w:()=>eX,zOv:()=>a$,YwR:()=>eZ,sVS:()=>tu,KJv:()=>nq,Fas:()=>tb,h2o:()=>n0,Rgm:()=>td,Ua7:()=>ag,TFx:()=>a9,r63:()=>a5,ftL:()=>eS,n6y:()=>tY,Nn4:()=>tJ,x4P:()=>tN,kzw:()=>tT,IJP:()=>th,ErM:()=>t6,Xam:()=>V,l0p:()=>na,Ggb:()=>ne,htp:()=>tl,aAe:()=>nM,qCA:()=>nJ,hfI:()=>av,b4N:()=>eQ,XzP:()=>aF,$gB:()=>aB,jHy:()=>eE,nS8:()=>eU,yQ6:()=>a7,jlJ:()=>ay,WgF:()=>n6,i7J:()=>nn,sd6:()=>aU,Ysl:()=>tG,LTh:()=>en,yQB:()=>aS,mfP:()=>a1,FPb:()=>ea,cMM:()=>es,l06:()=>ep,ULe:()=>ef,Wq9:()=>ei,Sk$:()=>em,K7f:()=>ec,Jbx:()=>er,Cu_:()=>ee,aZH:()=>aZ,Xp1:()=>nQ,WJ2:()=>aR,YE6:()=>tk,B0D:()=>nH,obX:()=>nh,jMU:()=>nl,XWN:()=>nB,lzi:()=>nX,YN4:()=>eL,PAy:()=>eN,OgQ:()=>nZ,QQp:()=>eT,mbX:()=>ac,$Vl:()=>eC,EDV:()=>ek,j8w:()=>et,wCu:()=>Q,nqg:()=>tL,xA2:()=>e7,ZiY:()=>e1,wxV:()=>eK,eAo:()=>t4,qu5:()=>as,uRV:()=>nD,w0j:()=>ar,UyO:()=>ti,s_V:()=>el,TMC:()=>n8,RG7:()=>tF,FCz:()=>
1ot,gXc:()=>af,Irp:()=>tX,pPn:()=>K,_cI:()=>tV,hf7:()=>tj,jy4:()=>eJ,y_6:()=>tP,hx1:()=>al,D_I:()=>tx,hor:()=>nU,pG8:()=>tA,SjZ:()=>e2,B8B:()=>a8,xr8:()=>to,a0V:()=>e8,T2F:()=>e5,EyT:()=>e4,PZd:()=>e6,y9e:()=>oa,kKs:()=>on,iqS:()=>eF,A$k:()=>nT,EsE:()=>ad,koK:()=>t8,dmW:()=>eV,w3o:()=>aD,JrH:()=>e0,ftq:()=>tn,Rj_:()=>te,rOo:()=>W,WAi:()=>ta,cC$:()=>nO,_XG:()=>tU,lK8:()=>aQ,zNi:()=>t_,dGP:()=>nG,PRU:()=>nY,$Yi:()=>ng,Iww:()=>t0,X5S:()=>tw,U36:()=>ts,I4Q:()=>tH,FeC:()=>t5,yXH:()=>nf,sPp:()=>e_,vIx:()=>aP,VYJ:()=>nr,JCY:()=>tS,ART:()=>n2,X_A:()=>tf,oSv:()=>tW,auD:()=>tK,Wnr:()=>nj,Shs:()=>eh,GKQ:()=>eb,RfH:()=>eH,$SE:()=>ns,ODb:()=>n9,R1m:()=>nL,DHE:()=>aA,Bhh:()=>nu});var e=a(40937),o=a(88622),c=a(20603),r=a(21030),i=a(79481),s=a(67741),u=a(86714),l=a(74598),d=a(80920),p=a(96978),f=a(83635),v=a(148),h=a(64524),y=a(85975),m=a(56148);class g extends Error{constructor(t,n,a){super(n),this.status=t,this.code=a,this.name="ApiError"}}function S(t){var n,a;return null!==(a=null===(n=H(t))||void 0===n?void 0:n.code)&&void 0!==a?a:void 0}function H(t){try{var n;let a=JSON.parse(t);return null!==(n=a.error)&&void 0!==n?n:void 0}catch(t){return}}function w(t){var n;if(t instanceof g)return(null===(n=H(t.message.slice(t.message.indexOf("{"))))||void 0===n?void 0:n.message)||void 0}function P(){var t;if("undefined"==typeof document)return null;let n=document.documentElement;return null!==(t=(0,l.re)(n.dataset.appLocale))&&void 0!==t?t:(0,l.re)(n.lang)}let b=null,O=null,T=!1,E=0,I=0,U=0,N=3,R=null;function k(){let t=(0,m.wn)();o.o("session_read",{emptyReads:E,rescuedByRetry:I,rescuedByMirror:U,mirrorHeld:t.held,mirrorSignedOut:t.signedOut,lastProbe:R,online:"undefined"==typeof navigator?null:navigator.onLine})}async function L(){if(!(N<=0)&&"undefined"!=typeof fetch){N-=1;try{let t=await fetch("/api/auth/session",{credentials:"same-origin"}),n=await t.text();R="".concat(t.status,":").concat(n.length)}catch(t){R="throw:".concat(t instanceof Error?t.name:"unknown")}}}function C(){b=null}async function J(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(!1===t.allowMirror){var n;let a=await _(t);return(null==a?void 0:null===(n=a.backendAuth)||void 0===n?void 0:n.token)&&(b={session:a,at:Date.now()}),a}return b&&Date.now()-b.at<3e5?b.session:O||(T||"undefined"==typeof BroadcastChannel||(T=!0,new BroadcastChannel("next-auth").addEventListener("message",C)),O=_(t).then(t=>{var n;return(null==t?void 0:null===(n=t.backendAuth)||void 0===n?void 0:n.token)&&(b={session:t,at:Date.now()}),t}).finally(()=>{O=null}))}async function _(){var t,n,a;let o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},c=await (0,e.Ht)({broadcast:!1});if(null==c?void 0:null===(t=c.backendAuth)||void 0===t?void 0:t.token)return c;E+=1,await new Promise(t=>setTimeout(t,250));let r=await (0,e.Ht)({broadcast:!1});if(null==r?void 0:null===(n=r.backendAuth)||void 0===n?void 0:n.token)return I+=1,k(),r;let i=!1===o.allowMirror?null:(0,m.El)();return(null==i?void 0:null===(a=i.backendAuth)||void 0===a?void 0:a.token)?(U+=1,k(),i):(await L(),k(),r)}async function A(t,n){var a,e;let o=await J(n);if(!(null==o?void 0:null===(a=o.backendAuth)||void 0===a?void 0:a.token))throw Error("No authentication token available");let c={Authorization:"Bearer ".concat(o.backendAuth.token)},r=P();return r&&(c["X-Locale"]=r),t.headers&&Object.assign(c,t.headers),!["POST","PUT","PATCH"].includes((null===(e=t.method)||void 0===e?void 0:e.toUpperCase())||"GET")||t.body instanceof FormData||(c["Content-Type"]="application/json"),c}async function D(t,n,a){let e=await fetch(t,{...n,headers:await a()});if(401!==e.status)return e;C();let o=await fetch(t,{...n,headers:await a({allowMirror:!1})});return 401===o.status&&(0,h.kM)(),o}async function x(t){let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};try{let a=await D(t,n,t=>A(n,t));if(!a.ok){let t=await a.text();throw console.error("Client fetch - Error response:",t),new g(a.status,"API request failed: ".concat(a.status," ").concat(a.statusText,". ").concat(t),S(t))}return(await a.json()).data}catch(t){throw console.error("Client fetch - Caught error:",t),t}}async function M(t){let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=await D(t,n,t=>A(n,t));if(!a.ok){let t=await a.text();throw console.error("Client fetch - Error response:",t),Error("API request failed: ".concat(a.status," ").concat(a.statusText,". ").concat(t))}return await a.json()}async function q(t){let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=await D(t,n,t=>A(n,t)),e=await a.text(),o=null;try{o=JSON.parse(e)}catch(t){o=null}if(o&&(void 0!==o.data||o.error))return o;throw Error("API request failed: ".concat(a.status," ").concat(a.statusText,". ").concat(e))}async function z(t){var n,a,e;let o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},c=await D(t,o,t=>A(o,t));if(!c.ok){let t=null!==(n=S(await c.text()))&&void 0!==n?n:"HTTP_".concat(c.status);throw new g(c.status,t,t)}let r=null!==(a=c.headers.get("content-disposition"))&&void 0!==a?a:"",i=/filename="([^"]+)"/.exec(r);return{blob:await c.blob(),filename:null!==(e=null==i?void 0:i[1])&&void 0!==e?e:null}}let j=()=>async t=>x(t);function F(t){var n,a;return t?{status:(0,d.Zt)(t.status),firstStoreEnteredAt:t.firstStoreEnteredAt,activeUntil:t.activeUntil,noticeUntil:t.noticeUntil,extensionUsed:null!==(n=t.extensionUsed)&&void 0!==n&&n,extensionGrantedAt:t.extensionGrantedAt,serverNow:null!==(a=t.serverNow)&&void 0!==a?a:0}:null}function B(t){var n,a;return{id:t.id,name:t.displayName,stone:t.stone,baseStone:null!==(n=t.baseStone)&&void 0!==n?n:t.stone,bonusStone:null!==(a=t.bonusStone)&&void 0!==a?a:0,price:t.price,currency:t.currency,bonus:t.bonus,imageUrl:t.imageUrl}}async function V(t){var n,a,e,o,r;let s=new URLSearchParams({is_web:(0,i.fe)()?"true":"false"});(null==t?void 0:t.includeVip)&&s.set("include_vip","true"),(null==t?void 0:t.locale)&&s.set("locale",(0,u.e)(t.locale)),(null==t?void 0:t.firstPurchasePolicy)&&s.set("first_purchase_policy",t.f
1irstPurchasePolicy);let l=await x("".concat(c.H,"/api/v1/products?").concat(s.toString()));return{packages:(null!==(n=null==l?void 0:l.products)&&void 0!==n?n:[]).map(B),vipTier:null!==(a=null==l?void 0:l.vipTier)&&void 0!==a?a:null,vipHeldTier:null!==(o=null!==(e=null==l?void 0:l.vipHeldTier)&&void 0!==e?e:null==l?void 0:l.vipTier)&&void 0!==o?o:null,stonePromotionActive:null!==(r=null==l?void 0:l.stonePromotionActive)&&void 0!==r&&r,promotion:F(null==l?void 0:l.firstPurchasePromotion),specialOffer:(0,p.tf)(null==l?void 0:l.specialOffer)}}async function G(t){await x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/multi-recommendation/dismiss"),{method:"POST"}).catch(t=>{console.error("Failed to dismiss multi recommendation:",t)})}async function K(t){await x("".concat(c.H,"/api/v1/saju/profile"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(t)})}async function X(){let t=await x("".concat(c.H,"/api/v1/products/first-purchase/enter"),{method:"POST"});return F(null==t?void 0:t.firstPurchasePromotion)}async function W(){try{let t=await x("".concat(c.H,"/api/v1/products/special-offer/trigger"),{method:"POST"});return(0,p.tf)(null==t?void 0:t.specialOffer)}catch(t){return console.error("Failed to trigger special offer:",t),null}}async function Y(t){let n=new URLSearchParams({locale:t.locale,location:t.location});return x("".concat(c.H,"/api/v1/ai-characters/curations?").concat(n.toString()))}async function $(t){let n=new URLSearchParams({locale:t.locale,location:"combined"});return x("".concat(c.H,"/api/v1/ai-characters/curations?").concat(n.toString()))}async function Z(t){return x("".concat(c.H,"/api/v1/chat/rooms").concat(t?"?type=".concat(t):""))}async function Q(t,n){var a;let e=(null!==(a=null==n?void 0:n.length)&&void 0!==a?a:0)>0,o=await x("".concat(c.H,"/api/v1/chat/rooms?opponentUserId=").concat(encodeURIComponent(t)),{method:"POST",...e?{body:JSON.stringify({subCharacterIds:n})}:{}});return(0,s.$e)(t),o}async function tt(t){return x("".concat(c.H,"/api/v1/chat/rooms"),{method:"POST",body:JSON.stringify({recommendationId:t})})}async function tn(t,n){let a=new URLSearchParams;(null==n?void 0:n.isIntroRequest)!==void 0&&a.set("isIntroRequest",String(n.isIntroRequest)),(null==n?void 0:n.endingChoice)&&a.set("endingChoice",n.endingChoice),(null==n?void 0:n.episodeId)&&a.set("episodeId",n.episodeId),(null==n?void 0:n.paid)&&a.set("paid","true");let e=a.toString();return M(e?"".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/trigger-main-event?").concat(e):"".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/trigger-main-event"),{method:"POST"})}async function ta(t,n,a){let e=new URLSearchParams;(null==a?void 0:a.episodeId)&&e.set("episodeId",a.episodeId),(null==a?void 0:a.paid)&&e.set("paid","true");let o=e.toString();return M(o?"".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/participants/").concat(n,"/trigger-episode?").concat(o):"".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/participants/").concat(n,"/trigger-episode"),{method:"POST"})}async function te(t,n,a){let e=new URLSearchParams;(null==a?void 0:a.episodeId)&&e.set("episodeId",a.episodeId);let o=e.toString();return M(o?"".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/participants/").concat(n,"/trigger-personal-episode?").concat(o):"".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/participants/").concat(n,"/trigger-personal-episode"),{method:"POST"})}async function to(t,n,a){let e=new URLSearchParams({episodeId:a});return x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/participants/").concat(n,"/skip-episode?").concat(e.toString()),{method:"POST"})}async function tc(t){return x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/sub-characters"))}async function tr(t,n){return x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/sub-characters"),{method:"POST",body:JSON.stringify({subCharacterIds:n})})}async function ti(t,n){return x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/sub-characters/").concat(n),{method:"DELETE"})}async function ts(t,n,a){return x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/sub-characters/").concat(n),{method:"PATCH",body:JSON.stringify({relationship:a})})}async function tu(t,n){let a=(null==n?void 0:n.trim())?"?".concat(new 
1URLSearchParams({search:n.trim()})):"";return x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/importable-main-characters").concat(a))}async function tl(t,n){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/public-sub-characters").concat(void 0===n?"":"?contextChatRoomId=".concat(n)))}async function td(t){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/sub-characters/manage"))}async function tp(t,n){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/sub-characters"),{method:"POST",body:JSON.stringify(n)})}async function tf(t,n,a){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/sub-characters/").concat(n),{method:"PUT",body:JSON.stringify(a)})}async function tv(t,n){let a=!(arguments.length>2)||void 0===arguments[2]||arguments[2];return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/sub-characters/").concat(n,"?confirm=").concat(a),{method:"DELETE"})}async function th(t){return x("".concat(c.H,"/api/v1/chat/preferred-generations?chatRoomId=").concat(t))}async function ty(t){return x("".concat(c.H,"/api/v1/chat/generation/").concat(t,"/prefer"),{method:"POST"})}async function tm(t){return x("".concat(c.H,"/api/v1/chat/generation/").concat(t,"/prefer"),{method:"DELETE"})}async function tg(){return x("".concat(c.H,"/api/v1/feed/preferences"))}async function tS(t){return x("".concat(c.H,"/api/v1/feed/preferences"),{method:"PUT",body:JSON.stringify({enableFrequentFeedGeneration:t})})}async function tH(t,n){return x("".concat(c.H,"/api/v1/chat/rooms/").concat(t),{method:"PUT",body:JSON.stringify({title:n})})}async function tw(t,n){return x("".concat(c.H,"/api/v1/chat/rooms/").concat(t),{method:"PUT",body:JSON.stringify({mode:n})})}async function tP(t,n){return x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/mode-transition"),{method:"POST",body:JSON.stringify({messages:n})})}async function tb(){var t;let n=await x("".concat(c.H,"/api/v1/chat/library/presets"));return null!==(t=null==n?void 0:n.presets)&&void 0!==t?t:[]}async function tO(){var t;let n=await x("".concat(c.H,"/api/v1/chat/accessories"));return null!==(t=null==n?void 0:n.accessories)&&void 0!==t?t:[]}async function tT(){var t;let n=await x("".concat(c.H,"/api/v1/chat/places"));return null!==(t=null==n?void 0:n.places)&&void 0!==t?t:[]}async function tE(t){return x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/place"))}async function tI(t,n){return x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/place"),{method:"PUT",body:JSON.stringify({slug:n})})}async function tU(t){return x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/place"),{method:"DELETE"})}async function tN(t){var n;let a=await x("".concat(c.H,"/api/v1/chat/places/").concat(encodeURIComponent(t),"/image-prompts"));return null!==(n=null==a?void 0:a.prompts)&&void 0!==n?n:[]}async function tR(t,n){return x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/place/generate-image"),{method:"POST",body:JSON.stringify({participantId:n.participantId,placeId:n.placeId,promptSlug:n.promptSlug,...n.referenceImageUrl?{referenceImageUrl:n.referenceImageUrl}:{}})})}function tk(t){return(t instanceof Error?t.message:String(t)).includes("INSUFFICIENT_STONES")}async function tL(t,n){return q("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/photo-capture/prepare"),{method:"POST",body:JSON.stringify({startMessageId:n.startMessageId,endMessageId:n.endMessageId,mode:"prompt"})})}async function tC(t,n){return q("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/photo-capture/generate"),{method:"POST",body:JSON.stringify({startMessageId:n.startMessageId,endMessageId:n.endMessageId,scenePrompt:n.scenePrompt,...n.imageModel?{imageModel:n.imageModel}:{}})})}async function tJ(t){let n=await x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/place/gallery"));return(0,y.bW)(n)}async function t_(t){return x("".concat(c.H,"/api/v1/chat/place/gallery/").concat(t),{method:"DELETE"})}async function tA(t,n,a){return x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/participants/").concat(n,"/profile-image"),{method:"PUT",body:JSON.stringify({imageUrl:a})})}async function tD(t){return x("".concat(c.H,"/api/v1/chat/rooms/").concat(t),{method:"DELETE"})}async function tx(t,n){return x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/pin"),{method:n?"PUT":"DELETE"})}async function tM(t,n){return x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/branch"),{method:"POST",body:JSON.stringify({title:n||void 0})})}async function tq(t){return x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/updates"))}async function tz(t){return x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/updates/apply"),{method:"POST",body:JSON.stringify({applyPromptUpdates:!0,addNewParticipants:!0,removeDeletedParticipants:!0})})}async function tj(t){return M("".concat(c.H,"/api/v1/chat/messages"),{method:"POST",body:JSON.stringify(t)})}async function tF(t){return x("".concat(c.H,"/api/v1/chat/messages/chat-hints"),{method:"POST",body:JSON.stringify({chatRoomId:t})})}async function tB(t,n){let a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:100,e=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"OLDER",o=arguments.length>4?arguments[4]:void 0,r=function(t){var n;let a=new URLSearchParams({chatRoomId:t.chatRoomId.toString(),size:t.size.toString(),direction:t.direction});
1t.cursor&&a.append("cursor",t.cursor.toString());let e=[...new Set((null!==(n=t.pendingWidgetMessageIds)&&void 0!==n?n:[]).map(t=>t.trim()).filter(t=>t.length>0))].slice(0,20);return e.length>0&&a.append("pendingWidgetMessageIds",e.join(",")),a}({chatRoomId:t,cursor:n,size:a,direction:e,pendingWidgetMessageIds:o});return x("".concat(c.H,"/api/v1/chat/messages?").concat(r.toString()))}async function tV(t,n){let a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:100,e=new URLSearchParams({chatRoomId:t.toString(),query:n,limit:a.toString()});return x("".concat(c.H,"/api/v1/chat/messages/search?").concat(e.toString()))}async function tG(){try{return await x("".concat(c.H,"/api/v1/users/me"))}catch(t){throw console.error("Failed to fetch user profile:",t),t}}async function tK(t){try{return await x("".concat(c.H,"/api/v1/users/me"),{method:"PUT",body:JSON.stringify(t)})}catch(t){if(t instanceof Error){let n=t.message;if(n.includes("VerificationRequired")||n.includes("UnderageUser")||n.includes("FAILURE_TYPE_PG"))throw Error(n.includes("UnderageUser")?"UnderageUser":"VerificationRequired")}throw t}}async function tX(t){return x("".concat(c.H,"/api/v1/users/me/acquisition"),{method:"POST",body:JSON.stringify(t)})}async function tW(t,n,a){let e=new URLSearchParams({userType:"HUMAN"});return a.userNickname&&e.set("userNickname",a.userNickname),a.description&&e.set("description",a.description),a.profileImageUrl&&e.set("profileImageUrl",a.profileImageUrl),x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/participants/").concat(n,"?").concat(e.toString()),{method:"PUT"})}async function tY(t,n){let a=new URLSearchParams({userType:"HUMAN"});try{let e="".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/participants/").concat(n,"?").concat(a.toString());return await x(e)}catch(e){return console.error("Failed to get participant info:",e,"URL: ".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/participants/").concat(n,"?").concat(a.toString())),null}}async function t$(t){return(await x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/participants/overview"))).participants||[]}async function tZ(t){return(await x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/participants/metadata"))).participants||[]}async function tQ(t,n){return x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/participants/").concat(n,"/episodes"))}async function t0(t,n){let a=new URL("".concat(c.H,"/api/v1/chat/messages/").concat(t));return a.searchParams.set("newMessage",n),x(a.toString(),{method:"PUT"})}async function t1(t){return x("".concat(c.H,"/api/v1/chat/messages/").concat(t),{method:"DELETE"})}async function t2(t,n){return x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/messages/").concat(n,"/after"),{method:"DELETE"})}async function t3(t){return x("".concat(c.H,"/api/v1/chat/generation-v2/").concat(t,"/cost"))}async function t4(t){let n=!(arguments.length>1)||void 0===arguments[1]||arguments[1];return M("".concat(c.H,"/api/v1/chat/generation-v2/").concat(t),{method:"POST",body:JSON.stringify({shouldDelete:n})})}async function t6(){return x("".concat(c.H,"/api/v1/stones/pricing"))}async function t7(t,n){let a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:20,e=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"OLDER",o=new URLSearchParams({chatRoomId:t.toString(),size:a.toString(),direction:e});return n&&o.append("cursor",n.toString()),x("".concat(c.H,"/api/v1/chat/summaries?").concat(o.toString()))}async function t5(t,n){return x("".concat(c.H,"/api/v1/chat/summaries/").concat(t),{method:"PUT",body:JSON.stringify({preview:n})})}async function t9(t){return x("".concat(c.H,"/api/v1/chat/summaries/").concat(t),{method:"DELETE"})}async function t8(t,n){return x("".concat(c.H,"/api/v1/chat/summaries/").concat(t,"/star"),{method:"PATCH",body:JSON.stringify({isStarred:n})})}async function nt(){return x("".concat(c.H,"/api/v1/users/ai-characters"))}async function nn(t){var n;let a=new URLSearchParams({size:String(null!==(n=null==t?void 0:t.size)&&void 0!==n?n:50)});return(null==t?void 0:t.cursor)!==void 0&&null!==t.cursor&&a.append("cursor",String(t.cursor)),(null==t?void 0:t.publishStatus)&&a.append("publishStatus",t.publishStatus),(null==t?void 0:t.locale)&&a.append("locale",t.locale),x("".concat(c.H,"/api/v1/ai-characters?").concat(a.toString()))}async function na(t){var n,a;let e=new URLSearchParams({creatorUserId:t.creatorUserId,size:String(null!==(n=t.size)&&void 0!==n?n:20),sortBy:null!==(a=t.sortBy)&&void 0!==a?a:"latest"});
1return t.cursor&&e.append("cursor",String(t.cursor)),t.locale&&e.append("locale",t.locale),n4("".concat(c.H,"/api/v1/ai-characters/public/by-creator?").concat(e.toString()))}async function ne(t){var n;let a=new URLSearchParams({sortBy:(null==t?void 0:t.sortBy)||"latest",size:String(null!==(n=null==t?void 0:t.size)&&void 0!==n?n:20)});return(null==t?void 0:t.cursor)&&a.append("cursor",String(t.cursor)),(null==t?void 0:t.spinoffOnly)&&a.append("spinoff_only","true"),(null==t?void 0:t.q)&&t.q.trim().length>0&&a.append("q",t.q.trim()),n4("".concat(c.H,"/api/v1/ai-characters/public?").concat(a.toString()))}async function no(t){let n=new URLSearchParams({size:(t.size||20).toString(),direction:t.direction||"OLDER"});return t.aiCharacterId&&n.append("aiCharacterId",t.aiCharacterId.toString()),t.cursor&&n.append("cursor",t.cursor.toString()),t.onlyFeatured&&n.append("onlyFeatured","true"),t.includePrivate&&n.append("includePrivate","true"),x("".concat(c.H,"/api/v1/feed/posts?").concat(n.toString()))}async function nc(t){return x("".concat(c.H,"/api/v1/feed/admin/posts"),{method:"POST",body:JSON.stringify(t)})}async function nr(t,n){return x("".concat(c.H,"/api/v1/feed/admin/posts/").concat(t),{method:"PUT",body:JSON.stringify(n)})}async function ni(t){return x("".concat(c.H,"/api/v1/feed/admin/posts/").concat(t),{method:"DELETE"})}async function ns(t,n){let a=new FormData;return a.append("file",t),n&&a.append("folder",n),x("".concat(c.H,"/api/v1/media"),{method:"POST",body:a})}async function nu(t,n){return x("".concat(c.H,"/api/v1/feed/posts/").concat(t,"/poll/vote"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({optionId:n})})}async function nl(t){return x("".concat(c.H,"/api/v1/feed/posts/").concat(t,"/like"),{method:"POST"})}async function nd(t){let n=new URLSearchParams({size:(t.size||20).toString()});if(t.cursor&&n.append("cursor",t.cursor.toString()),void 0!==t.parentCommentId&&null!==t.parentCommentId){var a;n.append("parentCommentId",(null===(a=t.parentCommentId)||void 0===a?void 0:a.toString())||"")}return await x("".concat(c.H,"/api/v1/feed/posts/").concat(t.postId,"/comments?").concat(n.toString()))}async function np(t){return x("".concat(c.H,"/api/v1/feed/comments"),{method:"POST",body:JSON.stringify(t)})}async function nf(t,n){return x("".concat(c.H,"/api/v1/feed/comments/").concat(t),{method:"PUT",body:JSON.stringify(n)})}async function nv(t){return x("".concat(c.H,"/api/v1/feed/comments/").concat(t),{method:"DELETE"})}async function nh(t){return x("".concat(c.H,"/api/v1/feed/comments/").concat(t,"/like"),{method:"POST"})}async function ny(t){let n=new URLSearchParams({size:(t.size||20).toString()});if(t.cursor&&n.append("cursor",t.cursor.toString()),void 0!==t.parentCommentId&&null!==t.parentCommentId){var a;n.append("parentCommentId",(null===(a=t.parentCommentId)||void 0===a?void 0:a.toString())||"")}return x("".concat(c.H,"/api/v1/ai-characters/").concat(t.characterId,"/comments?").concat(n.toString()))}async function nm(t,n){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/comments"),{method:"POST",body:JSON.stringify(n)})}async function ng(t,n){return x("".concat(c.H,"/api/v1/ai-characters/comments/").concat(t),{method:"PUT",body:JSON.stringify(n)})}async function nS(t){return x("".concat(c.H,"/api/v1/ai-characters/comments/").concat(t),{method:"DELETE"})}async function nH(t){return x("".concat(c.H,"/api/v1/ai-characters/comments/").concat(t,"/like"),{method:"POST"})}async function nw(t){return x("".concat(c.H,"/api/v1/feed/reports"),{method:"POST",body:JSON.stringify(t)})}async function nP(){let{blockedCreatorIds:t}=await x("".concat(c.H,"/api/v1/users/blocked-creators"));return t}async function nb(t){let{blockedCreatorIds:n}=await x("".concat(c.H,"/api/v1/users/blocked-creators"),{method:"POST",body:JSON.stringify({creatorUserId:t})});return n}async function nO(t){let{blockedCreatorIds:n}=await x("".concat(c.H,"/api/v1/users/blocked-creators/").concat(encodeURIComponent(t)),{method:"DELETE"});return n}async function nT(t){let{blockedCreatorIds:n}=await x("".concat(c.H,"/api/v1/users/blocked-creators/sync"),{method:"POST",body:JSON.stringify({creatorUserIds:t})});return n}async function nE(t){var n;let a=new URLSearchParams({limit:String(null!==(n=null==t?void 0:t.limit)&&void 0!==n?n:20)});
1return(null==t?void 0:t.cursor)&&a.append("cursor",t.cursor),x("".concat(c.H,"/api/v1/users/favorite-characters?").concat(a.toString()))}async function nI(t){return x("".concat(c.H,"/api/v1/users/favorite-characters/").concat(t))}async function nU(t,n){return x("".concat(c.H,"/api/v1/users/favorite-characters/").concat(t),{method:"PUT",body:JSON.stringify({isFavorite:n})})}async function nN(){return x("".concat(c.H,"/api/v1/users/achievements"))}class nR extends Error{constructor(t){super("Character is used in other users' chat rooms"),this.usageChatRoomCount=t,this.name="CharacterInUseError"}}async function nk(t){let{error:n}=await q("".concat(c.H,"/api/v1/ai-characters/").concat(t),{method:"DELETE"});if((null==n?void 0:n.code)==="CHARACTER_IN_USE")throw new nR("usageChatRoomCount"in n&&"number"==typeof n.usageChatRoomCount?n.usageChatRoomCount:0);if(n)throw Error("".concat(n.code,": ").concat(n.message))}async function nL(t,n){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/subs"),{method:"PUT",body:JSON.stringify({subCharacters:n})})}async function nC(t,n){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/subs/").concat(n),{method:"DELETE"})}async function nJ(){return x("".concat(c.H,"/api/v1/referrer/code"))}let n_=["REFERRAL_CODE_NOT_FOUND","REFERRAL_CODE_ALREADY_EXISTS","ALREADY_REFERRED","SELF_REFERRAL_NOT_ALLOWED","REFERRAL_SYSTEM_ERROR"];class nA extends Error{constructor(t,n){super(n),this.name="ReferralRegistrationError",this.code=t}}async function nD(t){var n,a,e;let o=new URL("".concat(c.H,"/api/v1/referrer/register"));o.searchParams.set("referral_code",t);let r={method:"POST"},i=await D(o.toString(),r,t=>A(r,t)),s=await i.json().catch(()=>({data:null,error:null}));if(s.error)throw new nA((a=s.error.code,null!==(e=n_.find(t=>t===a))&&void 0!==e?e:null),s.error.message);if(!i.ok)throw new nA(null,i.statusText);return(null===(n=s.data)||void 0===n?void 0:n.success)===!0}async function nx(t){return x("".concat(c.H,"/api/v1/media/generate"),{method:"POST",body:JSON.stringify(t)})}async function nM(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:20;return x("".concat(c.H,"/api/v1/media/recent?limit=").concat(t))}async function nq(t){let n=new URLSearchParams({dateRange:t.dateRange});return x("".concat(c.H,"/api/v1/admin/creators/analytics?").concat(n.toString()))}async function nz(t,n){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/user-persona"),{method:"POST",body:JSON.stringify(n)})}async function nj(t,n){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/user-persona"),{method:"PUT",body:JSON.stringify(n)})}async function nF(t){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/user-persona"),{method:"DELETE"})}async function nB(t){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/episodes"))}async function nV(t,n){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/episodes"),{method:"POST",body:JSON.stringify(n)})}async function nG(t,n,a){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/episodes/").concat(n),{method:"PUT",body:JSON.stringify(a)})}async function nK(t,n){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/episodes/").concat(n),{method:"DELETE"})}async function nX(t){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/personal-episodes"))}async function nW(t,n){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/personal-episodes"),{method:"POST",body:JSON.stringify(n)})}async function nY(t,n,a){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/personal-episodes/").concat(n),{method:"PUT",body:JSON.stringify(a)})}async function n$(t,n){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/personal-episodes/").concat(n),{method:"DELETE"})}async function nZ(t,n){let a=new URLSearchParams;(null==n?void 0:n.q)&&a.set("q",n.q),(null==n?void 0:n.cursor)!==void 0&&a.set("cursor",String(n.cursor)),(null==n?void 0:n.size)!==void 0&&a.set("size",String(n.size));let e=a.toString();return x(e?"".concat(c.H,"/api/v1/ai-characters/").concat(t,"/personal-episodes/public?").concat(e):"".concat(c.H,"/api/v1/ai-characters/").concat(t,"/personal-episodes/public"))}async function nQ(t,n){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/personal-episodes/").concat(n,"/import"),{method:"POST"})}async function n0(t){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/lore-books"))}async function n1(t,n){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/lore-books"),{method:"POST",body:JSON.stringify(n)})}async function n2(t,n,a){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/lore-books/").concat(n),{method:"PUT",body:JSON.stringify(a)})}async function n3(t,n){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/lore-books/").concat(n),{method:"DELETE"})}async function n4(t){let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=async t=>{var a,e;let o=await J(t),c={};(null==o?void 0:null===(a=o.backendAuth)||void 0===a?void 0:a.token)&&(c.Authorization="Bearer ".concat(o.backendAuth.token));let r=P();return r&&(c["X-Locale"]=r),n.headers&&Object.assign(c,n.headers),!["POST","PUT","PATCH"].includes((null===(e=n.method)||void 0===e?void 0:e.toUpperCase())||"GET")||n.body instanceof FormData||(c["Content-Type"]="application/json"),c};try{let e=await D(t,n,a);if(!e.ok){let t=await e.text();throw console.error("Client optional fetch - Error response:",t),Error("API request failed: ".concat(e.status," ").concat(e.statusText,". ").concat(t))}return(await e.json()).data}catch(t){throw console.error("Client optional fetch - Caught error:",t),t}}async function n6(){return x("".concat(c.H,"/api/v1/stones/rewards"))}async function n7(){return x("".concat(c.H,"/api/v1/stones/rewards/claim"),{method:"POST"})}async function n5(){return x("".concat(c.H,"/api/v1/stones/rewards/payout"))}async function n9(t){return q("".concat(c.H,"/api/v1/stones/rewards/payout/profile"),{method:"PUT",body:JSON.stringify(t)})}async function n8(t){return q("".concat(c.H,"/api/v1/stones/rewards/payout/request"),{method:"POST",body:JSON.stringify(void 0===t?{}:{stoneAmount:t})})}async function at(){return x("".concat(c.H,"/api/v1/stones/rewards/payout/wallet"))}async function an(t){return q("".concat(c.H,"/api/v1/stones/rewards/payout/wallet/convert"),{method:"POST",body:JSON.stringify({stoneAmount:t})})}async function aa(){return x("".concat(c.H,"/api/v1/creator-program/dashboard"))}async function ae(){return x("".concat(c.H,"/api/v1/admin/creator-payouts/whitelist"))}async function ao(t){return x("".concat(c.H,"/api/v1/admin/creator-payouts/requests").concat(t?"?status=".concat(t):""))}async function ac(t,n){return q("".concat(c.H,"/api/v1/admin/creator-payouts/requests/").concat(t,"/paid"),{method:"POST",body:JSON.stringify({note:n})})}async function ar(t,n){return q("".concat(c.H,"/api/v1/admin/creator-payouts/requests/").concat(t,"/reject"),{method:"POST",body:JSON.stringify({reason:n})})}async function ai(){return x("".concat(c.H,"/api/v1/admin/creator-program/partners"))}async function as(t){return q("".concat(c.H,"/api/v1/admin/creator-program/partners"),{method:"POST",body:JSON.stringify(t)})}async function au(t){return q("".concat(c.H,"/api/v1/admin/creator-program/partners/").concat(t,"/tier-suggestion"))}async function al(t,n){return q("".concat(c.H,"/api/v1/admin/creator-program/partners/").concat(t,"/tier"),{method:"POST",body:JSON.stringify(n)})}async function ad(t,n){return q("".concat(c.H,"/api/v1/admin/creator-program/partners/").concat(t,"/terminate"),{method:"POST",body:JSON.stringify(n?{terminatedOn:n}:{})})}async function ap(t){let n=new URLSearchParams(t).toString();return z("".concat(c.H,"/api/v1/admin/creator-payouts/export?").concat(n))}async function af(t){return q("".concat(c.H,"/api/v1/admin/creator-payouts/requests/").concat(t,"/pii"))}async function av(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:50;return x("".concat(c.H,"/api/v1/stones/rewards/history?limit=").concat(t))}async function ah(t,n){let a=new URLSearchParams;t&&a.set("startDate",t),n&&a.set("endDate",n);let e=a.toString();return x("".concat(c.H,"/api/v1/stones/rewards/daily").concat(e?"?".concat(e):""))}async function ay(){return x("".concat(c.H,"/api/v1/stones/milestone-rewards"))}async function am(){return x("".concat(c.H,"/api/v1/stones/milestone-rewards/claim"),{method:"POST"})}async function ag(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:100,n=arguments.length>1?arguments[1]:void 0,a=new URLSearchParams({limit:String(t),offset:"0"});return n&&a.set("locale",n),n4("".concat(c.H,"/api/v1/notifications?").concat(a.toString()))}async function aS(t){return n4("".concat(c.H,"/api/v1/users/app/version-check?os=").concat(t))}async function aH(){return x("".concat(c.H,"/api/v1/feed/personas"))}async function aw(t){return x("".concat(c.H,"/api/v1/feed/personas"),{method:"POST",body:JSON.stringify(t)})}async function aP(t,n){return x("".concat(c.H,"/api/v1/feed/personas/").concat(t),{method:"PUT",body:JSON.stringify(n)})}async function ab(t){return x("".concat(c.H,"/api/v1/feed/personas/").concat(t),{method:"DELETE"})}async function aO(t){return x("".concat(c.H,"/api/v1/feed/personas/adopt"),{method:"POST",body:JSON.stringify(t)})}async function aT(){return x("".concat(c.H,"/api/v1/users/follower-characters/stats"))}async function aE(t){var n;let a=new URLSearchParams({limit:String(null!==(n=null==t?void 0:t.limit)&&void 0!==n?n:20)});
1return(null==t?void 0:t.cursor)&&a.append("cursor",t.cursor),x("".concat(c.H,"/api/v1/users/follow-characters?").concat(a.toString()))}async function aI(t){var n;let a=new URLSearchParams({limit:String(null!==(n=null==t?void 0:t.limit)&&void 0!==n?n:20)});return(null==t?void 0:t.cursor)&&a.append("cursor",t.cursor),x("".concat(c.H,"/api/v1/users/follower-characters?").concat(a.toString()))}async function aU(t){var n;let a=new URLSearchParams({size:String(null!==(n=null==t?void 0:t.size)&&void 0!==n?n:20)});return(null==t?void 0:t.cursor)&&a.append("cursor",String(t.cursor)),x("".concat(c.H,"/api/v1/feed/user/posts?").concat(a.toString()))}async function aN(t){return x("".concat(c.H,"/api/v1/feed/user/posts/").concat(t),{method:"DELETE"})}async function aR(t,n){return x("".concat(c.H,"/api/v1/feed/posts/").concat(t,"/insert-to-chat"),{method:"POST",body:JSON.stringify({chatRoomId:n})})}async function ak(t){return x("".concat(c.H,"/api/v1/feed/posts/").concat(t))}async function aL(t){return x("".concat(c.H,"/api/v1/feed/posts/v3?").concat(t.toString()))}async function aC(){return x("".concat(c.H,"/api/v1/feed/user/available-dolos"))}async function aJ(t){var n,a;let e={visibility:t.visibility};return(null===(n=t.caption)||void 0===n?void 0:n.trim())&&(e.caption=t.caption.trim()),t.mediaUrl&&(e.mediaUrl=t.mediaUrl),t.boardDoloId&&(e.boardDoloId=t.boardDoloId),(null===(a=t.taggedDoloIds)||void 0===a?void 0:a.length)&&(e.taggedDoloIds=t.taggedDoloIds.slice(0,2)),t.category&&(e.category=t.category),t.poll&&(e.poll=t.poll),t.storyId&&(e.storyId=t.storyId),x("".concat(c.H,"/api/v1/feed/user/posts"),{method:"POST",body:JSON.stringify(e)})}async function a_(t,n){let a={incidentDescription:t};return(null==n?void 0:n.length)&&(a.taggedDoloIds=n),x("".concat(c.H,"/api/v1/feed/press/create-incident"),{method:"POST",body:JSON.stringify(a)})}async function aA(t){await x("".concat(c.H,"/api/v1/chat/messages/vote"),{method:"POST",body:JSON.stringify(t)})}async function aD(t,n){return x("".concat(c.H,"/api/v1/users/follow-characters/").concat(t),{method:"PUT",body:JSON.stringify({isFollowing:n})})}async function ax(t){return x("".concat(c.H,"/api/v1/users/follow-characters/").concat(t))}async function aM(t){return x("".concat(c.H,"/api/v1/ai-characters/").concat(t,"/social-stats"))}async function aq(t){var n,a;let e=new URLSearchParams({aiCharacterId:t.aiCharacterId,size:String(null!==(n=t.size)&&void 0!==n?n:30),direction:null!==(a=t.direction)&&void 0!==a?a:"NEWER"});return t.cursor&&e.append("cursor",String(t.cursor)),t.includePrivate&&e.append("includePrivate","true"),x("".concat(c.H,"/api/v1/feed/posts/v2?").concat(e.toString()))}async function az(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:100;return x("".concat(c.H,"/api/v1/coupons/applied?limit=").concat(t))}async function aj(t){return x("".concat(c.H,"/api/v1/coupons?couponCode=").concat(encodeURIComponent(t)),{method:"POST"})}async function aF(){return(await x("".concat(c.H,"/api/v1/subscription/products"))).products}async function aB(){return x("".concat(c.H,"/api/v1/subscription/status"))}async function aV(t){return x("".concat(c.H,"/api/v1/subscription/calculate-discount"),{method:"POST",body:JSON.stringify(t)})}async function aG(t){return x("".concat(c.H,"/api/v1/credits").concat(t?"?domain=".concat(t):""))}async function aK(){return x("".concat(c.H,"/api/v1/credits/daily"))}async function aX(){return x("".concat(c.H,"/api/v1/credits/daily"),{method:"POST"})}async function aW(){let t=await A({method:"POST"}),n=await fetch("".concat(c.H,"/api/v1/ads/reward-session"),{method:"POST",headers:t});if(n.status>=500)throw Error("Ad reward session failed: ".concat(n.status));return await n.json()}async function aY(){return x("".concat(c.H,"/api/v1/users/me"),{method:"DELETE"})}async function a$(t){var n;let a=new URLSearchParams({size:String(null!==(n=null==t?void 0:t.size)&&void 0!==n?n:50)});return(null==t?void 0:t.cursor)&&a.append("cursor",t.cursor),x("".concat(c.H,"/api/v1/feed/hides?").concat(a.toString()))}async function aZ(t){return x("".concat(c.H,"/api/v1/feed/hides"),{method:"POST",body:JSON.stringify({aiCharacterId:t})})}async function aQ(t){return x("".concat(c.H,"/api/v1/feed/hides/").concat(encodeURIComponent(t)),{method:"DELETE"})}async function a0(){return x("".concat(c.H,"/api/v1/ai-characters/curation/v3/filters"))}async function a1(){return x("".concat(c.H,"/api/v1/ai-characters/curation/weekly-reviews"))}async function a2(){return x("".concat(c.H,"/api/v1/ai-characters/curation/v2/categories"))}async function a3(t){var n;let a=new URLSearchParams({type:t.type,size:String(null!==(n=t.size)&&void 0!==n?n:50)});return void 0!==t.cursor&&null!==t.cursor&&a.append("cursor",String(t.cursor)),x("".concat(c.H,"/api/v1/ai-characters/curation/v3?").
1concat(a.toString()))}async function a4(t){return x("".concat(c.H,"/api/v1/ai-characters/curation/v2/category/").concat(t))}async function a6(t){let n=new URLSearchParams({slot:t,platform:"web"});return x("".concat(c.H,"/api/v1/dynamic-banners?").concat(n.toString()))}async function a7(){return x("".concat(c.H,"/api/v1/ai-characters/top-liked"))}async function a5(){return x("".concat(c.H,"/api/v1/users/onboarding/curated"))}async function a9(){return x("".concat(c.H,"/api/v1/users/onboarding/category-funnel"))}async function a8(t){let n=new URL("".concat(c.H,"/api/v1/oauth/signin/another"));return n.searchParams.set("userIdToLoad",t),x(n.toString(),{method:"POST"})}async function et(t){let{provider:n,providerAccessToken:a,locale:e}=t,o=new URL("".concat(c.H,"/api/v1/oauth/override"));return o.searchParams.set("provider",(0,f.h3)(n)),o.searchParams.set("providerAccessToken",a),e&&o.searchParams.set("locale",e),x(o.toString(),{method:"PUT"})}async function en(t){try{let n=await fetch("".concat(c.H,"/api/v1/users/me"),{headers:{Authorization:"Bearer ".concat(t)}});if(!n.ok)return null;return(await n.json()).data}catch(t){return null}}async function ea(){let t=await x("".concat(c.H,"/api/v1/world/assets"));return(0,v.vT)(t)}async function ee(){var t;let n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:50,a=await x("".concat(c.H,"/api/v1/world/user-personas?limit=").concat(n));return null!==(t=null==a?void 0:a.personas)&&void 0!==t?t:[]}async function eo(t){return x("".concat(c.H,"/api/v1/chat/world/rooms"),{method:"POST",body:JSON.stringify(t)})}async function ec(t){var n;let a=await x("".concat(c.H,"/api/v1/world/rooms/").concat(t,"/location"));return null!==(n=null==a?void 0:a.location)&&void 0!==n?n:null}async function er(t){var n;let a=await x("".concat(c.H,"/api/v1/world/rooms/").concat(t,"/participants"));return null!==(n=null==a?void 0:a.participants)&&void 0!==n?n:[]}async function ei(t){var n;let a=await x("".concat(c.H,"/api/v1/world/").concat(t,"/locations"));return null!==(n=null==a?void 0:a.locations)&&void 0!==n?n:[]}async function es(t){var n;let a=t?"?locale=".concat(encodeURIComponent(t)):"",e=await x("".concat(c.H,"/api/v1/world/characters").concat(a));return null!==(n=null==e?void 0:e.characters)&&void 0!==n?n:[]}async function eu(t,n){return x("".concat(c.H,"/api/v1/chat/world/rooms/").concat(t,"/participants"),{method:"POST",body:JSON.stringify({characterIds:n})})}async function el(t,n){await x("".concat(c.H,"/api/v1/chat/world/rooms/").concat(t,"/participants/").concat(n),{method:"DELETE"})}async function ed(t){var n,a;let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},o=new URLSearchParams({includeUnplayable:String(null!==(n=e.includeUnplayable)&&void 0!==n&&n)});e.locationId&&o.set("locationId",e.locationId);let r=await x("".concat(c.H,"/api/v1/chat/rooms/").concat(t,"/available-episodes?").concat(o.toString()));
1return null!==(a=null==r?void 0:r.episodes)&&void 0!==a?a:[]}async function ep(t,n){let a=await x("".concat(c.H,"/api/v1/world/episodes/").concat(t,"?chatRoomId=").concat(n));return null!=a?a:null}async function ef(t){var n;let a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},e=a.createdByMe?"?createdByMe=true":"",o=await x("".concat(c.H,"/api/v1/world/").concat(t,"/episodes").concat(e));return null!==(n=null==o?void 0:o.episodes)&&void 0!==n?n:[]}async function ev(t,n){return x("".concat(c.H,"/api/v1/world/").concat(t,"/episodes"),{method:"POST",body:JSON.stringify((0,r.k5)(n))})}async function eh(t,n){await x("".concat(c.H,"/api/v1/world/episodes/").concat(t),{method:"PATCH",body:JSON.stringify((0,r.k5)(n))})}async function ey(t){await x("".concat(c.H,"/api/v1/world/episodes/").concat(t),{method:"DELETE"})}async function em(t,n){var a;let e=n?"?locale=".concat(encodeURIComponent(n)):"",o=await x("".concat(c.H,"/api/v1/world/").concat(t,"/participants").concat(e));return null!==(a=null==o?void 0:o.participants)&&void 0!==a?a:[]}async function eg(t){var n;let a=await x("".concat(c.H,"/api/v1/world/rooms/").concat(t,"/completed-episodes"));return null!==(n=null==a?void 0:a.completedEpisodeIds)&&void 0!==n?n:[]}async function eS(){let t=await x("".concat(c.H,"/api/v1/world/onboarding-episode"));return(null==t?void 0:t.episodeId)||null}async function eH(t,n){await x("".concat(c.H,"/api/v1/chat/world/rooms/").concat(t,"/location"),{method:"PATCH",body:JSON.stringify({locationId:n})})}async function ew(t){await x("".concat(c.H,"/api/v1/world/locations/").concat(t),{method:"DELETE"})}async function eP(t){return x("".concat(c.H,"/api/v1/world/locations"),{method:"POST",body:JSON.stringify(t)})}async function eb(t,n){await x("".concat(c.H,"/api/v1/world/locations/").concat(t),{method:"PATCH",body:JSON.stringify(n)})}async function eO(t){return x("".concat(c.H,"/api/v1/support/tickets"),{method:"POST",body:JSON.stringify(t)})}async function eT(){return x("".concat(c.H,"/api/v1/support/tickets"))}async function eE(t){return x("".concat(c.H,"/api/v1/support/tickets/").concat(t))}async function eI(t,n){return x("".concat(c.H,"/api/v1/support/tickets/").concat(t,"/messages"),{method:"POST",body:JSON.stringify(n)})}async function eU(){return x("".concat(c.H,"/api/v1/support/unread-count"))}async function eN(){return x("".concat(c.H,"/api/v1/dolo-talks"))}async function eR(){return x("".concat(c.H,"/api/v1/dolo-talks/unread-count"))}async function ek(t){return x("".concat(c.H,"/api/v1/dolo-talks"),{method:"POST",body:JSON.stringify(t)})}async function eL(t,n){return x("".concat(c.H,"/api/v1/dolo-talks/").concat(t,"/messages").concat(void 0!==n?"?cursor=".concat(n):""))}async function eC(t,n){return x("".concat(c.H,"/api/v1/dolo-talks/").concat(t,"/read"),{method:"POST",body:JSON.stringify({lastReadMessageId:n})})}async function eJ(t,n){return x("".concat(c.H,"/api/v1/dolo-talks/").concat(t,"/messages"),{method:"POST",body:JSON.stringify(n)})}async function e_(t,n){return x("".concat(c.H,"/api/v1/dolo-talks/").concat(t),{method:"PATCH",body:JSON.stringify(n)})}async function eA(t){return x("".concat(c.H,"/api/v1/dolo-talks/").concat(t),{method:"DELETE"})}async function eD(t,n){return x("".concat(c.H,"/api/v1/dolo-talks/").concat(t,"/messages/").concat(n))}function ex(t,n){return"".concat(c.H,"/api/v1/dolo-talks/").concat(t,"/messages/").concat(n,"/image")}async function eM(t){return x("".concat(c.H,"/api/v1/feed/incidents"),{method:"POST",body:JSON.stringify(t)})}async function eq(t,n){return x("".concat(c.H,"/api/v1/feed/incidents/").concat(t),{signal:n})}async function ez(t){return x("".concat(c.H,"/api/v1/feed/incidents/active"),{signal:t})}async function ej(){return x("".concat(c.H,"/api/v1/feed/incidents/suggest/quota"))}async function eF(t){return x("".concat(c.H,"/api/v1/feed/incidents/suggest"),{method:"POST",body:JSON.stringify(t)})}async function eB(t){return x("".concat(c.H,"/api/v1/creators/").concat(encodeURIComponent(t)))}async function eV(t){return x("".concat(c.H,"/api/v1/creators/").concat(encodeURIComponent(t),"/follow"),{method:"POST"})}async function eG(t){var n;let a=new URLSearchParams({size:String(null!==(n=t.size)&&void 0!==n?n:20)});return null!=t.cursor&&a.append("cursor",String(t.cursor)),x("".concat(c.H,"/api/v1/creators/").concat(encodeURIComponent(t.creatorUserId),"/posts?").concat(a.toString()))}async function eK(t){return x("".concat(c.H,"/api/v1/creators/").concat(encodeURIComponent(t),"/visit"),{method:"POST"})}async function eX(){let{creators:t}=await x("".concat(c.H,"/api/v1/creators/following"));return t}async function eW(){let{posts:t}=await x("".concat(c.H,"/api/v1/creators/news"));return t}async function eY(t){return q("".concat(c.H,"/api/v1/creators/posts"),{method:"POST",body:JSON.stringify(t)})}async function e$(t){return q("".concat(c.H,"/api/v1/creators/howto"),{method:"POST",body:JSON.stringify(t)})}async function eZ(t){var n;let a=new URLSearchParams({size:String(null!==(n=t.size)&&void 0!==n?n:20)});return t.kind&&a.append("kind",t.kind),null!=t.cursor&&a.append("cursor",String(t.cursor)),n4("".concat(c.H,"/api/v1/creators/howto?").concat(a.toString()))}async function eQ(t){var n;let a=new URLSearchParams({size:String(null!==(n=t.size)&&void 0!==n?n:20)});return null!=t.cursor&&a.append("cursor",String(t.cursor)),x("".concat(c.H,"/api/v1/creators/howto/saved?").concat(a.toString()))}async function e0(t){return x("".concat(c.H,"/api/v1/creators/howto/").concat(t,"/bookmark"),{method:"POST"})}async function e1(t){return x("".concat(c.H,"/api/v1/creators/posts/").concat(t),{method:"PATCH",body:JSON.stringify({contentRating:"ADULT"})})}async function e2(t){return q("".concat(c.H,"/api/v1/feed/preferences"),{method:"PUT",body:JSON.stringify({showAdultPosts:t})})}let e3="".concat(c.H,"/api/v1/feed/stories");function e4(){return"".concat(e3,"/current")}function e6(t){return"".concat(e3,"/").concat(t)}async function e7(t){return x("".concat(e3,"/propose"),{method:"POST",body:JSON.stringify(t)})}async function e5(t,n){return x("".concat(e6(t),"/start"),{method:"POST",body:JSON.stringify(n)})}async function e9(t){await x("".concat(e6(t),"/decline"),{method:"POST",body:"{}"})}async function e8(t){return x("".concat(e6(t),"/skip"),{method:"POST",body:"{}"})}async function ot(t){await x("".concat(e6(t),"/retry"),{method:"POST",body:"{}"})}async function on(t){await x("".concat(e6(t),"/viewing"),{method:"POST",body:"{}"})}async function oa(t){await x("".concat(e6(t),"/leave"),{method:"POST",body:"{}"})}async function oe(t){await x("".concat(e6(t),"/abort"),{method:"POST",body:"{}"})}async function oo(t){await x("".concat(e6(t),"/close"),{method:"POST",body:"{}"})}async function oc(t){return x("".concat(c.H,"/api/v1/feed/dolos/").concat(encodeURIComponent(String(t)),"/rooms"))}},31351:(t,n,a)=>{a.d(n,{cn:()=>c});var e=a(64642),o=a(23330);function c(){for(var t=arguments.length,n=Array(t),a=0;a<t;a++)n[a]=arguments[a];return(0,o.QP)((0,e.$)(n))}a(55036)},67741:(t,n,a)=>{function e(t){return"has_multi_recommendation_shown_".concat(t)}a.d(n,{$e:()=>d,C_:()=>c,P5:()=>l,f5:()=>s,s0:()=>u});let o=()=>window.localStorage;function c(t,n){let a=o();if(!function(t,n,a){if(0===n.characters.length)return!1;if(!t)return!0;try{return"true"!==t.getItem(e(a))}catch(t){return!0}}(a,t,n))return null;if(a)try{a.setItem(e(n),"true")}catch(t){}return t}
1let r="dolo_pending_multi_recommendation";function i(t){if(!t)return null;try{let n=JSON.parse(t);return"object"==typeof n&&null!==n&&"string"==typeof n.title&&"number"==typeof n.sourceRoomId&&Array.isArray(n.characters)&&n.characters.every(t=>"string"==typeof(null==t?void 0:t.id)&&"string"==typeof(null==t?void 0:t.name))?n:null}catch(t){return null}}function s(t){let n=o();if(n)try{n.setItem(r,JSON.stringify(t))}catch(t){}}function u(t){let n=o();if(!n)return null;try{var a=n.getItem(r);let e=i(a);return e&&e.sourceRoomId===t?e:null}catch(t){return null}}function l(){let t=o();if(t)try{t.removeItem(r)}catch(t){}}function d(t){let n,a=o();if(a){try{n=function(t,n){let a=i(t);return!!a&&a.characters.some(t=>t.id===n)}(a.getItem(r),t)}catch(t){return}n&&l()}}},74598:(t,n,a)=>{a.d(n,{m0:()=>o,re:()=>u,uE:()=>c});let e={ko:"ko-KR",en:"en-US",ja:"ja-JP",tw:"zh-Hant-TW",hk:"zh-Hant-HK",ar:"ar-SA",es:"es-MX",fr:"fr-FR"};function o(t){var n;return null!==(n=e[t])&&void 0!==n?n:t}function c(t){var n,a;return null!==(a=null!==(n=r[t])&&void 0!==n?n:e[t])&&void 0!==a?a:t}let r={ar:"ar-SA-u-nu-latn"},i={ko:"ko_KR",en:"en_US",ja:"ja_JP",tw:"zh_TW",hk:"zh_HK",ar:"ar_SA",es:"es_MX",fr:"fr_FR",cn:"zh_CN",zh:"zh_CN"},s=new Set(Object.values(i));function u(t){var n,a,e;if(!t)return null;let o=t.trim();if(!o)return null;let c=i[o.toLowerCase()];if(c)return c;let r=o.replace(/_/g,"-").split("-").filter(Boolean),u=null===(n=r[0])||void 0===n?void 0:n.toLowerCase();if(!u)return null;let l=null===(a=r.slice(1).reverse().find(t=>/^[A-Za-z]{2}$/.test(t)))||void 0===a?void 0:a.toUpperCase();if(!l)return null!==(e=i[u])&&void 0!==e?e:null;let d="".concat(u,"_").concat(l);return s.has(d)?d:null}},80920:(t,n,a)=>{a.d(n,{$R:()=>u,HW:()=>m,J0:()=>f,Qg:()=>g,Zt:()=>o,b:()=>h,i7:()=>p,jz:()=>y,mI:()=>S,mb:()=>i,n7:()=>v,nm:()=>r,qM:()=>l,qy:()=>c,tO:()=>s,v1:()=>e,w4:()=>H,zt:()=>d});let e="store_entry_v1";function o(t){switch(t){case"not_started":case"active":case"expired_notice":case"ended":case"purchased":return t;default:return"unknown"}}function c(t){return t.startsWith("stone_pack_first_purchase")}function r(t){return t.filter(t=>c(t.id))}function i(t){if(t.promotion){var n;return"not_started"===(n=t.promotion).status||"active"===n.status||"expired_notice"===n.status}return r(t.packages).length>0}function s(t){return"active"===t.status}function u(t){return"expired_notice"===t.status&&!t.extensionUsed}function l(t){let n="active"===t.mode?t.promotion.activeUntil:t.promotion.noticeUntil;return null===n?0:Math.max(0,n-(t.promotion.serverNow+t.currentClientNow-t.initialClientNow))}function d(t){let n=Math.max(0,Math.floor(t/1e3));return[Math.floor(n/3600),Math.floor(n/60)%60,n%60].map(t=>t.toString().padStart(2,"0")).join(":")}function p(t){return!t.signUpAt||t.signUpAt<=0?0:Math.max(0,t.signUpAt+864e5-t.now)}function f(t){let n=r(t.packages);return t.promotion?"expired_notice"===t.promotion.status?"policy-expired":s(t.promotion)&&n.length>0?"policy-offer":null:0>=p({signUpAt:t.signUpAt,now:t.now})?null:n.length>0?"legacy-offer":null}function v(t){return"policy-offer"===f({packages:t.packages,promotion:t.promotion,signUpAt:null,now:0})}function h(t,n){let a=n.find(t=>"stone_pack_a"===t.id);if(!a||0===a.stone)return null;let e=t.stone*a.price/a.stone;return e>t.price?e:null}function y(t,n){let a=h(t,n);return null===a?{actualPrice:t.price,originalPrice:null,discountPercent:null}:{actualPrice:t.price,originalPrice:a,discountPercent:Math.round((a-t.price)/a*100)}}function m(t,n){return t.reduce((t,a)=>Math.max(t,function(t,n){let a=y(t,n).discountPercent;if(null!==a&&a>0)return a;let e=/(\d+)/.exec(t.bonus);return null===e?0:Number.parseInt(e[1],10)}(a,n)),0)}function g(t){return t.reduce((t,n)=>Math.max(t,n.bonusStone),0)}function S(t){var n;return Math.max(0,(null!==(n=t.originalPrice)&&void 0!==n?n:t.actualPrice)-t.actualPrice)}function H(t){return[...r(t)].sort((t,n)=>t.stone-n.stone)}},83635:(t,n,a)=>{a.d(n,{$2:()=>l,Pn:()=>r,e1:()=>d,h3:()=>i,lL:()=>u,s8:()=>c});var e=a(74598);let o=["google","apple","kakao"],c="accountLinked";function r(t){return!!t&&o.includes(t)}function i(t){return t.toUpperCase()}let s="dolo_guest_token";function u(t){t&&"undefined"!=typeof document&&(document.cookie="".concat(s,"=").concat(encodeURIComponent(t),"; path=/; max-age=").concat(300,"; samesite=none; secure"))}function l(){"undefined"!=typeof document&&(document.cookie="".concat(s,"=; path=/; max-age=0; samesite=none; secure"))}function d(t,n){return new Intl.DateTimeFormat((0,e.uE)(n),{year:"numeric",month:"short",day:"numeric",timeZone:"UTC"}).format(new Date(t))}},85975:(t,n,a)=>{function e(t,n){var a,e;let o=t.map(t=>({url:t,source:"character",isProfileImage:!1,participantId:null,participantName:null,userMediaGenerationId:null}));for(let t of null!==(a=null==n?void 0:n.participants)&&void 0!==a?a:[])for(let n of t.images)o.push({url:n.imageUrl,source:"album",isProfileImage:n.isProfileImage,participantId:t.participantId,participantName:t.participantName,userMediaGenerationId:n.userMediaGenerationId});for(let t of null!==(e=null==n?void 0:n.sharedImages)&&void 0!==e?e:[])o.push({url:t.imageUrl,source:"captured",isProfileImage:!1,participantId:null,participantName:null,userMediaGenerationId:t.userMediaGenerationId});return o}function o(t){return!t.isProfileImage&&"captured"!==t.source}function c(t){return"character"!==t.source&&null!==t.userMediaGenerationId}function r(t){var n,a;return{participants:(null!==(n=null==t?void 0:t.participants)&&void 0!==n?n:[]).map(t=>{var n;return{participantId:t.participantId,participantName:t.participantName,images:(null!==(n=t.images)&&void 0!==n?n:[]).map(i)}}),sharedImages:(null!==(a=null==t?void 0:t.sharedImages)&&void 0!==a?a:[]).map(i)}}function i(t){var n,a,e,o,c,r,i,s;return{userMediaGenerationId:null!==(a=null!==(n=t.userMediaGenerationId)&&void 0!==n?n:t.id)&&void 0!==a?a:0,imageUrl:null!==(o=null!==(e=t.imageUrl)&&void 0!==e?e:t.url)&&void 0!==o?o:"",promptSlug:null!==(c=t.promptSlug)&&void 0!==c?c:"",isFavorite:null!==(r=t.isFavorite)&&void 0!==r&&r,isProfileImage:null!==(i=t.isProfileImage)&&void 0!==i&&i,createdAt:null!==(s=t.createdAt)&&void 0!==s?s:0}}a.d(n,{Pf:()=>o,_P:()=>e,bW:()=>r,ju:()=>c})},86714:(t,n,a)=>{a.d(n,{e:()=>
1o});var e=a(74598);function o(t){var n;return null!==(n=(0,e.re)(t))&&void 0!==n?n:"ko_KR"}},96978:(t,n,a)=>{function e(t){var n,a,e;return t?{status:"not_started"===t.status||"active"===t.status||"ended"===t.status||"purchased"===t.status?t.status:"unknown",startedAt:null!==(n=t.startedAt)&&void 0!==n?n:null,until:null!==(a=t.until)&&void 0!==a?a:null,serverNow:null!==(e=t.serverNow)&&void 0!==e?e:0}:null}function o(t){return"stone_pack_special"===t}function c(t,n){var a;return(null==t?void 0:t.status)!=="active"?null:null!==(a=n.find(t=>o(t.id)))&&void 0!==a?a:null}function r(t){return{status:"active",firstStoreEnteredAt:t.startedAt,activeUntil:t.until,noticeUntil:t.until,extensionUsed:!0,extensionGrantedAt:null,serverNow:t.serverNow}}a.d(n,{KL:()=>c,Up:()=>o,_O:()=>r,tf:()=>e})}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.