import{c as t,j as s,f as e,w as l,k as o,Q as a,y as r,u as i,s as u,p as c,t as d,g as p,i as n,q as f}from"./index-CWyPMHxb.js";import{f as m}from"./useGoods.BQLkjza8.js";import{_ as g}from"./_plugin-vue_export-helper.BCo6x5W8.js";const x=g({__name:"s-goods-item",props:{img:{type:String,default:"https://img1.baidu.com/it/u=1601695551,235775011&fm=26&fmt=auto"},title:{type:String,default:""},titleWidth:{type:Number,default:0},skuText:{type:[String,Array],default:""},price:{type:[String,Number],default:""},priceColor:{type:[String],default:""},num:{type:[String,Number],default:0},point:{type:[String,Number],default:""},radius:{type:[String],default:""},marginBottom:{type:[String],default:""}},setup(g){const x=g,_=t((()=>x.skuText?"object"==typeof x.skuText?x.skuText.join(","):x.skuText:""));return(t,x)=>{const y=n,b=f;return s(),e(y,null,{default:l((()=>[o(y,null,{default:l((()=>[a(t.$slots,"top",{},void 0,!0)])),_:3}),o(y,{class:"ss-order-card-warp ss-flex ss-col-stretch ss-row-between bg-white",style:r([{borderRadius:g.radius+"rpx",marginBottom:g.marginBottom+"rpx"}])},{default:l((()=>[o(y,{class:"img-box ss-m-r-24"},{default:l((()=>[o(b,{class:"order-img",src:i(u).$url.cdn(g.img),mode:"aspectFill"},null,8,["src"])])),_:1}),o(y,{class:"box-right ss-flex-col ss-row-between",style:r([{width:g.titleWidth?g.titleWidth+"rpx":""}])},{default:l((()=>[g.title?(s(),e(y,{key:0,class:"title-text ss-line-2"},{default:l((()=>[c(d(g.title),1)])),_:1})):p("",!0),_.value?(s(),e(y,{key:1,class:"spec-text ss-m-t-8 ss-m-b-12"},{default:l((()=>[c(d(_.value),1)])),_:1})):p("",!0),o(y,{class:"groupon-box"},{default:l((()=>[a(t.$slots,"groupon",{},void 0,!0)])),_:3}),o(y,{class:"ss-flex"},{default:l((()=>[o(y,{class:"ss-flex ss-col-center"},{default:l((()=>[g.price&&Number(g.price)>0?(s(),e(y,{key:0,class:"price-text ss-flex ss-col-center",style:r([{color:g.priceColor}])},{default:l((()=>[c(" ￥"+d(i(m)(g.price)),1)])),_:1},8,["style"])):p("",!0),g.point&&Number(g.price)>0?(s(),e(y,{key:1},{default:l((()=>[c("+")])),_:1})):p("",!0),g.point?(s(),e(y,{key:2,class:"price-text ss-flex ss-col-center"},{default:l((()=>[o(b,{src:i(u).$url.static("/static/img/shop/goods/score1.svg"),class:"point-img"},null,8,["src"]),o(y,null,{default:l((()=>[c(d(g.point),1)])),_:1})])),_:1})):p("",!0),g.num?(s(),e(y,{key:3,class:"total-text ss-flex ss-col-center"},{default:l((()=>[c("x "+d(g.num),1)])),_:1})):p("",!0),a(t.$slots,"priceSuffix",{},void 0,!0)])),_:3})])),_:3}),o(y,{class:"tool-box"},{default:l((()=>[a(t.$slots,"tool",{},void 0,!0)])),_:3}),o(y,null,{default:l((()=>[a(t.$slots,"rightBottom",{},void 0,!0)])),_:3})])),_:3},8,["style"])])),_:3},8,["style"])])),_:3})}}},[["__scopeId","data-v-acc36881"]]);export{x as _};
