import{a4 as k}from"./index-CsCqMgta.js";import{M,aX as w,U as a,R as u,O as f,e as o,V as s,X as t,a8 as B,W as i,Y as c,aA as I,S as A}from"./vendor-CsGITfgk.js";const h=M({__name:"address-dropdown-menu",props:{address:{},placement:{default:"bottom-end"}},emits:["edit","delete","toggleFavorite"],setup(_,{emit:g}){const d=g,V=_,{address:n,placement:v}=w(V),{isCorporateMember:y}=k(),b=()=>{d("edit")},C=()=>{n.value.isDefault||d("delete")};return(e,m)=>{const $=a("VcButton"),l=a("VcIcon"),r=a("VcMenuItem"),D=a("VcDropdownMenu");return f(),u(D,{"y-offset":4,"x-offset":0,placement:o(v)},{trigger:s(({triggerProps:p})=>[t($,A({"aria-label":e.$t("common.labels.actions"),icon:"cog",color:"secondary",variant:"outline",size:"xs"},p),null,16,["aria-label"])]),content:s(()=>[t(r,{color:"secondary",onClick:b},{default:s(()=>[t(l,{name:"edit"}),i("span",null,c(e.$t("common.buttons.edit")),1)]),_:1}),o(y)?(f(),u(r,{key:0,color:"secondary",onClick:m[0]||(m[0]=p=>e.$emit("toggleFavorite"))},{default:s(()=>[t(l,{name:"whishlist"}),i("span",null,c(o(n).isFavorite?e.$t("pages.company.info.remove_from_favorites"):e.$t("pages.company.info.add_to_favorites")),1)]),_:1})):B("",!0),t(r,{title:o(n).isDefault?e.$t("pages.company.info.address_not_delete_message"):void 0,disabled:o(n).isDefault,color:"secondary",onClick:C},{default:s(()=>[t(l,{class:I(o(n).isDefault?"fill-neutral-400":"fill-danger"),name:"delete-2"},null,8,["class"]),i("span",null,c(e.$t("common.buttons.delete")),1)]),_:1},8,["title","disabled"])]),_:1},8,["placement"])}}});export{h as _};
//# sourceMappingURL=address-dropdown-menu.vue_vue_type_script_setup_true_lang-DbiGTZmS.js.map
