@dropins/storefront-checkout 0.1.0-alpha37 → 0.1.0-alpha39

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (90) hide show
  1. package/__generated__/types.d.ts +714 -1907
  2. package/api/estimateShippingMethods/fixtures.d.ts +1 -1
  3. package/api/getCart/graphql/getCart.graphql.d.ts +1 -1
  4. package/api/getCheckoutData/getCheckoutData.d.ts +2 -0
  5. package/api/getCheckoutData/index.d.ts +2 -0
  6. package/api/getCountries/getCountries.d.ts +1 -3
  7. package/api/getCustomer/fixtures.d.ts +5 -0
  8. package/api/getStoreConfig/getStoreConfig.d.ts +3 -1
  9. package/api/getStoreConfig/graphql/getStoreConfig.graphql.d.ts +1 -1
  10. package/api/index.d.ts +4 -0
  11. package/api/initialize/listeners.d.ts +4 -0
  12. package/api/initializeCheckout/index.d.ts +2 -0
  13. package/api/initializeCheckout/initializeCheckout.d.ts +2 -0
  14. package/api/placeOrder/graphql/placeOrder.graphql.d.ts +1 -1
  15. package/api/resetCheckout/index.d.ts +2 -0
  16. package/api/resetCheckout/resetCheckout.d.ts +2 -0
  17. package/api/resetCustomer/index.d.ts +2 -0
  18. package/api/resetCustomer/resetCustomer.d.ts +2 -0
  19. package/api/utils/dispatchApiCall.d.ts +13 -4
  20. package/api.js +1 -1
  21. package/chunks/BillToShippingAddress2.js +1 -1
  22. package/chunks/BillingForm.js +1 -1
  23. package/chunks/LoginForm.js +1 -1
  24. package/chunks/PlaceOrder.js +1 -1
  25. package/chunks/ShippingForm.js +1 -1
  26. package/chunks/ShippingMethods.js +1 -1
  27. package/chunks/ToggleButton.js +1 -1
  28. package/chunks/ToggleButton2.js +1 -1
  29. package/chunks/address-form-fields.js +1 -43
  30. package/chunks/fixtures.js +44 -0
  31. package/chunks/getCart.graphql.js +12 -4
  32. package/chunks/getCustomer.js +34 -0
  33. package/chunks/getMultilineValues.js +43 -0
  34. package/chunks/placeOrder2.js +68 -35
  35. package/chunks/resetCustomer.js +7 -0
  36. package/chunks/setBillingAddress.js +3 -3
  37. package/chunks/setGuestEmailOnCart.js +3 -3
  38. package/chunks/setPaymentMethod.js +2 -2
  39. package/chunks/setShippingAddress.js +3 -3
  40. package/chunks/setShippingMethods.js +3 -3
  41. package/components/AddressForm/useAddressBackup.d.ts +2 -2
  42. package/components/EstimateShipping/EstimateShipping.d.ts +12 -0
  43. package/components/EstimateShipping/EstimateShippingSkeleton.d.ts +4 -0
  44. package/components/EstimateShipping/index.d.ts +4 -0
  45. package/components/LoginForm/LoginForm.d.ts +0 -1
  46. package/components/index.d.ts +1 -0
  47. package/containers/BillToShippingAddress.js +1 -1
  48. package/containers/BillingForm.js +1 -1
  49. package/containers/Checkout.js +1 -1
  50. package/containers/EstimateShipping/EstimateShipping.d.ts +4 -0
  51. package/containers/EstimateShipping/index.d.ts +3 -0
  52. package/containers/EstimateShipping.d.ts +3 -0
  53. package/containers/EstimateShipping.js +1 -0
  54. package/containers/LoginForm/LoginForm.d.ts +1 -1
  55. package/containers/LoginForm.js +1 -1
  56. package/containers/PaymentMethods.js +1 -1
  57. package/containers/PlaceOrder.js +1 -1
  58. package/containers/ShippingForm.js +1 -1
  59. package/containers/ShippingMethods.js +1 -1
  60. package/containers/index.d.ts +1 -0
  61. package/context/index.d.ts +0 -4
  62. package/data/models/address-form-fields.d.ts +2 -2
  63. package/data/models/order.d.ts +39 -4
  64. package/data/models/store-config.d.ts +8 -0
  65. package/data/transforms/transform-address.d.ts +10 -0
  66. package/data/transforms/transform-shipping-methods.d.ts +1 -1
  67. package/data/transforms/transform-store-config.d.ts +2 -1
  68. package/i18n/en_US.json.d.ts +8 -0
  69. package/lib/backup-data.d.ts +4 -0
  70. package/lib/index.d.ts +0 -1
  71. package/msw/fixtures/fragments/cart.d.ts +10 -0
  72. package/package.json +1 -1
  73. package/render.js +3 -3
  74. package/signals/CountryListSignal.d.ts +7 -0
  75. package/signals/StoreConfigSignal.d.ts +7 -0
  76. package/signals/index.d.ts +2 -1
  77. package/tests/integration/utils/setup.d.ts +1 -1
  78. package/chunks/getStoreConfig.js +0 -49
  79. package/chunks/initialize.js +0 -1
  80. package/chunks/transform-shipping-methods.js +0 -1
  81. package/context/checkout.d.ts +0 -44
  82. package/context/countries.d.ts +0 -13
  83. package/context/services.d.ts +0 -13
  84. package/context/store.d.ts +0 -12
  85. package/hooks/useAuthentication/index.d.ts +0 -2
  86. package/hooks/useAuthentication/useAuthentication.d.ts +0 -2
  87. package/lib/localStorage.d.ts +0 -10
  88. package/services/backup.d.ts +0 -17
  89. package/services/index.d.ts +0 -2
  90. package/signals/AuthenticationSignal.d.ts +0 -2
@@ -1,4 +1,4 @@
1
- import{t as a,f as l}from"./transform-shipping-methods.js";const c=e=>{if(e)return{code:e.code,title:e.title}},d=e=>{if(e)return e.filter(t=>!!t).map(t=>{const{code:r,title:o}=t;return{code:r,title:o}})},u=e=>e?!!e.code&&!!e.label:!1,m=e=>{if(!u(e))return;const{code:t,label:r,region_id:o}=e;return o?{code:t,name:r,id:o}:{code:t,name:r}},_=e=>{const{code:t,label:r}=e;return{value:t,label:r}},p=e=>e?"code"in e&&"value"in e:!1,h=e=>e.filter(p).map(t=>{const{code:r,value:o}=t;return{code:r,value:o}}),s=e=>{const t=e.street.filter(Boolean);return{firstName:e.firstname,lastName:e.lastname,company:e.company||void 0,city:e.city,street:t,postCode:e.postcode||void 0,vatId:e.vat_id||void 0,telephone:e.telephone||void 0,region:m(e.region),country:_(e.country),customAttributes:h(e.custom_attributes)}},y=e=>{if(e)return s(e)},g=e=>e.filter(t=>!!t).map(t=>{const{available_shipping_methods:r,selected_shipping_method:o,...n}=t;return{...s(n),availableShippingMethods:a(r),selectedShippingMethod:l(o)}}),v=e=>({availablePaymentMethods:d(e.available_payment_methods),billingAddress:y(e.billing_address),email:e.email??void 0,id:e.id,isEmpty:e.total_quantity===0,isVirtual:e.is_virtual,selectedPaymentMethod:c(e.selected_payment_method),shippingAddresses:g(e.shipping_addresses)}),i=`
1
+ import{t as a,u as l}from"./fixtures.js";const c=e=>{if(e)return{code:e.code,title:e.title}},d=e=>{if(e)return e.filter(t=>!!t).map(t=>{const{code:r,title:i}=t;return{code:r,title:i}})},u=e=>e?!!e.code&&!!e.label:!1,m=e=>{if(!u(e))return;const{code:t,label:r,region_id:i}=e;return i?{code:t,name:r,id:i}:{code:t,name:r}},_=e=>{const{code:t,label:r}=e;return{value:t,label:r}},p=e=>e?"code"in e&&"value"in e:!1,h=e=>e.filter(p).map(t=>{const{code:r,value:i}=t;return{code:r,value:i}}),o=e=>{const t=e.street.filter(Boolean);return{firstName:e.firstname,lastName:e.lastname,company:e.company||void 0,city:e.city,street:t,postCode:e.postcode||void 0,vatId:e.vat_id||void 0,telephone:e.telephone||void 0,region:m(e.region),country:_(e.country),customAttributes:h(e.custom_attributes)}},y=e=>{if(e)return o(e)},g=e=>e.filter(t=>!!t).map(t=>{const{available_shipping_methods:r,selected_shipping_method:i,...n}=t;return{...o(n),availableShippingMethods:a(r),selectedShippingMethod:l(i)}}),f=e=>({availablePaymentMethods:d(e.available_payment_methods),billingAddress:y(e.billing_address),email:e.email??void 0,id:e.id,isEmpty:e.total_quantity===0,isVirtual:e.is_virtual,selectedPaymentMethod:c(e.selected_payment_method),shippingAddresses:g(e.shipping_addresses)}),s=`
2
2
  fragment CheckoutData on Cart {
3
3
  is_virtual
4
4
  email
@@ -81,6 +81,14 @@ import{t as a,f as l}from"./transform-shipping-methods.js";const c=e=>{if(e)retu
81
81
  carrier_title
82
82
  method_code
83
83
  method_title
84
+ price_excl_tax {
85
+ value
86
+ currency
87
+ }
88
+ price_incl_tax {
89
+ value
90
+ currency
91
+ }
84
92
  }
85
93
  }
86
94
  available_payment_methods {
@@ -99,7 +107,7 @@ import{t as a,f as l}from"./transform-shipping-methods.js";const c=e=>{if(e)retu
99
107
  ...CheckoutData
100
108
  }
101
109
  }
102
- ${i}
110
+ ${s}
103
111
  `,C=`
