import{r as s,h as r}from"./p-8a04cc92.js";import"./p-836e88d4.js";import{C as e}from"./p-e06bc7e2.js";import{G as c}from"./p-62f4c75e.js";import"./p-62a6c3f4.js";import"./p-8f078939.js";import{P as o}from"./p-a9c6745c.js";import{p as t}from"./p-77365f2d.js";const a=class{constructor(r){s(this,r)}async componentWillLoad(){if(this.resources)return;const s=((s=null)=>o.client("https://ionicframeworkcom.prismic.io/api/v2",((s=null,r=null)=>{const e=r?{accessToken:r}:{};return Object.assign(Object.assign({},s?{req:s}:{}),e)})(s,null)))(),r=this.resourceData.map(r=>s.getByUID(r.type,r.uid,null));try{this.resources=(await Promise.all(r)).map(s=>t(s))}catch(s){console.error("Unable to load more resources",s)}}render(){const{headingLevel:s,type:o,tags:t,description:a,author:i}=this,p={headingLevel:s,type:o,tags:t,description:a,author:i};let m={xs:12,cols:12};switch(this.resources.length){case 2:m=Object.assign(Object.assign({},m),{md:6,sm:6});break;case 3:m=Object.assign(Object.assign({},m),{md:4,xs:6})}return r(c,{class:"size-"+this.resources.length},this.resources.map((s,c)=>r(e,Object.assign({},m,{cols:12,key:s.id}),r("resource-card",Object.assign({prismicData:s,routing:Array.isArray(this.routing)?this.routing[c]:this.routing},p)))))}};a.style=".sc-more-resources-h{display:block;--column-gap:var(--space-6);--row-gap:var(--space-9)}.ui-grid.sc-more-resources{column-gap:var(--column-gap);row-gap:var(--row-gap)}@media screen and (max-width: 640px){.ui-grid.sc-more-resources{column-gap:0}}.ui-grid.size-2.sc-more-resources resource-card.sc-more-resources{--image-height:128px}";export{a as more_resources}