1import{a as Ue}from"/build/_shared/chunk-WVJGFTQU.js";import"/build/_shared/chunk-IDNYE6NB.js";import{a as Ee,c as X,d as L}from"/build/_shared/chunk-HV556EBQ.js";import"/build/_shared/chunk-GR46FNCS.js";import"/build/_shared/chunk-FDF3ONGC.js";import{b as H}from"/build/_shared/chunk-7Y75MFQ7.js";import{a as Se}from"/build/_shared/chunk-JAWNLJZH.js";import"/build/_shared/chunk-P5W3NYDN.js";import"/build/_shared/chunk-SL3MII6H.js";import{b as Ae}from"/build/_shared/chunk-4RSFGLUF.js";import"/build/_shared/chunk-EGVGJ5WK.js";import"/build/_shared/chunk-DNUNPHFN.js";import{a as S}from"/build/_shared/chunk-NKJP27CO.js";import{a as Me}from"/build/_shared/chunk-RJ5UOVEN.js";import{a as D}from"/build/_shared/chunk-L6KTIR6S.js";import{a as Fe,b as O}from"/build/_shared/chunk-2HM5VXXT.js";import{a as tr}from"/build/_shared/chunk-T7SY6LXP.js";import{a as He}from"/build/_shared/chunk-ESP7YC77.js";import{a as Y}from"/build/_shared/chunk-JGUH65GX.js";import{a as F}from"/build/_shared/chunk-KDHEBW4K.js";import"/build/_shared/chunk-A7PPZ6FY.js";import{c as rr}from"/build/_shared/chunk-OG5QXSHW.js";import{a as A,b as ke}from"/build/_shared/chunk-CBNTOKVY.js";import{l as v}from"/build/_shared/chunk-KYHPSXSI.js";import"/build/_shared/chunk-DWMKVSXX.js";import"/build/_shared/chunk-AA6Q7QIQ.js";import{a as De}from"/build/_shared/chunk-UV5JI2KA.js";import{a as W,e as Le,m as Re,n as Pe,r as p}from"/build/_shared/chunk-LBQWAS5I.js";import{d as l}from"/build/_shared/chunk-G5WX4PPA.js";var nr=l(tr());function I(r,a){return!r&&!a?"":r&&a?`${r} ${a}`:r||""}var _e=l(W());var y=l(p()),ee=(0,_e.forwardRef)(({className:r,title:a,image:o,cardFooterText:t,showDivider:s=!0,...d},f)=>(0,y.jsxs)("div",{children:[(0,y.jsx)("a",{href:"https://renewingyourmind.org?utm_source=ligonier&utm_medium=homepage",target:"_blank",rel:"noopener noreferrer",children:(0,y.jsx)("div",{ref:f,className:v("relative shadow-card bg-white overflow-hidden w-56 h-80 hover:shadow-card-hover hover:cursor-pointer transition-shadow duration-400",r),...d,children:(0,y.jsxs)("div",{className:"h-full",children:[(0,y.jsx)("div",{className:"p-4 h-1/2",children:(0,y.jsxs)("div",{className:"h-full flex flex-col gap-4 justify-end",children:[(0,y.jsx)("div",{className:"flex items-center justify-center flex-1",children:(0,y.jsx)(D,{variant:"xs",className:"font-light text-center text-base line-clamp-3",children:a})}),(0,y.jsx)(A,{orientation:"horizontal",length:20,thickness:"thin",color:"primary"}),(0,y.jsx)("div",{className:"flex items-center w-full",children:(0,y.jsx)(H,{variant:"audio",fill:"secondary",size:"xs"})})]})}),(0,y.jsx)("div",{className:"-mt-4 absolute h-8 w-full inset-y-1/2",children:(0,y.jsx)("div",{className:"flex justify-center"})}),(0,y.jsx)("div",{className:"relative w-full h-1/2 overflow-hidden",children:(0,y.jsx)(Y,{src:(o==null?void 0:o.url)||"/images/card.png",alt:(o==null?void 0:o.title)||"Featured Image",width:275,height:160,quality:50,className:"w-full h-full object-cover"})})]})})}),t&&(0,y.jsx)("span",{className:"block text-[#100b00] font-black text-[10px] tracking-widest leading-[1.4] opacity-30 pt-4 text-center uppercase font-avenir-bold",children:t})]}));ee.displayName="RymFeaturedCard";var $e=l(W());var u=l(p()),re=(0,$e.forwardRef)(({className:r,title:a,authors:o,slug:t,image:s,cardFooterText:d,...f},i)=>{let n=o&&o[0],h=n!=null&&n.firstName&&(n!=null&&n.lastName)?`${n.firstName} ${n.lastName}`:void 0;return(0,u.jsxs)("div",{children:[(0,u.jsx)("a",{href:`https://learn.ligonier.org/${t}`,children:(0,u.jsx)("div",{ref:i,className:v("relative shadow-card bg-white overflow-hidden w-56 h-80 hover:shadow-card-hover hover:cursor-pointer transition-shadow duration-400",r),...f,children:(0,u.jsxs)("div",{className:"h-full",children:[(0,u.jsx)("div",{className:"p-5 h-1/2",children:(0,u.jsxs)("div",{className:"h-full flex flex-col gap-4 justify-end",children:[(0,u.jsx)("div",{className:"flex items-center justify-center flex-1",children:(0,u.jsx)(D,{variant:"xs",className:"font-light text-center text-base line-clamp-3",children:a})}),(0,u.jsxs)("div",{className:"flex flex-col items-center gap-4",children:[(0,u.jsx)(A,{orientation:"horizontal",length:20,thickness:"thin",color:"primary"}),(0,u.jsxs)("div",{className:"w-full flex items-center justify-start gap-12",children:[(0,u.jsx)("div",{className:"flex items-center",children:(0,u.jsx)(H,{variant:"video",fill:"secondary",size:"xs"})}),h&&n?(0,u.jsx)(O,{color:"cool",size:"sm",className:"tracking-widest",children:h}):null]})]})]})}),(0,u.jsx)("div",{className:"-mt-4 absolute h-8 w-full inset-y-1/2",children:(0,u.jsx)("div",{className:"flex justify-center",children:(0,u.jsx)(Ee,{variant:"overlap",maxToShow:1,avatarCollection:o})})}),(0,u.jsx)("div",{className:"relative w-full h-1/2 overflow-hidden",children:(0,u.jsx)(Y,{src:(s==null?void 0:s.url)||"/images/card.png",alt:(s==null?void 0:s.title)||"Featured Image",width:275,height:160,qual
1ity:50,className:"w-full h-full object-cover"})})]})})}),d&&(0,u.jsx)("span",{className:"block text-[#100b00] font-black text-[10px] tracking-widest leading-[1.4] opacity-30 pt-3 text-center uppercase font-avenir-bold",children:d})]})});re.displayName="DailyVideoFeaturedCard";var je=l(W());var g=l(p()),te=(0,je.forwardRef)(({className:r,title:a,slug:o,scriptureReference:t,image:s,cardFooterText:d,showDivider:f=!0,...i},n)=>(0,g.jsxs)("div",{children:[(0,g.jsx)("a",{href:`https://learn.ligonier.org/devotionals/${o}`,children:(0,g.jsx)("div",{ref:n,className:v("relative shadow-card bg-white overflow-hidden w-56 h-80 hover:shadow-card-hover hover:cursor-pointer transition-shadow duration-400",r),...i,children:(0,g.jsxs)("div",{className:"h-full",children:[(0,g.jsx)("div",{className:"p-4 h-1/2",children:(0,g.jsxs)("div",{className:"h-full flex flex-col gap-4 justify-end",children:[(0,g.jsx)("div",{className:"flex items-center justify-center flex-1",children:(0,g.jsx)(D,{variant:"xs",className:"font-light text-center text-base line-clamp-3",children:a})}),(0,g.jsxs)("div",{className:"flex flex-col items-center gap-4",children:[(0,g.jsx)(A,{orientation:"horizontal",length:20,thickness:"thin",color:"primary"}),(0,g.jsxs)("div",{className:"w-full flex items-center justify-start gap-12",children:[(0,g.jsx)("div",{className:"flex items-center",children:(0,g.jsx)(H,{variant:"book",fill:"secondary",size:"xs"})}),t?(0,g.jsx)(O,{color:"cool",size:"sm",className:"tracking-widest",children:t}):null]})]})]})}),(0,g.jsx)("div",{className:"-mt-4 absolute h-8 w-full inset-y-1/2",children:(0,g.jsx)("div",{className:"flex justify-center"})}),(0,g.jsx)("div",{className:"relative w-full h-1/2 overflow-hidden",children:(0,g.jsx)(Y,{src:(s==null?void 0:s.url)||"/images/card.png",alt:(s==null?void 0:s.title)||"Featured Image",width:275,height:160,quality:50,className:"w-full h-full object-cover"})})]})})}),d&&(0,g.jsx)("span",{className:"block text-[#100b00] font-black text-[10px] tracking-widest leading-[1.4] opacity-30 pt-4 text-center uppercase font-avenir-bold",children:d})]}));te.displayName="DailyDevotionalFeaturedCard";var Ve=l(W());var C=l(p()),oe=(0,Ve.forwardRef)(({className:r,title:a,subtitle:o,bodyText:t,image:s,handlePress:d,showDivider:f=!0,url:i,...n},h)=>(0,C.jsx)("a",{href:i,target:"_blank",rel:"noopener noreferrer",children:(0,C.jsx)("div",{ref:h,className:v("relative shadow-card bg-white overflow-hidden w-56 h-80 hover:shadow-card-hover hover:cursor-pointer transition-shadow duration-400",r),...n,children:(0,C.jsxs)("div",{className:"h-full",children:[(0,C.jsx)("div",{className:"p-4 h-1/2",children:(0,C.jsxs)("div",{className:"h-full flex flex-col gap-4 justify-end",children:[(0,C.jsx)("div",{className:"flex items-center justify-center flex-1",children:(0,C.jsx)(D,{variant:"xs",className:"font-light text-center text-base line-clamp-3",children:a})}),(0,C.jsxs)("div",{className:"flex flex-col items-center gap-2",children:[t&&(0,C.jsx)(He,{className:"text-center text-base text-gray-800 w-48 line-clamp-2",children:t}),o&&(0,C.jsx)("span",{className:"text-center text-base font-medium text-primary-600 no-underline",children:o})]})]})}),(0,C.jsx)("div",{className:"-mt-4 absolute h-8 w-full inset-y-1/2",children:(0,C.jsx)("div",{className:"flex justify-center"})}),(0,C.jsx)("div",{className:"relative w-full h-1/2 overflow-hidden",children:(0,C.jsx)(Y,{src:(s==null?void 0:s.url)||"/images/card.png",alt:(s==null?void 0:s.title)||"Featured Image",width:275,height:160,quality:50,className:"w-full h-full object-cover"})})]})})}));oe.displayName="LigonierAppFeaturedCard";var G=l(p());function Be({resources:r,handlePress:a}){return(0,G.jsx)("div",{className:"flex gap-4",children:r.map((o,t)=>{let s=o.slug||`daily-resource-${t}`;switch(o.contentType){case"Podcast":return(0,G.jsx)(ee,{title:o.title,image:o.image,cardFooterText:o.cardFooterText},s);case"Video":return(0,G.jsx)(re,{title:o.title,authors:o.authors,slug:o.slug,image:o.image,cardFooterText:o.cardFooterText},s);case"Devotional":return(0,G.jsx)(te,{title:o.title,slug:o.slug,image:o.image,scriptureReference:o.centerText,cardFooterText:o.cardFooterText},s);case"Promotion":return(0,G.jsx)(oe,{title:o.title,image:o.image,url:o.url,subtitle:o.subtitle,bodyText:o.bodyText},s);default:return null}})})}var Ye=l(W());var m=l(p()),Q=(0,Ye.forwardRef)(({className:r,number:a,title:o,author:t,duration:s,handlePress:d,hasAudio:f=!1,...i},n)=>(0,m.jsx)(Fe,{as:"a",onPress:d,children:(0,m.jsx)("li",{ref:n,className:v("py-4 px-2 relative bg-white hover:bg-cream transition-all duration-200 cursor-pointer group list-none",r),...i,children:(0,m.jsxs)("div",{className:"flex items-start gap-4",children:[(0,m.jsx)("div",{className:"flex-shrink-0 w-8",children:(0,m.jsxs)(D,{variant:"xs",color:"cool",className:"group-hover:text-secondary-500 transition-colors duration-200",children:[a,"."]})}),(0,m.jsxs)("div",{className:"flex-1 flex flex-col",children:[(0,m.jsx)(D,{variant:"xs",color:"dark",className:"line-clamp-1 max-w-full mb-2",children:o}),(0,m.jsx)("div",{className:"w-full flex items-center justify-between",children:(0,m.jsxs)("div",{className:"flex items-center gap-4",children:[(0,m.jsx)(O,{size:"sm",color:"cool",className:"group-hover:text-primary-600 transition-colors duration-200",children:t}),s?(0,m.jsxs)(m.Fragment,{children:[(0,m.jsx)(A,{orientation:"vertical",length:8,thickness:"thin",color:"gray"}),(0,m.jsx)(O,{size:"sm",color:"cool",className:"tracking-widest group-hover:text-primary-600 transition-colors duration-200",children:s})]}):null]})})]}),(0,m.jsx)("div",{className:"flex-shrink-0 w-8 self-end justify-end items-end",children:(0,m.jsx)("div",{className:"flex self-end justify-end items-end mb-1",children:(0,m.jsx)(H,{variant:f?"audio":"article",size:"xs",fill:"secondary"})})})]})})}));Q.displayName="ListCard";var K=l(W());var ze=r=>{var a,o,t;switch(r.resourceType){case"dailyVideo":return((a=r.content.video.series.image)==null?void 0:a.url)||"";case"podcastEpisode":return"podcastShow"in r.content?(o=r.content.podcastShow.image)==null?void 0:o.url:"";case"mediaResource":return"series"in r.content?(t=r.content.series.image)==null?void 0:t.url:"";default:return null}},We=r=>Math.trunc(r.progress/r.duration*100),Oe=r=>r.resourceType==="sermon"?r.content.sermonTitle:r.resourceType==="podcastEpisode"||r.resourceType==="dailyVideo"?r.content.title:r.content.name,qe=r=>{let a=t=>{try{return new Date(t).toLocaleDateString("en-US",{year:"numeric",month:"long",day:"numeric"})}catch{return t}},o=t=>{var d,f,i,n,h;let s=(t==null?void 0:t.total)||((d=t==null?void 0:t.items)==null?void 0:d.length)||0;switch(s){case 0:return;case 1:return(f=t==null?void 0:t.items[0])==null?void 0:f.shortName;case 2:return`${(i=t==null?void 0:t.items[0])==null?void 0:i.shortName} & ${(n=t==null?void 0:t.items[1])==null?void 0:n.shortName}`;default:return`${(h=t==null?void 0:t.items[0])==null?void 0:h.shortName} & ${s-1} Others`}};switch(r.resourceType){case"dailyVideo":{let t=r.content;return a(t.displayDate)}case"sermon":return"R.C. Sproul";
1case"mediaResource":{let t=r.content;return o({items:t.teachersCollection.items.map(d=>({shortName:d.shortName})),total:t.teachersCollection.items.length})||""}case"podcastEpisode":{let t=r.content;return a(t.date)}default:return""}};var ae=l(p()),Ge=({fill:r="#FFFFFF"})=>(0,ae.jsx)("svg",{width:53,height:48,viewBox:"0 0 53 48",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:"w-12 h-12",children:(0,ae.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M43.8007 15.9696C38.6059 8.40632 32.3832 2.18732 27.0071 0.189254L26.4825 0L25.9556 0.189254C20.5817 2.18732 14.359 8.40632 9.16421 15.9696C4.02107 23.5489 0.0281234 32.4215 0 40.0135C0.00803525 41.629 0.952752 42.9033 2.09605 43.8324C5.5604 46.5823 11.9478 47.9518 17.0313 48C18.0736 48 19.0602 47.9352 19.967 47.7895C23.1283 47.2596 25.5865 46.4745 26.4825 46.5146C27.3801 46.4745 29.8366 47.2596 32.9939 47.7895C33.9013 47.9352 34.8885 48 35.9337 48C39.3119 47.9977 43.2939 47.3238 46.5861 46.1206C48.2339 45.5122 49.7061 44.7787 50.8695 43.8324C52.0105 42.9033 52.9546 41.629 52.9655 40.0135C52.9368 32.4215 48.9427 23.5489 43.8007 15.9696ZM26.8423 14.5783C26.6202 14.5668 26.3241 14.1637 26.3241 14.1637C26.3241 14.1637 26.405 13.0815 26.4957 11.9081C26.6306 10.1549 26.4676 7.72788 26.6237 7.88673C27.0662 8.34152 27.5896 11.049 27.5397 11.8272C27.488 12.6066 27.2659 14.5491 26.8423 14.5783ZM48.9077 41.4363C46.6343 43.3816 40.3622 44.9547 35.9337 44.9077C35.0211 44.9077 34.1837 44.8469 33.4944 44.7362C32.9595 44.6508 32.4607 44.5567 31.9763 44.4541C31.4563 44.3262 29.9807 44.0148 29.1111 42.7691C28.5395 41.9513 27.9598 39.4268 29.2655 38.4019C31.3673 36.7486 33.4347 38.7191 36.0031 38.43C42.1638 37.7419 42.0789 33.947 46.4317 31.4942C38.1841 29.3281 31.3685 32.0522 29.8286 35.1009C28.5033 37.7155 27.8129 36.6413 27.8284 35.7616C27.8284 35.7616 27.8244 34.6851 27.8244 33.7033C27.8244 32.8 27.8502 31.0078 29.3631 29.9664C30.9415 28.8733 31.326 29.6705 34.5872 29.413C39.2821 29.039 39.9105 24.8663 42.6144 23.12C39.9387 23.2903 32.6467 20.21 29.075 27.7619C28.842 28.2568 28.0338 28.8383 27.748 29.3791C27.7325 26.4807 27.6154 25.598 27.7446 24.4103C27.8221 23.6768 28.3398 21.8353 29.2368 21.6753C29.9451 21.552 31.4965 21.431 32.323 21.2521C34.5189 20.7681 37.1051 18.2733 36.9736 14.8111C35.0377 15.6054 30.1638 14.1069 28.175 19.9325C27.981 20.35 27.6671 21.2441 27.4978 21.7292C27.581 20.9653 27.1517 17.1745 27.3727 15.6691C27.5586 15.4775 30.7612 12.8836 28.5607 8.91272C27.6223 7.22377 26.4664 5.20277 26.4664 5.20277C26.4664 5.20277 25.311 7.22377 24.3749 8.91272C22.1721 12.8836 25.3937 15.4976 25.5819 15.6869C25.5819 15.6869 25.5573 20.4366 25.497 20.8139C25.2887 22.1726 24.6608 18.6903 23.7436 17.5261C22.6474 16.1262 21.5322 15.36 19.4189 15.0956C18.1712 14.9413 18.0346 15.1203 15.9127 14.8111C18.2532 22.4392 21.9827 21.0726 24.022 21.5297C24.8961 21.7246 25.3242 24.423 25.3242 24.423C25.3874 23.9389 25.3042 29.0052 25.3346 29.023C23.7436 28.1094 21.9661 22.3475 17.2184 22.6744C13.6685 22.9164 10.9239 22.6474 10.7167 22.531C13.1147 26.729 14.805 30.3827 22.5475 29.3074C24.0753 29.0935 25.0419 31.5332 25.062 32.0476C25.062 32.0476 25.1739 34.2619 25.0017 35.8447C24.841 37.3599 23.9152 36.0707 22.9705 35.0963C22.0264 34.1208 18.4673 30.4011 12.3737 31.3015C8.98054 31.8033 9.42191 31.6507 6.53668 31.2545C7.84355 32.9726 11.6637 40.6432 18.7399 37.696C22.7461 36.0282 25.5573 38.6428 24.0197 42.4812C23.7069 43.2641 22.6353 44.0171 20.9186 44.4696C20.456 44.5648 19.9808 44.6554 19.4706 44.7362C18.779 44.8469 17.9393 44.9077 17.0313 44.9077C14.0697 44.9106 10.3098 44.2757 7.44581 43.217C6.01324 42.6963 4.80566 42.0568 4.05723 41.4398C3.28584 40.8009 3.08726 40.3117 3.09506 40.0135C3.06717 33.5238 6.77774 24.9339 11.7223 17.709C16.4114 10.772 22.3449 5.04047 26.4825 3.30334C30.6201 5.04047 36.5535 10.772 41.2404 17.709C46.1872 24.9339 49.8955 33.5238 49.8677 40.0135C49.8771 40.3105 49.6791 40.798 48.9077 41.4363ZM31.9223 35.2265C31.9269 35.2231 34.1028 31.8222 40.5172 31.8996C40.8926 31.9031 41.7426 31.9914 42.1403 32.0338C42.1403 32.0338 42.2321 32.1485 41.7948 32.1933C39.8858 32.4473 35.4997 34.2418 34.4827 34.7046C33.759 35.02 32.4136 35.6343 31.9539 35.6406C31.8598 35.6406 31.8236 35.4771 31.9223 35.2265ZM38.8791 24.0834C38.5945 24.5113 33.8439 25.34 30.7165 27.7016C30.7165 27.7016 30.4685 27.5479 30.5322 27.4034C32.6208 23.5254 37.6807 24.0387 38.8791 24.0834ZM29.525 19.8809C30.1758 17.549 32.929 16.4984 34.9413 16.2839L35.3155 16.2437C34.7812 17.233 31.5998 18.1019 29.7241 20.1338C29.7241 20.1338 29.4745 20.0609 29.525 19.8809ZM23.4296 19.5098C23.4296 19.7249 23.161 19.6836 23.161 19.6836C23.161 19.6836 20.6162 17.7188 18.1344 16.117C18.0133 16.0682 18.0231 15.9696 18.0231 15.9696C21.0151 16.2627 23.1857 18.0055 23.4296 19.5098ZM22.6169 27.3128C22.6169 27.4304 22.3994 27.4619 22.3994 27.4619C22.1607 27.4459 20.2035 26.3918 18.6188 25.6262C16.6714 24.6839 14.4675 24.1213 14.4675 24.1213C18.4794 23.6768 20.9571 24.7533 22.3673 26.8099C22.5194 27.0364 22.5991 27.1436 22.6169 27.3128ZM10.8671 32.9583C10.8837 32.8304 13.2639 32.4777 14.1392 32.4777C18.8117 32.4777 21.1149 35.0963 21.1608 35.2913C21.1597 35.4077 20.9841 35.4662 20.9657 35.4662C20.421 35.4525 14.9857 33.2806 11.0117 33.0512C11.0117 33.0512 10.8705 32.9985 10.8671 32.9583Z",fill:r})});var ne=l(p()),Ze=({progress:r})=>(0,ne.jsx)("div",{className:"absolute bottom-0 left-0 right-0 h-1 bg-white/50 rounded-sm overflow-hidden",children:(0,ne.jsx)("div",{className:"h-full bg-secondary-400 rounded-sm transition-all duration-1000 ease-out",style:{width:`${r}%`}})});var R=l(p()),Qe=({item:r})=>{let a=ze(r),o=We(r),t=Oe(r),s=qe(r),d=r.resourceType==="podcastEpisode"?r.content.podcastShow.color:void 0;return(0,R.jsxs)("a",{href:r.navigationUrl,target:"_blank",rel:"noreferrer",className:v("w-[232px] block relative bg-white rounded-sm shadow-[0_0_32px_rgba(16,11,0,0.06)]","transition-all duration-250 hover:shadow-[0_0_32px_rgba(16,11,0,0.2)]","overflow-hidden"),children:[(0,R.jsxs)("div",{className:"relative w-[234px] h-[144px]",style:{aspectRatio:"234 / 144"}
1,children:[r.resourceType==="podcastEpisode"?(0,R.jsx)("div",{className:"h-full w-full flex items-center justify-center",style:{backgroundColor:d||"transparent"},children:a&&(0,R.jsx)("img",{className:"object-contain",src:a,height:100,width:100,alt:"recent resource"})}):(0,R.jsx)("div",{className:v(!a&&"bg-primary-800 flex items-center justify-center h-full"),children:a?(0,R.jsx)("img",{className:"w-full h-full",src:a,alt:"recent resource",style:{aspectRatio:"234 / 144"}}):(0,R.jsx)(Ge,{})}),(0,R.jsx)(Ze,{progress:o})]}),(0,R.jsxs)("div",{className:"p-2",children:[(0,R.jsx)("div",{className:"font-mercury text-[17px] text-text-dark overflow-hidden text-ellipsis whitespace-nowrap",children:t}),(0,R.jsx)("div",{className:"text-steel font-avenir-caps text-[11px] leading-[140%] tracking-[1px] uppercase mt-1",children:s})]})]})};var Z=l(W());var Je=/^(.+)\.remix-app-(.+)\.preflig\.ht$/,J=r=>r?Je.test(r)||r.includes("staging"):typeof window!="undefined"?Je.test(window.location.hostname)||window.location.hostname.includes("staging"):!1;var Ke=async r=>{try{let a=await fetch("/api/progress-navigation-urls",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({items:r})});if(!a.ok)throw new Error(`API error: ${a.status}`);return(await a.json()).navigationUrls||[]}catch(a){console.error("Error fetching navigation URLs:",a);let t=J()?"https://stage-learn.ligonier.org/":"https://learn.ligonier.org/";return r.map(s=>{switch(s.resourceType){case"sermon":return`${t}sermons`;case"podcastEpisode":return`${t}podcasts`;case"dailyVideo":return`${t}daily-video`;case"mediaResource":return`${t}series`;default:return t}})}};var or=async r=>{let a={offset:0,limit:4,filters:["Sermon","Podcast Episode","Daily Video","Teaching Series Message","Conference Message"]},o=`?type=${a.filters.join(",")}`,t=`&limit=${a.limit}`,d=`${De().PUBLIC_LIBRARY_API_URL||"https://library.ligonier.org"}/api/progress${o}${t}`,f={Authorization:`Bearer ${r}`,"Content-Type":"application/json"};try{let i=await fetch(d,{headers:f,credentials:"omit",method:"GET"});if(!i.ok)throw new Error(`HTTP error! status: ${i.status}`);return(await i.json()).data}catch(i){return console.error("Error fetching progress data:",i),null}},Xe=(r,a)=>{let[o,t]=(0,Z.useState)([]),[s,d]=(0,Z.useState)(!1),[f,i]=(0,Z.useState)(null);return(0,Z.useEffect)(()=>{(async()=>{if(!r||!a){t([]),d(!1);return}d(!0),i(null);try{let h=await or(a);if(h!=null&&h.resources){let M=await Ke(h.resources),z=h.resources.map((E,U)=>({...E,navigationUrl:M[U]}));t(z)}else t([])}catch(h){console.error("Error in useProgressData:",h),i(h instanceof Error?h:new Error("Unknown error")),t([])}finally{d(!1)}})()},[r,a]),{progressData:o,progressDataLoading:s,error:f}};var P=l(p()),ar=()=>(0,P.jsxs)("div",{className:"w-[234px] bg-white rounded-sm shadow-[0_0_32px_rgba(16,11,0,0.06)] overflow-hidden animate-pulse",children:[(0,P.jsx)("div",{className:"h-36 bg-gray-200"}),(0,P.jsxs)("div",{className:"p-2",children:[(0,P.jsx)("div",{className:"h-5 bg-gray-200 rounded mb-2"}),(0,P.jsx)("div",{className:"h-3 bg-gray-200 rounded w-3/4"})]})]}),Ie=({authenticated:r,accessToken:a})=>{let{progressData:o,progressDataLoading:t}=Xe(r,a),[s,d]=(0,K.useState)("https://library.ligonier.org");if((0,K.useEffect)(()=>{let n=J()?"https://stage-library.ligonier.org":"https://library.ligonier.org";d(n)},[]),!r||!o.length)return null;let f=!t&&o.length<4;return(0,P.jsx)(L.ContentCollection,{title:"Resume Your Study",carouselClassName:"py-4",className:v("pt-[3em] mb-12 lg:mb-0 lg:pb-20",f?"lg:w-[1040px] lg:mx-auto":""),rightElement:(0,P.jsxs)("a",{href:s,target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-2 cursor-pointer group hover:underline",children:[(0,P.jsx)("span",{className:"text-primary-500 text-sm font-normal leading-[22px] capitalize",children:"See More"}),(0,P.jsx)(H,{size:"sm",fill:"primary",variant:"chevron-right"})]}),children:t?Array.from({length:4},(i,n)=>(0,P.jsx)(ar,{},`skeleton-${n}`)):o.map(i=>(0,P.jsx)(Qe,{item:i},i.resourceId))})};var k=l(rr());var c=l(p()),sr={navVariant:"clear"};var ir=()=>{let r=F.description,a=F.title,o=F.openGraphImage;return[{title:a},{name:"description",content:r},{name:"keywords",content:F.keywords.join(", ")},{"og:type":F.openGraphType},{"og:site_name":F.openGraphSiteName},{"og:title":a},{"og:description":r},{"og:image":o},{"og:image:secure_url":o},{"twitter:card":F.twitterCard},{"twitter:site":F.twitterSite},{"twitter:title":a},{"twitter:image":o},{"twitter:description":r},{"fb:pages":F.fbPage}
1]};function er(){var le,de,ce,pe,ue,ge,me,fe,he,ve,ye,xe,Ce,we,be,Ne,Te;let r=Re(),a=Pe("root"),o=Le(),{featuredForYouCollection:t,additionalFeaturedCollection:s,recentListCollection:d,popularListCollection:f,homePagePromotion:i,featuredEvent:n,displayFeaturedEvent:h,callToAction:M,eventCollection:z,yearEndHeader:E,user:U,dailyResources:se}=r,q=a==null?void 0:a.ENV,ie={placeholder:"Search",querySuggestionsIndex:`${q==null?void 0:q.PUBLIC_ALGOLIA_ENV}_${k.algoliaIdxs.querySuggestions}`||"",searchResultsIndex:(q==null?void 0:q.PUBLIC_ALGOLIA_ENV)||"",onSelectSearchResult:e=>{let{urlFromAlgolia:b,internal:w}=(0,k.getUrlFromAlgoliaRecord)(e,"Search"),x=w?b:Se(b);w?o(x):window.location.href=x},onSearch:e=>{window.location.href=`https://www.ligonier.org/search?query=${e}`},renderItemImage:k.renderItemImage,renderPersonItemImage:k.renderItemImage,renderProductItemImage:k.renderProductItemImage,renderAvatarImage:k.renderAvatarImage};return(0,c.jsxs)(ke.Main,{children:[(0,c.jsx)(L.IndexPageHero,{data:E,handlePress:S((le=E==null?void 0:E.primaryCtaLink)!=null?le:""),searchProps:ie}),(0,c.jsxs)("div",{className:v("relative",!E&&"-mt-[13.6em]"),children:[E&&(0,c.jsx)("div",{className:"my-[72px] px-5",children:(0,c.jsx)(Ae,{...ie,inputVariant:"gray",placeholder:"Search",className:"min-w-[200px] max-w-[446px] mx-auto",dropdownClassName:"!mt-1 !mx-auto max-w-[480px] !left-0 !right-0 md:!-left-[82px] md:!-right-[82px] md:max-w-[650px] bg-white rounded shadow-card p-6 [&>div]:!shadow-none [&>div]:!p-0 [&>div]:!bg-transparent"})}),t.length>0?(0,c.jsx)(L.ContentCollection,{title:"For You",labelVariant:E?"dark":"light",children:t.map((e,b)=>{var w,x,N,T;return e?(0,c.jsx)(X,{contentType:e==null?void 0:e.contentType,title:(e==null?void 0:e.title)||"Untitled",authors:(e==null?void 0:e.authors)||[],additionalAuthorsCount:(x=(w=e==null?void 0:e.authors)==null?void 0:w.length)!=null?x:0,image:e==null?void 0:e.image,duration:(N=e==null?void 0:e.duration)!=null?N:">1MIN",handlePress:S((T=e==null?void 0:e.url)!=null?T:"")},(e==null?void 0:e.slug)||b):null})}):null,(0,c.jsx)(Ie,{authenticated:U==null?void 0:U.authenticated,accessToken:U!=null&&U.authenticated?U.accessToken:void 0}),i?(0,c.jsx)(L.PromotionBlock,{overline:(de=i==null?void 0:i.overline)!=null?de:"",headline:(ce=i==null?void 0:i.headline)!=null?ce:"",subhead:i==null?void 0:i.subhead,image:i==null?void 0:i.image,primaryCtaText:(pe=i==null?void 0:i.primaryCtaText)!=null?pe
1:"",handlePress:S((ue=i==null?void 0:i.primaryCtaLink)!=null?ue:""),background:"cream"}):null,s.length>0?(0,c.jsx)(L.ContentCollection,{title:"Featured",divider:"bottom",children:s.map((e,b)=>{var w,x,N,T;return(0,c.jsx)(X,{contentType:e==null?void 0:e.contentType,title:(e==null?void 0:e.title)||"Untitled",authors:(e==null?void 0:e.authors)||[],additionalAuthorsCount:(x=(w=e==null?void 0:e.authors)==null?void 0:w.length)!=null?x:0,image:e==null?void 0:e.image,duration:(N=e==null?void 0:e.duration)!=null?N:">1MIN",handlePress:S((T=e==null?void 0:e.url)!=null?T:"")},(e==null?void 0:e.slug)||b)})}):null,f.length>0||d.length>0?(0,c.jsxs)("section",{className:v("ps-2 py-16 lg:py-24 flex flex-col lg:flex-row justify-center items-start md:items-center gap-12 lg:gap-20"),children:[(0,c.jsx)(L.ContentList,{title:"Trending",subTitle:"See what other people are studying",as:"ol",children:f.map((e,b)=>{var w,x,N,T,_,$,j,V,B;return(0,c.jsx)(Q,{number:b+1,title:(w=e==null?void 0:e.title)!=null?w:"",author:I((T=(N=(x=e==null?void 0:e.authors)==null?void 0:x[0])==null?void 0:N.firstName)!=null?T:"",(j=($=(_=e==null?void 0:e.authors)==null?void 0:_[0])==null?void 0:$.lastName)!=null?j:""),duration:(V=e==null?void 0:e.duration)!=null?V:"",handlePress:S((B=e==null?void 0:e.url)!=null?B:"")},b)})}),(0,c.jsx)(A,{color:"cool",length:520,orientation:"vertical",thickness:"thin",hideBelow:"lg"}),(0,c.jsx)(L.ContentList,{title:"Recent",subTitle:"Explore our latest resources and updates.",callToActionLink:"https://search.ligonier.org/?sort=newest",callToActionText:"See More",as:"ol",children:d.map((e,b)=>{var w,x,N,T,_,$,j,V,B;return(0,c.jsx)(Q,{number:b+1,title:(w=e==null?void 0:e.title)!=null?w:"",author:I((T=(N=(x=e==null?void 0:e.authors)==null?void 0:x[0])==null?void 0:N.firstName)!=null?T:"",(j=($=(_=e==null?void 0:e.authors)==null?void 0:_[0])==null?void 0:$.lastName)!=null?j:""),duration:(V=e==null?void 0:e.duration)!=null?V:"",handlePress:S((B=e==null?void 0:e.url)!=null?B:"")},b)})})]}):null,se.length>0?(0,c.jsx)(L.ContentCollection,{title:"Daily Resources",divider:"top",children:(0,c.jsx)(Be,{resources:se,handlePress:S})}):null,M?(0,c.jsx)(L.CallToActionBlock,{title:(ge=M.title)!=null?ge:"",subTitle:(me=M.subtitle)!=null?me:"",body:(fe=M.body)!=null?fe:"",image:M.image,callToActionText:(he=M.buttonText)!=null?he:"",callToActionLink:(ve=M.buttonUrl)!=null?ve:"",sectionClassName:"p-8 md:py-16"}):null,(0,c.jsxs)("section",{className:v("flex flex-col justify-center items-center gap-12 lg:gap-0 pt-12","max-lg:border-t max-lg:border-black/[0.08]"),children:[z&&z.length>0?(0,c.jsxs)(L.ContentList,{title:"Upcoming Events",callToActionLink:"https://www.ligonier.org/events",callToActionText:"See More Events",as:"ol",size:"md",listClassName:"pl-0",wrapperClassName:"gap-0 lg:max-w-3xl xl:max-w-5xl",hideHeaderOnDesktop:!0,children:[h&&n?(0,c.jsx)(L.FeaturedEvent,{title:(ye=n==null?void 0:n.title)!=null?ye:"",image:n==null?void 0:n.image,speakersCollection:(Ce=(xe=n==null?void 0:n.speakersCollection)==null?void 0:xe.items)!=null?Ce:[],callToActionText:"Learn More",startDate:(we=n==null?void 0:n.startDate)!=null?we:"",endDate:(be=n==null?void 0:n.endDate)!=null?be:"",location:(Ne=n==null?void 0:n.location)!=null?Ne:"",handlePress:S((Te=n==null?void 0:n.url)!=null?Te:""),titleClassName:"text-xl lg:text-4xl"}):null,z==null?void 0:z.slice(1,3).map((e,b,w)=>{var x,N,T,_,$,j,V,B;return(0,c.jsx)("li",{className:"w-full list-none mb-6 border-none lg:border-b lg:border-0 lg:border-solid",children:(0,c.jsx)(Ue,{title:(x=e==null?void 0:e.title)!=null?x:"",speakersCollection:(T=(N=e==null?void 0:e.speakersCollection)==null?void 0:N.items)!=null?T:[],startDate:(_=e==null?void 0:e.startDate)!=null?_:"",endDate:($=e==null?void 0:e.endDate)!=null?$:"",location:(j=e==null?void 0:e.location)!=null?j:"",image:e==null?void 0:e.image,callToActionText:"Learn More",callToActionLink:(V=e==null?void 0:e.url)!=null?V:"",handlePress:S((B=e==null?void 0:e.url)!=null?B:"")})},`event-list-item-${b}`)})]}):null,(0,c.jsx)(Me,{onPress:S("/events"),className:"hidden lg:block",children:"See More Events"})]})]})]})}export{er as default,sr as handle,ir as meta};
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.