1import{kl as G,p as Q,bE as u,eL as x}from"./utilities-previous.BNOUhCqt.js";import{x as B}from"./esnext-vendor.7EcvH7tF.js";import{jz as E}from"./hydrate.CvWSYK3c.js";function z({address1:e="",address2:r,city:s="",company:i,countryCode:t,firstName:n,lastName:o="",postalCode:d,zoneCode:c,phone:f="",oneTimeUse:p=!1,coordinates:a,district:g,line2:m,streetName:C,streetNumber:h,subdistrict:y},A){const{extendedFields:F,...L}=G({address1:e,address2:r,countryCode:t,fields:{district:g,line2:m,streetName:C,streetNumber:h,subdistrict:y},extendedAddressMode:A?.extendedAddressMode});return{...L,city:s??"",countryCode:t||"ZZ",postalCode:d,company:i,firstName:n,lastName:o,zoneCode:c,phone:f,oneTimeUse:p,coordinates:a?l(a):void 0,extendedFields:F}}function N({handle:e=""}){return{handle:e}}function l(e){return{latitude:e.latitude,longitude:e.longitude}}function P(e,r,s,i,t=!1){const n=Q(e),o=e?.[0]?.method?.type==="deferred"&&s==="custom"&&!t;if(!n&&o)return null;const d=!!r.address1;return n||d?{streetAddress:u(r,i)}:null}function R(e,r){return e.coordinates?{geolocation:{coordinates:l(e.coordinates),countryCode:x(e.countryCode),zoneCode:e.zoneCode,postalCode:e.postalCode}}:{streetAddress:u(e,r)}}function b({deliveryMethodHandle:e,deliveryMethodOptions:r,isCustomRate:s,isPointOfSale:i,retailLocationId:t,isPointOfSaleShipToHome:n,customDeliveryStrategy:o}={}){return i&&t&&!n?{deliveryStrategyMatchingConditions:{shipments:{any:!0}},options:r,originLocationId:t,autoFulfill:!0}:e?{deliveryStrategyByHandle:{handle:e,customDeliveryRate:s??!1},options:r}:o?{customDeliveryStrategy:{title:o.title,price:{value:o.price},code:o.code,source:o.source},options:r}:{deliveryStrategyMatchingConditions:{estimatedTimeInTransit:{any:!0},shipments:{any:!0}},options:r}}function k(){return B(E)}const _=["phone","company","firstName","lastName","countryCode"];export{_ as S,N as a,P as b,z as d,R as g,b as s,k as u};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.