import{d as n,r as s,G as i,c as r,Y as c}from"./index.c0642b2f.js";import{a as p,S as l}from"./index.48a53d89.js";import{r as u}from"./request.c9d640e0.js";import{T as m}from"./index.c4427c7f.js";const f="_swiper_5ixx8_1",b={swiper:f};function d(t){return typeof t=="function"||Object.prototype.toString.call(t)==="[object Object]"&&!c(t)}const _=n({name:"banner",setup(){const t=s([]),a=async()=>{try{const{data:e}=await u.get("/api-website/open/banner/list");e&&Array.isArray(e)&&(t.value=e)}catch{}};return i(()=>{a()}),()=>{let e;return r(l,{class:b.swiper,autoplay:3e3},d(e=t.value.map(o=>r(p,null,{default:()=>[r(m,{src:o.coverImage,objectFit:"cover"},null)]})))?e:{default:()=>[e]})}}});export{_ as B};
