import{C as v,N as f,K as _,E as g,O as e,Q as o,a3 as w,u as t,at as S,S as n,R as m,bb as h,a2 as b,aE as V}from"./vendor-BGtMsOoo.js";import{ae as N,aD as O}from"./index-CRze-aDK.js";import{u as A}from"./order-summary.vue_vue_type_style_index_0_scoped_471240a6_lang-DB8A0s2y.js";import{_ as B}from"./order-comment-section.vue_vue_type_script_setup_true_lang-CMuAvjU8.js";import{O as D}from"./order-summary-BfC6AHs9.js";import{_ as E}from"./proceed-to.vue_vue_type_script_setup_true_lang-BpsSeiLK.js";import{_ as L}from"./shipping-details-section.vue_vue_type_script_setup_true_lang-CtkI8i2y.js";import"./address-type.enum-CGCAFS3X.js";import"./useUserCheckoutDefaults-BlmbrerI.js";import"./useOrganizationAddresses-DFhlvSxC.js";import"./payment-policies.vue_vue_type_style_index_0_lang-BQUPSUyI.js";import"./add-or-update-address-modal.vue_vue_type_script_setup_true_lang-EfEQeCT4.js";import"./address-form.vue_vue_type_script_setup_true_lang-OQrHDDSp.js";import"./address-selection.vue_vue_type_script_setup_true_lang-BjP7icJi.js";import"./address-line.vue_vue_type_script_setup_true_lang-C5lgR6Et.js";const W=v({__name:"shipping",setup(z){const{cart:r,shipment:y,selectedLineItems:l,hasValidationErrors:C}=N(),{comment:i,isValidShipment:c}=A(),{analytics:$}=O();return(a,s)=>{const p=f("VcAlert"),k=f("VcLayout");return g(),_(k,{"sidebar-position":"right","sticky-sidebar":""},{sidebar:e(()=>[o(t(D),{cart:t(r),"selected-items":t(l),footnote:""},{footer:e(()=>[o(t(E),{to:{name:"Billing"},disabled:!t(c),onClick:s[1]||(s[1]=d=>{var u;return t($)("addShippingInfo",{...t(r),items:t(l)},{},(u=t(y))==null?void 0:u.shipmentMethodOption)})},{default:e(()=>[n(m(a.$t("common.buttons.go_to_billing")),1)]),_:1},8,["disabled"]),o(h,{name:"slide-fade-top",mode:"out-in",appear:""},{default:e(()=>[b(o(p,{color:"warning",size:"sm",variant:"solid-light",class:"mt-4",icon:""},{default:e(()=>[n(m(a.$t("common.messages.fill_all_required")),1)]),_:1},512),[[V,!t(c)]])]),_:1}),o(h,{name:"slide-fade-top",mode:"out-in",appear:""},{default:e(()=>[b(o(p,{color:"warning",size:"sm",variant:"solid-light",class:"mt-4",icon:""},{default:e(()=>[n(m(a.$t("common.messages.something_went_wrong")),1)]),_:1},512),[[V,t(C)]])]),_:1})]),_:1},8,["cart","selected-items"])]),default:e(()=>[o(t(L)),a.$cfg.checkout_comment_enabled?(g(),_(t(B),{key:0,comment:t(i),"onUpdate:comment":s[0]||(s[0]=d=>S(i)?i.value=d:null),class:"mt-5"},null,8,["comment"])):w("",!0)]),_:1})}}});export{W as default};
//# sourceMappingURL=shipping-BLIau1e-.js.map