104
112
  query getCustomerCart {
105
113
  cart: customerCart {
@@ -107,5 +115,5 @@ import{t as a,f as l}from"./transform-shipping-methods.js";const c=e=>{if(e)retu
107
115
  ...CheckoutData
108
116
  }
109
117
  }
110
- ${i}
111
- `;export{i as C,C as a,b as g,v as t};
118
+ ${s}
119
+ `;export{s as C,C as a,b as g,f as t};
@@ -0,0 +1,34 @@
1
+ import"@dropins/tools/event-bus.js";import{o,M as l,p as u}from"./fixtures.js";import{t as d,g as f,a as g}from"./getCart.graphql.js";const p=e=>e?"code"in e&&"value"in e:!1,y=e=>e.filter(p).map(t=>{const{code:r,value:s}=t;return{code:r,value:s}}),m=e=>{var n,i,c;const t=e.street.filter(Boolean),r=(n=e.region)==null?void 0:n.region_id,s=r&&r>0;return{id:String(e.id),firstName:e.firstname,lastName:e.lastname,company:e.company||void 0,city:e.city,street:t,postCode:e.postcode||void 0,vatId:e.vat_id||void 0,telephone:e.telephone||void 0,region:{id:s?r:void 0,code:(i=e.region)==null?void 0:i.region_code,name:(c=e.region)==null?void 0:c.region},country:{value:e.country_code,label:e.country_code},customAttributes:y(e.custom_attributesV2)}},h=e=>e?e.filter(Boolean).map(m):[],a=(e,t)=>{if(!t)return;const r=t.find(s=>(s==null?void 0:s[e])===!0);if(r)return m(r)},C=e=>{if(!e)return;const t=e.addresses;return{firstName:e.firstname||"",lastName:e.lastname||"",email:e.email||"",addresses:h(t),defaultBillingAddress:a("default_billing",t),defaultShippingAddress:a("default_shipping",t)}},_=async()=>{const e=o.cartId,t=o.authenticated===!1,r=t?f:g,s=t?{cartId:e}:{};if(t&&!e)throw new l;return await u({type:"query",query:r,options:{method:"POST",cache:"no-cache",variables:s},path:"cart",signalType:"cart",transformer:d})},q=async()=>{const e=o.cartId,t=o.authenticated;if(e)try{await _(),t&&await A()}catch(r){console.error(r)}},v=`
2
+ query getCustomer {
3
+ customer {
4
+ firstname
5
+ lastname
6
+ email
7
+ addresses {
8
+ id
9
+ default_shipping
10
+ default_billing
11
+ city
12
+ country_code
13
+ firstname
14
+ lastname
15
+ company
16
+ postcode
17
+ vat_id
18
+ region {
19
+ region
20
+ region_id
21
+ region_code
22
+ }
23
+ street
24
+ telephone
25
+ custom_attributesV2 {
26
+ ... on AttributeValue {
27
+ code
28
+ value
29
+ }
30
+ }
31
+ }
32
+ }
33
+ }
34
+ `,A=async()=>{if(o.authenticated)return await u({type:"query",query:v,options:{method:"POST",cache:"no-cache"},path:"customer",signalType:"customer",transformer:C})};export{q as a,A as b,_ as g};
@@ -0,0 +1,43 @@
1
+ import{o as _,M as y,d as h,p as g,t as l,z as I}from"./fixtures.js";import"@dropins/tools/event-bus.js";const m=`
2
+ mutation estimateShippingMethods(
3
+ $cartId: String!
4
+ $address: EstimateAddressInput!
5
+ ) {
6
+ estimateShippingMethods(
7
+ input: {
8
+ cart_id: $cartId
9
+ address: $address
10
+ }
11
+ ) {
12
+ carrier_title
13
+ carrier_code
14
+ method_title
15
+ method_code
16
+ available
17
+ amount {
18
+ currency
19
+ value
20
+ }
21
+ price_excl_tax {
22
+ currency
23
+ value
24
+ }
25
+ price_incl_tax {
26
+ currency
27
+ value
28
+ }
29
+ error_message
30
+ }
31
+ }
32
+ `,M=t=>t?!!t.id&&!!t.code&&!!t.name:!1,S=t=>{if(t)return t.filter(M).map(e=>{const{id:a,code:n,name:i}=e;return{id:a,code:n,name:i}})};var v=(t=>(t.SHIPPING="shipping_addresses",t.BILLING="billing_address",t))(v||{}),f=(t=>(t.City="city",t.Company="company",t.Country="country_id",t.FirstName="firstname",t.LastName="lastname",t.PostCode="postcode",t.Region="region",t.RegionId="region_id",t.SaveInAddressBook="save_in_address_book",t.Street="street",t.Telephone="telephone",t.Vat="vat_id",t))(f||{});const b=async t=>{const e=_.cartId,{criteria:a}=t||{},{country_code:n,region_id:i,region_name:s,zip:r}=a||{};if(!e)throw new y;if(!n)throw new h;const o=typeof i=="string"?parseInt(i,10):i,c=i||s?{...o&&{region_id:o},...s&&{region_code:s}}:void 0,u={country_code:n,...r&&{postcode:r},...c&&{region:c}};return await g({type:"mutation",query:m,options:{variables:{cartId:e,address:u}},path:"estimateShippingMethods",signalType:"estimateShippingMethods",transformer:l})},d=`
33
+ query getRegions($countryCode: String!) {
34
+ country(id: $countryCode) {
35
+ id
36
+ available_regions {
37
+ id
38
+ code
39
+ name
40
+ }
41
+ }
42
+ }`,L=async(t,e)=>(I.value.addressType=e,g({type:"query",query:d,options:{variables:{countryCode:t}},path:"country.available_regions",signalType:"regions",transformer:S})),p="-",N=`
43
+ `,R=2e3,E=(t,e)=>Object.keys(e).filter(a=>a.startsWith(t)).sort((a,n)=>parseInt(a.replace(`${t}${p}`,""),10)-parseInt(n.replace(`${t}${p}`,""),10)).map(a=>e[a]);export{v as A,R as D,p as M,f as a,E as b,N as c,b as e,L as g};
@@ -1,42 +1,11 @@
1
- import{t as A,g as E,a as q}from"./getCart.graphql.js";import{M as b,e as d,F as w,U as N}from"./transform-shipping-methods.js";import{i as l,f as k,n as D}from"./getStoreConfig.js";import{events as f}from"@dropins/tools/event-bus.js";const L=t=>({id:l.cartId,totalQuantity:t.totalQuantity,possibleOnepageCheckout:!0,items:t.items.map(n=>{var a;return{canApplyMsrp:!0,formattedPrice:"",id:n.id,quantity:n.totalQuantity,product:{canonicalUrl:n.product.canonicalUrl||"",mainImageUrl:n.product.image||"",name:n.product.name,productId:0,productType:n.product.productType,sku:n.product.sku},prices:{price:{value:n.price.value,currency:n.price.currency}},configurableOptions:((a=n.selectedOptions)==null?void 0:a.map(e=>({optionLabel:e.label,valueLabel:e.value})))||[]}})}),Q=t=>{var e,s,i;const n=t.coupons[0],a=(e=t.payments)==null?void 0:e[0];return{appliedCouponCode:(n==null?void 0:n.code)||"",email:t.email,grandTotal:t.total,orderId:t.number,orderType:"checkout",otherTax:0,salesTax:t.totalTax,shipping:{shippingMethod:((s=t.shipping)==null?void 0:s.code)||"",shippingAmount:((i=t.shipping)==null?void 0:i.amount)||0},subtotalExcludingTax:t.subtotal,subtotalIncludingTax:0,payments:a?[{paymentMethodCode:(a==null?void 0:a.code)||"",paymentMethodName:(a==null?void 0:a.name)||"",total:t.total}]:[]}},R=t=>t?"code"in t&&"value"in t:!1,S=t=>t.filter(R).map(n=>{const{code:a,value:e}=n;return{code:a,value:e}}),T=t=>{var s,i,u;const n=t.street.filter(Boolean),a=(s=t.region)==null?void 0:s.region_id,e=a&&a>0;return{id:String(t.id),firstName:t.firstname,lastName:t.lastname,company:t.company||void 0,city:t.city,street:n,postCode:t.postcode||void 0,vatId:t.vat_id||void 0,telephone:t.telephone||void 0,region:{id:e?a:void 0,code:(i=t.region)==null?void 0:i.region_code,name:(u=t.region)==null?void 0:u.region},country:{value:t.country_code,label:t.country_code},customAttributes:S(t.custom_attributesV2)}},P=t=>t?t.filter(Boolean).map(T):[],m=(t,n)=>{if(!n)return;const a=n.find(e=>(e==null?void 0:e[t])===!0);if(a)return T(a)},V=t=>{if(!t)return;const n=t.addresses;return{firstName:t.firstname||"",lastName:t.lastname||"",email:t.email||"",addresses:P(n),defaultBillingAddress:m("default_billing",n),defaultShippingAddress:m("default_shipping",n)}},o=t=>t||0,M=t=>{var n;return{canonicalUrl:(t==null?void 0:t.canonical_url)||"",id:(t==null?void 0:t.uid)||"",name:(t==null?void 0:t.name)||"",sku:(t==null?void 0:t.sku)||"",image:((n=t==null?void 0:t.image)==null?void 0:n.url)||"",productType:(t==null?void 0:t.__typename)||""}},U=t=>o(t==null?void 0:t.quantity_ordered)+o(t==null?void 0:t.quantity_shipped)+o(t==null?void 0:t.quantity_canceled)+o(t==null?void 0:t.quantity_invoiced)+o(t==null?void 0:t.quantity_refunded)+o(t==null?void 0:t.quantity_returned),F=t=>t?t.map(n=>({id:(n==null?void 0:n.id)||"",price:{value:(n==null?void 0:n.product_sale_price.value)||0,currency:(n==null?void 0:n.product_sale_price.currency)||""},totalQuantity:U(n),product:M(n==null?void 0:n.product)})):[],G=t=>{var p,r,y,g,_,h;const n=((p=t.total)==null?void 0:p.grand_total.value)??0,a=(r=t.payment_methods)==null?void 0:r[0],e=(a==null?void 0:a.type)??"",s=(a==null?void 0:a.name)??"",i=F(t.items),u=i.reduce((c,x)=>c+x.totalQuantity,0);return{coupons:((y=t==null?void 0:t.applied_coupons)==null?void 0:y.map(c=>({code:(c==null?void 0:c.code)??""})))||[],email:t.email??"",items:i,number:t.number,token:t.token,total:n,totalQuantity:u,totalTax:((g=t.total)==null?void 0:g.total_tax.value)??0,subtotal:((_=t.total)==null?void 0:_.subtotal.value)??0,shipping:{amount:((h=t.total)==null?void 0:h.total_shipping.value)??0,code:t.shipping_method??""},payments:[{code:e,name:s}]}},Z=async()=>{const t=l.cartId,n=l.authenticated===!1,a=n?E:q,e=n?{cartId:t}:{};if(n&&!t)throw new b;return await d({type:"query",query:a,options:{method:"POST",cache:"no-cache",variables:e},path:"cart",signalType:"cart",transformer:A})},X=`
2
- query getCustomer {
3
- customer {
4
- firstname
5
- lastname
6
- email
7
- addresses {
8
- id
9
- default_shipping
10
- default_billing
11
- city
12
- country_code
13
- firstname
14
- lastname
15
- company
16
- postcode
17
- vat_id
18
- region {
19
- region
20
- region_id
21
- region_code
22
- }
23
- street
24
- telephone
25
- custom_attributesV2 {
26
- ... on AttributeValue {
27
- code
28
- value
29
- }
30
- }
31
- }
32
- }
33
- }
34
- `,I=async()=>await d({type:"query",query:X,options:{method:"POST",cache:"no-cache"},path:"customer",signalType:"customer",transformer:V}),B=`
1
+ import{o as E,M as w,g as A,v as k,n as D,F as L,U as R}from"./fixtures.js";import{events as C}from"@dropins/tools/event-bus.js";const V=n=>({id:E.cartId,totalQuantity:n.totalQuantity,possibleOnepageCheckout:!0,items:n.items.map(a=>{var i;return{canApplyMsrp:!0,formattedPrice:"",id:a.id,quantity:a.totalQuantity,product:{canonicalUrl:a.product.canonicalUrl||"",mainImageUrl:a.product.image||"",name:a.product.name,productId:0,productType:a.product.productType,sku:a.product.sku},prices:{price:{value:a.price.value,currency:a.price.currency}},configurableOptions:((i=a.selectedOptions)==null?void 0:i.map(t=>({optionLabel:t.label,valueLabel:t.value})))||[]}})}),Q=n=>{var t,c,u;const a=n.coupons[0],i=(t=n.payments)==null?void 0:t[0];return{appliedCouponCode:(a==null?void 0:a.code)||"",email:n.email,grandTotal:n.total,orderId:n.number,orderType:"checkout",otherTax:0,salesTax:n.totalTax,shipping:{shippingMethod:((c=n.shipping)==null?void 0:c.code)||"",shippingAmount:((u=n.shipping)==null?void 0:u.amount)||0},subtotalExcludingTax:n.subtotal,subtotalIncludingTax:0,payments:i?[{paymentMethodCode:(i==null?void 0:i.code)||"",paymentMethodName:(i==null?void 0:i.name)||"",total:n.total}]:[]}},l=n=>n||0,S=n=>{var a;return{canonicalUrl:(n==null?void 0:n.canonical_url)||"",id:(n==null?void 0:n.uid)||"",name:(n==null?void 0:n.name)||"",sku:(n==null?void 0:n.sku)||"",image:((a=n==null?void 0:n.image)==null?void 0:a.url)||"",productType:(n==null?void 0:n.__typename)||""}};function M(n){if(!n||!("selected_options"in n))return;const a={};for(const i of n.selected_options)a[i.label]=i.value;return a}const P=n=>l(n==null?void 0:n.quantity_ordered)+l(n==null?void 0:n.quantity_shipped)+l(n==null?void 0:n.quantity_canceled)+l(n==null?void 0:n.quantity_invoiced)+l(n==null?void 0:n.quantity_refunded)+l(n==null?void 0:n.quantity_returned),U=n=>n?n.map(a=>{var i,t,c,u,s,p,_,e,y,g,o,h,v,b;return{type:a==null?void 0:a.__typename,id:a==null?void 0:a.id,discounted:(a==null?void 0:a.product.price_range.maximum_price.regular_price.value)*(a==null?void 0:a.quantity_ordered)!==(a==null?void 0:a.product_sale_price.value)*(a==null?void 0:a.quantity_ordered),total:{value:(a==null?void 0:a.product_sale_price.value)*(a==null?void 0:a.quantity_ordered),currency:a==null?void 0:a.product_sale_price.currency},totalInclTax:{value:(a==null?void 0:a.product_sale_price.value)*(a==null?void 0:a.quantity_ordered),currency:a==null?void 0:a.product_sale_price.currency},price:{value:a==null?void 0:a.product_sale_price.value,currency:a==null?void 0:a.product_sale_price.currency},priceInclTax:{value:a==null?void 0:a.product_sale_price.value,currency:a==null?void 0:a.product_sale_price.currency},totalQuantity:P(a),regularPrice:{value:(c=(t=(i=a==null?void 0:a.product)==null?void 0:i.price_range)==null?void 0:t.maximum_price)==null?void 0:c.regular_price.value,currency:(p=(s=(u=a==null?void 0:a.product)==null?void 0:u.price_range)==null?void 0:s.maximum_price)==null?void 0:p.regular_price.currency},product:S(a==null?void 0:a.product),thumbnail:{label:((e=(_=a==null?void 0:a.product)==null?void 0:_.thumbnail)==null?void 0:e.label)||"",url:((g=(y=a==null?void 0:a.product)==null?void 0:y.thumbnail)==null?void 0:g.url)||""},giftCard:(a==null?void 0:a.__typename)==="GiftCardOrderItem"?{senderName:((o=a.gift_card)==null?void 0:o.sender_name)||"",senderEmail:((h=a.gift_card)==null?void 0:h.sender_email)||"",recipientEmail:((v=a.gift_card)==null?void 0:v.recipient_email)||"",recipientName:((b=a.gift_card)==null?void 0:b.recipient_name)||""}:void 0,configurableOptions:M(a)}}):[];function G(n){return n!==null&&n.value!==void 0}const x=n=>n?{city:n.city,company:n.company||"",country:n.country_code||"",firstName:n.firstname,middleName:n.middlename||"",lastName:n.lastname,postCode:n.postcode||"",regionId:n.region_id||"",region:n.region||"",street:n.street.filter(a=>a!==null),telephone:n.telephone||"",customAttributes:n.custom_attributesV2.filter(G).map(a=>({code:a.code,value:a.value}))}:null,F=n=>{var s,p,_,e,y,g,o,h,v,b;const a=(s=n.payment_methods)==null?void 0:s[0],i=(a==null?void 0:a.type)??"",t=(a==null?void 0:a.name)??"",c=U(n.items),u=c.reduce((f,N)=>f+N.totalQuantity,0);return{status:n.status,isVirtual:n.is_virtual,coupons:((p=n==null?void 0:n.applied_coupons)==null?void 0:p.map(f=>({code:(f==null?void 0:f.code)??""})))||[],email:n.email??"",items:c,number:n.number,token:n.token,grandTotal:{value:((_=n.total)==null?void 0:_.grand_total.value)??0,currency:((e=n.total)==null?void 0:e.grand_total.currency)||""},totalQuantity:u,totalTax:{value:((y=n.total)==null?void 0:y.total_tax.value)??0,currency:((g=n.total)==null?void 0:g.total_tax.currency)||""},subtotal:{value:((o=n.total)==null?void 0:o.subtotal.value)??0,currency:((h=n.total)==null?void 0:h.subtotal.currency)||""},shipping:{amount:((v=n.total)==null?void 0:v.total_shipping.value)??0,currency:((b=n.total)==null?void 0:b.total_shipping.currency)||"",code:n.shipping_method??""},payments:[{code:i,name:t}],shippingAddress:x(n.shipping_address),billingAddress:x(n.billing_address)}},X=`
35
2
  mutation placeOrder($cartId: String!) {
36
3
  placeOrder(input: { cart_id: $cartId }) {
37
4
  orderV2 {
38
5
  number
6
+ status
39
7
  token
8
+ is_virtual
40
9
  applied_coupons {
41
10
  code
42
11
  }
@@ -44,15 +13,19 @@ import{t as A,g as E,a as q}from"./getCart.graphql.js";import{M as b,e as d,F as
44
13
  id
45
14
  total {
46
15
  grand_total {
16
+ currency
47
17
  value
48
18
  }
49
19
  subtotal {
20
+ currency
50
21
  value
51
22
  }
52
23
  total_shipping {
24
+ currency
53
25
  value
54
26
  }
55
27
  total_tax {
28
+ currency
56
29
  value
57
30
  }
58
31
  }
@@ -61,7 +34,46 @@ import{t as A,g as E,a as q}from"./getCart.graphql.js";import{M as b,e as d,F as
61
34
  name
62
35
  type
63
36
  }
37
+ billing_address {
38
+ firstname
39
+ middlename
40
+ lastname
41
+ street
42
+ city
43
+ postcode
44
+ telephone
45
+ country_code
46
+ region
47
+ region_id
48
+ company
49
+ custom_attributesV2 {
50
+ code
51
+ ... on AttributeValue {
52
+ value
53
+ }
54
+ }
55
+ }
56
+ shipping_address {
57
+ firstname
58
+ middlename
59
+ lastname
60
+ street
61
+ city
62
+ postcode
63
+ telephone
64
+ country_code
65
+ region
66
+ region_id
67
+ company
68
+ custom_attributesV2 {
69
+ code
70
+ ... on AttributeValue {
71
+ value
72
+ }
73
+ }
74
+ }
64
75
  items {
76
+ __typename
65
77
  id
66
78
  discounts {
67
79
  amount {
@@ -74,9 +86,21 @@ import{t as A,g as E,a as q}from"./getCart.graphql.js";import{M as b,e as d,F as
74
86
  image {
75
87
  url
76
88
  }
89
+ thumbnail {
90
+ label
91
+ url
92
+ }
77
93
  name
78
94
  sku
79
95
  uid
96
+ price_range {
97
+ maximum_price {
98
+ regular_price {
99
+ currency
100
+ value
101
+ }
102
+ }
103
+ }
80
104
  }
81
105
  selected_options {
82
106
  label
@@ -92,8 +116,17 @@ import{t as A,g as E,a as q}from"./getCart.graphql.js";import{M as b,e as d,F as
92
116
  quantity_refunded
93
117
  quantity_returned
94
118
  quantity_shipped
119
+ ... on GiftCardOrderItem {
120
+ gift_card {
121
+ recipient_name
122
+ recipient_email
123
+ sender_name
124
+ sender_email
125
+ message
126
+ }
127
+ }
95
128
  }
96
129
  }
97
130
  }
98
131
  }
99
- `,v={SHOPPING_CART_CONTEXT:"shoppingCartContext",ORDER_CONTEXT:"orderContext"},$={PLACE_ORDER:"place-order"};function O(){return window.adobeDataLayer=window.adobeDataLayer||[],window.adobeDataLayer}function C(t,n){const a=O();a.push({[t]:null}),a.push({[t]:n})}function H(t,n){O().push(e=>{const s=e.getState?e.getState():{};e.push({event:t,eventInfo:{...s,...n}})})}function j(t){const n=L(t),a=Q(t);console.debug({shoppingCartContext:n,orderContext:a}),C(v.SHOPPING_CART_CONTEXT,{...n}),C(v.ORDER_CONTEXT,{...a}),H($.PLACE_ORDER)}function z(t){throw t.every(a=>{var e;return(e=a.extensions)==null?void 0:e.category})?new w(t):new N(t[0].message)}const tt=async()=>{const t=l.cartId;if(!t)throw new b;const{data:n,errors:a}=await k(B,{variables:{cartId:t}}).catch(D);a&&z(a);const e=G(n.placeOrder.orderV2);return j(e),f.emit("checkout/order",e),f.emit("cart/reset",void 0),e};export{I as a,Z as g,tt as p};
132
+ `,O={SHOPPING_CART_CONTEXT:"shoppingCartContext",ORDER_CONTEXT:"orderContext"},$={PLACE_ORDER:"place-order"};function q(){return window.adobeDataLayer=window.adobeDataLayer||[],window.adobeDataLayer}function T(n,a){const i=q();i.push({[n]:null}),i.push({[n]:a})}function H(n,a){q().push(t=>{const c=t.getState?t.getState():{};t.push({event:n,eventInfo:{...c,...a}})})}function j(n){const a=V(n),i=Q(n);console.debug({shoppingCartContext:a,orderContext:i}),T(O.SHOPPING_CART_CONTEXT,{...a}),T(O.ORDER_CONTEXT,{...i}),H($.PLACE_ORDER)}function z(n){throw n.every(i=>{var t;return(t=i.extensions)==null?void 0:t.category})?new L(n):new R(n[0].message)}const K=async()=>{const n=E.cartId;if(!n)throw new w;const{data:a,errors:i}=await A(X,{variables:{cartId:n}}).catch(k);i&&z(i);const t=F(a.placeOrder.orderV2);return j(t),C.emit("checkout/order",t),D.value={pending:!1,data:null},C.emit("cart/reset",void 0),t};export{K as p};
@@ -0,0 +1,7 @@
1
+ import{events as i}from"@dropins/tools/event-bus.js";import{p as s,o as a,k as l,n as c,m as u}from"./fixtures.js";import{Initializer as f}from"@dropins/tools/lib.js";import{a as g}from"./getCustomer.js";const m=e=>{if(e)return e.filter(t=>!!t).filter(t=>{const{two_letter_abbreviation:n,full_name_locale:o}=t;return!!n&&!!o}).map(t=>{const{two_letter_abbreviation:n,full_name_locale:o}=t;return{value:n,label:o}})},p=`
2
+ query getCountries {
3
+ countries {
4
+ two_letter_abbreviation
5
+ full_name_locale
6
+ }
7
+ }`,d=async()=>await s({type:"query",query:p,options:{method:"GET",cache:"no-cache"},path:"countries",signalType:"countryList",transformer:m,defaultValueOnFail:[]}),C=()=>[i.on("cart/data",e=>{const t=(e==null?void 0:e.id)||null;a.cartId=t,t?g():h()},{eager:!0}),i.on("authenticated",e=>{a.authenticated=e,e||y()},{eager:!0})],r=new f({init:async e=>{const t={guestViewCookieExpirationDays:30,...e};r.config.setConfig(t),_()},listeners:C}),I=r.config,_=async()=>Promise.all([l(),d()]),h=()=>{a.cartId=null,c.value={pending:!1,data:null}},y=()=>{a.authenticated=!1,u.value={pending:!1,data:null}};export{_ as a,y as b,I as c,d as g,r as i,h as r};
@@ -1,4 +1,4 @@
1
- import{M as e,c as d,e as o}from"./transform-shipping-methods.js";import{C as l,t as c}from"./getCart.graphql.js";import{i as p}from"./getStoreConfig.js";import{events as m}from"@dropins/tools/event-bus.js";const g=`
1
+ import{o as n,M as e,c as d,p as l}from"./fixtures.js";import{C as o,t as c}from"./getCart.graphql.js";const p=`
2
2
  mutation setBillingAddress($cartId: String!, $input: BillingAddressInput!) {
3
3
  setBillingAddressOnCart(
4
4
  input: { cart_id: $cartId, billing_address: $input }
@@ -9,5 +9,5 @@ import{M as e,c as d,e as o}from"./transform-shipping-methods.js";import{C as l,
9
9
  }
10
10
  }
11
11
  }
12
- ${l}
13
- `,B=async({signal:i,input:s})=>{const t=p.cartId,{address:r,same_as_shipping:a}=s;if(!t)throw new e;if(!a&&!r)throw new d;const n=await o({type:"mutation",query:g,options:{signal:i,variables:{cartId:t,input:s}},path:"setBillingAddressOnCart.cart",signalType:"cart",transformer:c});return m.emit("cart/updated",t),n};export{B as s};
12
+ ${o}
13
+ `,m=async({signal:a,input:s})=>{const t=n.cartId,{address:i,same_as_shipping:r}=s;if(!t)throw new e;if(!r&&!i)throw new d;return await l({type:"mutation",query:p,options:{signal:a,variables:{cartId:t,input:s}},path:"setBillingAddressOnCart.cart",signalType:"cart",transformer:c})};export{m as s};
@@ -1,10 +1,10 @@
1
- import{a as r,M as s,e}from"./transform-shipping-methods.js";import{f as l,n,o,i as m}from"./getStoreConfig.js";import"@dropins/tools/event-bus.js";import{C as c,t as E}from"./getCart.graphql.js";const u=a=>!!(a!=null&&a.is_email_available),h=`
1
+ import{a as r,g as s,v as e,w as l,o as n,M as o,p as m}from"./fixtures.js";import"@dropins/tools/event-bus.js";import{C as c,t as E}from"./getCart.graphql.js";const u=a=>!!(a!=null&&a.is_email_available),h=`
2
2
  query isEmailAvailable($email: String!) {
3
3
  isEmailAvailable(email: $email) {
4
4
  is_email_available
5
5
  }
6
6
  }
7
- `,C=async a=>{if(!a)throw new r;const{data:t,errors:i}=await l(h,{method:"GET",cache:"no-cache",variables:{email:a}}).catch(n);return i&&o(i),u(t.isEmailAvailable)},p=`
7
+ `,C=async a=>{if(!a)throw new r;const{data:t,errors:i}=await s(h,{method:"GET",cache:"no-cache",variables:{email:a}}).catch(e);return i&&l(i),u(t.isEmailAvailable)},p=`
8
8
  mutation setGuestEmail($cartId: String!, $email: String!) {
9
9
  setGuestEmailOnCart(input: { cart_id: $cartId, email: $email }) {
10
10
  cart {
@@ -14,4 +14,4 @@ import{a as r,M as s,e}from"./transform-shipping-methods.js";import{f as l,n,o,i
14
14
  }
15
15
  }
16
16
  ${c}
17
- `,y=async a=>{const t=m.cartId;if(!t)throw new s;return await e({type:"mutation",query:p,options:{variables:{cartId:t,email:a}},path:"setGuestEmailOnCart.cart",signalType:"cart",transformer:E})};export{C as i,y as s};
17
+ `,f=async a=>{const t=n.cartId;if(!t)throw new o;return await m({type:"mutation",query:p,options:{variables:{cartId:t,email:a}},path:"setGuestEmailOnCart.cart",signalType:"cart",transformer:E})};export{C as i,f as s};
@@ -1,4 +1,4 @@
1
- import{M as r,b as o,e as n}from"./transform-shipping-methods.js";import{C as s,t as i}from"./getCart.graphql.js";import{i as m}from"./getStoreConfig.js";import{events as d}from"@dropins/tools/event-bus.js";const c=`
1
+ import{o as e,M as r,b as n,p as o}from"./fixtures.js";import{C as s,t as i}from"./getCart.graphql.js";const m=`
2
2
  mutation setPaymentMethod($cartId: String!, $paymentMethod: String!) {
3
3
  setPaymentMethodOnCart(
4
4
  input: { cart_id: $cartId, payment_method: { code: $paymentMethod } }
@@ -10,4 +10,4 @@ import{M as r,b as o,e as n}from"./transform-shipping-methods.js";import{C as s,
10
10
  }
11
11
  }
12
12
  ${s}
13
- `,u=async a=>{const t=m.cartId;if(!t)throw new r;if(!a)throw new o;const e=await n({type:"mutation",query:c,options:{variables:{cartId:t,paymentMethod:a}},path:"setPaymentMethodOnCart.cart",signalType:"cart",transformer:i});return d.emit("cart/updated",t),e};export{u as s};
13
+ `,h=async t=>{const a=e.cartId;if(!a)throw new r;if(!t)throw new n;return await o({type:"mutation",query:m,options:{variables:{cartId:a,paymentMethod:t}},path:"setPaymentMethodOnCart.cart",signalType:"cart",transformer:i})};export{h as s};
@@ -1,4 +1,4 @@
1
- import{a as s,b as p,M as u,c as _}from"./address-form-fields.js";import{i as I}from"./getStoreConfig.js";import{M as g,e as m}from"./transform-shipping-methods.js";import{C,t as h}from"./getCart.graphql.js";import{events as A}from"@dropins/tools/event-bus.js";const l=/^\d+$/,T=t=>{if(l.test(t))return parseInt(t,10)},y=`
1
+ import{a as s,b as p,M as u,c as _}from"./getMultilineValues.js";import{o as I,M as g,p as C}from"./fixtures.js";import{C as h,t as A}from"./getCart.graphql.js";import"@dropins/tools/event-bus.js";const T=/^\d+$/,l=t=>{if(T.test(t))return parseInt(t,10)},m=`
2
2
  mutation setShippingAddress($cartId: String!, $address: CartAddressInput!) {
3
3
  setShippingAddressesOnCart(
4
4
  input: { cart_id: $cartId, shipping_addresses: [{ address: $address }] }
@@ -9,5 +9,5 @@ import{a as s,b as p,M as u,c as _}from"./address-form-fields.js";import{i as I}
9
9
  }
10
10
  }
11
11
  }
12
- ${C}
13
- `,S=["city","company","country_code","firstname","lastname","postcode","region","region_id","save_in_address_book","street","telephone","vat_id"],N=t=>{const a={city:t[s.City],company:t[s.Company],country_code:t[s.Country],firstname:t[s.FirstName],lastname:t[s.LastName],postcode:t[s.PostCode],save_in_address_book:!0,street:p(s.Street,t),telephone:t[s.Telephone],vat_id:t[s.Vat]},r=t[s.Region],i=T(r);i?a.region_id=i:a.region=r;const c=Object.keys(t).filter(e=>!e.startsWith("street")).filter(e=>!S.includes(e)).filter(e=>e!=="country_id").map(e=>{const[n,o]=e.split(u);if(!o)return{attribute_code:n,value:t[e]};const d=p(n,t).join(_);return{attribute_code:n,value:d}}).filter((e,n,o)=>n===o.findIndex(d=>d.attribute_code===e.attribute_code));return c.length>0&&(a.custom_attributes=c),a},U=async({signal:t,address:a})=>{const r=I.cartId;if(!r)throw new g;const i=await m({type:"mutation",query:y,options:{signal:t,variables:{cartId:r,address:a}},path:"setShippingAddressesOnCart.cart",signalType:"cart",transformer:h});return A.emit("cart/updated",r),i};export{S,N as p,U as s};
12
+ ${h}
13
+ `,y=["city","company","country_code","firstname","lastname","postcode","region","region_id","save_in_address_book","street","telephone","vat_id"],v=t=>{const a={city:t[s.City],company:t[s.Company],country_code:t[s.Country],firstname:t[s.FirstName],lastname:t[s.LastName],postcode:t[s.PostCode],save_in_address_book:!0,street:p(s.Street,t),telephone:t[s.Telephone],vat_id:t[s.Vat]},r=t[s.Region],d=l(r);d?a.region_id=d:a.region=r;const c=Object.keys(t).filter(e=>!e.startsWith("street")).filter(e=>!y.includes(e)).filter(e=>e!=="country_id").map(e=>{const[n,i]=e.split(u);if(!i)return{attribute_code:n,value:t[e]};const o=p(n,t).join(_);return{attribute_code:n,value:o}}).filter((e,n,i)=>n===i.findIndex(o=>o.attribute_code===e.attribute_code));return c.length>0&&(a.custom_attributes=c),a},N=async({signal:t,address:a})=>{const r=I.cartId;if(!r)throw new g;return await C({type:"mutation",query:m,options:{signal:t,variables:{cartId:r,address:a}},path:"setShippingAddressesOnCart.cart",signalType:"cart",transformer:A})};export{y as S,v as p,N as s};
@@ -1,4 +1,4 @@
1
- import{M as a,e as r}from"./transform-shipping-methods.js";import{i as p}from"./getStoreConfig.js";import{C as n,t as o}from"./getCart.graphql.js";import{events as e}from"@dropins/tools/event-bus.js";const h=`
1
+ import{o as s,M as a,p}from"./fixtures.js";import{C as r,t as n}from"./getCart.graphql.js";import"@dropins/tools/event-bus.js";const o=`
2
2
  mutation setShippingMethods(
3
3
  $cartId: String!
4
4
  $shippingMethods: [ShippingMethodInput]!
@@ -12,5 +12,5 @@ import{M as a,e as r}from"./transform-shipping-methods.js";import{i as p}from"./
12
12
  }
13
13
  }
14
14
  }
15
- ${n}
16
- `,M=async i=>{const t=p.cartId;if(!t)throw new a;const s=r({type:"mutation",query:h,options:{variables:{cartId:t,shippingMethods:i}},path:"setShippingMethodsOnCart.cart",signalType:"cart",transformer:o});return e.emit("cart/updated",t),s};export{M as s};
15
+ ${r}
16
+ `,c=async i=>{const t=s.cartId;if(!t)throw new a;return p({type:"mutation",query:o,options:{variables:{cartId:t,shippingMethods:i}},path:"setShippingMethodsOnCart.cart",signalType:"cart",transformer:n})};export{c as s};
@@ -2,7 +2,7 @@ import { AddressFormType, AddressFormValues } from '../../data/models/address-fo
2
2
 
3
3
  export declare function useAddressBackup(addressType: AddressFormType): {
4
4
  addressBackup: AddressFormValues | null;
5
- backup: (address: AddressFormValues) => NodeJS.Timeout;
6
- removeBackup: () => void;
5
+ backupAddress: (address: AddressFormValues) => NodeJS.Timeout;
6
+ removeAddressBackup: () => void;
7
7
  };
8
8
  //# sourceMappingURL=useAddressBackup.d.ts.map
@@ -0,0 +1,12 @@
1
+ import { FunctionComponent, VNode } from 'preact';
2
+ import { HTMLAttributes } from 'preact/compat';
3
+
4
+ export interface EstimateShippingProps {
5
+ estimated?: boolean;
6
+ price: VNode<HTMLAttributes<HTMLSpanElement>>;
7
+ priceExclTax?: VNode<HTMLAttributes<HTMLSpanElement>>;
8
+ taxExcluded?: boolean;
9
+ taxIncluded?: boolean;
10
+ }
11
+ export declare const EstimateShipping: FunctionComponent<EstimateShippingProps>;
12
+ //# sourceMappingURL=EstimateShipping.d.ts.map
@@ -0,0 +1,4 @@
1
+ import { FunctionComponent } from 'preact';
2
+
3
+ export declare const EstimateShippingSkeleton: FunctionComponent;
4
+ //# sourceMappingURL=EstimateShippingSkeleton.d.ts.map
@@ -0,0 +1,4 @@
1
+ export * from './EstimateShipping';
2
+ export { EstimateShipping as default } from './EstimateShipping';
3
+ export * from './EstimateShippingSkeleton';
4
+ //# sourceMappingURL=index.d.ts.map
@@ -10,7 +10,6 @@ export interface LoginFormProps extends HTMLAttributes<HTMLDivElement> {
10
10
  onEmailInvalid: (e: any) => void;
11
11
  onSignInClick?: (email: string | null) => void;
12
12
  onSignOutClick?: () => void;
13
- isAuthenticated: boolean;
14
13
  customer?: Customer | null;
15
14
  }
16
15
  export declare const LoginForm: FunctionComponent<LoginFormProps>;
@@ -2,6 +2,7 @@ export * from './AddressForm';
2
2
  export * from './BillToShippingAddress';
3
3
  export * from './Checkout';
4
4
  export * from './EmptyCart';
5
+ export * from './EstimateShipping';
5
6
  export * from './FieldsForm';
6
7
  export * from './Heading';
7
8
  export * from './LoginForm';
@@ -1 +1 @@
1
- import{a as A,B as L,c as P,B as S}from"../chunks/BillToShippingAddress2.js";import"@dropins/tools/event-bus.js";import"../chunks/getStoreConfig.js";import"@dropins/tools/fetch-graphql.js";import"@dropins/tools/preact.js";import"@dropins/tools/preact-hooks.js";import"@dropins/tools/preact-jsx-runtime.js";import"../chunks/setBillingAddress.js";import"../chunks/transform-shipping-methods.js";import"../chunks/getCart.graphql.js";import"@dropins/tools/lib.js";import"@dropins/tools/components.js";/* empty css */import"@dropins/tools/i18n.js";import"@dropins/tools/preact-compat.js";export{A as BILL_TO_SHIPPING_KEY,L as BillToShippingAddress,P as compareAddresses,S as default};
1
+ import{a as A,B as L,c as P,B as S}from"../chunks/BillToShippingAddress2.js";import"@dropins/tools/event-bus.js";import"../chunks/fixtures.js";import"@dropins/tools/preact.js";import"@dropins/tools/preact-hooks.js";import"@dropins/tools/fetch-graphql.js";import"../chunks/setBillingAddress.js";import"../chunks/getCart.graphql.js";import"@dropins/tools/lib.js";import"@dropins/tools/components.js";/* empty css */import"@dropins/tools/preact-jsx-runtime.js";import"@dropins/tools/i18n.js";import"@dropins/tools/preact-compat.js";import"../chunks/address-form-fields.js";export{A as BILL_TO_SHIPPING_KEY,L as BillToShippingAddress,P as compareAddresses,S as default};
@@ -1 +1 @@
1
- import{B as u,B as A}from"../chunks/BillingForm.js";import{B as G}from"../chunks/constants2.js";import"@dropins/tools/event-bus.js";import"../chunks/getStoreConfig.js";import"@dropins/tools/fetch-graphql.js";import"@dropins/tools/preact.js";import"@dropins/tools/preact-hooks.js";import"@dropins/tools/preact-jsx-runtime.js";import"../chunks/setBillingAddress.js";import"../chunks/transform-shipping-methods.js";import"../chunks/getCart.graphql.js";import"../chunks/setShippingAddress.js";import"../chunks/address-form-fields.js";import"../chunks/ToggleButton.js";import"@dropins/tools/lib.js";import"@dropins/tools/i18n.js";import"@dropins/tools/components.js";/* empty css */import"@dropins/tools/preact-compat.js";import"../chunks/ErrorBanner.js";import"../chunks/MergedCartBanner.js";import"../chunks/BillToShippingAddress2.js";export{G as BILLING_FORM_NAME,u as BillingForm,A as default};
1
+ import{B as u,B as A}from"../chunks/BillingForm.js";import{B as G}from"../chunks/constants2.js";import"@dropins/tools/event-bus.js";import"../chunks/fixtures.js";import"@dropins/tools/preact.js";import"@dropins/tools/preact-hooks.js";import"@dropins/tools/fetch-graphql.js";import"../chunks/getMultilineValues.js";import"../chunks/setBillingAddress.js";import"../chunks/getCart.graphql.js";import"../chunks/setShippingAddress.js";import"../chunks/ToggleButton.js";import"@dropins/tools/lib.js";import"@dropins/tools/i18n.js";import"@dropins/tools/components.js";/* empty css */import"@dropins/tools/preact-jsx-runtime.js";import"@dropins/tools/preact-compat.js";import"../chunks/address-form-fields.js";import"../chunks/ErrorBanner.js";import"../chunks/MergedCartBanner.js";import"../chunks/BillToShippingAddress2.js";export{G as BILLING_FORM_NAME,u as BillingForm,A as default};
@@ -1 +1 @@
1
- import{U as z}from"../chunks/transform-shipping-methods.js";import{events as O}from"@dropins/tools/event-bus.js";import{t as b,m as Y,v as d,l as h,i as M,w as f,j as J}from"../chunks/getStoreConfig.js";import{p as Q,g as W,a as X}from"../chunks/placeOrder2.js";import{C as T}from"../chunks/ToggleButton.js";import{useEffect as ee}from"@dropins/tools/preact-hooks.js";import{Slot as k,classes as a}from"@dropins/tools/lib.js";import{Divider as te,IllustratedMessage as A,Icon as N,Button as B}from"@dropins/tools/components.js";/* empty css */import{jsx as t,jsxs as U,Fragment as re}from"@dropins/tools/preact-jsx-runtime.js";import{useText as S,MarkupText as oe}from"@dropins/tools/i18n.js";import{B as ne}from"../chunks/BillToShippingAddress2.js";import{B as ie}from"../chunks/BillingForm.js";import*as r from"@dropins/tools/preact-compat.js";import{useState as C,useCallback as w,useEffect as P}from"@dropins/tools/preact-compat.js";import{L as se}from"../chunks/LoginForm.js";import{P as ae}from"../chunks/ToggleButton2.js";import{P as ce}from"../chunks/PlaceOrder.js";import{S as le}from"../chunks/ShippingForm.js";import{S as pe}from"../chunks/ShippingMethods.js";import"@dropins/tools/fetch-graphql.js";import"@dropins/tools/preact.js";import"../chunks/getCart.graphql.js";import"../chunks/address-form-fields.js";import"../chunks/ErrorBanner.js";import"../chunks/MergedCartBanner.js";import"../chunks/setBillingAddress.js";import"../chunks/setShippingAddress.js";import"../chunks/constants2.js";import"../chunks/setGuestEmailOnCart.js";import"../chunks/constants3.js";import"../chunks/setPaymentMethod.js";import"../chunks/constants.js";import"../chunks/setShippingMethods.js";const de=n=>r.createElement("svg",{width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",...n},r.createElement("g",{clipPath:"url(#clip0_102_196)"},r.createElement("path",{vectorEffect:"non-scaling-stroke",d:"M18.3601 18.16H6.5601L4.8801 3H2.3501M19.6701 19.59C19.6701 20.3687 19.0388 21 18.2601 21C17.4814 21 16.8501 20.3687 16.8501 19.59C16.8501 18.8113 17.4814 18.18 18.2601 18.18C19.0388 18.18 19.6701 18.8113 19.6701 19.59ZM7.42986 19.59C7.42986 20.3687 6.79858 21 6.01986 21C5.24114 21 4.60986 20.3687 4.60986 19.59C4.60986 18.8113 5.24114 18.18 6.01986 18.18C6.79858 18.18 7.42986 18.8113 7.42986 19.59Z",stroke:"currentColor",strokeLinejoin:"round"}),r.createElement("path",{vectorEffect:"non-scaling-stroke",d:"M5.25 6.37L20.89 8.06L20.14 14.8H6.19",stroke:"currentColor",strokeLinejoin:"round"})),r.createElement("defs",null,r.createElement("clipPath",{id:"clip0_102_196"},r.createElement("rect",{vectorEffect:"non-scaling-stroke",width:19.29,height:19.5,fill:"white",transform:"translate(2.3501 2.25)"})))),me=n=>r.createElement("svg",{width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",...n},r.createElement("g",{clipPath:"url(#clip0_4797_15331)"},r.createElement("path",{vectorEffect:"non-scaling-stroke",d:"M10.25 20.91L1.5 17.55V6.51996L10.25 9.92996V20.91Z",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round"}),r.createElement("path",{vectorEffect:"non-scaling-stroke",d:"M6.24023 4.64001L14.9902 8.06001V11.42",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round"}),r.createElement("path",{className:"error-icon",vectorEffect:"non-scaling-stroke",d:"M19 13.31L15.5 19.37H22.5L19 13.31Z",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round"}),r.createElement("path",{className:"error-icon",vectorEffect:"non-scaling-stroke",d:"M19.0202 17.11H18.9802L18.9502 15.56H19.0502L19.0202 17.11ZM18.9602 18.29V18.06H19.0502V18.29H18.9602Z",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round"}),r.createElement("path",{vectorEffect:"non-scaling-stroke",d:"M19 12.16V6.51996L10.25 9.92996V20.91L14.27 19.37L14.4 19.32",stroke:"currentColor",strokeLinejoin:"round"}),r.createElement("path",{vectorEffect:"non-scaling-stroke",d:"M1.5 6.51999L10.25 3.04999L19 6.51999L10.25 9.92999L1.5 6.51999Z",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round"})),r.createElement("defs",null,r.createElement("clipPath",{id:"clip0_4797_15331"},r.createElement("rect",{width:22,height:18.86,fill:"white",transform:"translate(1 2.54999)"})))),Ye="OUT_OF_STOCK";function ue(){const{dispatch:n}=b();ee(()=>{const s=O.on("authenticated",e=>{Y.value=e,n(e?{type:d.USER_AUTHENTICATED}:{type:d.USER_UNAUTHENTICATED})},{eager:!0});return()=>{s==null||s.off()}},[n])}const Je=n=>{const{className:s,slots:e,routeHome:m,preselectedCartData:i,onSignInClick:c,onSignOutClick:E,...x}=n,{state:u,dispatch:l}=b(),[L,_]=C(""),j=L!=="",[F,I]=C(),p=h.value.data,g=!!(p!=null&&p.isVirtual),R=S({CheckoutUnexpectedError:"Checkout.ServerError.unexpected"}),V=w(async()=>{p&&(await Q(),h.value={pending:!1},l({type:d.ORDER_PLACED}))},[p,l]),D=o=>{I(()=>o)},Z=async()=>{_(""),p&&await v()},y=o=>{_(o instanceof TypeError||o instanceof z?R.CheckoutUnexpectedError:o.message)},v=w(async()=>{const o=M.cartId,G=M.authenticated;if(!o)h.value={data:null,pending:!1},l({type:d.CART_UPDATED,payload:null});else{h.value={...h.value,pending:!0};const q=await W();G&&await X(),l({type:d.CART_UPDATED,payload:q})}},[l]);ue();const[H,K]=C({});if(P(()=>{u===f.IN_PROGRESS&&K({})},[u]),P(()=>{const o=O.on("cart/data",()=>{v()},{eager:!0});return()=>{o==null||o.off()}},[v]),u===f.COMPLETE)return null;if(u===f.EMPTY)return t(he,{routeHome:m});if(j)return t(ge,{errorMessage:L,onClick:Z});const $=()=>{const o=J.value.checked?"checkout-billing-form__hidden":"checkout-billing-form__visible";return t(T.Main,{sections:{billingAddress:U(re,{children:[t(k,{name:"BillingForm",className:o,slot:e==null?void 0:e.BillingForm,children:t(ie,{})}),t(te,{className:a([`${o}`,"checkout-billing-form__divider"]),variant:"primary"})]}),billToShippingAddress:g?void 0:t(ne,{},H),login:t(k,{name:"Login",slot:e==null?void 0:e.Login,children:t(se,{onSignInClick:c,onSignOutClick:()=>{l({type:d.USER_SIGN_OUT}),E==null||E()}})}),paymentMethods:t(ae,{isShippingInfoRequired:!g,onPlaceOrder:D,handleServerError:y,paymentMethodsSlot:e==null?void 0:e.PaymentMethods}),placeOrder:t(ce,{onClick:F??V,handleServerError:y}),shippingAddress:g?void 0:t(k,{name:"ShippingForm",slot:e==null?void 0:e.ShippingForm,children:t(le,{preselectedFields:i==null?void 0:i.address})}),shippingMethods:g?void 0:t(k,{name:"ShippingMethods",slot:e==null?void 0:e.ShippingMethods,children:t(pe,{preSelectedMethod:i==null?void 0:i.shippingMethod})})}})};return t(T,{className:s,isLoading:u===f.LOADING,...x,children:$()})},he=({className:n,title:s,routeHome:e,...m})=>{const i=S({Title:"Checkout.EmptyCart.title",Button:"Checkout.EmptyCart.button"});return t(A,{...m,"data-testid":"checkout-empty-cart",className:a(["checkout-empty-cart",n]),heading:s??i.Title,icon:t(N,{className:a(["checkout-empty-cart__icon"]),source:de}),action:e!=null&&e()?t(B,{className:"checkout-empty-cart__button",size:"medium",variant:"primary",type:"submit",href:e==null?void 0:e(),children:i.Button},"routeHome"):void 0})},ge=({className:n,errorMessage:s,contactSupport:e,...m})=>{const{onClick:i}=m,c=S({Title:"Checkout.ServerError.title",Message:"Checkout.ServerError.message",ContactSupport:"Checkout.ServerError.contactSupport",Button:"Checkout.ServerError.button"});return t(A,{"aria-invalid":"true","aria-describedby":"checkout-server-error__message","aria-live":"polite",className:a(["checkout-server-error",n]),"data-testid":"checkout-server-error",heading:s??c.Title,message:U("p",{id:a(["checkout-server-error__message"]),children:[c.Message,t("br",{}),t(oe,{id:"",children:e??c.ContactSupport})]}),icon:t(N,{className:a(["checkout-server-error__icon"]),source:me}),action:t(B,{className:a(["checkout-server-error__button"]),onClick:i,children:c.Button})})};export{Je as Checkout,Ye as OUT_OF_STOCK,Je as default};
1
+ import{o as $,n as K,m as C,l as R,U as q}from"../chunks/fixtures.js";import"@dropins/tools/event-bus.js";import{a as z}from"../chunks/getCustomer.js";import{p as G}from"../chunks/placeOrder2.js";import{C as L}from"../chunks/ToggleButton.js";import"@dropins/tools/preact-hooks.js";import{Slot as d,classes as c}from"@dropins/tools/lib.js";import{Divider as J,IllustratedMessage as S,Icon as M,Button as _}from"@dropins/tools/components.js";/* empty css */import{jsx as r,jsxs as y,Fragment as Q}from"@dropins/tools/preact-jsx-runtime.js";import{useText as g,MarkupText as W}from"@dropins/tools/i18n.js";import{B as X}from"../chunks/BillToShippingAddress2.js";import{B as Y}from"../chunks/BillingForm.js";import*as t from"@dropins/tools/preact-compat.js";import{useState as u,useCallback as D}from"@dropins/tools/preact-compat.js";import{L as ee}from"../chunks/LoginForm.js";import{P as re}from"../chunks/ToggleButton2.js";import{P as te}from"../chunks/PlaceOrder.js";import{S as oe}from"../chunks/ShippingForm.js";import{S as ne}from"../chunks/ShippingMethods.js";import"@dropins/tools/preact.js";import"@dropins/tools/fetch-graphql.js";import"../chunks/getCart.graphql.js";import"../chunks/getMultilineValues.js";import"../chunks/address-form-fields.js";import"../chunks/ErrorBanner.js";import"../chunks/MergedCartBanner.js";import"../chunks/setBillingAddress.js";import"../chunks/setShippingAddress.js";import"../chunks/constants2.js";import"../chunks/setGuestEmailOnCart.js";import"../chunks/constants3.js";import"../chunks/setPaymentMethod.js";import"../chunks/constants.js";import"../chunks/setShippingMethods.js";const ie=i=>t.createElement("svg",{width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",...i},t.createElement("g",{clipPath:"url(#clip0_102_196)"},t.createElement("path",{vectorEffect:"non-scaling-stroke",d:"M18.3601 18.16H6.5601L4.8801 3H2.3501M19.6701 19.59C19.6701 20.3687 19.0388 21 18.2601 21C17.4814 21 16.8501 20.3687 16.8501 19.59C16.8501 18.8113 17.4814 18.18 18.2601 18.18C19.0388 18.18 19.6701 18.8113 19.6701 19.59ZM7.42986 19.59C7.42986 20.3687 6.79858 21 6.01986 21C5.24114 21 4.60986 20.3687 4.60986 19.59C4.60986 18.8113 5.24114 18.18 6.01986 18.18C6.79858 18.18 7.42986 18.8113 7.42986 19.59Z",stroke:"currentColor",strokeLinejoin:"round"}),t.createElement("path",{vectorEffect:"non-scaling-stroke",d:"M5.25 6.37L20.89 8.06L20.14 14.8H6.19",stroke:"currentColor",strokeLinejoin:"round"})),t.createElement("defs",null,t.createElement("clipPath",{id:"clip0_102_196"},t.createElement("rect",{vectorEffect:"non-scaling-stroke",width:19.29,height:19.5,fill:"white",transform:"translate(2.3501 2.25)"})))),se=i=>t.createElement("svg",{width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",...i},t.createElement("g",{clipPath:"url(#clip0_4797_15331)"},t.createElement("path",{vectorEffect:"non-scaling-stroke",d:"M10.25 20.91L1.5 17.55V6.51996L10.25 9.92996V20.91Z",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round"}),t.createElement("path",{vectorEffect:"non-scaling-stroke",d:"M6.24023 4.64001L14.9902 8.06001V11.42",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round"}),t.createElement("path",{className:"error-icon",vectorEffect:"non-scaling-stroke",d:"M19 13.31L15.5 19.37H22.5L19 13.31Z",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round"}),t.createElement("path",{className:"error-icon",vectorEffect:"non-scaling-stroke",d:"M19.0202 17.11H18.9802L18.9502 15.56H19.0502L19.0202 17.11ZM18.9602 18.29V18.06H19.0502V18.29H18.9602Z",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round"}),t.createElement("path",{vectorEffect:"non-scaling-stroke",d:"M19 12.16V6.51996L10.25 9.92996V20.91L14.27 19.37L14.4 19.32",stroke:"currentColor",strokeLinejoin:"round"}),t.createElement("path",{vectorEffect:"non-scaling-stroke",d:"M1.5 6.51999L10.25 3.04999L19 6.51999L10.25 9.92999L1.5 6.51999Z",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round"})),t.createElement("defs",null,t.createElement("clipPath",{id:"clip0_4797_15331"},t.createElement("rect",{width:22,height:18.86,fill:"white",transform:"translate(1 2.54999)"})))),Re="OUT_OF_STOCK",qe=i=>{const{className:l,slots:e,routeHome:m,preselectedCartData:o,onSignInClick:a,onSignOutClick:h,...b}=i,w=$.authenticated,[P,B]=u(!1),[k,f]=u(""),T=k!=="",[O,x]=u(),{data:n,pending:F}=K.value,p=!!(n!=null&&n.isVirtual),N=n===null||(n==null?void 0:n.isEmpty),{data:E,pending:j}=C.value,V=F&&w&&!E,Z=g({CheckoutUnexpectedError:"Checkout.ServerError.unexpected"}),A=D(async()=>{n&&(await G(),B(!0))},[n]),U=s=>{x(()=>s)},I=async()=>{f(""),n&&z()},v=s=>{const H=s instanceof TypeError||s instanceof q?Z.CheckoutUnexpectedError:s.message;f(H)};return P?null:N?r(ce,{routeHome:m}):T?r(ae,{errorMessage:k,onClick:I}):r(L,{className:l,isLoading:V||j,...b,children:(()=>{const s=R.value.checked?"checkout-billing-form__hidden":"checkout-billing-form__visible";return r(L.Main,{sections:{billingAddress:y(Q,{children:[r(d,{name:"BillingForm",className:s,slot:e==null?void 0:e.BillingForm,children:r(Y,{})}),r(J,{className:c([`${s}`,"checkout-billing-form__divider"]),variant:"primary"})]}),billToShippingAddress:p?void 0:r(X,{},`bill-to-shipping-address${E?"-customer":""}`),login:r(d,{name:"Login",slot:e==null?void 0:e.Login,children:r(ee,{onSignInClick:a,onSignOutClick:()=>{h==null||h(),C.value.pending=!0}})}),paymentMethods:r(re,{isShippingInfoRequired:!p,onPlaceOrder:U,handleServerError:v,paymentMethodsSlot:e==null?void 0:e.PaymentMethods}),placeOrder:r(te,{onClick:O??A,handleServerError:v}),shippingAddress:p?void 0:r(d,{name:"ShippingForm",slot:e==null?void 0:e.ShippingForm,children:r(oe,{preselectedFields:o==null?void 0:o.address})}),shippingMethods:p?void 0:r(d,{name:"ShippingMethods",slot:e==null?void 0:e.ShippingMethods,children:r(ne,{preSelectedMethod:o==null?void 0:o.shippingMethod})})}})})()})},ce=({className:i,title:l,routeHome:e,...m})=>{const o=g({Title:"Checkout.EmptyCart.title",Button:"Checkout.EmptyCart.button"});return r(S,{...m,"data-testid":"checkout-empty-cart",className:c(["checkout-empty-cart",i]),heading:l??o.Title,icon:r(M,{className:c(["checkout-empty-cart__icon"]),source:ie}),action:e!=null&&e()?r(_,{className:"checkout-empty-cart__button",size:"medium",variant:"primary",type:"submit",href:e==null?void 0:e(),children:o.Button},"routeHome"):void 0})},ae=({className:i,errorMessage:l,contactSupport:e,...m})=>{const{onClick:o}=m,a=g({Title:"Checkout.ServerError.title",Message:"Checkout.ServerError.message",ContactSupport:"Checkout.ServerError.contactSupport",Button:"Checkout.ServerError.button"});return r(S,{"aria-invalid":"true","aria-describedby":"checkout-server-error__message","aria-live":"polite",className:c(["checkout-server-error",i]),"data-testid":"checkout-server-error",heading:l??a.Title,message:y("p",{id:c(["checkout-server-error__message"]),children:[a.Message,r("br",{}),r(W,{id:"",children:e??a.ContactSupport})]}),icon:r(M,{className:c(["checkout-server-error__icon"]),source:se}),action:r(_,{className:c(["checkout-server-error__button"]),onClick:o,children:a.Button})})};export{qe as Checkout,Re as OUT_OF_STOCK,qe as default};
@@ -0,0 +1,4 @@
1
+ import { FunctionComponent } from 'preact';
2
+
3
+ export declare const EstimateShipping: FunctionComponent;
4
+ //# sourceMappingURL=EstimateShipping.d.ts.map
@@ -0,0 +1,3 @@
1
+ export * from './EstimateShipping';
2
+ export { EstimateShipping as default } from './EstimateShipping';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1,3 @@
1
+ export * from './EstimateShipping/index'
2
+ import _default from './EstimateShipping/index'
3
+ export default _default
@@ -0,0 +1 @@
1
+ import"../chunks/ToggleButton.js";import{events as S}from"@dropins/tools/event-bus.js";import{useState as L,useEffect as E}from"@dropins/tools/preact-hooks.js";import{q as M,T as k}from"../chunks/fixtures.js";import{VComponent as w,classes as C}from"@dropins/tools/lib.js";import{Skeleton as A,SkeletonRow as B,Price as h}from"@dropins/tools/components.js";/* empty css */import{jsx as t,jsxs as I}from"@dropins/tools/preact-jsx-runtime.js";import{useText as G,Text as o}from"@dropins/tools/i18n.js";import"../chunks/getMultilineValues.js";import"@dropins/tools/preact-compat.js";import"../chunks/address-form-fields.js";import"@dropins/tools/preact.js";import"../chunks/ErrorBanner.js";import"../chunks/MergedCartBanner.js";import"@dropins/tools/fetch-graphql.js";const P=()=>t(A,{"data-testid":"estimate-shipping-skeleton",children:t(B,{size:"small"})}),Z=()=>{const[e,s]=L(),c=e!==void 0,r=(e==null?void 0:e.amount.value)===0,{data:n,pending:_}=M.value,y=_||n===void 0,l=n==null?void 0:n.shoppingCartDisplaySetting.shipping,D=l===k.INCLUDING_EXCLUDING_TAX,g=l===k.INCLUDING_TAX,x=G({freeShipping:"Checkout.EstimateShipping.freeShipping",taxToBeDetermined:"Checkout.EstimateShipping.taxToBeDetermined"});if(E(()=>{const i=S.on("shipping/estimate",a=>{const p=a.shippingMethod,{amount:m,amountExclTax:u,amountInclTax:d}=p;s({estimated:!0,amount:m,amountExclTax:u,amountInclTax:d})});return()=>{i==null||i.off()}},[]),E(()=>{const i=S.on("checkout/data",a=>{var f,T;const p=(T=(f=a==null?void 0:a.shippingAddresses)==null?void 0:f[0])==null?void 0:T.selectedShippingMethod;if(!p)return;const{amount:m,amountExclTax:u,amountInclTax:d}=p;s({estimated:!1,amount:m,amountExclTax:u,amountInclTax:d})});return()=>{i==null||i.off()}},[]),!c||y)return t(P,{});const N=()=>r?t("span",{"data-testId":"free-shipping",children:x.freeShipping}):g&&e.amountInclTax?t(h,{"data-testid":"shipping",amount:e.amountInclTax.value,currency:e.amountInclTax.currency}):t(h,{"data-testid":"shipping",amount:e.amount.value,currency:e.amount.currency}),v=()=>e.amountExclTax?t(h,{"data-testid":"shipping-excluding-tax",amount:e.amountExclTax.value,currency:e.amountExclTax.currency}):t("span",{children:x.taxToBeDetermined});return t(U,{estimated:e.estimated,price:N(),taxExcluded:D,taxIncluded:g,priceExclTax:v()})},U=({estimated:e=!1,price:s,priceExclTax:c,taxExcluded:r=!1,taxIncluded:n=!1})=>I("div",{"data-testid":"estimate-shipping",className:"checkout-estimate-shipping",children:[t("span",{className:"checkout-estimate-shipping__label",children:e?t(o,{id:"Checkout.EstimateShipping.estimated"}):t(o,{id:"Checkout.EstimateShipping.label"})}),t(w,{node:s,className:"checkout-estimate-shipping__price"}),n&&t("span",{"data-testid":"shipping-tax-included",className:C(["checkout-estimate-shipping__caption"]),children:t(o,{id:"Checkout.EstimateShipping.withTaxes"})}),r&&I("span",{"data-testid":"shipping-tax-included-excluded",className:C(["checkout-estimate-shipping__caption"]),children:[c,t(o,{id:"Checkout.EstimateShipping.withoutTaxes"})]})]});export{Z as EstimateShipping,Z as default};
@@ -1,5 +1,5 @@
1
- import { HTMLAttributes } from 'preact/compat';
2
1
  import { FunctionComponent } from 'preact';
2
+ import { HTMLAttributes } from 'preact/compat';
3
3
 
4
4
  export interface LoginFormProps extends HTMLAttributes<HTMLDivElement> {
5
5
  email?: string;
@@ -1 +1 @@
1
- import{L as n}from"../chunks/constants3.js";import{L as A,L as E}from"../chunks/LoginForm.js";import"@dropins/tools/event-bus.js";import"../chunks/getStoreConfig.js";import"@dropins/tools/fetch-graphql.js";import"@dropins/tools/preact.js";import"@dropins/tools/preact-hooks.js";import"@dropins/tools/preact-jsx-runtime.js";import"../chunks/setGuestEmailOnCart.js";import"../chunks/transform-shipping-methods.js";import"../chunks/getCart.graphql.js";import"@dropins/tools/components.js";import"../chunks/ToggleButton.js";import"../chunks/address-form-fields.js";import"@dropins/tools/lib.js";import"@dropins/tools/i18n.js";/* empty css */import"@dropins/tools/preact-compat.js";import"../chunks/ErrorBanner.js";import"../chunks/MergedCartBanner.js";export{n as LOGIN_FORM_NAME,A as LoginForm,E as default};
1
+ import{L as n}from"../chunks/constants3.js";import{L as A,L as E}from"../chunks/LoginForm.js";import"@dropins/tools/event-bus.js";import"../chunks/fixtures.js";import"@dropins/tools/preact.js";import"@dropins/tools/preact-hooks.js";import"@dropins/tools/fetch-graphql.js";import"../chunks/setGuestEmailOnCart.js";import"../chunks/getCart.graphql.js";import"../chunks/ToggleButton.js";import"../chunks/getMultilineValues.js";import"@dropins/tools/lib.js";import"@dropins/tools/i18n.js";import"@dropins/tools/components.js";/* empty css */import"@dropins/tools/preact-jsx-runtime.js";import"@dropins/tools/preact-compat.js";import"../chunks/address-form-fields.js";import"../chunks/ErrorBanner.js";import"../chunks/MergedCartBanner.js";export{n as LOGIN_FORM_NAME,A as LoginForm,E as default};
@@ -1 +1 @@
1
- import{P as c,P as g}from"../chunks/ToggleButton2.js";import"@dropins/tools/event-bus.js";import"../chunks/getStoreConfig.js";import"@dropins/tools/fetch-graphql.js";import"@dropins/tools/preact.js";import"@dropins/tools/preact-hooks.js";import"@dropins/tools/preact-jsx-runtime.js";import"../chunks/setPaymentMethod.js";import"../chunks/transform-shipping-methods.js";import"../chunks/getCart.graphql.js";import"../chunks/ToggleButton.js";import"../chunks/address-form-fields.js";import"@dropins/tools/lib.js";import"@dropins/tools/i18n.js";import"@dropins/tools/components.js";/* empty css */import"@dropins/tools/preact-compat.js";import"../chunks/ErrorBanner.js";import"../chunks/MergedCartBanner.js";export{c as PaymentMethods,g as default};
1
+ import{P as c,P as g}from"../chunks/ToggleButton2.js";import"@dropins/tools/event-bus.js";import"../chunks/fixtures.js";import"@dropins/tools/preact.js";import"@dropins/tools/preact-hooks.js";import"@dropins/tools/fetch-graphql.js";import"../chunks/setPaymentMethod.js";import"../chunks/getCart.graphql.js";import"../chunks/ToggleButton.js";import"../chunks/getMultilineValues.js";import"@dropins/tools/lib.js";import"@dropins/tools/i18n.js";import"@dropins/tools/components.js";/* empty css */import"@dropins/tools/preact-jsx-runtime.js";import"@dropins/tools/preact-compat.js";import"../chunks/address-form-fields.js";import"../chunks/ErrorBanner.js";import"../chunks/MergedCartBanner.js";export{c as PaymentMethods,g as default};
@@ -1 +1 @@
1
- import{P as k,P as n}from"../chunks/PlaceOrder.js";import"@dropins/tools/lib.js";import"../chunks/ToggleButton.js";import"@dropins/tools/event-bus.js";import"../chunks/getStoreConfig.js";import"@dropins/tools/fetch-graphql.js";import"@dropins/tools/preact.js";import"@dropins/tools/preact-hooks.js";import"@dropins/tools/preact-jsx-runtime.js";import"../chunks/address-form-fields.js";import"../chunks/transform-shipping-methods.js";import"@dropins/tools/i18n.js";import"@dropins/tools/components.js";/* empty css */import"@dropins/tools/preact-compat.js";import"../chunks/ErrorBanner.js";import"../chunks/MergedCartBanner.js";import"../chunks/constants2.js";import"../chunks/constants3.js";import"../chunks/constants.js";export{k as PlaceOrder,n as default};
1
+ import{P as k,P as n}from"../chunks/PlaceOrder.js";import"@dropins/tools/lib.js";import"../chunks/ToggleButton.js";import"@dropins/tools/event-bus.js";import"../chunks/fixtures.js";import"@dropins/tools/preact.js";import"@dropins/tools/preact-hooks.js";import"@dropins/tools/fetch-graphql.js";import"../chunks/getMultilineValues.js";import"@dropins/tools/i18n.js";import"@dropins/tools/components.js";/* empty css */import"@dropins/tools/preact-jsx-runtime.js";import"@dropins/tools/preact-compat.js";import"../chunks/address-form-fields.js";import"../chunks/ErrorBanner.js";import"../chunks/MergedCartBanner.js";import"../chunks/constants2.js";import"../chunks/constants3.js";import"../chunks/constants.js";export{k as PlaceOrder,n as default};
@@ -1 +1 @@
1
- import{S as l,S as n}from"../chunks/ShippingForm.js";import{S as A}from"../chunks/constants.js";import"@dropins/tools/event-bus.js";import"../chunks/getStoreConfig.js";import"@dropins/tools/fetch-graphql.js";import"@dropins/tools/preact.js";import"@dropins/tools/preact-hooks.js";import"@dropins/tools/preact-jsx-runtime.js";import"../chunks/setBillingAddress.js";import"../chunks/transform-shipping-methods.js";import"../chunks/getCart.graphql.js";import"../chunks/setShippingAddress.js";import"../chunks/address-form-fields.js";import"../chunks/ToggleButton.js";import"@dropins/tools/lib.js";import"@dropins/tools/i18n.js";import"@dropins/tools/components.js";/* empty css */import"@dropins/tools/preact-compat.js";import"../chunks/ErrorBanner.js";import"../chunks/MergedCartBanner.js";export{A as SHIPPING_FORM_NAME,l as ShippingForm,n as default};
1
+ import{S as l,S as n}from"../chunks/ShippingForm.js";import{S as A}from"../chunks/constants.js";import"@dropins/tools/event-bus.js";import"../chunks/fixtures.js";import"@dropins/tools/preact.js";import"@dropins/tools/preact-hooks.js";import"@dropins/tools/fetch-graphql.js";import"../chunks/getMultilineValues.js";import"../chunks/setBillingAddress.js";import"../chunks/getCart.graphql.js";import"../chunks/setShippingAddress.js";import"../chunks/ToggleButton.js";import"@dropins/tools/lib.js";import"@dropins/tools/i18n.js";import"@dropins/tools/components.js";/* empty css */import"@dropins/tools/preact-jsx-runtime.js";import"@dropins/tools/preact-compat.js";import"../chunks/address-form-fields.js";import"../chunks/ErrorBanner.js";import"../chunks/MergedCartBanner.js";export{A as SHIPPING_FORM_NAME,l as ShippingForm,n as default};