1import{$ as m}from"#entry";let d;const y=()=>{if(d)return;const t=`https://${globalThis.incrowd?.env!=="stage"?"":"stage-"}article-cms-api.incrowdsports.com`;d=m({baseURL:t})},c=(t,a)=>(y(),d(t,a));function o(t){return{id:t.id,clientId:t.clientId,text:t.text,slug:t.slug,parentId:t.parentId,lastModified:t.lastModified,i18n:t.i18n,children:"children"in t?t.children:void 0,tags:t.tags}}function M(t){return t.map(o)}function h(t){return t.map(a=>{const e=o(a);return a.children&&(e.children=h(a.children)),e})}const v=t=>{const a=Array.isArray(t.data)?M(t.data):o(t.data);return{...t,data:a}},I=t=>({...t,data:h(t.data)});async function w(t){const a={size:"9999",clientId:globalThis.incrowd.clientId,...t?.params};return await c("/v2/categories",{...t,params:a,dataMapper:t?.params.tree?I:v})}async function $(t){const a={...t,params:{...t?.params,tree:!0}};return await w(a)}async function b(t,a){return await c(`/v2/categories/slug/${t}`,{...a,params:{clientId:globalThis.incrowd?.clientId,...a?.params},dataMapper:v})}function T(t,a,e=[]){let r=a;a?.slug||(r=t.find(i=>i.id===a.id));const n=[r?.slug,...e],l=t.find(i=>i.id===r?.parentId);if(l)return T(t,l,n);const u=n;for(let i=n.length-1;i>0;i--){const g=`${n[i-1]}-`;n[i].indexOf(g)===0&&(u[i]=n[i].replace(g,""))}return`/${u.join("/")}`}function f(t){const a={id:void 0,clientId:void 0,version:void 0,slug:void 0,publishDate:void 0,lastModified:{date:void 0},pinned:void 0,singlePage:void 0,heroMedia:{title:void 0,summary:void 0,content:void 0},author:void 0,readTimeMinutes:void 0,language:void 0,linkedIds:void 0,categories:void 0,displayCategory:{id:void 0,text:void 0},source:{sourceSystem:void 0},articleMetadata:void 0,content:void 0,auth:{loginRequired:void 0,roles:void 0,entitlements:void 0,restrictionType:void 0},blocked:void 0,tags:void 0,sponsors:void 0};return Object.keys(a).forEach(e=>{a[e]=t[e]}),a}function p(t){return t.map(f)}function s(t){const a={categories:t?.data?.categories,article:null,articles:null};return Array.isArray(t.data)&&t.data.length&&(a.articles=p(t.data)),t.data?.articles&&(a.articles=p(t.data.articles)),t.data?.article&&(a.article=f(t.data.article)),{...t,data:a}}const C=(t,a="")=>{const e=t?.heroMedia?.content?.image||t?.heroMedia?.content?.imageThumbnail||t?.heroMedia?.content?.videoThumbnail||a,r=t?.heroMedia?.title||"";return{src:e,alt:r}};async function x(t,a){return await c(`/v2/articles/${t}/localizations`,{...a,params:{clientId:globalThis.incrowd?.clientId,...a?.params},dataMapper:s})}async function R(t,a){return await c(`/v2/articles/slug/${t}`,{...a,params:{clientId:globalThis.incrowd?.clientId,...a?.params},dataMapper:s})}async function W(t,a){return await c(`/v1/feeds/${t}/execute`,{...a,params:{clientId:globalThis.incrowd?.clientId,...a?.params},dataMapper:s})}async function B(t){return await c("v2/articles",{...t,params:{clientId:globalThis.incrowd?.clientId,...t?.params},dataMapper:s})}async function D(t){return await c("v2/articles/search",{...t,params:{clientId:globalThis.incrowd?.clientId,...t?.params},dataMapper:s})}async function P(t,a,e){const r=await b(a,{params:{clientId:e}});return!!r&&t.categories?.some(n=>r.data.id===n.id)}function F(t,a){return P(t,"utility",a)}export{w as a,x as b,T as c,B as d,W as e,C as f,R as g,$ as h,F as i,D as s};
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.