import{r as m,w as $,u as I,c as a,a as e,k as d,v as w,e as n,i as _,F as P,f as A,b as F,l as v,g as y,h as B,o,n as R,t as x}from"./entry.0b5aa3d9.js";import{_ as C}from"./search.b7b33edb.js";const T=""+globalThis.__publicAssetsURL("download.svg"),V={class:"animate-fade w-full"},J={class:"bg-white uhjk py-6 mt-6 w-[90%] mx-auto rounded-xl my-12",style:{border:"1.4px solid #EFEFEF"}},M={class:"sm:flex items-center w-full mt-8 px-4 mx-auto"},D={class:"w-full mt-8 grid grid-cols-1 sm:grid-cols-2 gap-6"},z={style:{border:"1px solid #EFEFEF"},class:"sm:flex items-center rounded-xl p-4"},N={class:"sm:px-3 ui"},S={class:"flex items-center justify-between"},H=["href"],Y={class:"rounded-full p-1 cursor-pointer"},q=["href"],G=["onClick"],K={class:"san line-clamp-2"},O={class:"mt-1 text-[#7F7F7F]"},Q={class:"line-clamp-2"},W={class:"mt-5 flex items-center justify-between"},X={class:"flex items-center"},Z={class:"flex-0 mr-2"},ee={class:"flex-1"},te={class:"text-base font-medium"},ne={__name:"Jurnal",async setup(se){let u,g;const l=m(null),c=m(null),r=m(1),p=m(0),h=v(),{data:E,total:U}=([u,g]=$(()=>$fetch(h.public.API_PUBLIC_URL+"/api/jurnal?limit=6&page=1")),u=await u,g(),u);c.value=E,p.value=Math.ceil(U/6);async function k(){let i;if(l.value?i=await $fetch(v().public.API_PUBLIC_URL+`/api/jurnal?limit=6&page=${r.value}&search=${l.value}`):i=await $fetch(v().public.API_PUBLIC_URL+`/api/jurnal?limit=6&page=${r.value}`),c.value=i.data,navigator.userAgent.includes("Chrome")){window.scrollTo({behavior:"smooth",top:0,left:0});return}windowScrollTo(window,{behavior:"smooth",top:0,left:0})}async function b(){const{data:i,total:t}=await $fetch(h.public.API_PUBLIC_URL+`/api/jurnal?limit=100&page=1&search=${l.value}`);c.value=i,p.value=Math.ceil(t/6)}return I({title:"Informasi Mahasiswa"}),(i,t)=>{const L=y("v-img"),j=y("v-pagination"),f=B("ripple");return o(),a("div",V,[e("div",J,[t[7]||(t[7]=e("div",{class:"sm:flex items-center justify-between w-full pb-4",style:{"border-bottom":"1px solid #EFEFEF"}},[e("h1",{class:"font-bold"},"Jurnal UCY")],-1)),e("div",M,[d(e("input",{"onUpdate:modelValue":t[0]||(t[0]=s=>_(l)?l.value=s:null),class:"bg-[#F8F8F8] flex-1 sm:flex hidden rounded-xl px-4 h-[50px]",placeholder:"Cari Jurnal"},null,512),[[w,n(l)]]),d(e("input",{"onUpdate:modelValue":t[1]||(t[1]=s=>_(l)?l.value=s:null),class:"flex sm:hidden bg-[#F8F8F8] w-full rounded-xl px-4 h-[50px]",placeholder:"Cari Jurnal"},null,512),[[w,n(l)]]),d((o(),a("button",{onClick:b,class:"text-base sm:text-lg hidden sm:flex items-center flex-none bg-[#2E8586] text-white ml-2 rounded-xl font-semibold text-center px-8 py-3"},t[3]||(t[3]=[e("div",{class:"mr-1"},"Cari",-1),e("img",{src:C},null,-1)]))),[[f]]),d((o(),a("button",{onClick:b,class:"text-base sm:text-lg flex sm:hidden items-center w-full justify-center mt-3 flex-none bg-[#2E8586] text-white rounded-xl font-semibold text-center px-8 py-3"},t[4]||(t[4]=[e("div",{class:"mr-1"},"Cari",-1),e("img",{src:C},null,-1)]))),[[f]])]),e("div",D,[(o(!0),a(P,null,A(n(c),s=>(o(),a("div",z,[e("div",N,[e("div",S,[t[6]||(t[6]=e("div",{class:"uppercase tracking-widest font-semibold text-[#2E8586]"},[e("span",null,"Jurnal")],-1)),e("a",{href:s.url,target:"_blank"},[d((o(),a("div",Y,t[5]||(t[5]=[e("img",{src:T},null,-1)]))),[[f]])],8,H)]),e("a",{href:s.url,target:"_blank"},[e("div",{class:"text-2xl font-semibold cursor-pointer",onClick:le=>("navigateTo"in i?i.navigateTo:n(R))("/jurnal/"+s.slug)},[e("span",K,x(s.title),1)],8,G)],8,q),e("div",O,[e("span",Q,x(s.description),1)]),e("div",W,[e("div",X,[e("div",Z,[F(L,{src:"/avatar.png",width:"30"})]),e("div",ee,[e("div",te,[e("span",null,x(s.created_by),1)])])])])])]))),256))]),F(j,{size:(i.$vuetify.display.mobile,"small"),class:"mt-10 mb-6",modelValue:n(r),"onUpdate:modelValue":[t[2]||(t[2]=s=>_(r)?r.value=s:null),k],"total-visible":5,length:n(p)},null,8,["size","modelValue","length"])])])}}};export{ne as default};
