import{d as c,at as r,a as s,q as a,u as i,j as o,F as m}from"./vendor.a0144ce9.js";/* empty css               */import{i as l}from"./icon-address.5833d084.js";import{p as u}from"./index.3d95a92c.js";const _="_cellEntry_13jw9_1",f="_cell_13jw9_1",j="_userName_13jw9_18",y="_phone_13jw9_23",N="_addressInfo_13jw9_28",k="_emtry_13jw9_32";var n={cellEntry:_,cell:f,userName:j,phone:y,addressInfo:N,emtry:k},I=c({name:"cart-address",props:{item:{type:Object,default:{}},isLink:{type:Boolean,default:!0},setAddress:{type:Function,default:e=>{}}},setup(e){const d=r(()=>[e.item.province,e.item.city,e.item.region,e.item.detailAddress].join("")),t=()=>{!e.isLink||u({api:"setAddress",content:{}})};return()=>s(m,null,[e.item&&e.item.phoneNumber?s(a,{class:n.cell,"is-link":e.isLink,onClick:()=>t()},{icon:()=>s(i,{name:l,size:19},null),title:()=>s("div",null,[s("span",{class:n.userName},[e.item.name]),s("span",{class:n.phone},[e.item&&e.item.phoneNumber&&e.item.phoneNumber.replace(/^(\d{3})\d{4}(\d+)/,"$1****$2")])]),label:()=>s("span",{class:n.addressInfo},[d.value])}):s(a,{class:n.cell,"is-link":e.isLink,onClick:()=>t()},{icon:()=>s(i,{name:l,size:19},null),title:()=>s("div",{class:n.emtry},[o("\u53BB\u586B\u5199\u6536\u8D27\u5730\u5740")])})])}});export{I as A};
