import{t as e}from"./cache-DUthuMSu.mjs";import{t}from"./parse-date-BdYTmLpo.mjs";import{t as n}from"./got-BBDj7u1e.mjs";import{Fragment as r,jsx as i,jsxs as a}from"hono/jsx/jsx-runtime";import{load as o}from"cheerio";import{renderToString as s}from"hono/jsx/dom/server";import{raw as c}from"hono/html";const l=({featuredImage:e,fullContent:t})=>s(a(r,{children:[e?a(r,{children:[c(e),i(`br`,{})]}):null,t?c(t):null]})),u={path:`/articles`,categories:[`new-media`],example:`/meritalk/articles`,features:{requireConfig:!1,requirePuppeteer:!1,antiCrawler:!1,supportBT:!1,supportPodcast:!1,supportScihub:!1},radar:[{source:[`meritalk.com/articles/`],target:`/articles`}],name:`Latest Articles`,maintainers:[`superguyDiluc`],handler:d};async function d(){let{data:r}=await n(`https://www.meritalk.com/articles`),i=o(r),a=i(`div.news-block-sm`).toArray().map(e=>{let n=i(e),r=n.find(`.news-block-title a`),a=r.attr(`href`);return{title:r.text().trim(),link:a,pubDate:t(n.find(`time[datetime]`).attr(`datetime`)),category:n.find(`.category-header-name a`).toArray().map(e=>i(e).text()),description:``}});return{title:`News – MeriTalk`,link:`https://www.meritalk.com/articles/`,item:await Promise.all(a.map(t=>e.tryGet(t.link,async()=>{let{data:e}=await n(t.link),r=o(e);return t.description=l({featuredImage:r(`.single-featured-image`).first().html()||``,fullContent:r(`.single-body`).first().html()||``}),t})))}}export{u as route};