1import{P as b,h as _,i as x,f as h,j as P,s as N}from"./entry.vtU-ay4h.js";import{_ as k,c as A,a3 as e,a4 as a,Z as y,N as g,X as C,U as j,a7 as w,a as S,b as M,r as c,L as u,o as f}from"./vue-core.CCfgwnyW.js";import{S as q}from"./SearchCode.BxCgBaWG.js";import{M as B}from"./MasonryContainer.k-1X7A23.js";import L from"./Stats.uv-2hWqG.js";import T from"./WhySimpliers.Bh22b41P.js";import{u as V}from"./usePageMeta.jxlYvWsf.js";import"./LoadingElement.cwt7MtzM.js";import"./SearchFormInput.CP1fCP3K.js";import"./GiveawayCard.Y04lCXKW.js";import"./VerifiedSvg.CAgwNdAm.js";import"./AnimateNumber.DJ1ERZhA.js";import"./AccordionItem.CMpsNd_e.js";const $={components:{WhySimpliers:T,Stats:L,SearchCode:q,MasonryContainer:B},async setup(){const n=_(),s=x(),v=h(),t=S(()=>Number(v.query.page)||1),p=c({data:[]}),l=c(null);V({titlePath:"headers.giveaway.browse.index.title",descPath:"headers.giveaway.browse.index.description",iosDeeplink:"simpliersgiveaway://upcoming"}),M(t,d=>{m(d)});const m=(d=1)=>s.get(P.giveaway.browse.get,{params:{page:d}}).then(o=>{const i=o.data.giveaways;if(Array.isArray(i)){p.value={data:[]};return}i.data=i.data.map(r=>(r.post=r.posts[0],r)),p.value=i,n.$domHelpers.scrollWindow(l.value)}).catch(o=>{const i=o.response?.status??0,r=o.response?.data?.data?.message??o.response?.data?.message??o.message;return N({statusCode:i,statusMessage:r})});return await m(t.value),{giveaways:p,giveawayList:l}},methods:{goToPage(n=1){this.$router.push({path:(this._.provides[b]||this.$route).path,query:{page:n}})}}},R={class:"container pt-12 lg:pt-20 pb-12 md:pb-20"},D={class:"flex flex-wrap justify-center"},E={class:"w-auto"},W={class:"text-4xl font-medium"},G={class:"mt-3"},H={class:"w-full my-10"},U={ref:"giveawayList",class:"my-12"},X={"aria-label":"Page navigation",class:"flex justify-end"},Z={class:"join"},z=["disabled"],F=["disabled"],I={class:"container py-12"},J={class:"container py-12"};function K(n,s,v,t,p,l){const m=u("search-code"),d=u("masonry-container"),o=u("stats"),i=u("why-simpliers");return f(),A("div",null,[e("div",R,[e("div",D,[e("div",E,[e("h1",W,y(n.$t("pages.giveaway.browse.index.title")),1),s[2]||(s[2]=a()),e("p",G,y(n.$t("pages.giveaway.browse.index.text")),1)]),s[3]||(s[3]=a()),s[4]||(s[4]=e("div",{class:"w-full md:w-1/2 mb-4"},null,-1)),s[5]||(s[5]=a()),s[6]||(s[6]=e("div",{class:"w-full md:w-1/2 mb-4"},null,-1)),s[7]||(s[7]=a()),e("div",H,[g(m)])]),s[11]||(s[11]=a()),e("div",U,[t.giveaways.data.length>0?(f(),C(d,{key:0,giveaways:t.giveaways.data},null,8,["giveaways"])):j("",!0)],512),s[12]||(s[12]=a()),e("nav",X,[e("div",Z,[e("button",{"aria-label":"Previous",tabindex:"-1",class:"join-item btn",disabled:!t.giveaways.prev_page_url,onClick:s[0]||(s[0]=w(r=>l.goToPage(t.giveaways.current_page-1),["prevent"]))},[...s[8]||(s[8]=[e("i",{class:"fa fa-chevron-left","aria-hidden":"true"},null,-1)])],8,z),s[10]||(s[10]=a()),e("button",{"aria-label":"Next",class:"join-item btn",disabled:!t.giveaways.next_page_url,onClick:s[1]||(s[1]=w(r=>l.goToPage(t.giveaways.current_page+1),["prevent"]))},[...s[9]||(s[9]=[e("i",{class:"fa fa-chevron-right","aria-hidden":"true"},null,-1)])],8,F)])])]),s[13]||(s[13]=a()),e("div",I,[g(o)]),s[14]||(s[14]=a()),e("div",J,[g(i,{social:n.$t("components.variables.socialArgs.instagram")},null,8,["social"])])])}const ps=k($,[["render",K]]);export{ps as default};
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.