import{K as w,S as _,P as f,M as g,T as t,V as o,a7 as C,b as e,az as S,X as i,W as m,bj as h,a6 as b,aL as V}from"./vendor-bSWkQivH.js";import{aj as L,aM as z,aQ as A}from"./index-Dqv5IkpS.js";import{_ as B}from"./order-comment-section.vue_vue_type_script_setup_true_lang-Dotym-7w.js";import{O as M}from"./order-summary-DbBBQpx2.js";import{_ as N}from"./proceed-to.vue_vue_type_script_setup_true_lang-CzPN8rQE.js";import{_ as O}from"./shipping-details-section.vue_vue_type_script_setup_true_lang-DJwGI0uE.js";import"./address-selection.vue_vue_type_script_setup_true_lang-CVSe4ho1.js";const P=w({__name:"shipping",setup(T){const{cart:r,shipment:y,selectedLineItems:l,hasValidationErrors:$}=L(),{comment:n,isValidShipment:c}=z(),{analytics:k}=A();return(a,s)=>{const d=_("VcAlert"),v=_("VcLayout");return g(),f(v,{"sidebar-position":"right","sticky-sidebar":""},{sidebar:t(()=>[o(e(M),{cart:e(r),"selected-items":e(l),footnote:""},{footer:t(()=>[o(e(N),{to:{name:"Billing"},disabled:!e(c),onClick:s[1]||(s[1]=p=>{var u;return e(k)("addShippingInfo",{...e(r),items:e(l)},{},(u=e(y))==null?void 0:u.shipmentMethodOption)})},{default:t(()=>[i(m(a.$t("common.buttons.go_to_billing")),1)]),_:1},8,["disabled"]),o(h,{name:"slide-fade-top",mode:"out-in",appear:""},{default:t(()=>[b(o(d,{color:"warning",size:"sm",variant:"solid-light",class:"mt-4",icon:""},{default:t(()=>[i(m(a.$t("common.messages.fill_all_required")),1)]),_:1},512),[[V,!e(c)]])]),_:1}),o(h,{name:"slide-fade-top",mode:"out-in",appear:""},{default:t(()=>[b(o(d,{color:"warning",size:"sm",variant:"solid-light",class:"mt-4",icon:""},{default:t(()=>[i(m(a.$t("common.messages.something_went_wrong")),1)]),_:1},512),[[V,e($)]])]),_:1})]),_:1},8,["cart","selected-items"])]),default:t(()=>[o(e(O)),a.$cfg.checkout_comment_enabled?(g(),f(e(B),{key:0,comment:e(n),"onUpdate:comment":s[0]||(s[0]=p=>S(n)?n.value=p:null),class:"mt-5"},null,8,["comment"])):C("",!0)]),_:1})}}});export{P as default};
//# sourceMappingURL=shipping-DM7P_RHB.js.map
