1try{let e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="322dcb34-dcb2-47dd-8a6d-025ea7a1a636",e._sentryDebugIdIdentifier="sentry-dbid-322dcb34-dcb2-47dd-8a6d-025ea7a1a636")}catch(e){}"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2538],{29668:(e,n,a)=>{a.d(n,{R:()=>t});let t={ns:"domain/view/shipping-address-form",en:{name:"Name",enter_recipient_name_blah:"Enter recipient name",phone_number:"Phone Number",enter_without_hyphens_blah:"Enter without hyphens",address_alias:"Address Alias",enter_address_alias_blah:"Enter address alias (e.g. Friend's house)",shipping_address:"Shipping address",change:"Change",set_as_default_blah:"Set as default shipping address",save:"Save",please_enter_name_blah:"Please enter your name",please_enter_phone_blah:"Please enter your phone number",please_enter_alias_blah:"Please enter address alias",please_select_a_blah:"Please select a country",choose_country:"Choose country"},ko:{name:"ì´ë¦",enter_recipient_name_blah:"ì 물 ë°ë ë¶ì ì¤ëª
ì ì
ë ¥íì¸ì.",phone_number:"í´ëí° ë²í¸",enter_without_hyphens_blah:"íì´í(-), ëì´ì°ê¸° ìì´ ì
ë ¥í´ì£¼ì¸ì.",address_alias:"주ì ë³ëª
",enter_address_alias_blah:"주ì ë³ëª
ì ìë ¤ì£¼ì¸ì (ìì:ì¹êµ¬ì§)",shipping_address:"ë°°ì¡ì§ ì ë³´",change:"ë°°ì¡ì§ ë³ê²½",set_as_default_blah:"기본 ë°°ì¡ì§ë¡ ì¤ì ",save:"ì ì¥í기",please_enter_name_blah:"ì´ë¦ì ì
ë ¥í´ì£¼ì¸ì",please_enter_phone_blah:"í´ëí° ë²í¸ë¥¼ ì
ë ¥í´ì£¼ì¸ì",please_enter_alias_blah:"주ì ë³ëª
ì ì
ë ¥í´ì£¼ì¸ì",please_select_a_blah:"êµê°ë¥¼ ì íí´ì£¼ì¸ì",choose_country:"êµê° ì í"},ja:{name:"ãåå",enter_recipient_name_blah:"åå人ã®ååãå
¥åãã¦ãã ãã",phone_number:"é»è©±çªå·",enter_without_hyphens_blah:"ãã¤ãã³ãªãã§å
¥åãã¦ãã ãã",address_alias:"使ããã¯ãã¼ã ",enter_address_alias_blah:"使ããã¯ãã¼ã ãå
¥åãã¦ãã ããï¼ä¾ï¼å人å®
ï¼",shipping_address:"é
éå
æ
å ±",change:"é
éå
ã夿´",set_as_default_blah:"ããã©ã«ãã®é
éå
ã«è¨å®",save:"ä¿å",please_enter_name_blah:"ååãå
¥åãã¦ãã ãã",please_enter_phone_blah:"é»è©±çªå·ãå
¥åãã¦ãã ãã",please_enter_alias_blah:"使ããã¯ãã¼ã ãå
¥åãã¦ãã ãã",please_select_a_blah:"å½ã鏿ãã¦ãã ãã",choose_country:"å½ã鏿"}}},54500:(e,n,a)=>{a.d(n,{Ay:()=>p,Bl:()=>c,QO:()=>_,h8:()=>o,yh:()=>d,zA:()=>h});var t=a(14232),r=a(55197),i=a(87987),s=a(40426),l=a(70704);let o="recipientName",_="recipientFirstName",d="recipientLastName",c="nonEmpty",h='input[name="'.concat(o,'"], input[name="').concat(_,'"], input[name="').concat(d,'"]'),p=e=>{var n,a,o;let{deliveryMethod:_,destinationCode:d}=e,{t:c}=(0,r.Z)(m),{paymentItem:h}=null!=(a=null==(n=(0,l.Pj)().user)?void 0:n.payment)?a:{},{isGiftCardType:p,isDeliveryType:u}=null!=(o=null==h?void 0:h.item)?o:{},f=_===i.ye.Manual,b=f&&!!d,g=b&&(0,s.Ko)(d),y=f?(e=>{switch(e){case i.yt.KR:return c("enter_name");case i.yt.JP:return c("please_enter_giftee_name_in_english_or_japanese");default:return c("please_enter_giftee_blah")}})(d):c("enter_name");return{recipientNamePlaceholder:y,recipientNameTypingHint:(0,t.useMemo)(()=>d===i.yt.US&&p?{message:"please_enter_giftee_name_in_english",color:"#9d9d9d"}:d===i.yt.US&&u?{message:"if_the_recipient_blah",color:"#0f0f0f"}:d===i.yt.KR||u?{message:"if_you_do_blah",color:"#0f0f0f"}:{message:"please_both_your_blah",color:"#9d9d9d"},[d,p,u]),recipientNameValidator:(0,t.useMemo)(()=>{if(!f)return null;let e=(e=>{switch(e){case i.yt.KR:return{pattern:/^[a-zA-Zê°-í£\s]+$/,messageI18nKey:"name_can_only_blah"};case i.yt.JP:return{pattern:/^[a-zA-Zã-ãã¡-ã³ä¸-龯\s]+$/,messageI18nKey:"please_enter_giftee_name_in_english_or_japanese"};case i.yt.VN:return{pattern:/^[a-zA-ZÃ-ỹ\s]+$/,messageI18nKey:"please_enter_giftee_name_in_english_or_vietnamese"};case i.yt.CN:case i.yt.TW:case i.yt.HK:return{pattern:/^[a-zA-Z\u4e00-\u9fff\s]+$/,messageI18nKey:"please_enter_giftee_name_in_english_or_chinese"};default:return{pattern:/^[a-zA-Z\s]+$/,messageI18nKey:"if_the_recipient_blah"}}})(d);return[{name:"nameFormatValidator",validatorFn:n=>new RegExp(e.pattern).test(n),message:c(e.messageI18nKey)}]}
1,[d,f,c]),isSplitNameRequired:b,isFamilyNameFirst:g}},m={ns:"domain/giftee-name-config",en:{enter_name:"Please enter the gifteeâs name",name_can_only_blah:"Name can only be entered in Korean or English",please_enter_giftee_name_in_english_or_japanese:"Please enter the gifteeâs name in English or Japanese.",please_enter_giftee_name_in_english:"Please enter your first name and last name correctly in English.",please_enter_giftee_blah:"Please enter the gifteeâs name",please_enter_giftee_name_in_english_or_vietnamese:"Please enter the gifteeâs name in English or Vietnamese.",please_enter_giftee_name_in_english_or_chinese:"Please enter the gifteeâs name in English or Chinese.",if_the_recipient_blah:"If the recipientâs full name is not entered in English, the order may be canceled."},ko:{enter_name:"ë°ë ë¶ ì´ë¦ì ì
ë ¥í´ì£¼ì¸ì.",name_can_only_blah:"ë°ë ë¶ ì´ë¦ì íê¸ ëë ìì´ë§ ì
ë ¥í ì ììµëë¤",please_enter_giftee_name_in_english_or_japanese:"ë°ë ë¶ ì´ë¦ì ìì´ ëë ì¼ë³¸ì´ë¡ ì
ë ¥í´ ì£¼ì¸ì",please_enter_giftee_name_in_english:"ì문ì¼ë¡ ì±ê³¼ ì´ë¦ì 모ë ì íí ì
ë ¥í´ ì£¼ì¸ì.",please_enter_giftee_blah:"ë°ë ë¶ ì´ë¦ì ì
ë ¥í´ ì£¼ì¸ì",please_enter_giftee_name_in_english_or_vietnamese:"ë°ë ë¶ ì´ë¦ì ìì´ ëë ë² í¸ë¨ì´ë¡ ì
ë ¥í´ ì£¼ì¸ì",please_enter_giftee_name_in_english_or_chinese:"ë°ë ë¶ ì´ë¦ì ìì´ ëë ì¤êµì´ë¡ ì
ë ¥í´ ì£¼ì¸ì",if_the_recipient_blah:"ë°ë ë¶ì ì±ê³¼ ì´ë¦ì´ ì문ì¼ë¡ ì íí ì
ë ¥ëì§ ìì ê²½ì° ì£¼ë¬¸ì´ ì·¨ìë ì ììµëë¤."},ja:{enter_name:"åå人ã®ååãå
¥åãã¦ãã ããã",name_can_only_blah:"åå人ã®ãååã¯éå½èªã¾ãã¯è±èªã§å
¥åããå¿
è¦ãããã¾ãã",please_enter_giftee_name_in_english_or_japanese:"è´ãæ¹ã®ãååãè±èªã¾ãã¯æ¥æ¬èªã§å
¥åãã¦ãã ããã",please_enter_giftee_name_in_english:"è±åã§å§ã¨åãæ¼ããªãæ£ç¢ºã«å
¥åãã¦ãã ããã",please_enter_giftee_blah:"åå人ã®ãååãå
¥åãã¦ãã ããã",please_enter_giftee_name_in_english_or_vietnamese:"åå人ã®ãååãè±èªã¾ãã¯ãããã èªã§å
¥åãã¦ãã ãã",please_enter_giftee_name_in_english_or_chinese:"åå人ã®ãååãè±èªã¾ãã¯ä¸å½èªã§å
¥åãã¦ãã ãã",if_the_recipient_blah:"ååäººã®æ°åãè±èªã§å
¥åããªãå ´åãæ³¨æããã£ã³ã»ã«ãããå¯è½æ§ãããã¾ãã"}}},61223:(e,n,a)=>{a.d(n,{A:()=>t});let t={ns:"domain/add-friend",en:{country:"Country",choose_country:"Choose country",search_country:"Search country",relationship:"Relationship with the friend",add_new_giftee:"Add new giftee",name:"Name",please_enter_name:"Please enter your name",please_enter_email_blah:"Please enter your email address",country_of_residence:"Country of residence",please_select_a_relationship:"Please select a relationship",please_select_a_blah:"Please select a country",no_matching_country:"No matching countries.",optional_details:"Optional details",email:"Email",invalid_email_address:"Invalid email address",mobile_number:"Mobile number",please_enter_without_blah:"Please enter without hyphens (-) or spaces.",address:"Delivery address",confirm:"Confirm",share_a_gift_blah:"Share a gift link â no address or phone number needed.",other_countries:"Other countries"},ko:{country:"êµê°",choose_country:"êµê° ì í",search_country:"êµê° ê²ì",relationship:"ì¹êµ¬ìì ê´ê³",add_new_giftee:"ë°ë ë¶ ì¶ê°",name:"ì´ë¦",please_enter_name:"ì´ë¦ì ì
ë ¥í´ì£¼ì¸ì",please_enter_email_blah:"ì´ë©ì¼ 주ì를 ì
ë ¥í´ì£¼ì¸ì",country_of_residence:"거주 êµê°",please_select_a_relationship:"ê´ê³ë¥¼ ì íí´ì£¼ì¸ì",please_select_a_blah:"êµê°ë¥¼ ì íí´ì£¼ì¸ì",no_matching_country:"ì¼ì¹íë êµê°ê° ìì´ì.",optional_details:"ì¶ê° ì í ì ë³´",email:"ì´ë©ì¼",invalid_email_address:"ì í¨íì§ ìì ì´ë©ì¼ íìì
ëë¤",mobile_number:"í´ëí° ë²í¸",please_enter_without_blah:"íì´í(-), ëì´ì°ê¸° ìì´ ì
ë ¥í´ì£¼ì¸ì.",address:"주ì",confirm:"íì¸",share_a_gift_blah:"주ìë ë²í¸ë¥¼ ì
ë ¥íì§ ììë ë§í¬ë¡ ì 물í ì ìì´ì.",other_countries:"ê·¸ ë°ì êµê°"},ja:{country:"å½",choose_country:"å½ã鏿",search_country:"å½ãæ¤ç´¢",relationship:"åéã¨ã®é¢ä¿",add_new_giftee:"åå人ã®è¿½å ",name:"ãåå",please_enter_name:"ãååãå
¥åãã¦ãã ãã",please_enter_email_blah:"ã¡ã¼ã«ã¢ãã¬ã¹ãå
¥åãã¦ãã ãã",country_of_residence:"å±
ä½å½",please_select_a_relationship:"é¢ä¿ã鏿ãã¦ãã ãã",please_select_a_blah:"å½ã鏿ãã¦ãã ãã",no_matching_country:"ä¸è´ããå½ãè¦ã¤ããã¾ããã",optional_details:"ä»»æã®æ
å ±",email:"ã¡ã¼ã«ã¢ãã¬ã¹",invalid_email_address:"ã¡ã¼ã«ã¢ãã¬ã¹ã®å½¢å¼ãæ£ããããã¾ãã",mobile_number:"æºå¸¯é»è©±çªå·",please_enter_without_blah:"ãã¤ãã³(-)ã空ç½ã
1ªãã§å
¥åãã¦ãã ããã",address:"使",confirm:"確èª",share_a_gift_blah:"ã®ãããªã³ã¯ãå
±æããã ãã使ãçªå·ãå¿
è¦ããã¾ããã",other_countries:"ãã®ä»ã®å½"}}},63978:(e,n,a)=>{a.d(n,{A:()=>g});var t=a(37876),r=a(14232),i=a(18827),s=a(61223),l=a(23339),o=a(91143),_=a(19363),d=a(29319),c=a(24078),h=a(6208),p=a(26104),m=a(55197),u=a(67327),f=a(98815),b=a(29683);let g=(0,r.memo)(function(e){var n,a;let{onSelect:i,value:g,onlyDestinationCountries:x=!1}=e,{locale:v}=(0,p.r)(),{destinationList:A}=(0,h.t)({availableOnly:!0}),w=(0,r.useMemo)(()=>(0,u.X6)({locale:v}),[v]),j=(0,r.useMemo)(()=>{if(!A||0===A.length)return x?[]:w;let e=new Set(A.map(e=>e.code)),n=[],a=[];return(w.forEach(t=>{var r;e.has(null==(r=t.value)?void 0:r.code)?n.push(t):a.push(t)}),x)?n:[...n,...a]},[w,A,x]),[C,I]=(0,r.useState)(void 0),[N,k]=(0,r.useState)(!1),[S,L]=(0,r.useState)(""),{t:P}=(0,m.Z)(s.A),E=(0,r.useMemo)(()=>{if(!S)return j;let e=S.replace(/\s/g,"").toLowerCase(),n=f.A.disassemble(e).join("");return j.filter(e=>{var a,t,r,i,s;let l="".concat(null==(a=e.value)?void 0:a.name.en).concat(null==(t=e.value)?void 0:t.name.ko).concat(null==(r=e.value)?void 0:r.callingCode).concat(null==(i=e.value)?void 0:i.code).concat(null==(s=e.value)?void 0:s.abbreviatedNameKo).replace(/\s/g,"").toLowerCase(),o=f.A.disassemble(l).join("");return b.A.includes(o,n)})},[j,S]);(0,r.useEffect)(()=>{if(!g)return void I(void 0);I(e=>{var n;return(null==e||null==(n=e.value)?void 0:n.code)===g.code?e:j.find(e=>{var n;return(null==(n=e.value)?void 0:n.code)===g.code})})},[j,g]);let O=(0,r.useCallback)(e=>{L(e)},[]),z=(0,r.useCallback)(()=>{k(!0),L("")},[]),F=(0,r.useCallback)(()=>{k(!1),L("")},[]),B=(0,r.useCallback)(e=>{I(e),null==i||i(e.value),F()},[F,i]);return(0,t.jsxs)(y.CountrySelector,{children:[(0,t.jsxs)(o.A,{onClick:z,flexDirection:"row",style:{alignItems:"center",justifyContent:"space-between",width:"100%",padding:"9px 12px 9px 14px",border:"1px solid #ebebeb",borderRadius:2},children:[C?(0,t.jsxs)(y.SelectedCountry,{style:{alignItems:"center",gap:4},children:[(0,t.jsx)(c.A,{emoji:null==(n=C.value)?void 0:n.flag,width:20,height:20}),(0,t.jsx)(_.A,{size:13,children:null==(a=C.value)?void 0:a.name[v]})]}):(0,t.jsx)(_.A,{size:14,color:"#7b7b7b",children:P("please_select_a_blah")}),(0,t.jsx)(y.SelectCountryBtn,{children:(0,t.jsx)(_.A,{size:12,semiBold:!0,color:"#7b7b7b",children:P("choose_country")})})]}),(0,t.jsx)(l.A,{visible:N,onDismiss:F,height:"80%",scrollable:!0,children:(0,t.jsxs)(y.BottomSheetContent,{children:[(0,t.jsxs)(y.BottomSheetHeader,{children:[(0,t.jsx)(_.A,{size:18,semiBold:!0,children:P("choose_country")}),!x&&(0,t.jsx)(y.SearchInput,{type:"text",placeholder:P("search_country"),value:S,onChange:e=>O(e.target.value),autoFocus:!0})]}),(0,t.jsx)(y.OptionList,{role:"listbox",children:E.length>0?E.map(e=>{var n,a,r,i,s,l;return(0,t.jsx)(y.OptionItem,{role:"option",children:(0,t.jsx)(y.OptionButton,{tabIndex:0,onClick:()=>B(e),children:(0,t.jsxs)(d.A,{style:{flexDirection:"row",alignItems:"center",flex:1,gap:8},children:[(0,t.jsx)(c.A,{emoji:null==(n=e.value)?void 0:n.flag,width:24,height:24}),(0,t.jsx)(_.A,{size:15,children:null==(a=e.value)?void 0:a.name[v]})]})})},null!=(l=null!=(s=null==(r=e.value)?void 0:r.id)?s:null==(i=e.value)?void 0:i.code)?l:e.text)}):(0,t.jsx)(y.NoResult,{children:(0,t.jsx)(_.A,{size:14,color:"#7b7b7b",children:P("no_matching_country")})})})]})})]})}),y={CountrySelector:(0,i.Ay)(d.A).withConfig({componentId:"sc-875d402e-0"})(["display:flex;flex-direction:column;gap:12px;"]),SelectedCountry:(0,i.Ay)(d.A).withConfig({componentId:"sc-875d402e-1"})(["display:flex;flex-direction:row;align-items:center;gap:6px;flex:1;min-width:0;"]),SelectCountryBtn:(0,i.Ay)(d.A).withConfig({componentId:"sc-875d402e-2"})(["padding:4px 8px;border:1px solid #ebebeb;border-radius:20px;&:hover{background:#ebebeb;}"]),BottomSheetContent:(0,i.Ay)(d.A).withConfig({componentId:"sc-875d402e-3"})(["display:flex;flex-direction:column;height:100%;"]),BottomSheetHeader:(0,i.Ay)(d.A).withConfig({componentId:"sc-875d402e-4"})(["align-items:flex-start;padding:14px 16px 8px;gap:12px;"]),SearchInput:i.Ay.input.withConfig({componentId:"sc-875d402e-5"})(["width:100%;padding:12px 14px;border:1px solid #ebebeb;border-radius:8px;font-size:15px;outline:none;&:focus{border-color:#7b7b7b;}&::placeholder{color:#b0b0b0;}"]),OptionList:(0,i.Ay)(d.A).withConfig({componentId:"sc-875d402e-6"})(["display:flex;flex-direction:column;flex:1;overflow-y:auto;"]),OptionItem:(0,i.Ay)(d.A).withConfig({componentId:"sc-875d402e-7"})([""]),OptionButton:(0,i.Ay)(o.A).withConfig({componentId:"sc-875d402e-8"})(["width:100%;padding:12px 16px;display:flex;flex-direction:row;align-items:center;justify-content:space-between;&:focus,&:hover{background-color:#f6f6f6;}"]),NoResult:(0,i.Ay)(d.A).withConfig({componentId:"sc-875d402e-9"})(["display:flex;align-items:center;justify-content:center;padding:40px 16px;"])}},73705:(e,n,a)=>{a.d(n,{Ay:()=>m});var t=a(37876),r=a(88992),i=a(18827),s=a(98447),l=a(19363),o=a(29319),_=a(54500),d=a(55197),c=a(87987),h=a(40426),p=a(29683);let m=function(e){let{destinationCode:n,tabIndex:a,...i}=e,{t:l}=(0,d.Z)(f),{recipientNameValidator:m,isFamilyNameFirst:b}=(0,_.Ay)({deliveryMethod:c.ye.Manual,destinationCode:n}),{register:g,getValues:y,formState:{errors:x}}=(0,r.xW)(),v=e=>({[_.Bl]:n=>!!(null==n?void 0:n.trim())||l(e),...p.A.getValidatorObj(m),partLength:e=>(null!=e?e:"").length<=50||l("please_enter_within_blah"),fullNameLength:()=>(0,h.yM)(n,{firstName:y(_.QO),lastName:y(_.yh)}).length<=100||l("name_is_too_blah")}),A=(0,t.jsx)(s.A,{placeholder:l("first_name"),"aria-label":l("first_name"),autoComplete:"shipping given-name",error:x[_.QO],tabIndex:a,...g(_.QO,{validate:v("enter_first_name")}
1)},_.QO),w=(0,t.jsx)(s.A,{placeholder:l("last_name"),"aria-label":l("last_name"),autoComplete:"shipping family-name",error:x[_.yh],tabIndex:a,...g(_.yh,{validate:v("enter_last_name")})},_.yh);return(0,t.jsxs)(o.A,{...i,children:[(0,t.jsxs)(u.Row,{children:[b?w:A,b?A:w]}),(0,t.jsx)(u.Guide,{size:12,color:"#9d9d9d",children:l("enter_the_recipients_blah",{nameOrder:l(b?"last_name_first_blah":"first_name_last_blah")})})]})},u={Row:(0,i.Ay)(o.A).withConfig({componentId:"sc-2c8f7b0a-0"})(["flex-direction:row;align-items:flex-start;gap:8px;"]),Guide:(0,i.Ay)(l.A).withConfig({componentId:"sc-2c8f7b0a-1"})(["margin-top:6px;margin-left:6px;"])},f={ns:"domain/recipient-full-name-control-view",en:{first_name:"First name",last_name:"Last name",enter_first_name:"Enter first name",enter_last_name:"Enter last name",enter_the_recipients_blah:"Enter the recipient's real full name ({{nameOrder}}). Nicknames, relationship terms, numbers, and special characters are not allowed.",first_name_last_blah:"First Name / Last Name",last_name_first_blah:"Last Name / First Name",please_enter_within_blah:"Please enter within 50 characters.",name_is_too_blah:"Name is too long. Please enter within 100 characters."},ko:{first_name:"ì´ë¦ (First name)",last_name:"ì± (Last name)",enter_first_name:"ì´ë¦ì ì
ë ¥í´ ì£¼ì¸ì",enter_last_name:"ì±ì ì
ë ¥í´ ì£¼ì¸ì",enter_the_recipients_blah:"ë°ì¼ìë ë¶ì ì¤ì ì±í¨({{nameOrder}})ì ì íí ì
ë ¥í´ ì£¼ì¸ì. ëë¤ì, ê´ê³ëª
, ì«ì ëë í¹ì문ìë ì¬ì©í ì ììµëë¤.",first_name_last_blah:"First Name / Last Name",last_name_first_blah:"Last Name / First Name",please_enter_within_blah:"50ì ì´ë´ë¡ ì
ë ¥í´ ì£¼ì¸ì.",name_is_too_blah:"ì´ë¦ì´ ë무 ê¹ëë¤. 100ì ì´ë´ë¡ ì
ë ¥í´ ì£¼ì¸ì."},ja:{first_name:"å (First name)",last_name:"å§ (Last name)",enter_first_name:"åãå
¥åãã¦ãã ãã",enter_last_name:"å§ãå
¥åãã¦ãã ãã",enter_the_recipients_blah:"åå人ã®å®éã®æ°åï¼{{nameOrder}}ï¼ãæ£ç¢ºã«å
¥åãã¦ãã ãããããã¯ãã¼ã ãé¢ä¿åãæ°åãç¹æ®æåã¯ä½¿ç¨ã§ãã¾ããã",first_name_last_blah:"First Name / Last Name",last_name_first_blah:"Last Name / First Name",please_enter_within_blah:"50æå以å
ã§å
¥åãã¦ãã ããã",name_is_too_blah:"æ°åãé·ããã¾ãã100æå以å
ã§å
¥åãã¦ãã ããã"}}},92538:(e,n,a)=>{a.d(n,{A:()=>C});var t=a(37876),r=a(5811),i=a(14232),s=a(88992),l=a(18827),o=a(29668),_=a(20555),d=a(98447),c=a(38613),h=a(19363),p=a(29319),m=a(95352),u=a(13268),f=a(73705),b=a(63978),g=a(54500),y=a(26104),x=a(55197),v=a(87987),A=a(67327),w=a(29683);let j=(0,i.forwardRef)((e,n)=>{var a,r;let{canSelectCountry:l=!0,defaultValues:p,onChange:j,isInitiallyRepresentative:C=!1}=e,{t:N}=(0,x.Z)(o.R),{locale:k}=(0,y.r)(),[S,L]=(0,i.useState)((null==p||null==(r=p.country)||null==(a=r.value)?void 0:a.code)||v.yt.US),{recipientNameValidator:P,recipientNamePlaceholder:E,isSplitNameRequired:O}=(0,g.Ay)({deliveryMethod:v.ye.Manual,destinationCode:S}),z=(0,s.mN)({mode:"onChange",defaultValues:{recipientName:"",recipientFirstName:"",recipientLastName:"",recipientPhone:"",addressAlias:"",representative:!1,country:void 0,...p}}),{register:F,watch:B,setValue:D,trigger:R,getValues:K,reset:M,control:V,formState:{errors:W}}=z,Z=B("representative"),Q=B(),T=(0,i.useRef)(!1);return(0,i.useEffect)(()=>{T.current&&(T.current=!1,(K(g.QO)||K(g.yh))&&R([g.QO,g.yh]))},[S,K,R]),(0,i.useEffect)(()=>{if(p){var e,n;M({recipientName:"",recipientFirstName:"",recipientLastName:"",recipientPhone:"",addressAlias:"",representative:!1,country:void 0,...p},{keepErrors:!1,keepDirty:!1,keepTouched:!1}),(null==(n=p.country)||null==(e=n.value)?void 0:e.code)&&L(p.country.value.code)}},[p,M]),(0,i.useImperativeHandle)(n,()=>({validate:async()=>await R(),getValues:()=>K(),setValue:(e,n)=>D(e,n)})),(0,i.useEffect)(()=>{j&&j(Q)},[Q,p,j]),(0,t.jsx)(s.Op,{...z,children:(0,t.jsxs)(I.FormItemContainer,{children:[l&&(0,t.jsxs)(I.InputWrapper,{children:[(0,t.jsx)(I.InputLabel,{size:13,children:N("choose_country")}),(0,t.jsx)(s.xI,{control:V,name:"country",rules:{required:!0},render:e=>{let{field:{value:n,onChange:a},fieldState:{error:r}}=e;return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(b.A,{onlyDestinationCountries:!0,value:null==n?void 0:n.value,onSelect:e=>{let n=(0,A.X6)({locale:k}).find(n=>n.value.code===e.code);n&&(a({value:n.value,text:n.text}),D("recipientPhone",""),D("address",{line1:"",postalCode:"",buildingName:"",locality:"",administrativeArea:"",line2:""}),T.current=!0,L(e.code))}}),r&&(0,t.jsx)(I.ErrorText,{size:12,color:"#ff3c78",children:N("please_select_a_blah")})]})}})]}),(0,t.jsxs)(I.InputWrapper,{children:[(0,t.jsx)(I.InputLabel,{size:13,children:N("name")}
1),O?(0,t.jsx)(f.Ay,{destinationCode:S}):(0,t.jsx)(d.A,{placeholder:E,error:W.recipientName,...F("recipientName",{required:{value:!0,message:N("please_enter_name_blah")},validate:{...w.A.getValidatorObj(P)}})})]}),(0,t.jsxs)(I.InputWrapper,{children:[(0,t.jsx)(I.InputLabel,{size:13,children:N("phone_number")}),(0,t.jsx)(c.A,{name:"recipientPhone",mask:(0,m.sC)(S),minLength:(0,m.yJ)(S),maxLength:(0,m.MD)(S),placeholder:N("enter_without_hyphens_blah"),countryCode:S,showCallingCode:!0,rules:{required:{value:!0,message:N("please_enter_phone_blah")}}})]}),(0,t.jsxs)(I.InputWrapper,{children:[(0,t.jsx)(I.InputLabel,{size:13,children:N("address_alias")}),(0,t.jsx)(d.A,{placeholder:N("enter_address_alias_blah"),error:W.addressAlias,...F("addressAlias",{required:{value:!0,message:N("please_enter_alias_blah")}})})]}),(0,t.jsxs)(I.InputWrapper,{children:[(0,t.jsx)(I.InputLabel,{size:13,children:N("shipping_address")}),(0,t.jsx)(u.A,{destinationCode:S,required:!0,showLabel:!1,defaultValues:null==p?void 0:p.address}),(0,t.jsxs)(I.CheckboxWrapper,{onClick:()=>{C||D("representative",!Z)},$disabled:C,children:[(0,t.jsx)(_.A,{checked:Z,onChange:e=>{e.stopPropagation(),C||D("representative",e.target.checked)},size:16,backgroundColor:"#ffffff",borderColor:"#D1D1D1",checkedBackgroundColor:"#ff4f85",checkedBorderColor:"#ff4f85",checkmarkColor:"#ffffff",disabled:C,style:{cursor:C?"not-allowed":"pointer",margin:0}}),(0,t.jsx)(h.A,{size:13,style:{marginLeft:-2},color:C?"#b0b0b0":void 0,children:N("set_as_default_blah")})]})]})]})})}),C=(0,r.PA)(j),I={FormItemContainer:(0,l.Ay)(p.A).withConfig({componentId:"sc-6363b4ae-0"})(["display:flex;flex-direction:column;gap:22px;"]),InputWrapper:(0,l.Ay)(p.A).withConfig({componentId:"sc-6363b4ae-1"})([""]),InputLabel:(0,l.Ay)(h.A).withConfig({componentId:"sc-6363b4ae-2"})(["margin-bottom:6px;color:#3c3c3c;"]),CheckboxWrapper:(0,l.Ay)(p.A).withConfig({componentId:"sc-6363b4ae-3"})(["width:fit-content;margin-top:16px;flex-direction:row;align-items:center;cursor:",";opacity:",";"],e=>{let{$disabled:n}=e;return n?"not-allowed":"pointer"},e=>{let{$disabled:n}=e;return n?.4:1}),ErrorText:(0,l.Ay)(h.A).withConfig({componentId:"sc-6363b4ae-4"})(["margin-top:4px;margin-left:6px;"])}}}]);
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.