PageSourceSearch

https://www.faithassembly.org.uk/assets/EstherResources-BesDqujY.js

js faithassembly.org.uk collected 2026-09-25 13:56:07 UTC 4,131 bytes, 1 lines download raw bytes

1import{r as a,j as e,ag as l}from"./vendor-BFIOfVip.js";import{i as f,bB as d,A as b,br as y}from"./vendor-icons-BjlO8Ivt.js";import{d as j}from"./index-CKRbob3g.js";import{C as w,k as v,E as N,G as k}from"./vendor-firebase-dJP658Hw.js";import"./vendor-motion-C4-LgF0B.js";const q=()=>{const[r,m]=a.useState(""),[x,h]=a.useState([]),[p,u]=a.useState(!0);a.useEffect(()=>{(async()=>{try{const t=w(v(j,"esther_resources"),N("createdAt","desc")),g=(await k(t)).docs.map(c=>({id:c.id,...c.data()}));h(g)}catch(t){console.error("Error fetching resources:",t)}finally{u(!1)}})()},[]);const i=x.filter(s=>s.title.toLowerCase().includes(r.toLowerCase())||s.author.toLowerCase().includes(r.toLowerCase())),n=(s,t,o)=>{if(!o){l.error("Resource link not available.");return}window.open(o,"_blank"),s==="video"?l.success(`Playing: ${t}`):l.success(`Downloading: ${t}`)};return e.jsxs("div",{className:"space-y-8 font-sans",children:[e.jsxs("div",{className:"text-center max-w-2xl mx-auto mb-12",children:[e.jsx("span",{className:"text-rose-500 font-bold tracking-widest uppercase text-xs mb-2 block",children:"Equipping the Saints"}),e.jsx("h1",{className:"text-4xl md:text-5xl font-serif text-rose-950 mb-4",children:"Resource Library"}),e.jsx("p",{className:"text-gray-500",children:"Access study guides, sermon recordings, and spiritual tools to deepen your walk."})]}),e.jsxs("div",{className:"max-w-md mx-auto relative mb-12",children:[e.jsx(f,{className:"absolute left-4 top-3.5 text-gray-400 w-5 h-5"}),e.jsx("input",{type:"text",placeholder:"Search for guides, videos...",value:r,onChange:s=>m(s.target.value),className:"w-full pl-12 pr-4 py-3 rounded-full border border-gray-200 focus:border-rose-400 focus:ring-2 focus:ring-rose-100 transition-all shadow-sm"})]}),e.jsx("div",{className:"grid md:grid-cols-2 lg:grid-cols-3 gap-8",children:p?e.jsx("div",{className:"col-span-full text-center py-12 text-gray-400",children:"Loading resources..."}):i.length===0?e.jsx("div",{className:"col-span-full text-center py-12 text-gray-400",children:"No resources found matching your search."}):i.map(s=>e.jsxs("div",{className:"bg-white rounded-2xl overflow-hidden border border-rose-100 shadow-sm hover:shadow-lg transition-all group",children:[e.jsxs("div",{className:"h-48 overflow-hidden relative",children:[e.jsx("img",{src:s.image||"https://images.unsplash.com/photo-1544928147-79a774bed935?w=800&auto=format&fit=crop&q=60",alt:s.title,className:"w-full h-full object-cover group-hover:scale-105 transition-transform duration-700"}),e.jsx("div",{className:"absolute inset-0 bg-black/20 group-hover:bg-black/40 transition-colors flex items-center justify-center",children:e.jsx("button",{onClick:()=>n(s.type,s.title,s.url),className:"w-12 h-12 bg-white/20 backdrop-blur rounded-full flex items-center justify-center text-white hover:bg-white hover:text-rose-600 transition-all scale-90 group-hover:scale-100",children:s.type==="video"?e.jsx(d,{className:"w-6 h-6 ml-1"}):e.jsx(b,{className:"w-6 h-6"})})}),e.jsx("span",{className:`absolute top-4 left-4 text-[10px] font-bold uppercase tracking-wider px-2 py-1 rounded bg-white/90 backdrop-blur ${s.type==="video"?"text-red-600":"text-blue-600"}`,children:s.type})]}),e.jsxs("div",{className:"p-6",children:[e.jsx("h3",{className:"text-lg font-serif text-rose-950 mb-2 line-clamp-2",children:s.title}),e.jsxs("div",{className:"flex items-center text-xs text-gray-400 mb-3 space-x-3",children:[e.jsx("span",{children:s.author}),e.jsx("span",{children:"•"}),e.jsx("span",{children:s.type==="video"?s.duration:s.size})]}),e.jsx("p",{className:"text-gray-500 text-sm mb-4 line-clamp-2",children:s.desc}),e.jsx("button",{onClick:()=>n(s.type,s.title,s.url),className:"w-full py-2.5 rounded-lg border border-gray-100 hover:border-rose-200 hover:bg-rose-50 text-gray-600 hover:text-rose-600 font-medium text-sm transition-all flex items-center justify-center",children:s.type==="video"?e.jsxs(e.Fragment,{children:[e.jsx(d,{className:"w-4 h-4 mr-2"})," Watch Now"]}):e.jsxs(e.Fragment,{children:[e.jsx(y,{className:"w-4 h-4 mr-2"})," Download PDF"]})})]})]},s.id))})]})};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.