All-Resources/[phone]/codem-phone/ui/dist/js/SellyApp.D2mF3l4I.js
2026-04-14 17:41:39 +02:00

2 lines
59 KiB
JavaScript

var U=(G,H,r)=>new Promise((m,k)=>{var $=w=>{try{n(r.next(w))}catch(M){k(M)}},N=w=>{try{n(r.throw(w))}catch(M){k(M)}},n=w=>w.done?m(w.value):Promise.resolve(w.value).then($,N);n((r=r.apply(G,H)).next())});import{_ as Se,u as ce,dw as ye,a as de,i as p,A as _e,f as J}from"./index.CjrDwa0W.js";import{C as Te}from"./CrossFade.B9Ap6pL9.js";import{s as ue,r as y,o as ke,w as we,e as Pe,b as he,V as ve,f as a,h as s,v as Y,i as e,g as P,k as t,q,A as Q,W as ge,t as b,x as A,F as z,m as K,Q as ie,l as C,U as re,j as oe,Y as Ce,n as xe,J as se,C as X}from"./vendor-vue.CmaRnji1.js";import{N as fe,P as me,i as De}from"./swiper.tg5sgs8j.js";import{N as je}from"./NewMessage.BMl6Sl0c.js";import{aC as Oe}from"./vendor.DSdF8huI.js";import{B as Ie}from"./BananaPay.C5pAUf3c.js";import{U as Fe}from"./UploadPhoto.DgxGHiME.js";import{_ as Re}from"./NoInternet.dMK-ez9k.js";import"./AiakosEmojiPicker.D8pZj3nB.js";import"./UploadPhoto.Bqd-ApD8.js";const Ne=["src"],Ae={key:0,class:"w-full h-full z-[2] absolute"},Me=["src"],Ve={class:"w-full h-[18%] flex items-end justify-center border-b-[1px] border-neutral-500/30"},ze={class:"w-[87%] h-[50%]"},Be={class:"w-full flex justify-between h-[65%]"},Ye={class:"w-[50%] h-full flex items-start",delay:100},qe={class:"text-[18em] font-['SFPRO'] text-white leading-[100%] font-[400]"},He={class:"w-[32%] h-full flex justify-end"},Ue=["src"],Ze=["src"],Ge={class:"w-full h-[60em] flex items-center"},We=["onClick"],Je=["src"],Qe=["src"],Ke=["data-index"],Xe={key:0,class:"w-full h-[150em] rounded-[18em] flex items-end justify-center px-[2px] pt-[2px] overflow-hidden relative"},et=["src"],tt=["src"],lt={key:1,class:"w-full h-[14em] absolute top-0 flex items-center justify-center z-10"},st={class:"w-[38%] h-full flex items-center justify-center relative"},ot=["src"],nt={class:"text-[12em] font-['SFPRO'] font-[400] text-black absolute text-center fixtext truncate w-full px-[.9em]"},at={key:2,class:"w-full h-[12em] absolute bottom-0 flex items-center justify-center z-10"},it={class:"w-[38%] h-full flex items-center justify-center relative mt-[3em]"},rt=["src"],ct={class:"text-[8em] font-['SFPRO'] font-[500] text-black absolute text-start fixtext"},ut={class:"w-full h-full overflow-hidden rounded-[18em]"},dt=["onClick","src"],ft=["onClick"],mt=["src"],pt={class:"absolute inset-0 flex items-center justify-center pointer-events-none"},ht={class:"w-[35em] h-[35em] rounded-full flex items-center justify-center group-hover:scale-110 transition-transform duration-200"},vt=["src"],gt={key:1,class:"w-full h-[12px]"},xt={class:"w-full h-[32em] flex items-center justify-center px-[2px]"},yt={class:"text-[13em] font-['SFPRO'] mt-[.2em] font-[500] text-black fixtext"},wt={class:"w-full max-h-[53em] overflow-auto no-scrollbar px-[4em] py-[5em] flex items-start"},bt={class:"text-[11em] font-['SFPRO'] font-[400] text-[#000000A6] w-full leading-[1.3] text-center"},_t={class:"w-full h-[43em] flex items-center justify-center mt-[6px] border-t-[1px] border-white"},kt={class:"w-[93%] h-[65%] flex"},Ct={class:"w-[50%] h-full flex items-center"},$t=["src"],St={style:{"letter-spacing":"-0.23px"},class:"text-[11em] font-['SFPRO'] ml-[.9em] font-[500] text-black fixtext"},Pt={class:"w-[50%] h-full flex items-center justify-end"},jt=["onClick","src"],Ft=["onClick","src"],Et=["onClick","src"],Lt={key:1,class:"w-full h-full flex flex-col items-center justify-start"},Tt=["src"],Dt={__name:"Home",props:{show:{type:Boolean,default:!1}},emits:["changepage"],setup(G,{emit:H}){const r=ce(),m=ye(),{PhoneData:k,appConfig:$}=ue(r),{ScrollPage:N}=ue(m),{t:n}=de(),w=_=>{_.style.opacity=0,_.style.transform="translateY(15px)"},M=(_,u)=>{const ee=(parseInt(_.dataset.index)||0)*50;setTimeout(()=>{_.style.transition="opacity 0.3s ease, transform 0.3s ease",_.style.opacity=1,_.style.transform="translateY(0)",setTimeout(u,300)},ee)},W=_=>{_.style.transition=null,_.style.opacity=null,_.style.transform=null},L=[De],I=[fe,me],S=y("all"),V=y(null),D=_=>{var u;if(S.value=_,V.value){const ee=(((u=r.appConfig.SellyConfig)==null?void 0:u.Categories)||[]).findIndex(le=>le.name===_);ee!==-1&&V.value.slideTo(ee)}};y(0);const B={freeMode:{enabled:!0,sticky:!1,momentum:!0,momentumRatio:.5,momentumVelocityRatio:.5}},O=H,T=_=>{O("changepage",_)},R=G,j=y(null),F=y(0),E=y("top"),v=()=>{if(!j.value)return;const _=j.value,u=_.scrollTop,ae=_.scrollHeight,ee=_.clientHeight,le=ae-ee;F.value=le>0?u/le:0,u<=5?E.value="top":u>=le-5?E.value="bottom":E.value="middle",u+ee>=ae-200&&m.LoadMoreSelly()},l=()=>{j.value?(j.value.addEventListener("scroll",v),setTimeout(()=>U(this,null,function*(){yield xe(),v()}),100)):console.log("scrollContainer ref not found")};ke(()=>{R.show&&l()}),we(()=>R.show,_=>{_?xe(()=>{l()}):j.value&&j.value.removeEventListener("scroll",v)}),Pe(()=>{j.value&&j.value.removeEventListener("scroll",v)});const o=_=>{const u=r.isVideo(_);r.setPhotoViewerData({image:_,type:u?"video":"image"})},g=he(()=>S.value==="all"?N.value.selly.loadedData:N.value.selly.loadedData.filter(_=>_.category===S.value)),h=(_,u)=>{_.currentIndex=u.activeIndex},x=y(!1),i=()=>U(this,null,function*(){const _=x.value,u=yield J("DELETE_POST",_);u&&u.success?r.TriggerNotification({appname:"selly",header:n("selly.title"),message:n("selly.postDeletedSuccess")}):r.TriggerNotification({appname:"selly",header:n("selly.title"),message:n(u==null?void 0:u.message)||(u==null?void 0:u.message)||n("selly.failedDeletePost")}),x.value=!1}),c=()=>{x.value=!1},d=_=>U(this,null,function*(){if(_.length<=0)return;let u=yield J("CALL_PLAYER",{phoneNumber:_});u&&u.success?r.StartCall(u.data):r.TriggerNotification({appname:"message",header:n("message.title"),message:n(u==null?void 0:u.message)||(u==null?void 0:u.message)||n("selly.failedInitiateCall")})}),Z=y(!1),ne=y({name:"",target_phone:""}),be=_=>U(this,null,function*(){let u=yield J("GET_CONTACT_INFO",{phoneNumber:_});u&&u.success?(ne.value={name:u.contact.name,target_phone:_},Z.value=!0):r.TriggerNotification({appname:"message",header:n("message.title"),message:n(u==null?void 0:u.message)||(u==null?void 0:u.message)||n("selly.failedGetContactInfo")})});return(_,u)=>{var le,$e;const ae=ve("motion"),ee=ve("motion-slide-left");return s(),a(z,null,[Y(je,{show:Z.value,onCancel:u[0]||(u[0]=f=>Z.value=!1),recipientData:ne.value},null,8,["show","recipientData"]),e("img",{src:t(p)["selly/mainbg.png"],class:"w-full h-full absolute",alt:""},null,8,Ne),R.show?(s(),a("div",Ae,[x.value?(s(),q(_e,{key:0,onCancel:c,onSubmit:i,header:t(n)("general.areYouSure"),label:t(n)("selly.confirmDeleteOffer"),buttons:{cancel:t(n)("general.cancel"),submit:t(n)("general.delete")}},null,8,["header","label","buttons"])):P("",!0),Q(e("img",{src:t(p)["selly/add.svg"],onClick:u[1]||(u[1]=f=>T("newpost")),class:"absolute bottom-[11em] right-[13em] h-[50em] z-[10] cursor-pointer anim-hover-1",alt:"",initial:{opacity:0,scale:.5},enter:{opacity:1,scale:1,transition:{delay:200,duration:400,type:"spring",stiffness:200,damping:15}}},null,8,Me),[[ae]]),e("div",Ve,[e("div",ze,[e("div",Be,[Q((s(),a("div",Ye,[e("span",qe,[ge(b(t(n)("selly.welcomeTo"))+" ",1),u[5]||(u[5]=e("br",null,null,-1)),ge(" "+b(t(n)("selly.title")),1)])])),[[ee]]),e("div",He,[e("div",{onClick:u[2]||(u[2]=f=>T("search")),class:"h-full rounded-full mr-[7em] aspect-square border-[1px] border-white/40 p-[2px] cursor-pointer anim-hover-1"},[e("img",{src:t(p)["selly/search.svg"],class:"h-full aspect-square rounded-full object-cover object-top",alt:""},null,8,Ue)]),e("div",{onClick:u[3]||(u[3]=f=>T("myoffers")),class:"h-full rounded-full aspect-square ml-[1em] border-[1px] border-white/40 p-[2px] cursor-pointer anim-hover-1"},[e("img",{src:t(r).GetPlayerPhotoByNumber(t(r).PhoneData.phone_number),class:"h-full aspect-square rounded-full object-cover object-center",alt:""},null,8,Ze)])])])])]),e("div",Ge,[(($e=(le=t($).SellyConfig)==null?void 0:le.Categories)==null?void 0:$e.length)>0?(s(),q(t(re),{key:0,modules:L,"slides-per-view":"auto","space-between":12,"free-mode":B.freeMode,"grab-cursor":!0,resistance:!0,"resistance-ratio":.85,class:"w-full h-full !pr-[1%]",onSwiper:u[4]||(u[4]=f=>V.value=f)},{default:A(()=>[(s(!0),a(z,null,K(t($).SellyConfig.Categories,(f,pe)=>(s(),q(t(ie),{key:pe,class:"!w-auto"},{default:A(()=>[e("div",{class:C([{"bg-yellow-400 shadow-[0px_4px_22.100000381469727px_0px_rgba(236,196,26,0.32)]":S.value==f.name,"ml-[20em]":pe==0},"h-[47%] min-h-[30em] px-[7em] bg-white/5 rounded-full anim-hover-1 flex items-center justify-start cursor-pointer"]),onClick:te=>D(f.name)},[S.value!==f.name?(s(),a("img",{key:0,src:f.homecategorydeactiveicon.startsWith("selly/")?t(p)[f.homecategorydeactiveicon]:f.homecategorydeactiveicon,class:"h-[20em] aspect-square rounded-full",alt:""},null,8,Je)):(s(),a("img",{key:1,src:f.homecategoryactiveicon.startsWith("selly/")?t(p)[f.homecategoryactiveicon]:f.homecategoryactiveicon,class:"h-[20em] aspect-square ml-[-1em] rounded-full",alt:""},null,8,Qe)),e("span",{class:C([S.value==f.name?"text-black":"text-white","text-[12em] font-['SFPRO'] ml-[12%] pr-[1em] font-[400] whitespace-nowrap"])},b(t(n)(f.label)),3)],10,We)]),_:2},1024))),128))]),_:1},8,["free-mode"])):P("",!0)]),e("div",{class:C(["w-full h-[calc(100%-26%)] px-[5%] overflow-auto no-scrollbar",[E.value==="top"?"mask-bottom":"",E.value==="middle"?"mask-both":"",E.value==="bottom"?"mask-top":""]]),ref_key:"scrollContainer",ref:j},[g.value.length>0?(s(),q(Ce,{key:0,appear:"",onBeforeEnter:w,onEnter:M,onAfterEnter:W,css:!1,class:"w-full h-full flex gap-[7em] flex-wrap content-start",tag:"div"},{default:A(()=>[(s(!0),a(z,null,K(g.value,(f,pe)=>(s(),a("div",{key:f.id,"data-index":pe,class:C(["w-full inline-flex flex-wrap content-start overflow-hidden first:mt-[5px] mt-[10px]",f.photos&&f.photos.length<=0?"min-h-[18%]":""]),style:oe({backgroundImage:f.photos&&f.photos.length>0?`url(${t(p)["selly/adsbg.png"]})`:`url(${t(p)["selly/adssmall.png"]})`,backgroundSize:"100% 100%"})},[f.photos&&f.photos.length>0?(s(),a("div",Xe,[f.photos.length>1?(s(),a(z,{key:0},[e("div",{class:C([`image-swiper-prev-${f.id}`,"w-[13%] h-full absolute left-0 flex items-center justify-center z-10"])},[e("img",{src:t(p)["selly/arrow.svg"],class:"h-[15%] cursor-pointer",alt:""},null,8,et)],2),e("div",{class:C([`image-swiper-next-${f.id}`,"w-[13%] h-full absolute right-0 flex items-center justify-center z-10"])},[e("img",{src:t(p)["selly/arrow.svg"],class:"h-[15%] rotate-180 cursor-pointer",alt:""},null,8,tt)],2)],64)):P("",!0),f.category!=="ads"?(s(),a("div",lt,[e("div",st,[e("img",{src:t(p)["selly/pricebar.svg"],class:"h-full w-full absolute",alt:""},null,8,ot),e("span",nt,"$ "+b(f.price.toLocaleString()),1)])])):P("",!0),f.photos.length>1?(s(),a("div",at,[e("div",it,[e("img",{src:t(p)["selly/imagecount.svg"],class:"h-full w-full absolute",alt:""},null,8,rt),e("span",ct,b(f.currentIndex+1)+"/"+b(f.photos.length),1)])])):P("",!0),e("div",ut,[Y(t(re),{modules:f.photos.length>1?I:[],"slides-per-view":1,"space-between":10,navigation:f.photos.length>1?{nextEl:`.image-swiper-next-${f.id}`,prevEl:`.image-swiper-prev-${f.id}`}:!1,"grab-cursor":f.photos.length>1,"allow-touch-move":f.photos.length>1,onSlideChange:te=>h(f,te),class:"w-full h-full overflow-hidden"},{default:A(()=>[(s(!0),a(z,null,K(f.photos,(te,Ee)=>(s(),q(t(ie),{key:Ee},{default:A(()=>[t(r).isVideo(te)?(s(),a("div",{key:1,onClick:Le=>o(f.photos[f.currentIndex]),class:"w-full h-full relative bg-black"},[e("video",{class:"w-full h-full object-cover",src:te,preload:"metadata",muted:""},"Your browser does not support the video tag.",8,mt),e("div",pt,[e("div",ht,[e("img",{src:t(p)["photos/play.svg"],class:"h-[80%]",alt:""},null,8,vt)])])],8,ft)):(s(),a("img",{key:0,onClick:Le=>o(f.photos[f.currentIndex]),src:te,alt:"",class:"h-full object-cover object-top w-full"},null,8,dt))]),_:2},1024))),128))]),_:2},1032,["modules","navigation","grab-cursor","allow-touch-move","onSlideChange"])])])):P("",!0),f.photos&&f.photos.length<=0?(s(),a("div",gt)):P("",!0),e("div",xt,[e("span",yt,b(f.title),1)]),e("div",wt,[e("span",bt,b(f.description),1)]),e("div",_t,[e("div",kt,[e("div",Ct,[e("img",{src:t(r).GetPlayerPhotoByNumber(f.phone_number),class:"h-full aspect-square rounded-full object-cover object-center",alt:""},null,8,$t),e("span",St,b(f.playername),1)]),e("div",Pt,[f.allowmessage?(s(),a("img",{key:0,onClick:te=>be(f.phone_number),src:t(p)["selly/messageicon.png"],class:"h-full aspect-square rounded-full mr-[4em] cursor-pointer anim-hover-1",alt:""},null,8,jt)):P("",!0),f.allowcalls?(s(),a("img",{key:1,onClick:te=>d(f.phone_number),src:t(p)["selly/callicon.png"],class:"h-full aspect-square ml-[3px] rounded-full cursor-pointer anim-hover-1",alt:""},null,8,Ft)):P("",!0),f.phone_number===t(r).PhoneData.phone_number||t(r).PlayerIsAdmin?(s(),a("img",{key:2,onClick:te=>x.value=f.id,src:t(p)["selly/deleteicon.png"],class:"h-full aspect-square ml-[6em] rounded-full cursor-pointer anim-hover-1",alt:""},null,8,Et)):P("",!0)])])])],14,Ke))),128)),u[6]||(u[6]=e("div",{class:"w-full h-[250px]"},null,-1))]),_:1,__:[6]})):(s(),a("div",Lt,[e("img",{src:t(p)["selly/search3.svg"],class:"h-[30%] mt-[80em]",alt:""},null,8,Tt),u[7]||(u[7]=e("p",{style:{"letter-spacing":"-0.28px"},class:"text-[12em] font-['SFPRO'] text-white/20 font-[400] leading-[100%] mt-[2em]"},"No post found.",-1))]))],2)])):P("",!0)],64)}}},Ot=Se(Dt,[["__scopeId","data-v-dec2696f"]]),It={key:0,class:"w-full h-full absolute z-[2]"},Rt={class:"w-full h-[92em] flex items-end justify-center border-b-[1px] border-white/10",initial:{opacity:0},enter:{opacity:1,transition:{delay:100,duration:400}}},Nt={class:"w-[87%] flex items-center mb-[1em] h-[50%]"},At={class:"w-full h-[65%] flex rounded-full justify-between overflow-hidden"},Mt={class:"w-[85%] h-full rounded-full bg-white/10 flex"},Vt={class:"w-[80%] h-full flex items-center justify-center"},zt=["placeholder"],Bt={class:"w-full h-[calc(100%-110px)] flex flex-col items-center justify-center"},Yt=["data-index"],qt={key:0,class:"w-full h-[132em] flex items-end justify-center px-[2px] pt-[2px] overflow-hidden relative"},Ht=["src"],Ut=["src"],Zt={key:0,class:"w-full h-[12em] absolute top-0 flex items-center justify-center z-10"},Gt={class:"w-[38%] h-full flex items-center justify-center relative mt-[3em]"},Wt=["src"],Jt={class:"text-[10em] font-['SFPRO'] font-[500] text-black absolute text-center fixtext w-full px-[8px]"},Qt={class:"w-full h-[12em] absolute bottom-0 flex items-center justify-center z-10"},Kt={class:"w-[38%] h-full flex items-center justify-center relative mt-[3em]"},Xt=["src"],el={class:"text-[8em] font-['SFPRO'] font-[500] text-black absolute text-start fixtext"},tl={class:"w-full h-[130em] overflow-hidden rounded-[15em]"},ll=["onClick","src"],sl=["onClick"],ol=["src"],nl={class:"absolute inset-0 flex items-center justify-center pointer-events-none"},al={class:"w-[35em] h-[35em] rounded-full flex items-center justify-center group-hover:scale-110 transition-transform duration-200"},il=["src"],rl={key:1,class:"w-full h-[12px]"},cl={class:"w-full h-[25em] flex items-center justify-center px-[2px]"},ul={class:"text-[13em] font-['SFPRO'] font-[500] text-black fixtext"},dl={class:"w-full max-h-[53em] overflow-auto no-scrollbar px-[2px] py-[5em] flex items-start"},fl={class:"text-[11em] font-['SFPRO'] font-[400] text-[#000000A6] w-full leading-[1] text-center"},ml={class:"w-full h-[43em] flex items-center justify-center mt-[6px] border-t-[1px] border-white"},pl={class:"w-[93%] h-[65%] flex"},hl={class:"w-[50%] h-full flex items-center"},vl=["src"],gl={style:{"letter-spacing":"-0.23px"},class:"text-[11em] font-['SFPRO'] ml-[.9em] font-[500] text-black fixtext"},xl={class:"w-[50%] h-full flex items-center justify-end"},yl=["onClick","src"],wl=["onClick","src"],bl=["onClick","src"],_l={key:1,class:"w-full h-full flex flex-col items-center justify-start"},kl=["src"],Cl={style:{"letter-spacing":"-0.28px"},class:"text-[12em] font-['SFPRO'] text-white/20 font-[400] leading-[100%] mt-[2em]"},$l={__name:"Search",props:{show:{type:Boolean,default:!1}},emits:["changepage"],setup(G,{emit:H}){const{t:r}=de(),m=ce();ye();const k=[fe,me],$=l=>{l.style.opacity=0,l.style.transform="translateY(15px)"},N=(l,o)=>{const h=(parseInt(l.dataset.index)||0)*50;setTimeout(()=>{l.style.transition="opacity 0.3s ease, transform 0.3s ease",l.style.opacity=1,l.style.transform="translateY(0)",setTimeout(o,300)},h)},n=l=>{l.style.transition=null,l.style.opacity=null,l.style.transform=null},w=H,M=l=>{w("changepage",l)},W=G,L=y(""),I=y(!1),S=y([]),V=(l,o)=>{l.currentIndex=o.activeIndex},D=l=>{const o=m.isVideo(l);m.setPhotoViewerData({image:l,type:o?"video":"image"})},B=Oe(l=>U(this,null,function*(){if(l.length>=2){I.value=!0;let o=yield J("SEARCH_SELLY_POST",{query:l});o&&o.success?S.value=o.data:(S.value=[],m.TriggerNotification({appname:"selly",header:r("selly.title"),message:r(o==null?void 0:o.message)||(o==null?void 0:o.message)||r("selly.searchFailed")})),I.value=!1}else l===""&&(S.value=[])}),300);we(()=>L.value,(l,o)=>{B(l)},{immediate:!1});const O=y(!1),T=()=>U(this,null,function*(){const l=O.value,o=yield J("DELETE_POST",l);o&&o.success?(S.value=S.value.filter(g=>g.id!==l),m.TriggerNotification({appname:"selly",header:r("selly.title"),message:r("selly.postDeletedSuccess")})):m.TriggerNotification({appname:"selly",header:r("selly.title"),message:r(o==null?void 0:o.message)||(o==null?void 0:o.message)||r("selly.failedDeletePost")}),O.value=!1}),R=()=>{O.value=!1},j=l=>U(this,null,function*(){if(l.length<=0)return;let o=yield J("CALL_PLAYER",{phoneNumber:l});o&&o.success?m.StartCall(o.data):m.TriggerNotification({appname:"message",header:r("message.title"),message:r(o==null?void 0:o.message)||(o==null?void 0:o.message)||r("selly.failedInitiateCall")})}),F=y(!1),E=y({name:"",target_phone:""}),v=l=>U(this,null,function*(){let o=yield J("GET_CONTACT_INFO",{phoneNumber:l});o&&o.success?(E.value={name:o.contact.name,target_phone:l},F.value=!0):m.TriggerNotification({appname:"message",header:r("message.title"),message:r(o==null?void 0:o.message)||(o==null?void 0:o.message)||r("selly.failedGetContactInfo")})});return(l,o)=>{const g=ve("motion");return s(),a(z,null,[Y(je,{show:F.value,onCancel:o[0]||(o[0]=h=>F.value=!1),recipientData:E.value},null,8,["show","recipientData"]),W.show?(s(),a("div",It,[O.value?(s(),q(_e,{key:0,onCancel:R,onSubmit:T,header:t(r)("general.areYouSure"),label:t(r)("selly.confirmDeleteOffer"),buttons:{cancel:t(r)("general.cancel"),submit:t(r)("general.delete")}},null,8,["header","label","buttons"])):P("",!0),Q((s(),a("div",Rt,[e("div",Nt,[e("div",At,[e("div",Mt,[o[3]||(o[3]=e("div",{class:"w-[15%] h-full flex text-white/20 items-center justify-center"},[e("svg",{width:"50%",viewBox:"0 0 22 22",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[e("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M9.75004 0.75C4.77943 0.75 0.75 4.77944 0.75 9.75C0.75 14.7206 4.77943 18.75 9.75004 18.75C11.8749 18.75 13.8279 18.0135 15.3676 16.7819L19.8357 21.25L21.25 19.8358L16.7818 15.3677C18.0135 13.8281 18.75 11.875 18.75 9.75C18.75 4.77944 14.7205 0.75 9.75004 0.75ZM2.75 9.75C2.75 5.88401 5.884 2.75 9.75004 2.75C13.6159 2.75 16.75 5.88401 16.75 9.75C16.75 13.616 13.6159 16.75 9.75004 16.75C5.884 16.75 2.75 13.616 2.75 9.75Z",fill:"currentColor"})])],-1)),e("div",Vt,[Q(e("input",{type:"text","onUpdate:modelValue":o[1]||(o[1]=h=>L.value=h),class:"w-full h-full bg-transparent outline-none text-[11em] font-['SFPRO'] text-white/60 placeholder:text-white/30",placeholder:t(r)("selly.searchPlaceholder")},null,8,zt),[[se,L.value]])])]),e("div",{onClick:o[2]||(o[2]=h=>M("home")),class:"w-[11%] h-full text-white/40 rounded-full bg-white/10 flex anim-hover-1 items-center justify-center cursor-pointer"},o[4]||(o[4]=[e("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[e("path",{d:"M1.91394 15.5L7.999 9.4141L14.085 15.5L15.499 14.0859L9.4131 8L15.5 1.91393L14.0861 0.5L7.999 6.5859L1.91309 0.5L0.499023 1.91406L6.585 8L0.500003 14.0861L1.91394 15.5Z",fill:"currentColor"})],-1)]))])])])),[[g]]),e("div",Bt,[S.value.length>0?(s(),q(Ce,{key:0,appear:"",onBeforeEnter:$,onEnter:N,onAfterEnter:n,css:!1,class:"w-full h-full flex flex-wrap content-start px-[20px]",tag:"div"},{default:A(()=>[(s(!0),a(z,null,K(S.value,(h,x)=>(s(),a("div",{key:h.id,"data-index":x,class:C(["w-full inline-flex flex-wrap content-start overflow-hidden first:mt-[5px] mt-[10px]",h.photos&&h.photos.length<=0?"h-[100em]":""]),style:oe({backgroundImage:h.photos&&h.photos.length>0?`url(${t(p)["selly/adsbg.png"]})`:`url(${t(p)["selly/adssmall.png"]})`,backgroundSize:"100% 100%"})},[h.photos&&h.photos.length>0?(s(),a("div",qt,[e("div",{class:C([`image-swiper-prev-${h.id}`,"w-[13%] h-full absolute left-0 flex items-center justify-center z-10"])},[e("img",{src:t(p)["selly/arrow.svg"],class:"h-[15%] cursor-pointer",alt:""},null,8,Ht)],2),e("div",{class:C([`image-swiper-next-${h.id}`,"w-[13%] h-full absolute right-0 flex items-center justify-center z-10"])},[e("img",{src:t(p)["selly/arrow.svg"],class:"h-[15%] rotate-180 cursor-pointer",alt:""},null,8,Ut)],2),h.category!=="ads"?(s(),a("div",Zt,[e("div",Gt,[e("img",{src:t(p)["selly/pricebar.svg"],class:"h-full w-full absolute",alt:""},null,8,Wt),e("span",Jt,"$ "+b(h.price),1)])])):P("",!0),e("div",Qt,[e("div",Kt,[e("img",{src:t(p)["selly/imagecount.svg"],class:"h-full w-full absolute",alt:""},null,8,Xt),e("span",el,b(h.currentIndex+1)+"/"+b(h.photos.length),1)])]),e("div",tl,[Y(t(re),{modules:k,"slides-per-view":1,"space-between":10,navigation:{nextEl:`.image-swiper-next-${h.id}`,prevEl:`.image-swiper-prev-${h.id}`},"grab-cursor":!0,onSlideChange:i=>V(h,i),class:"w-full h-full overflow-hidden"},{default:A(()=>[(s(!0),a(z,null,K(h.photos,(i,c)=>(s(),q(t(ie),{key:c},{default:A(()=>[t(m).isVideo(i)?(s(),a("div",{key:1,onClick:d=>D(h.photos[h.currentIndex]),class:"w-full h-full relative bg-black"},[e("video",{class:"w-full h-full object-cover",src:i,preload:"metadata",muted:""},"Your browser does not support the video tag.",8,ol),e("div",nl,[e("div",al,[e("img",{src:t(p)["photos/play.svg"],class:"h-[80%]",alt:""},null,8,il)])])],8,sl)):(s(),a("img",{key:0,onClick:d=>D(h.photos[h.currentIndex]),src:i,alt:"",class:"h-full object-cover object-center w-full"},null,8,ll))]),_:2},1024))),128))]),_:2},1032,["navigation","onSlideChange"])])])):P("",!0),h.photos&&h.photos.length<=0?(s(),a("div",rl)):P("",!0),e("div",cl,[e("span",ul,b(h.title),1)]),e("div",dl,[e("span",fl,b(h.description),1)]),e("div",ml,[e("div",pl,[e("div",hl,[e("img",{src:t(m).GetPlayerPhotoByNumber(h.phone_number),class:"h-full aspect-square rounded-full object-cover object-center",alt:""},null,8,vl),e("span",gl,b(h.playername),1)]),e("div",xl,[h.allowmessage?(s(),a("img",{key:0,onClick:i=>v(h.phone_number),src:t(p)["selly/messageicon.png"],class:"h-full aspect-square rounded-full mr-[4em] cursor-pointer anim-hover-1",alt:""},null,8,yl)):P("",!0),h.allowcalls?(s(),a("img",{key:1,onClick:i=>j(h.phone_number),src:t(p)["selly/callicon.png"],class:"h-full aspect-square ml-[3px] rounded-full cursor-pointer anim-hover-1",alt:""},null,8,wl)):P("",!0),h.phone_number===t(m).PhoneData.phone_number||t(m).PlayerIsAdmin?(s(),a("img",{key:2,onClick:i=>O.value=h.id,src:t(p)["selly/deleteicon.png"],class:"h-full aspect-square ml-[6em] rounded-full cursor-pointer anim-hover-1",alt:""},null,8,bl)):P("",!0)])])])],14,Yt))),128)),o[5]||(o[5]=e("div",{class:"w-full h-[250px]"},null,-1))]),_:1,__:[5]})):(s(),a("div",_l,[e("img",{src:t(p)["selly/search3.svg"],class:"h-[20%] mt-[180em]",alt:""},null,8,kl),e("p",Cl,b(t(r)("selly.searchEmptyState")),1)]))])])):P("",!0)],64)}}},Sl={class:"w-full mt-[20em] h-full"},Pl={class:"w-full h-[80em] flex items-center justify-center border-b-[1px] border-black/30"},jl={class:"w-full h-[30em] mt-[16em] flex justify-between items-center"},Fl={class:"text-[16em] font-['SFPRO'] font-[400] text-black text-start fixtext"},El=["src"],Ll={class:"w-full h-[54em] flex items-end relative"},Tl=["src"],Dl=["src"],Ol={key:0,class:"absolute top-[70%] left-0 w-full border-[1.2em] border-t-0 mt-[16em] border-black rounded-b-[10em] overflow-hidden z-10"},Il=["onClick"],Rl=["src"],Nl={class:"text-[11em] font-['SFPRO'] font-[400] ml-[1em] text-black"},Al={class:"w-full h-[147em] flex items-end"},Ml=["src"],Vl=["src"],zl={class:"w-full h-[12px] absolute bottom-[12px] flex items-center justify-center z-10"},Bl={class:"w-[38%] h-full flex items-center justify-center relative mt-[3px]"},Yl=["src"],ql={class:"text-[8px] font-['SFPRO'] font-[500] text-black absolute text-start fixtext"},Hl={class:"text-[10em] font-['SFPRO'] font-[500] text-[#FF7E7E] mt-[3px] fixtext cursor-pointer anim-hover-1"},Ul=["src"],Zl={key:1,class:"w-full h-full relative bg-black"},Gl=["src"],Wl={class:"absolute inset-0 flex items-center justify-center pointer-events-none"},Jl={class:"w-[35px] h-[35px] rounded-full flex items-center justify-center group-hover:scale-110 transition-transform duration-200"},Ql=["src"],Kl=["src"],Xl={class:"text-[11em] font-['SFPRO'] font-[400] ml-[5px] text-black mt-[1em]"},es={class:"w-full h-[50em] flex items-end"},ts=["disabled","placeholder"],ls={class:"w-full h-[97em] flex items-end"},ss=["disabled","placeholder"],os={class:"w-full h-[53em] flex items-end"},ns=["disabled","placeholder"],as={class:"w-full h-[45em] flex items-end"},is={class:"w-full h-[70%] flex justify-between"},rs={class:"text-[12em] font-['SFPRO'] font-[400] text-start fixtext"},cs={class:"text-[12em] font-['SFPRO'] font-[400] text-start fixtext"},us={class:"w-full h-[54em] mt-[20em] anim-hover-1 flex items-end"},ds={class:"text-[12em] font-['SFPRO'] font-[400] text-black text-start fixtext"},fs={__name:"NewPost",props:{show:{type:Boolean,default:!1}},emits:["changepage"],setup(G,{emit:H}){const r=ce(),{appConfig:m}=ue(r),{t:k}=de(),$=y(m.value.SellyConfig.Categories.filter(i=>i.name!=="all")),N=[fe,me],n=y(!1),w=y(null),M=()=>{n.value=!n.value},W=i=>{w.value=i,n.value=!1},L=()=>{n.value=!1},I=y(0),S=i=>{I.value=i.activeIndex},V=H,D=i=>{w.value=null,F.value=[],E.value="",v.value="",l.value="",T.value=!1,R.value=!1,I.value=0,o.value=!1,n.value=!1,V("changepage",i)},B=G,O=y(!1),T=y(!0),R=y(!0),j=i=>{F.value=i},F=y([]),E=y(""),v=y(""),l=y(""),o=y(!1),g=()=>U(this,null,function*(){if(!w.value)return;if(E.value.trim()===""){r.TriggerNotification({appname:"selly",header:k("selly.title"),message:k("selly.enterTitle")});return}if(v.value.trim()===""){r.TriggerNotification({appname:"selly",header:k("selly.title"),message:k("selly.enterDescription")});return}const i={category:w.value.name,title:E.value,description:v.value};let c=yield J("SELLY_VALIDATE_POST",i);if(!c||!c.success){r.TriggerNotification({appname:"selly",header:k("selly.title"),message:k(c==null?void 0:c.message)||(c==null?void 0:c.message)||k("selly.validationFailed")});return}o.value=!0}),h=()=>{F.value.length!==0&&(F.value.splice(I.value,1),I.value>=F.value.length&&(I.value=F.value.length-1))},x=()=>U(this,null,function*(){const i={category:w.value.name,photos:F.value,title:E.value,description:v.value,price:Number(l.value),allowCalls:T.value,allowMessages:R.value};let c=yield J("SELLY_POST_AD",i);c&&c.success?(w.value=null,F.value=[],E.value="",v.value="",l.value="",T.value=!1,R.value=!1,I.value=0,o.value=!1,V("changepage","home")):r.TriggerNotification({appname:"selly",header:k("selly.title"),message:k(c.message)||c.message||k("selly.failedPostOffer")})});return(i,c)=>(s(),a(z,null,[Y(Ie,{show:o.value&&w.value,onClose:c[0]||(c[0]=d=>o.value=!1),onPaided:x,reference:"Selly Fee",amount:t(m).SellyConfig.PostPrice,taxRate:t(m).SellyConfig.PostTax},null,8,["show","amount","taxRate"]),Y(Fe,{show:O.value,onCancel:c[1]||(c[1]=d=>O.value=!1),onSelectPhoto:j,multiselect:!0},null,8,["show"]),B.show?(s(),a("div",{key:0,class:"w-full h-full absolute z-[2] px-[20em] bg-gray-400/90",onClick:L},[e("div",Sl,[e("div",Pl,[e("div",jl,[e("span",Fl,b(t(k)("selly.newPost")),1),e("img",{onClick:c[2]||(c[2]=d=>D("home")),src:t(p)["selly/close2.svg"],class:"h-[90%] cursor-pointer anim-hover-1",alt:""},null,8,El)])]),e("div",Ll,[e("div",{onClick:X(M,["stop"]),class:C(["w-full h-[70%] bg-black/10 border-[1.2em] border-black flex items-center justify-between px-[7em] cursor-pointer hover:bg-black/20 transition-all",n.value?"rounded-t-[10em] border-b-0":"rounded-[10em]"]),style:oe({backgroundColor:w.value?w.value.color:""})},[w.value?(s(),a("img",{key:0,src:w.value.newposticon.startsWith("selly/")?t(p)[w.value.newposticon]:w.value.newposticon,class:"h-[22em] rounded-full absolute",alt:""},null,8,Tl)):P("",!0),e("span",{class:C([[w.value?"ml-[2.5em]":"",(w.value,"text-black")],"text-[11em] font-['SFPRO'] font-[400] text-start fixtext"])},b(w.value?t(k)(w.value.label):t(k)("selly.selectCategory")),3),e("img",{src:t(p)["selly/dropdown.svg"],class:C(["h-[30%] transition-transform duration-200",{"rotate-180":n.value}]),alt:""},null,10,Dl)],6),n.value?(s(),a("div",Ol,[c[14]||(c[14]=e("div",{class:"w-full h-[1em] bg-black -mt-[1px]"},null,-1)),(s(!0),a(z,null,K($.value,(d,Z)=>(s(),a("div",{key:d.name,onClick:X(ne=>W(d),["stop"]),class:C(["w-full px-[7em] py-[6em] cursor-pointer transition-colors flex items-center",Z!==$.value.length-1?"border-b border-black/20":""]),style:oe({backgroundColor:d.color})},[e("img",{src:d.homecategorydeactiveicon.startsWith("selly/")?t(p)[d.newposticon]:d.newposticon,class:"h-[22em] rounded-full",alt:""},null,8,Rl),e("span",Nl,b(t(k)(d.label)),1)],14,Il))),128))])):P("",!0)]),e("div",Al,[e("div",{class:C(["w-full h-[90%] relative bg-black/20 cursor-pointer anim-hover-1 rounded-[15px] border-[1.5em] overflow-hidden border-black transition-opacity flex flex-col items-center justify-center",{"opacity-20":!w.value}])},[F.value.length>0?(s(),a("div",{key:0,onClick:c[6]||(c[6]=d=>O.value=!0),class:"w-full h-full"},[e("div",{onClick:c[3]||(c[3]=X(()=>{},["stop"])),class:"image-swiper-prev w-[13%] h-full absolute left-0 flex items-center justify-center z-10"},[e("img",{src:t(p)["selly/arrow.svg"],class:"h-[15%] cursor-pointer",alt:""},null,8,Ml)]),e("div",{onClick:c[4]||(c[4]=X(()=>{},["stop"])),class:"image-swiper-next w-[13%] h-full absolute right-0 flex items-center justify-center z-10"},[e("img",{src:t(p)["selly/arrow.svg"],class:"h-[15%] rotate-180 cursor-pointer",alt:""},null,8,Vl)]),e("div",zl,[e("div",Bl,[e("img",{src:t(p)["selly/imagecount.svg"],class:"h-full w-full absolute",alt:""},null,8,Yl),e("span",ql,b(I.value+1)+"/"+b(F.value.length),1)])]),e("div",{onClick:[c[5]||(c[5]=X(()=>{},["stop"])),h],class:"w-full h-[15em] absolute bottom-[0px] flex items-center justify-center z-10 bg-black"},[e("span",Hl,b(t(k)("selly.deletePhoto")),1)]),Y(t(re),{modules:N,"slides-per-view":1,"space-between":10,navigation:{nextEl:".image-swiper-next",prevEl:".image-swiper-prev"},"grab-cursor":!0,onSlideChange:S,class:"w-full h-full overflow-hidden"},{default:A(()=>[(s(!0),a(z,null,K(F.value,(d,Z)=>(s(),q(t(ie),{key:Z},{default:A(()=>[t(r).isVideo(d)?(s(),a("div",Zl,[e("video",{class:"w-full h-full object-cover",src:d,preload:"metadata",muted:""},"Your browser does not support the video tag.",8,Gl),e("div",Wl,[e("div",Jl,[e("img",{src:t(p)["photos/play.svg"],class:"h-[80%]",alt:""},null,8,Ql)])])])):(s(),a("img",{key:0,src:d,alt:"",class:"h-full object-cover object-center w-full rounded-[6em]"},null,8,Ul))]),_:2},1024))),128))]),_:1})])):(s(),a("div",{key:1,onClick:c[7]||(c[7]=d=>O.value=!0),class:"w-full h-full flex flex-col items-center justify-center"},[e("img",{src:t(p)["selly/uploadphoto.svg"],class:"h-[30%]",alt:""},null,8,Kl),e("span",Xl,b(t(k)("selly.clickUploadPhotos")),1)]))],2)]),e("div",es,[e("div",{class:C(["w-full h-[70%] bg-black/10 rounded-[10em] border-[1.5em] border-black transition-opacity",{"opacity-20":!w.value}])},[Q(e("input",{type:"text","onUpdate:modelValue":c[8]||(c[8]=d=>E.value=d),disabled:!w.value,class:"w-full h-full bg-transparent outline-none text-[12em] text-center font-['SFPRO'] text-black placeholder:text-black/60 disabled:cursor-not-allowed",placeholder:t(k)("selly.postTitle")},null,8,ts),[[se,E.value]])],2)]),e("div",ls,[e("div",{class:C(["w-full h-[84%] bg-black/10 rounded-[10em] border-[1.5em] border-black transition-opacity",{"opacity-20":!w.value}])},[Q(e("textarea",{maxlength:800,disabled:!w.value,"onUpdate:modelValue":c[9]||(c[9]=d=>v.value=d),style:{resize:"none","white-space":"pre-wrap","word-wrap":"break-word","overflow-wrap":"break-word"},class:"w-full h-full bg-transparent text-[11em] font-['SFPRO'] text-black placeholder:text-black/60 p-[1em] font-[400] leading-[100%] fixtext outline-none",placeholder:t(k)("selly.description")},null,8,ss),[[se,v.value]])],2)]),e("div",os,[e("div",{class:C(["w-full h-[70%] bg-black/10 rounded-[10em] border-[1.5em] border-black transition-opacity",{"opacity-20":!w.value}])},[Q(e("input",{type:"tel","onUpdate:modelValue":c[10]||(c[10]=d=>l.value=d),onInput:c[11]||(c[11]=d=>l.value=l.value.replace(/[^0-9]/g,"")),disabled:!w.value,class:"w-full h-full bg-transparent outline-none text-[12em] text-center font-['SFPRO'] mt-[0.5px] text-black placeholder:text-black/60 disabled:cursor-not-allowed",placeholder:t(k)("selly.price")},null,40,ns),[[se,l.value]])],2)]),e("div",as,[e("div",is,[e("div",{onClick:c[12]||(c[12]=d=>T.value=!T.value),class:C(["w-[47%] h-full border-[1.5em] border-black rounded-[10em] flex items-center justify-center transition-opacity cursor-pointer",{"bg-[#41FE7090] text-black":T.value,"bg-black/10 text-black":!T.value,"opacity-20":!w.value}])},[e("span",rs,b(t(k)("selly.allowCalls")),1)],2),e("div",{onClick:c[13]||(c[13]=d=>R.value=!R.value),class:C(["w-[47%] h-full border-[1.5em] border-black rounded-[10em] flex items-center justify-center transition-opacity cursor-pointer",{"bg-[#41FE7090] text-black":R.value,"bg-black/10 text-black":!R.value,"opacity-20":!w.value}])},[e("span",cs,b(t(k)("selly.allowMessage")),1)],2)])]),e("div",us,[e("div",{onClick:g,class:C(["w-full h-[70%] bg-[#F1D047] rounded-[15em] border-[1.5em] border-black flex items-center justify-center cursor-pointer hover:bg-[#E5C542] transition-colors",{"opacity-50 cursor-not-allowed":!w.value}])},[e("span",ds,b(t(k)("selly.post")),1)],2)])])])):P("",!0)],64))}},ms={key:0,class:"w-full h-full z-[2] absolute"},ps=["src"],hs={class:"w-full h-[18%] flex items-end justify-center border-b-[1px] border-neutral-500/30",initial:{opacity:0},enter:{opacity:1,transition:{delay:100,duration:400}}},vs={class:"w-[87%] h-[50%]"},gs={class:"w-full h-[65%] flex"},xs={class:"w-[50%] h-full flex items-start"},ys={class:"text-[18em] font-['SFPRO'] text-white leading-[100%] font-[400]"},ws={class:"w-[50%] h-full flex justify-end"},bs=["src"],_s=["data-index"],ks={key:0,class:"w-full h-[150em] flex items-end justify-center px-[2px] pt-[2px] overflow-hidden relative"},Cs=["src"],$s=["src"],Ss={key:0,class:"w-full h-[12em] absolute top-0 flex items-center justify-center z-10"},Ps={class:"w-[38%] h-full flex items-center justify-center relative mt-[3em]"},js=["src"],Fs={class:"text-[10em] font-['SFPRO'] font-[500] text-black absolute text-center fixtext w-full px-[8px]"},Es={class:"w-full h-[12em] absolute bottom-0 flex items-center justify-center z-10"},Ls={class:"w-[38%] h-full flex items-center justify-center relative mt-[3em]"},Ts=["src"],Ds={class:"text-[8em] font-['SFPRO'] font-[500] text-black absolute text-start fixtext"},Os={class:"w-full h-full overflow-hidden rounded-[18em]"},Is=["onClick","src"],Rs=["onClick"],Ns=["src"],As={class:"absolute inset-0 flex items-center justify-center pointer-events-none"},Ms={class:"w-[35em] h-[35em] rounded-full flex items-center justify-center group-hover:scale-110 transition-transform duration-200"},Vs=["src"],zs={key:1,class:"w-full h-[12px]"},Bs={class:"w-full h-[25em] flex items-center justify-center px-[2px]"},Ys={class:"text-[13em] font-['SFPRO'] font-[500] text-black fixtext"},qs={class:"w-full max-h-[53em] overflow-auto no-scrollbar px-[2px] py-[5em] flex items-start"},Hs={class:"text-[11em] font-['SFPRO'] font-[400] text-[#000000A6] w-full leading-[1] text-center"},Us={class:"w-full h-[43em] flex items-center justify-center mt-[6px] border-t-[1px] border-black/10"},Zs={class:"w-[93%] h-[65%] flex relative items-center justify-center"},Gs=["onClick"],Ws={class:"text-[13em] font-['SFPRO'] font-[400] text-black fixtext ml-[1em]"},Js=["onClick"],Qs={class:"text-[13em] font-['SFPRO'] font-[400] text-black fixtext ml-[1em]"},Ks={key:1,class:"w-full h-full flex flex-col items-center justify-start"},Xs=["src"],eo={__name:"MyOffers",props:{show:{type:Boolean,default:!1}},emits:["changepage","editoffer"],setup(G,{emit:H}){const r=ce(),m=ye(),{ScrollPage:k}=ue(m),{t:$}=de(),N=v=>{v.style.opacity=0,v.style.transform="translateY(15px)"},n=(v,l)=>{const g=(parseInt(v.dataset.index)||0)*50;setTimeout(()=>{v.style.transition="opacity 0.3s ease, transform 0.3s ease",v.style.opacity=1,v.style.transform="translateY(0)",setTimeout(l,300)},g)},w=v=>{v.style.transition=null,v.style.opacity=null,v.style.transform=null},M=[fe,me],W=H,L=v=>{W("changepage",v)},I=G,S=y(null),V=y(0),D=y("top"),B=()=>{if(!S.value)return;const v=S.value,l=v.scrollTop,o=v.scrollHeight,g=v.clientHeight,h=o-g;V.value=h>0?l/h:0,l<=5?D.value="top":l>=h-5?D.value="bottom":D.value="middle",l+g>=o-200&&m.LoadMoreMyOffers()},O=v=>{const l=r.isVideo(v);r.setPhotoViewerData({image:v,type:l?"video":"image"})},T=()=>{S.value?(S.value.addEventListener("scroll",B),setTimeout(()=>U(this,null,function*(){yield xe(),B()}),100)):console.log("scrollContainer ref not found")};ke(()=>{I.show&&T()}),we(()=>I.show,v=>{v?xe(()=>{T()}):S.value&&S.value.removeEventListener("scroll",B)}),Pe(()=>{S.value&&S.value.removeEventListener("scroll",B)});const R=y(!1),j=()=>U(this,null,function*(){const v=R.value,l=yield J("DELETE_POST",v);l&&l.success?r.TriggerNotification({appname:"selly",header:$("selly.title"),message:$("selly.postDeletedSuccess")}):r.TriggerNotification({appname:"selly",header:$("selly.title"),message:$(l==null?void 0:l.message)||(l==null?void 0:l.message)||$("selly.failedDeletePost")}),R.value=!1}),F=()=>{R.value=!1},E=(v,l)=>{v.currentIndex=l.activeIndex};return(v,l)=>{const o=ve("motion");return I.show?(s(),a("div",ms,[R.value?(s(),q(_e,{key:0,onCancel:F,onSubmit:j,header:t($)("general.areYouSure"),label:t($)("selly.confirmDeleteYourOffer"),buttons:{cancel:t($)("general.cancel"),submit:t($)("general.delete")}},null,8,["header","label","buttons"])):P("",!0),Q(e("img",{src:t(p)["selly/add.svg"],onClick:l[0]||(l[0]=g=>L("newpost")),class:"absolute bottom-[15em] right-[13em] h-[50em] z-[10] cursor-pointer anim-hover-1",alt:"",initial:{opacity:0,scale:.5},enter:{opacity:1,scale:1,transition:{delay:200,duration:400,type:"spring",stiffness:200,damping:15}}},null,8,ps),[[o]]),Q((s(),a("div",hs,[e("div",vs,[e("div",gs,[e("div",xs,[e("span",ys,[ge(b(t($)("selly.myOffersOn"))+" ",1),l[3]||(l[3]=e("br",null,null,-1)),ge(" "+b(t($)("selly.title")),1)])]),e("div",ws,[e("div",{onClick:l[1]||(l[1]=g=>L("search")),class:"h-full rounded-full mr-[10em] aspect-square border-[1px] border-white/40 p-[2px] cursor-pointer anim-hover-1"},[e("img",{src:t(p)["selly/search.svg"],class:"h-full aspect-square rounded-full object-cover object-top",alt:""},null,8,bs)]),e("div",{onClick:l[2]||(l[2]=g=>L("home")),class:"h-full rounded-full aspect-square ml-[1em] border-[1px] border-white/40 p-[2px] cursor-pointer anim-hover-1"},l[4]||(l[4]=[e("svg",{class:"h-full",viewBox:"0 0 44 44",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[e("circle",{cx:"22",cy:"22",r:"22",fill:"white"}),e("path",{d:"M22.0001 11.75C22.546 11.75 23.0747 11.9427 23.4922 12.294L32.4756 19.8574C32.8202 20.2127 32.8464 20.7785 32.5206 21.165C32.2103 21.5327 31.6867 21.6121 31.2842 21.3789V25.9531C31.2843 27.0533 31.2843 27.9608 31.2022 28.6885C31.1274 29.3517 30.9763 29.9581 30.6348 30.4961L30.4766 30.7217C30.3208 30.9245 30.1453 31.1119 29.9532 31.2803L29.754 31.4434C29.1609 31.8977 28.4774 32.0825 27.7188 32.168C26.9946 32.2495 26.0927 32.249 25.0001 32.249V27C25.0001 25.5858 24.9999 24.8788 24.5606 24.4395C24.1213 24.0002 23.4141 24 22.0001 24C20.586 24 19.8788 24.0001 19.4395 24.4395C19.0003 24.8788 19 25.5859 19 27V32.249C17.9074 32.249 17.0055 32.2495 16.2813 32.168C15.6173 32.0932 15.0103 31.9427 14.4717 31.6016L14.2461 31.4434C14.043 31.2876 13.8551 31.1119 13.6865 30.9199L13.5235 30.7217C13.0685 30.1292 12.8834 29.4463 12.7979 28.6885C12.7158 27.9608 12.7158 27.0533 12.7158 25.9531V21.3789C12.3133 21.6121 11.7897 21.5327 11.4795 21.165C11.132 20.7528 11.1852 20.1364 11.5977 19.7891L20.5088 12.294L20.67 12.1699C21.0583 11.8977 21.5224 11.75 22.0001 11.75Z",fill:"black"})],-1)]))])])])])),[[o]]),e("div",{class:C(["w-full h-[calc(100%-18%)] px-[20px] overflow-auto no-scrollbar",[D.value==="top"?"mask-bottom":"",D.value==="middle"?"mask-both":"",D.value==="bottom"?"mask-top":""]]),ref_key:"scrollContainer",ref:S},[t(k).myads.loadedData.length>0?(s(),q(Ce,{key:0,appear:"",onBeforeEnter:N,onEnter:n,onAfterEnter:w,css:!1,class:"w-full h-full flex gap-[6em] flex-wrap content-start",tag:"div"},{default:A(()=>[(s(!0),a(z,null,K(t(k).myads.loadedData,(g,h)=>(s(),a("div",{key:g.id,"data-index":h,class:C(["w-full inline-flex flex-wrap content-start overflow-hidden first:mt-[12em] mt-[10em]",g.photos&&g.photos.length<=0?"min-h-[110px]":""]),style:oe({backgroundImage:g.photos&&g.photos.length>0?`url(${t(p)["selly/adsbg.png"]})`:`url(${t(p)["selly/adssmall.png"]})`,backgroundSize:"100% 100%"})},[g.photos&&g.photos.length>0?(s(),a("div",ks,[e("div",{class:C([`image-swiper-prev-${g.id}`,"w-[13%] h-full absolute left-0 flex items-center justify-center z-10"])},[e("img",{src:t(p)["selly/arrow.svg"],class:"h-[15%] cursor-pointer",alt:""},null,8,Cs)],2),e("div",{class:C([`image-swiper-next-${g.id}`,"w-[13%] h-full absolute right-0 flex items-center justify-center z-10"])},[e("img",{src:t(p)["selly/arrow.svg"],class:"h-[15%] rotate-180 cursor-pointer",alt:""},null,8,$s)],2),g.category!=="ads"?(s(),a("div",Ss,[e("div",Ps,[e("img",{src:t(p)["selly/pricebar.svg"],class:"h-full w-full absolute",alt:""},null,8,js),e("span",Fs,"$ "+b(g.price),1)])])):P("",!0),e("div",Es,[e("div",Ls,[e("img",{src:t(p)["selly/imagecount.svg"],class:"h-full w-full absolute",alt:""},null,8,Ts),e("span",Ds,b(g.currentIndex+1)+"/"+b(g.photos.length),1)])]),e("div",Os,[Y(t(re),{modules:M,"slides-per-view":1,"space-between":10,navigation:{nextEl:`.image-swiper-next-${g.id}`,prevEl:`.image-swiper-prev-${g.id}`},"grab-cursor":!0,onSlideChange:x=>E(g,x),class:"w-full h-full overflow-hidden"},{default:A(()=>[(s(!0),a(z,null,K(g.photos,(x,i)=>(s(),q(t(ie),{key:i},{default:A(()=>[t(r).isVideo(x)?(s(),a("div",{key:1,onClick:c=>O(g.photos[g.currentIndex]),class:"w-full h-full relative bg-black"},[e("video",{class:"w-full h-full object-cover",src:x,preload:"metadata",muted:""},"Your browser does not support the video tag.",8,Ns),e("div",As,[e("div",Ms,[e("img",{src:t(p)["photos/play.svg"],class:"h-[80%]",alt:""},null,8,Vs)])])],8,Rs)):(s(),a("img",{key:0,onClick:c=>O(g.photos[g.currentIndex]),src:x,alt:"",class:"h-full object-cover object-top w-full"},null,8,Is))]),_:2},1024))),128))]),_:2},1032,["navigation","onSlideChange"])])])):P("",!0),g.photos&&g.photos.length<=0?(s(),a("div",zs)):P("",!0),e("div",Bs,[e("span",Ys,b(g.title),1)]),e("div",qs,[e("span",Hs,b(g.description),1)]),e("div",Us,[e("div",Zs,[l[7]||(l[7]=e("div",{class:"w-[2px] h-[90%] absolute bg-[#00000073]"},null,-1)),e("div",{onClick:x=>W("editoffer",g),class:"w-[50%] h-full flex items-center justify-center cursor-pointer anim-hover-1"},[l[5]||(l[5]=e("svg",{class:"h-[70%]",viewBox:"0 0 32 32",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[e("circle",{cx:"16",cy:"16",r:"16",fill:"#D7B31A"}),e("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M15.25 22.5625C15.25 22.1483 15.5858 21.8125 16 21.8125H20.5C20.9141 21.8125 21.25 22.1483 21.25 22.5625C21.25 22.9767 20.9141 23.3125 20.5 23.3125H16C15.5858 23.3125 15.25 22.9767 15.25 22.5625Z",fill:"black"}),e("path",{d:"M21.2871 8.90196C20.7102 8.61601 20.0326 8.61601 19.4556 8.90196C19.1502 9.05331 18.8831 9.32086 18.538 9.66648L17.875 10.3295L21.6706 14.125L22.3336 13.462C22.6792 13.117 22.9467 12.8499 23.0981 12.5445C23.3841 11.9674 23.3841 11.2899 23.0981 10.7129C22.9467 10.4075 22.6792 10.1404 22.3336 9.79532L22.2048 9.66648C21.8597 9.32086 21.5925 9.05331 21.2871 8.90196Z",fill:"black"}),e("path",{d:"M20.8751 14.9206L17.0796 11.125L9.66691 18.5376C9.29607 18.9078 9.00257 19.2007 8.84461 19.5821C8.68666 19.9634 8.68705 20.378 8.68756 20.902L8.68762 22.75C8.68762 23.0607 8.93945 23.3125 9.25012 23.3125L11.0981 23.3126C11.6221 23.3131 12.0367 23.3135 12.4181 23.1555C12.7994 22.9976 13.0924 22.7041 13.4625 22.3332L20.8751 14.9206Z",fill:"black"})],-1)),e("span",Ws,b(t($)("general.edit")),1)],8,Gs),e("div",{onClick:x=>R.value=g.id,class:"w-[50%] h-full flex items-center justify-center cursor-pointer anim-hover-1"},[l[6]||(l[6]=e("svg",{class:"h-[70%]",viewBox:"0 0 32 32",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[e("circle",{cx:"16",cy:"16",r:"16",fill:"#D7B31A"}),e("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M21.6869 18.7423C21.6294 19.6822 21.5837 20.4281 21.4902 21.0238C21.3941 21.6348 21.2406 22.1436 20.9333 22.5887C20.6522 22.9959 20.2903 23.3395 19.8706 23.5977C19.4118 23.88 18.8996 24.0035 18.2898 24.0625L13.6955 24.0624C13.0851 24.0033 12.5723 23.8796 12.1132 23.5968C11.6932 23.3381 11.3312 22.9938 11.0502 22.586C10.743 22.1402 10.5899 21.6306 10.4947 21.0188C10.4018 20.4221 10.3572 19.6752 10.3009 18.734L9.8125 10.5625H22.1875L21.6869 18.7423ZM14.125 20.4707C13.8143 20.4707 13.5625 20.2189 13.5625 19.9082V15.4082C13.5625 15.0975 13.8143 14.8457 14.125 14.8457C14.4357 14.8457 14.6875 15.0975 14.6875 15.4082V19.9082C14.6875 20.2189 14.4357 20.4707 14.125 20.4707ZM18.4375 15.4082C18.4375 15.0975 18.1856 14.8457 17.875 14.8457C17.5644 14.8457 17.3125 15.0975 17.3125 15.4082V19.9082C17.3125 20.2189 17.5644 20.4707 17.875 20.4707C18.1856 20.4707 18.4375 20.2189 18.4375 19.9082V15.4082Z",fill:"black"}),e("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M17.0105 7.96208C17.4343 7.99998 17.8326 8.12932 18.1747 8.38443C18.4277 8.57311 18.6034 8.80406 18.7535 9.0542C18.8927 9.28598 19.0328 9.57497 19.1916 9.9028L19.5117 10.563H22.75C23.1642 10.563 23.5 10.8988 23.5 11.313C23.5 11.7272 23.1642 12.063 22.75 12.063C18.2498 12.063 13.7501 12.063 9.25 12.063C8.83579 12.063 8.5 11.7272 8.5 11.313C8.5 10.8988 8.83579 10.563 9.25 10.563H12.5573L12.8242 9.97762C12.9791 9.63772 13.1155 9.33836 13.2526 9.09815C13.4004 8.83905 13.5754 8.59928 13.8315 8.40284C14.1777 8.13719 14.5841 8.00252 15.0174 7.96307C15.3437 7.93337 15.6725 7.93745 16 7.93798C16.3831 7.93859 16.7275 7.93676 17.0105 7.96208ZM14.2058 10.563H17.8448C17.6747 10.2125 17.566 9.9903 17.4674 9.82615C17.3232 9.5859 17.1504 9.48059 16.8768 9.45611C16.6823 9.43872 16.4289 9.43802 16.0259 9.43802C15.6128 9.43802 15.3527 9.43874 15.1534 9.45689C14.8728 9.48243 14.6979 9.59176 14.5554 9.84149C14.4621 10.0052 14.3604 10.2242 14.2058 10.563Z",fill:"black"})],-1)),e("span",Qs,b(t($)("general.delete")),1)],8,Js)])])],14,_s))),128)),l[8]||(l[8]=e("div",{class:"w-full h-[250px]"},null,-1))]),_:1,__:[8]})):(s(),a("div",Ks,[e("img",{src:t(p)["selly/search3.svg"],class:"h-[30%] mt-[140em]",alt:""},null,8,Xs),l[9]||(l[9]=e("p",{style:{"letter-spacing":"-0.28px"},class:"text-[12em] font-['SFPRO'] text-white/20 font-[400] leading-[100%] mt-[2em]"},"No post found.",-1))]))],2)])):P("",!0)}}},to=Se(eo,[["__scopeId","data-v-eadfe2b7"]]),lo={class:"w-full mt-[5em] h-full"},so={class:"w-full h-[80em] flex items-center justify-center border-b-[1px] border-black/30"},oo={class:"w-full h-[30em] mt-[30em] flex justify-between items-center"},no={class:"text-[16em] font-['SFPRO'] font-[400] text-black text-start fixtext"},ao=["src"],io={class:"w-full h-[54em] flex items-end relative z-[50]"},ro=["src"],co=["src"],uo={key:0,class:"absolute top-[70%] left-0 w-full bg-white border-[1.2em] border-t-0 mt-[16em] border-black rounded-b-[10em] overflow-hidden z-10"},fo=["onClick"],mo=["src"],po={class:"text-[11em] font-['SFPRO'] font-[400] ml-[1em] text-black"},ho={class:"w-full h-[147em] flex items-end"},vo=["src"],go=["src"],xo={class:"w-full h-[12em] absolute bottom-[12em] flex items-center justify-center z-10"},yo={class:"w-[38%] h-full flex items-center justify-center relative mt-[3px]"},wo=["src"],bo={class:"text-[8em] font-['SFPRO'] font-[500] text-black absolute text-start fixtext"},_o={class:"text-[8em] font-['SFPRO'] font-[500] text-[#FF7E7E] mt-[0.2em] fixtext cursor-pointer anim-hover-1"},ko=["src"],Co={key:1,class:"w-full h-full relative bg-black"},$o=["src"],So={class:"absolute inset-0 flex items-center justify-center pointer-events-none"},Po={class:"w-[35px] h-[35px] rounded-full flex items-center justify-center group-hover:scale-110 transition-transform duration-200"},jo=["src"],Fo=["src"],Eo={class:"text-[11em] font-['SFPRO'] font-[400] text-black mt-[0.5em]"},Lo={class:"w-full h-[54em] flex items-end"},To=["disabled","placeholder"],Do={class:"w-full h-[97em] flex items-end"},Oo=["disabled","placeholder"],Io={key:0,class:"w-full h-[53em] flex items-end"},Ro=["disabled","placeholder"],No={class:"w-full h-[50em] flex items-end"},Ao={class:"w-full h-[70%] flex justify-between"},Mo={class:"text-[12em] font-['SFPRO'] font-[400] text-start fixtext"},Vo={class:"text-[12em] font-['SFPRO'] font-[400] text-start fixtext"},zo={class:"w-full h-[54em] mt-[3em] flex items-end"},Bo={class:"text-[12em] font-['SFPRO'] font-[400] text-black text-start fixtext"},Yo={__name:"EditingOffer",props:{show:{type:Boolean,default:!1},editoffer:{type:Object,default:null}},emits:["changepage"],setup(G,{emit:H}){const r=ce(),{t:m}=de(),k=he(()=>[{name:"ads",get label(){return m("selly.categories.ads")},color:"#A06499",icon:"adsactive.svg"},{name:"vehicles",get label(){return m("selly.categories.vehicles")},color:"#A06464",icon:"vehiclesactive.svg"},{name:"items",get label(){return m("selly.categories.items")},color:"#A09264",icon:"itemsactive.svg"},{name:"houses",get label(){return m("selly.categories.houses")},color:"#64A071",icon:"housesactive.svg"}]),$=[fe,me],N=y(!1),n=y(null),w=()=>{N.value=!N.value},M=x=>{n.value=x,N.value=!1},W=()=>{N.value=!1},L=y(0),I=x=>{L.value=x.activeIndex},S=H,V=x=>{S("changepage",x)},D=G,B=y(!1),O=y(!1),T=y(!1),R=x=>{j.value=x},j=y([]),F=y(""),E=y(""),v=y("");y(!1);const l=y({category:null,photos:[],title:"",description:"",price:"",allowCalls:!1,allowMessages:!1}),o=he(()=>{var _;if(!D.editoffer)return!0;const x=((_=n.value)==null?void 0:_.name)!==l.value.category,i=JSON.stringify(j.value)!==JSON.stringify(l.value.photos),c=F.value!==l.value.title,d=E.value!==l.value.description,Z=v.value!==l.value.price,ne=O.value!==l.value.allowCalls,be=T.value!==l.value.allowMessages;return x||i||c||d||Z||ne||be}),g=()=>U(this,null,function*(){if(!n.value)return;if(D.editoffer&&!o.value){r.TriggerNotification({appname:"selly",header:m("selly.title"),message:m("selly.noChangesDetected")});return}if(F.value.trim()===""){r.TriggerNotification({appname:"selly",header:m("selly.title"),message:m("selly.enterTitle")});return}if(E.value.trim()===""){r.TriggerNotification({appname:"selly",header:m("selly.title"),message:m("selly.enterDescription")});return}const x={category:n.value.name,title:F.value,description:E.value};let i=yield J("SELLY_VALIDATE_POST",x);if(!i||!i.success){r.TriggerNotification({appname:"selly",header:m("selly.title"),message:m(i==null?void 0:i.message)||(i==null?void 0:i.message)||m("selly.validationFailed")});return}const c={category:n.value.name,photos:j.value,title:F.value,description:E.value,price:Number(v.value),allowCalls:O.value,allowMessages:T.value};D.editoffer&&D.editoffer.id&&(c.id=D.editoffer.id);let d=yield J("POST_EDIT_SELLY",c);d&&d.success?(n.value=null,j.value=[],F.value="",E.value="",v.value="",O.value=!1,T.value=!1,V("myoffers")):r.TriggerNotification({appname:"selly",header:m("selly.title"),message:m(d.error)||d.error||m("selly.failedPostOffer")})}),h=()=>{j.value.length!==0&&(j.value.splice(L.value,1),L.value>=j.value.length&&(L.value=j.value.length-1))};return we(()=>D.editoffer,x=>{if(x){const i=k.value.find(c=>c.name===x.category);i&&(n.value=i),j.value=x.photos||[],F.value=x.title||"",E.value=x.description||"",v.value=x.price||"",O.value=x.allowCalls||!1,T.value=x.allowMessages||!1,L.value=0,l.value={category:x.category,photos:[...x.photos||[]],title:x.title||"",description:x.description||"",price:x.price||"",allowCalls:x.allowCalls||!1,allowMessages:x.allowMessages||!1}}},{immediate:!0}),(x,i)=>{var c;return s(),a(z,null,[Y(Fe,{show:B.value,onCancel:i[0]||(i[0]=d=>B.value=!1),onSelectPhoto:R,multiselect:!0},null,8,["show"]),D.show?(s(),a("div",{key:0,class:"w-full h-full absolute z-[2] px-[20em] bg-gray-400/90",onClick:W},[e("div",lo,[e("div",so,[e("div",oo,[e("span",no,b(D.editoffer?t(m)("selly.editPost"):t(m)("selly.newPost")),1),e("img",{onClick:i[1]||(i[1]=d=>V("myoffers")),src:t(p)["selly/close2.svg"],class:"h-[90%] cursor-pointer anim-hover-1",alt:""},null,8,ao)])]),e("div",io,[e("div",{onClick:X(w,["stop"]),class:C(["w-full h-[70%] bg-black/10 border-[1.2em] border-black flex items-center justify-between px-[7em] cursor-pointer hover:bg-black/20 transition-all",N.value?"rounded-t-[10em] border-b-0":"rounded-[10em]"]),style:oe({backgroundColor:n.value?n.value.color:""})},[e("img",{src:t(p)[`selly/${n.value?n.value.icon:""}`],class:"h-[22em] rounded-full absolute",alt:""},null,8,ro),e("span",{class:C([n.value?"ml-[2.5em]":"","text-[11em] font-['SFPRO'] font-[400] text-black text-start fixtext"])},b(n.value?n.value.label:t(m)("selly.selectCategory")),3),e("img",{src:t(p)["selly/dropdown.svg"],class:C(["h-[30%] transition-transform duration-200",{"rotate-180":N.value}]),alt:""},null,10,co)],6),N.value?(s(),a("div",uo,[i[12]||(i[12]=e("div",{class:"w-full h-[1em] bg-black -mt-[1px]"},null,-1)),(s(!0),a(z,null,K(k.value,(d,Z)=>(s(),a("div",{key:d.name,onClick:X(ne=>M(d),["stop"]),class:C(["w-full px-[10px] py-[6em] cursor-pointer transition-colors flex items-center",Z!==k.value.length-1?"border-b border-black/20":""]),style:oe({backgroundColor:d.color})},[e("img",{src:t(p)[`selly/${d.icon}`],class:"h-[22em] rounded-full",alt:""},null,8,mo),e("span",po,b(d.label),1)],14,fo))),128))])):P("",!0)]),e("div",ho,[e("div",{class:C(["w-full h-[90%] relative bg-black/10 rounded-[15em] border-[1.2em] overflow-hidden border-black transition-opacity flex flex-col items-center justify-center",{"opacity-20":!n.value}])},[j.value.length>0?(s(),a("div",{key:0,onClick:i[5]||(i[5]=d=>B.value=!0),class:"w-full h-full"},[e("div",{onClick:i[2]||(i[2]=X(()=>{},["stop"])),class:"image-swiper-prev w-[13%] h-full absolute left-0 flex items-center justify-center z-10"},[e("img",{src:t(p)["selly/arrow.svg"],class:"h-[15%] cursor-pointer",alt:""},null,8,vo)]),e("div",{onClick:i[3]||(i[3]=X(()=>{},["stop"])),class:"image-swiper-next w-[13%] h-full absolute right-0 flex items-center justify-center z-10"},[e("img",{src:t(p)["selly/arrow.svg"],class:"h-[15%] rotate-180 cursor-pointer",alt:""},null,8,go)]),e("div",xo,[e("div",yo,[e("img",{src:t(p)["selly/imagecount.svg"],class:"h-full w-full absolute",alt:""},null,8,wo),e("span",bo,b(L.value+1)+"/"+b(j.value.length),1)])]),e("div",{onClick:[i[4]||(i[4]=X(()=>{},["stop"])),h],class:"w-full h-[12em] absolute bottom-[0px] flex items-center justify-center z-10 bg-black"},[e("span",_o,b(t(m)("selly.deletePhoto")),1)]),Y(t(re),{modules:$,"slides-per-view":1,"space-between":10,navigation:{nextEl:".image-swiper-next",prevEl:".image-swiper-prev"},"grab-cursor":!0,onSlideChange:I,class:"w-full h-full overflow-hidden"},{default:A(()=>[(s(!0),a(z,null,K(j.value,(d,Z)=>(s(),q(t(ie),{key:Z},{default:A(()=>[t(r).isVideo(d)?(s(),a("div",Co,[e("video",{class:"w-full h-full object-cover",src:d,preload:"metadata",muted:""},"Your browser does not support the video tag.",8,$o),e("div",So,[e("div",Po,[e("img",{src:t(p)["photos/play.svg"],class:"h-[80%]",alt:""},null,8,jo)])])])):(s(),a("img",{key:0,src:d,alt:"",class:"h-full object-cover object-center w-full rounded-[13px]"},null,8,ko))]),_:2},1024))),128))]),_:1})])):(s(),a("div",{key:1,onClick:i[6]||(i[6]=d=>B.value=!0),class:"w-full h-full flex flex-col items-center justify-center"},[e("img",{src:t(p)["selly/uploadphoto.svg"],class:"h-[30%]",alt:""},null,8,Fo),e("span",Eo,b(t(m)("selly.clickUploadPhotos")),1)]))],2)]),e("div",Lo,[e("div",{class:C(["w-full h-[70%] bg-black/10 rounded-[10em] border-[1.2em] border-black transition-opacity",{"opacity-20":!n.value}])},[Q(e("input",{type:"text","onUpdate:modelValue":i[7]||(i[7]=d=>F.value=d),disabled:!n.value,class:"w-full h-full bg-transparent outline-none text-[12em] text-center font-['SFPRO'] text-black placeholder:text-black/60 disabled:cursor-not-allowed",placeholder:t(m)("selly.postTitle")},null,8,To),[[se,F.value]])],2)]),e("div",Do,[e("div",{class:C(["w-full h-[84%] bg-black/10 rounded-[10em] border-[1.2em] border-black transition-opacity",{"opacity-20":!n.value}])},[Q(e("textarea",{maxlength:800,disabled:!n.value,"onUpdate:modelValue":i[8]||(i[8]=d=>E.value=d),style:{resize:"none","white-space":"pre-wrap","word-wrap":"break-word","overflow-wrap":"break-word"},class:"w-full h-full bg-transparent text-[11em] font-['SFPRO'] text-black placeholder:text-black/60 p-[1em] font-[400] leading-[100%] fixtext outline-none",placeholder:t(m)("selly.description")},null,8,Oo),[[se,E.value]])],2)]),((c=n.value)==null?void 0:c.name)!=="ads"?(s(),a("div",Io,[e("div",{class:C(["w-full h-[70%] bg-black/10 rounded-[10em] border-[1.2em] border-black transition-opacity",{"opacity-20":!n.value}])},[Q(e("input",{type:"text","onUpdate:modelValue":i[9]||(i[9]=d=>v.value=d),disabled:!n.value,class:"w-full h-full bg-transparent outline-none text-[12em] text-center font-['SFPRO'] mt-[0.1em] text-black placeholder:text-black/60 disabled:cursor-not-allowed",placeholder:t(m)("selly.price")},null,8,Ro),[[se,v.value]])],2)])):P("",!0),e("div",No,[e("div",Ao,[e("div",{onClick:i[10]||(i[10]=d=>O.value=!O.value),class:C(["w-[47%] h-full border-[1.2em] border-black rounded-[10em] flex items-center justify-center transition-opacity cursor-pointer",{"bg-black text-white":O.value,"bg-black/10 text-black":!O.value,"opacity-20":!n.value}])},[e("span",Mo,b(t(m)("selly.allowCalls")),1)],2),e("div",{onClick:i[11]||(i[11]=d=>T.value=!T.value),class:C(["w-[47%] h-full border-[1.2em] border-black rounded-[10em] flex items-center justify-center transition-opacity cursor-pointer",{"bg-black text-white":T.value,"bg-black/10 text-black":!T.value,"opacity-20":!n.value}])},[e("span",Vo,b(t(m)("selly.allowMessage")),1)],2)])]),e("div",zo,[e("div",{onClick:g,class:C(["w-full h-[70%] bg-[#F1D047] rounded-[10em] border-[2px] border-black flex items-center justify-center cursor-pointer hover:bg-[#E5C542] transition-colors",{"opacity-50 cursor-not-allowed":!n.value||D.editoffer&&!o.value}])},[e("span",Bo,b(D.editoffer?t(m)("selly.update"):t(m)("selly.post")),1)],2)])])])):P("",!0)],64)}}},qo={class:"w-full h-full rounded-[44em] overflow-hidden bg-black relative"},sn={__name:"SellyApp",setup(G){const H=ye(),r=ce(),{networkSignal:m,appConfig:k}=ue(r),$=y("none"),N=he(()=>{var I,S,V;const L=((V=(S=(I=k.value)==null?void 0:I.TowerConfig)==null?void 0:S.AppRequirements)==null?void 0:V.selly)||2;return m.value>=L}),n=L=>{$.value=L},w=y([{key:"home"},{key:"search"},{key:"newpost"},{key:"myoffers"},{key:"editingoffer"}]),M=y(null),W=L=>{M.value=L,n("editingoffer")};return ke(()=>{n("home"),H.fetchSelly(),H.FetchMyOffers()}),(L,I)=>(s(),a("div",qo,[N.value?(s(),q(Te,{key:1,"current-key":$.value,items:w.value,duration:300,easing:"ease-in-out"},{home:A(()=>[Y(Ot,{show:$.value==="home",onChangepage:n},null,8,["show"])]),search:A(()=>[Y($l,{show:$.value==="search",onChangepage:n},null,8,["show"])]),newpost:A(()=>[Y(fs,{show:$.value==="newpost",onChangepage:n},null,8,["show"])]),myoffers:A(()=>[Y(to,{show:$.value==="myoffers",onChangepage:n,onEditoffer:W},null,8,["show"])]),editingoffer:A(()=>[Y(Yo,{show:$.value==="editingoffer",onChangepage:n,editoffer:M.value},null,8,["show","editoffer"])]),_:1},8,["current-key","items"])):(s(),q(Re,{key:0}))]))}};export{sn as default};