PageSourceSearch

https://myka.ng/assets/BlogListPage-D9W2LEyI.js

js myka.ng collected 2026-10-09 22:41:21 UTC 2,580 bytes, 1 lines download raw bytes

1import{d as k,r as n,j as e}from"./vendor-react-DfYGAhtm.js";import{q as S}from"./vendor-icons-1odZwi-b.js";import{D as p,m as t,g as C}from"./index-DsBgCU7r.js";import{u as z,b as A,C as E}from"./blogApi-B-tmEZPp.js";import{w as L}from"./contentfulPreview-UQGJUROZ.js";import{B as N}from"./BlogPostSummaryCard-CAmiGhT5.js";import{a,h as x,B as g,F as h,T as l,i as R,w as u,s as m}from"./vendor-ui-DA_r9yXk.js";import"./vendor-state-BsBVN-fX.js";import"./vendor-forms-BP-7CbAP.js";import"./Tag-CjDhIpKV.js";const T=12,q=()=>{const o=k(),r=z(),{data:d,isLoading:f,isError:b,fetchNextPage:j,hasNextPage:w,isFetchingNextPage:y,refetch:P}=A(T,r),v=n.useCallback(()=>{o(`/${p.Overview}`)},[o]),B=n.useCallback(s=>{o(L(`/${p.BlogList}/${s}`,r))},[o,r]),c=n.useMemo(()=>(d?.pages.flatMap(s=>s.posts)??[]).sort((s,i)=>new Date(i.updatedAt).getTime()-new Date(s.updatedAt).getTime()),[d?.pages]);return e.jsxs(a,{w:"100%",py:{base:6,md:10},children:[r.isPreview?e.jsx(E,{}):null,e.jsx(a,{w:"100%",maxW:"1200px",mx:"auto",px:{base:4,md:6},children:e.jsxs(x,{gap:6,children:[e.jsx(g,{type:"button",variant:"ghost",size:"sm",colorPalette:"gray",onClick:v,alignSelf:"flex-start","aria-label":"Back to home",children:e.jsxs(h,{as:"span",align:"center",gap:2,children:[e.jsx(S,{size:18,"aria-hidden":!0}),e.jsx(l,{as:"span",fontSize:"sm",fontWeight:"semibold",children:"Back"})]})}),e.jsx(R,{color:t.text.primary,fontFamily:"'Baloo 2', cursive",fontSize:{base:"xl",md:"28px"},fontWeight:"600",lineHeight:{base:"1.2",md:"1.25"},letterSpacing:"-1px",children:"All blog posts"}),f?e.jsx(u,{columns:{base:1,md:2,lg:3},gap:{base:3,md:4},children:Array.from({length:6}).map((s,i)=>e.jsxs(a,{borderRadius:"16px",overflow:"hidden",children:[e.jsx(m,{h:{base:"136px",md:"180px"},w:"100%"}),e.jsxs(a,{p:3,children:[e.jsx(m,{h:"20px",w:"90%",mb:3}),e.jsx(m,{h:"16px",w:"40%"})]})]},i))}):b?e.jsxs(a,{borderRadius:"md",border:`1px solid ${t.border.primary}`,bg:t.gray[50],p:4,children:[e.jsx(l,{color:t.text.info,fontSize:"sm",mb:3,children:"We couldn't load blog posts. Please try again."}),e.jsx(C,{buttonType:"outline",size:"sm",text:"Retry",onClick:()=>{P()}})]}):c.length===0?e.jsx(l,{color:t.text.info,fontSize:"sm",children:"No articles yet. Check back soon."}):e.jsxs(x,{gap:6,children:[e.jsx(u,{columns:{base:1,md:2,lg:3},gap:{base:3,md:4},children:c.map(s=>e.jsx(N,{post:s,onOpenPost:B},s.id))}),w?e.jsx(h,{justify:"center",children:e.jsx(g,{type:"button",variant:"outline",size:"sm",colorPalette:"gray",loading:y,onClick:()=>{j()},children:"Load more"})}):null]})]})})]})};export{q 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.