import{M as v,U as u,R as f,O as _,V as t,X as o,a8 as w,e,az as C,Z as n,Y as m,bl as g,a7 as h,aR as b}from"./vendor-CsGITfgk.js";import{aY as S,bi as O}from"./index-B7qwhRTg.js";import{u as z}from"./useCheckout-DSGieegQ.js";import{_ as A}from"./order-comment-section.vue_vue_type_script_setup_true_lang-CpQu58Uf.js";import{O as B}from"./order-summary-DMAwQhhQ.js";import{_ as L}from"./proceed-to.vue_vue_type_script_setup_true_lang-DWOC-1iZ.js";import{_ as N}from"./shipping-details-section.vue_vue_type_script_setup_true_lang-BTzbceNz.js";import"./address-type.enum-CGCAFS3X.js";import"./address-selection.vue_vue_type_script_setup_true_lang-DZFBOEA2.js";import"./useXPickup-Ci46kjnB.js";const Z=v({__name:"shipping",setup(R){const{cart:r,shipment:V,selectedLineItems:l,hasValidationErrors:k}=S(),{comment:i,isValidShipment:c}=z(),{analytics:y}=O();return(s,a)=>{const d=u("VcAlert"),$=u("VcLayout");return _(),f($,{"sidebar-position":"right","sticky-sidebar":""},{sidebar:t(()=>[o(e(B),{cart:e(r),"selected-items":e(l),footnote:""},{footer:t(()=>[o(e(L),{to:{name:"Billing"},disabled:!e(c),"test-id":"checkout.billing-button",onClick:a[1]||(a[1]=p=>e(y)("addShippingInfo",{...e(r),items:e(l)},{},e(V)?.shipmentMethodOption))},{default:t(()=>[n(m(s.$t("common.buttons.go_to_billing")),1)]),_:1},8,["disabled"]),o(g,{name:"slide-fade-top",mode:"out-in",appear:""},{default:t(()=>[h(o(d,{color:"warning",size:"sm",variant:"solid-light",class:"mt-4",icon:""},{default:t(()=>[n(m(s.$t("common.messages.fill_all_required")),1)]),_:1},512),[[b,!e(c)]])]),_:1}),o(g,{name:"slide-fade-top",mode:"out-in",appear:""},{default:t(()=>[h(o(d,{color:"warning",size:"sm",variant:"solid-light",class:"mt-4",icon:""},{default:t(()=>[n(m(s.$t("common.messages.something_went_wrong")),1)]),_:1},512),[[b,e(k)]])]),_:1})]),_:1},8,["cart","selected-items"])]),default:t(()=>[o(e(N)),s.$cfg.checkout_comment_enabled?(_(),f(e(A),{key:0,comment:e(i),"onUpdate:comment":a[0]||(a[0]=p=>C(i)?i.value=p:null),class:"mt-5"},null,8,["comment"])):w("",!0)]),_:1})}}});export{Z as default};
//# sourceMappingURL=shipping-16tEYmMD.js.map
