/* empty css                  *//* empty css                        *//* empty css                    */import{d as x,r as y,a4 as V,c,o,a5 as s,a as n,x as w,ak as _,ah as B,t as d,b as i,w as u,E as b,u as p,ag as $,Z as E,$ as A,_ as P}from"./index-hZHbf6Qq.js";/* empty css                                                              */const I={class:"product-card"},N={key:0,class:"card-header"},T={class:"product-image"},S={class:"image-placeholder"},z={class:"product-info"},D={class:"product-name"},U={class:"product-price"},Z={key:0,class:"price-tag"},j={class:"current-price"},q={key:1,class:"original-price"},F=x({__name:"index",props:{product:{},modelValue:{type:Boolean},showCheckbox:{type:Boolean},showAction:{type:Boolean},showAddCart:{type:Boolean},actionText:{}},emits:["update:modelValue","action","addCart"],setup(e,{emit:k}){const m=e,C=k,l=y(m.modelValue||!1);V(()=>m.modelValue,t=>{l.value=t||!1});const f=t=>{C("update:modelValue",!!t)};return(t,a)=>{const g=B,h=b,v=E;return o(),c("div",I,[e.showCheckbox||e.showAction?(o(),c("div",N,[e.showCheckbox?(o(),w(g,{key:0,modelValue:l.value,"onUpdate:modelValue":a[0]||(a[0]=r=>l.value=r),onChange:f},null,8,["modelValue"])):s("",!0),_(t.$slots,"action",{},()=>[e.actionText?(o(),c("span",{key:0,class:"action-btn",onClick:a[1]||(a[1]=r=>t.$emit("action"))},d(e.actionText),1)):s("",!0)],!0)])):s("",!0),n("div",T,[i(v,{src:e.product.image,fit:"contain"},{error:u(()=>[n("div",S,[i(h,{size:40,color:"#ccc"},{default:u(()=>[i(p($))]),_:1})])]),_:1},8,["src"])]),n("div",z,[n("div",D,d(e.product.name),1),n("div",U,[e.product.tag?(o(),c("span",Z,d(e.product.tag),1)):s("",!0),n("span",j,"¥"+d(e.product.price),1),e.product.originalPrice?(o(),c("span",q,"¥"+d(e.product.originalPrice),1)):s("",!0),e.showAddCart?(o(),c("div",{key:2,class:"add-cart",onClick:a[2]||(a[2]=r=>t.$emit("addCart"))},[i(h,null,{default:u(()=>[i(p(A))]),_:1})])):s("",!0)])])])}}}),M=P(F,[["__scopeId","data-v-7c6c5c64"]]);export{M as P};
