1import{_ as T}from"./BO2MJVnM.js";import{i as V,ag as j,aA as E,aB as F,j as k,k as x,s as H,Z as z,c as t,n as i,a as p,b as r,F as d,l as y,A as B,B as v,o as e,h as L,N as w,P as O,Q as G}from"./CBZx7rdy.js";import{_ as P}from"./DTQ3aOFE.js";import{_ as Q}from"./BXrdiHdf.js";import"./DTmifBnS.js";const U=O(G),Z={key:0,class:"lg:space-y-8"},q={key:1},D={key:2,class:"lg:space-y-4"},J={class:"grid lg:grid-cols-2 gap-4 lg:gap-8"},K={key:1,class:"col-span-2 space-y-8"},se=V({__name:"index",setup(R){const a=j(),{getBookmarkedTeasers:A,loadBookmarks:b}=E(),{$keycloak:o}=F(),n=k([]),c=k(!0),m=k(null),h=x(()=>(n==null?void 0:n.value[0])||null),N=x(()=>n.value.slice(1)),f=async()=>{if(a.isInitialized){if(!a.isAuthenticated){await(o==null?void 0:o.login());return}c.value=!0,m.value=null;try{await b();const{articles:s}=await A();n.value=s.value}catch(s){m.value=s}finally{c.value=!1}}};return H(()=>{a.isInitialized&&f()}),z(()=>a.isInitialized,s=>{s&&f()}),z(()=>a.isAuthenticated,async s=>{a.isInitialized&&(s?await f():await(o==null?void 0:o.login()))}),(s,u)=>{const g=T,I=L,S=P,C=U,M=Q;return i(c)?(e(),t("div",Z,[u[0]||(u[0]=p("div",{class:"h-9 w-1/4 rounded-md bg-surface-05 my-spacing-l inline-block"},null,-1)),r(g,{type:"hero"}),(e(),t(d,null,y(3,l=>r(g,{key:l,type:"horizontal"})),64))])):i(m)?(e(),t("div",q,[r(I)])):(e(),t("div",D,[u[1]||(u[1]=p("div",{class:"flex justify-between py-spacing-l"},[p("h1",{class:"text-2xl lg:text-4xl font-bold capitalize flex items-center flex-row gap-2"}," Bookmarks ")],-1)),p("div",J,[h.value?(e(),B(S,{key:0,teaser:h.value,class:"col-span-2 -mx-4 md:mx-0 lg:mx-0"},null,8,["teaser"])):v("",!0),(e(!0),t(d,null,y(N.value,(l,_)=>(e(),t(d,{key:_},[!(_%3)&&_!=0?(e(),B(C,{key:0,"slot-id":i(w).bookmarks[0].id,pos:[Math.ceil(_/3).toString()],class:"col-span-2 grid place-items-center -mx-4",sizes:i(w).takeOver[0].size},null,8,["slot-id","pos","sizes"])):v("",!0),r(M,{teaser:l,class:"col-span-2 grid-cols-12"},null,8,["teaser"])],64))),128)),i(c)?(e(),t("div",K,[(e(),t(d,null,y(3,l=>r(g,{key:l,type:"horizontal"})),64))])):v("",!0)])]))}}});
1export{se 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.