(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1931],{8247:function(e,s,t){Promise.resolve().then(t.bind(t,3003)),Promise.resolve().then(t.bind(t,4962)),Promise.resolve().then(t.bind(t,4785)),Promise.resolve().then(t.bind(t,6612)),Promise.resolve().then(t.bind(t,3761)),Promise.resolve().then(t.bind(t,1742)),Promise.resolve().then(t.bind(t,4264)),Promise.resolve().then(t.bind(t,4205)),Promise.resolve().then(t.bind(t,9457)),Promise.resolve().then(t.bind(t,3390)),Promise.resolve().then(t.bind(t,5719)),Promise.resolve().then(t.bind(t,7052)),Promise.resolve().then(t.bind(t,7810)),Promise.resolve().then(t.t.bind(t,8753,23)),Promise.resolve().then(t.bind(t,4787)),Promise.resolve().then(t.t.bind(t,5469,23)),Promise.resolve().then(t.bind(t,897)),Promise.resolve().then(t.bind(t,697))},5710:function(e,s,t){"use strict";t.d(s,{Z7:function(){return l}});var a=t(7573);let l=()=>(0,a.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor",className:"h-4 w-4",children:(0,a.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M12 6.042A8.967 8.967 0 006 3.75c-1.052 0-2.062.18-3 .512v14.25A8.987 8.987 0 016 18c2.305 0 4.408.867 6 2.292m0-14.25a8.966 8.966 0 016-2.292c1.052 0 2.062.18 3 .512v14.25A8.987 8.987 0 0018 18a8.967 8.967 0 00-6 2.292m0-14.25v14.25"})})},2471:function(e,s){"use strict";s.Z=e=>new Date(e).toLocaleDateString("en-US",{year:"numeric",month:"short",day:"numeric"})},3259:function(e,s,t){"use strict";var a=t(2446);s.Z=e=>(0,a.slug)(e)},3003:function(e,s,t){"use strict";t.d(s,{InfiniteList:function(){return d}});var a=t(7573),l=t(9187),r=t(7653),i=t(9899);t(1364);var n=t(359);(0,n.$)("cab46373cdd213d9cc0a7bfcb751d7b4781ba640"),(0,n.$)("88a7a1b146772384eb09e5c912f28ae9f3a65421");var c=(0,n.$)("dab4ff0f648d99df1ab660a7d07f7b00db5822ae");(0,n.$)("1cf0f91680af43dc4ac1e9c024a659d8ae13fedf"),(0,n.$)("8f3fae20be6b736d6ee83508d352c2329f53498d"),(0,n.$)("d1d5097efcd180f3c9f493b49d24a671ded4836f"),(0,n.$)("3bf635b9f8e82f24abbef2e65b24e58080b045de"),(0,n.$)("95f5f4a22f1c63bcf7609c39d4b5952324555846"),(0,n.$)("de0c76c7880d4d0135c59d5e447ef6d6b3b070fc"),(0,n.$)("a8d3215c8803fbea1c3618cfaac005ebe7b0445f"),(0,n.$)("a0a2a233b45ad57d398af187f412f56dd284bf3d"),(0,n.$)("fce07f12ac4bd57c0ae7c374695d9de8dfe0ff4f"),(0,n.$)("f83955f297f6c8ff4fc12247090834b8ab49ad6f");let d=e=>{let{RenderCard:s}=e,[t,n]=(0,r.useState)([]),[d,o]=(0,r.useState)(!1),m=(0,r.useRef)(null),[x,h]=(0,r.useState)(!0),[u,f]=(0,r.useState)(2),{isIntersecting:p}=(0,i.S)(m,{}),v=(0,r.useCallback)(async()=>{if(d||!x)return;o(!0);let e=await c(u);o(!1),e&&(0===e.rows.length?h(!1):(n(s=>[...s,...e.rows]),f(e=>e+1)))},[x,d,u]);return(0,r.useEffect)(()=>{p&&x&&!d&&v()},[x,p,v,d]),(0,a.jsxs)(a.Fragment,{children:[t.map(e=>(0,a.jsx)(s,{post:e},e.slug)),d&&(0,a.jsx)("div",{className:"flex items-center justify-center py-8",children:(0,a.jsx)(l.Z,{className:"animate-spin",size:24})}),(0,a.jsx)("div",{ref:m})]})}},4264:function(e,s,t){"use strict";var a=t(7573),l=t(7653);s.default=()=>{let[e,s]=(0,l.useState)(!1);return(0,l.useEffect)(()=>{let e=()=>{window.scrollY>50?s(!0):s(!1)};return window.addEventListener("scroll",e),()=>window.removeEventListener("scroll",e)},[]),(0,a.jsx)("div",{className:"fixed bottom-20 right-8 hidden flex-col gap-3 ".concat(e?"md:flex":"md:hidden"),children:(0,a.jsx)("button",{"aria-label":"Scroll To Top",type:"button",onClick:()=>{window.scrollTo({top:0,behavior:"smooth"})},className:"rounded-full bg-gray-200 p-2 text-gray-500 transition-all hover:bg-gray-300 dark:bg-gray-700 dark:text-gray-300 dark:hover:bg-gray-600",children:(0,a.jsx)("svg",{className:"h-5 w-5",viewBox:"0 0 20 20",fill:"currentColor",children:(0,a.jsx)("path",{fillRule:"evenodd",d:"M3.293 9.707a1 1 0 010-1.414l6-6a1 1 0 011.414 0l6 6a1 1 0 01-1.414 1.414L11 5.414V17a1 1 0 11-2 0V5.414L4.707 9.707a1 1 0 01-1.414 0z",clipRule:"evenodd"})})})})}},9457:function(e,s,t){"use strict";t.d(s,{RenderCard:function(){return d}});var a=t(7573),l=t(5531),r=t.n(l),i=t(7174),n=t(2471),c=t(1109);let d=e=>{var s,t,l;let{post:d,size:o="sm"}=e;return(0,a.jsxs)("div",{className:"shrink-0 basis-full xl:basis-[70%] space-y-4",children:[(0,a.jsx)(c.Z,{className:"block",href:d.slug,children:(0,a.jsx)("div",{className:"relative block bg-black/5 dark:bg-white/5 ",children:(0,a.jsx)(i.E,{src:null!==(l=d.cover_image.src)&&void 0!==l?l:"",className:"object-cover",alt:d.title})})}),(0,a.jsx)("div",{className:"flex flex-wrap items-center gap-3",children:(0,a.jsxs)("div",{className:"data-color flex items-center text-sm ",children:[(0,a.jsx)("span",{className:"whitespace-nowrap ",children:(0,n.Z)(d.publishedAt)}),(0,a.jsx)("span",{className:"px-2.5",children:"⋅"}),(0,a.jsxs)("span",{className:"whitespace-nowrap",children:[null===(s=d.stats)||void 0===s?void 0:s.reading_time," read"]})]})}),(0,a.jsx)("h4",{className:r()("text-xl font-bold leading-snug",{"sm:text-md":"sm"===o,"sm:text-4xl":"md"===o}),children:(0,a.jsx)(c.Z,{className:"block",href:d.slug,children:d.title})}),(0,a.jsx)("p",{className:r()("font-normal opacity-80",{"sm:text-md":"sm"===o,"sm:text-xl":"md"===o}),children:d.excerpt}),(0,a.jsx)("div",{className:"flex items-center gap-2",children:(0,a.jsx)("div",{children:(0,a.jsx)(c.Z,{className:"heading-color text-sm font-medium",href:"/about",children:(null===(t=d.author)||void 0===t?void 0:t.__typename)==="Author"?d.author.name:""})})})]})}},3390:function(e,s,t){"use strict";t.d(s,{Card:function(){return d},HorizontalCard:function(){return o}});var a=t(7573),l=t(5531),r=t.n(l),i=t(7174),n=t(2471),c=t(1109);let d=e=>{var s,t,l,d;let{post:o,size:m="sm"}=e;return(0,a.jsxs)("div",{className:"shrink-0 basis-full xl:basis-[55%]",children:[(0,a.jsx)(c.Z,{className:"block",href:o.slug,children:(0,a.jsx)("div",{className:"relative block bg-black/5 dark:bg-white/5",children:(0,a.jsx)(i.E,{src:null!==(d=null===(s=o.cover_image)||void 0===s?void 0:s.src)&&void 0!==d?d:"",alt:o.title,className:"object-cover"})})}),(0,a.jsxs)("div",{className:r()("flex flex-col",{"gap-4 py-6":"md"===m,"gap-2 py-4":"sm"===m,"gap-2 py-2":"xs"===m}),children:[(0,a.jsx)("div",{className:r()("flex flex-wrap items-center gap-3",{}),children:(0,a.jsxs)("div",{className:"data-color flex items-center text-sm ",children:[(0,a.jsx)("span",{className:"whitespace-nowrap",children:(0,n.Z)(o.publishedAt)}),(0,a.jsx)("span",{className:"px-2.5",children:"⋅"}),(0,a.jsxs)("span",{className:"whitespace-nowrap",children:[null===(t=o.stats)||void 0===t?void 0:t.reading_time," read"]})]})}),(0,a.jsx)("h2",{className:r()("font-system hyphens-auto break-all text-xl font-bold leading-snug",{"sm:text-sm":"xs"===m,"sm:text-[1.1rem]":"sm"===m,"sm:text-4xl":"md"===m}),children:(0,a.jsx)(c.Z,{className:"block",href:o.slug,children:o.title})}),(0,a.jsx)("p",{className:r()("font-normal opacity-80",{"sm:text-sm":"xs"===m,"sm:text-md":"sm"===m,"sm:text-xl":"md"===m}),children:o.excerpt}),(0,a.jsx)("div",{className:r()("flex items-center",{hidden:"xs"===m||"sm"===m}),children:(0,a.jsx)("div",{children:(0,a.jsx)(c.Z,{className:"heading-color text-sm font-medium",href:"/about",children:(null===(l=o.author)||void 0===l?void 0:l.__typename)==="Author"?o.author.name:""})})})]})]})},o=e=>{var s,t,l;let{post:r}=e;return(0,a.jsxs)(c.Z,{className:"flex flex-col items-center gap-2 rounded-lg  md:max-w-xl md:flex-row",href:r.slug,children:[(0,a.jsx)("div",{className:"relative block h-52 w-full bg-black/5 dark:bg-white/5 sm:h-44 sm:w-52",children:(0,a.jsx)(i.E,{src:null!==(l=null===(s=r.cover_image)||void 0===s?void 0:s.src)&&void 0!==l?l:"",alt:r.title,className:"rounded-t-lg  md:rounded-lg object-cover"})}),(0,a.jsxs)("div",{className:"flex w-full flex-col justify-between p-2 leading-normal",children:[(0,a.jsx)("h5",{className:"mb-2 text-sm font-bold tracking-tight text-gray-900 dark:text-white",children:r.title}),(0,a.jsx)("p",{className:"mb-3 text-sm font-normal leading-5 text-gray-700 dark:text-white/70",children:r.excerpt}),(0,a.jsxs)("div",{className:"data-color flex items-center text-xs  opacity-80",children:[(0,a.jsx)("span",{className:"whitespace-nowrap",children:(0,n.Z)(r.publishedAt)}),(0,a.jsx)("span",{className:"px-2.5",children:"⋅"}),(0,a.jsxs)("span",{className:"whitespace-nowrap",children:[null===(t=r.stats)||void 0===t?void 0:t.reading_time," read"]})]})]})]})}},5719:function(e,s,t){"use strict";t.d(s,{RenderCard:function(){return o}});var a=t(7573),l=t(5531),r=t.n(l),i=t(7174),n=t(2471),c=t(5710),d=t(1109);let o=e=>{var s;let{post:t}=e,{slug:l,publishedAt:o,title:m,excerpt:x,cover_image:h,stats:u}=t;return(0,a.jsx)("div",{className:"bg-day dark:bg-night group w-full bg-opacity-50 dark:bg-opacity-50",children:(0,a.jsxs)(d.Z,{className:"c-card block transform overflow-hidden rounded-lg bg-transparent transition duration-300 group-hover:scale-[1.02]",href:null!=l?l:"",children:[(0,a.jsx)("div",{className:"relative max-h-4 overflow-hidden rounded-lg pb-60",children:(0,a.jsx)("span",{children:(0,a.jsx)(i.E,{src:null===(s=h.src)||void 0===s?void 0:s.replace("w=1080","w=600"),alt:m,style:{objectFit:"cover"}})})}),(0,a.jsxs)("div",{className:"h-44 px-2 py-4 md:px-0",children:[(0,a.jsxs)("span",{className:"inline-flex w-full items-center justify-between",children:[(0,a.jsxs)("span",{className:"flex items-center gap-1 text-sm",children:[(0,a.jsx)(c.Z7,{}),null==u?void 0:u.reading_time," read"]}),(0,a.jsx)("time",{dateTime:o,className:"text-sm",children:(0,n.Z)(o)})]}),(0,a.jsx)("h4",{className:r()("mb-2 mt-2 font-bold leading-5"),children:m}),(0,a.jsx)("p",{className:"text-base tracking-tight text-gray-600 dark:text-gray-300",children:x})]})]})},l)}},7052:function(e,s,t){"use strict";t.d(s,{RenderCard:function(){return c}});var a=t(7573),l=t(1109),r=t(2471),i=t(5710);let n=e=>{let{publishedAt:s,className:t,reading_time:l,separator:n}=e;return(0,a.jsxs)("dl",{className:t+" text-gray-500 dark:text-gray-400",children:[(0,a.jsx)("dt",{className:"sr-only",children:"Published on"}),(0,a.jsx)("dd",{className:" font-medium leading-6 ",children:(0,a.jsx)("time",{dateTime:s,children:(0,r.Z)(s)})}),n,(0,a.jsxs)("span",{className:"flex items-center gap-1",children:[(0,a.jsx)(i.Z7,{}),l.replace("read","")," read"]})]})},c=e=>{let{post:s}=e,{slug:t,publishedAt:r,title:i,excerpt:c,stats:d}=s;return(0,a.jsx)("li",{className:"py-12 dark:border-gray-800 [&:not(:last-child)]:border-b-[1px]",children:(0,a.jsxs)("article",{className:"md:space-y-2 xl:grid xl:grid-cols-4 xl:items-baseline xl:space-y-0",children:[(0,a.jsx)(n,{publishedAt:r,className:"flex justify-between text-sm xl:block",reading_time:null==d?void 0:d.reading_time}),(0,a.jsxs)("div",{className:"md:space-y-3 xl:col-span-3",children:[(0,a.jsx)("div",{children:(0,a.jsx)("h3",{className:"text-xl font-bold leading-8 tracking-tight md:text-2xl",children:(0,a.jsx)(l.Z,{href:"".concat(t),className:"text-gray-900 dark:text-gray-100",children:i})})}),(0,a.jsx)("div",{className:"max-w-none text-md leading-6 text-gray-500 dark:text-gray-300",children:c})]})]})},t)}},7810:function(e,s,t){"use strict";t.d(s,{RenderCard:function(){return o}});var a=t(7573),l=t(7174),r=t(2471),i=t(5710),n=t(1109),c=t(3259);let d=e=>{let{text:s,className:t}=e,l=s;return l=s.toLowerCase().startsWith("_topic_")?s.replace("_topic_",""):l.split(" ").join("-"),(0,a.jsx)("span",{onClick:()=>{window.location.href="/tag/".concat((0,c.Z)(s))},className:"text-xs font-medium uppercase ".concat(t),children:l})};function o(e){var s,t,c;let{post:o}=e,m=o.tags.rows.filter(e=>e.name.startsWith("_topic_")).map(e=>e.name);return(0,a.jsx)("li",{className:"group w-full",children:(0,a.jsxs)(n.Z,{className:"block overflow-hidden rounded-2xl bg-white/[0.7] dark:bg-white/[0.15]  group-hover:shadow-xl transition hover:scale-[1.01] dark:hover:shadow-slate-800 duration-100 ease-in-out",href:null!==(t=o.slug)&&void 0!==t?t:"",children:[(0,a.jsxs)("div",{className:"relative max-h-4 overflow-hidden pb-60",children:[(0,a.jsx)("span",{children:(0,a.jsx)(l.E,{className:"",src:null!==(c=o.cover_image.src)&&void 0!==c?c:"",alt:o.title,style:{objectFit:"cover"}})}),(0,a.jsx)("div",{className:"h-16 absolute bottom-0 z-10 left-0",children:(0,a.jsx)("div",{className:"flex flex-wrap gap-2 mt-4 mb-2",children:m.map((e,s)=>(0,a.jsx)(d,{text:e,className:"text-white text-shadow bg-slate-900/75 hover:bg-slate-900 rounded-r-xl py-2 px-4"},s))})})]}),(0,a.jsxs)("div",{className:"px-6 py-4",children:[(0,a.jsx)("div",{className:"h-16",children:(0,a.jsx)("h3",{className:"mb-2 mt-2 font-bold text-lg leading-6 line-clamp-2",children:o.title})}),(0,a.jsx)("div",{className:"h-32",children:(0,a.jsx)("p",{className:"text-sm tracking-tight text-gray-600 dark:text-gray-300 line-clamp-4 leading-6",children:o.excerpt})}),(0,a.jsxs)("div",{className:"my-2 opacity-60 inline-flex w-full items-center justify-between",children:[(0,a.jsxs)("span",{className:"flex items-center gap-1 text-sm",children:[(0,a.jsx)(i.Z7,{}),null===(s=o.stats)||void 0===s?void 0:s.reading_time," read"]}),(0,a.jsx)("time",{dateTime:o.publishedAt,className:"text-sm",children:(0,r.Z)(o.publishedAt)})]})]})]})})}},4787:function(e,s,t){"use strict";t.d(s,{RenderCard:function(){return d}});var a=t(7573),l=t(7174),r=t(1109),i=t(3259);let n=e=>{let{text:s,className:t}=e,l=s;return l=s.toLowerCase().startsWith("_topic_")?s.replace("_topic_",""):l.split(" ").join("-"),(0,a.jsx)(r.Z,{href:"/tag/".concat((0,i.Z)(s)),className:"text-[0.6rem] font-medium uppercase ".concat(t),children:l})},c=e=>new Date(e).toLocaleString("en-us",{month:"short",year:"numeric",day:"numeric"}),d=e=>{let{post:s}=e,{slug:t,publishedAt:i,title:d,excerpt:o,stats:m,id:x,cover_image:h,tags:u}=s,f=(null==u?void 0:u.__typename)==="TagsNode"?u.rows.find(e=>e.name.startsWith("_topic_")):null;return(0,a.jsx)("article",{"aria-labelledby":"episode-".concat(x,"-title"),className:"py-10 sm:py-12",children:(0,a.jsx)("div",{className:"lg:px-8",children:(0,a.jsxs)("div",{className:"lg:max-w-4xl",children:[(0,a.jsxs)("div",{className:"relative",children:[(0,a.jsx)(r.Z,{href:"".concat(t),children:(0,a.jsx)(l.E,{src:h.src,alt:d,className:"mb-8 w-full h-72 object-cover rounded-lg",loading:"lazy"})}),(null==f?void 0:f.name)&&(0,a.jsx)(n,{text:f.name,className:"text-white text-shadow bg-slate-900/75 hover:bg-slate-900 rounded-r-xl py-1 px-2 absolute bottom-2 left-0"})]}),(0,a.jsx)("div",{className:"mx-auto px-4 sm:px-6 md:max-w-2xl md:px-4 lg:px-0",children:(0,a.jsxs)("div",{className:"flex flex-col items-start",children:[(0,a.jsx)("h2",{className:"mt-2 text-lg font-bold ",children:(0,a.jsx)(r.Z,{href:"".concat(t),children:d})}),(0,a.jsx)("time",{dateTime:i,className:"order-first text-sm leading-7 opacity-80",children:c(i)}),(0,a.jsx)("p",{className:"mt-1 text-base leading-7 opacity-85",children:o}),(0,a.jsxs)("div",{className:"mt-4 flex items-center gap-4 justify-between",children:[(0,a.jsx)(r.Z,{className:"flex items-center text-sm font-bold leading-6 text-pink-500 hover:text-pink-700 active:text-pink-900",href:"".concat(t),children:"Read More"}),(0,a.jsx)("span",{"aria-hidden":"true",className:"text-sm font-bold text-slate-400",children:"•"}),(0,a.jsxs)("span",{className:"flex items-center gap-x-3 text-sm leading-6 opacity-50",children:[null==m?void 0:m.reading_time," read"]})]})]})})]})})})}},8753:function(){},7174:function(e,s,t){"use strict";t.d(s,{E:function(){return d}});var a=t(1884),l=t(1799),r=t(7653),i=t(7573),n=t(8571),c=(0,l.v)((0,a.g)()),d=(0,r.forwardRef)((e,s)=>{var{className:t,src:a,alt:r,loading:d}=e,o=(0,l.S0)(e,["className","src","alt","loading"]);let m=new URL(n.env.NEXT_PUBLIC_ROOT_URL||"https://letterpad.app/api/graphql").origin;if((null==a?void 0:a.startsWith("/"))&&!m.includes("localhost")){let e=new URL(a,m).href;a="https://res.cloudinary.com/abhisheksaha/image/fetch/f_auto,q_auto/".concat(e)}return(0,i.jsx)("img",(0,l.ih)({ref:s,className:(0,c.default)(t),alt:r,loading:void 0===d?"lazy":d,src:a},o))});d.displayName="Image"},9899:function(e,s,t){"use strict";t.d(s,{S:function(){return l}});var a=t(7653),l=(e,s)=>{let[t,l]=(0,a.useState)(!1),[r,i]=(0,a.useState)(!1);return(0,a.useEffect)(()=>{let t=e.current,a=new IntersectionObserver(e=>{let[s]=e;l(s.isIntersecting)},s);return t&&a.observe(t),()=>{t&&a.unobserve(t)}},[e,s]),(0,a.useEffect)(()=>{t&&i(!0)},[t]),{isIntersecting:t,hasLoaded:r}}}},function(e){e.O(0,[5562,7943,3662,4553,4464,5717,3436,5469,5492,3041,6496,776,7990,1293,3874,1744],function(){return e(e.s=8247)}),_N_E=e.O()}]);