!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="1841dc58-cae5-404a-9708-1c9c4c7cd269",e._sentryDebugIdIdentifier="sentry-dbid-1841dc58-cae5-404a-9708-1c9c4c7cd269")}catch(e){}}(),(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[185],{2357:function(e,t,n){Promise.resolve().then(n.t.bind(n,52445,23)),Promise.resolve().then(n.bind(n,28716)),Promise.resolve().then(n.t.bind(n,14282,23)),Promise.resolve().then(n.t.bind(n,91574,23)),Promise.resolve().then(n.t.bind(n,49090,23))},28716:function(e,t,n){"use strict";n.r(t),n.d(t,{WebVitals:function(){return r}});var o=n(64090),a=n(47379);function r(){let e=(0,o.useCallback)(e=>{let t=e.attribution?e.attribution.largestShiftTarget||e.attribution.element||e.attribution.eventTarget||"":"(not set)";window.gtag("event",e.name,{value:Math.round("CLS"===e.name?1e3*e.value:e.value),event_label:e.id,metric_rating:e.rating,metric_delta:e.delta,non_interaction:!0,debug_target:t,debug_event_type:e.attribution&&e.attribution.eventType||"",debug_timing:e.attribution&&e.attribution.loadState||"",event_time:e.attribution&&(e.attribution.largestShiftTime||e.attribution.lcpEntry&&e.attribution.lcpEntry.startTime||e.attribution.eventTime)||""})},[]),t=(0,o.useCallback)(t=>{"function"==typeof window.gtag?e(t):setTimeout(()=>{"function"==typeof window.gtag?e(t):a.r.message("Not Found GTAG")},500)},[]);return(0,o.useEffect)(()=>{let e=document.createElement("script");return e.src="https://cdn.ornament.health/js/web-vitals.js",e.onload=function(){window.webVitals?(window.webVitals.onCLS(t),window.webVitals.onFID(t),window.webVitals.onLCP(t),window.webVitals.onFCP(t),window.webVitals.onTTFB(t),window.webVitals.onINP(t)):a.r.message("Not Found Web-Vitals")},document.head.appendChild(e),()=>{document.head.removeChild(e)}},[]),null}},47379:function(e,t,n){"use strict";n.d(t,{r:function(){return R}});var o=n(84648),a=n(61581),r=n(88318),i=n(43706),s=n(34273),l=n(90844),u=n(41231);let d=()=>(0,u.Z)();var c=n(7908),p=n(8698),f=n(64233),g=n(81177),v=n(22125),m=n(45894),h=n(49146),_=n(72438),b=n(18021);let T=c.Z.create({baseURL:"https://test-api.ornament.health/"}),w=(0,p.Z)((0,f.Z)(g.Z,(0,v.Z)({}),(0,p.Z)((0,m.Z)((e,t)=>{let[n,o]=t,a="orn.http.param.".concat(decodeURIComponent(n));return{...e,[a]:decodeURIComponent(o)}},{}),(0,h.Z)((0,p.Z)((0,h.Z)(decodeURIComponent),(0,_.Z)("="))),(0,_.Z)("&"))),(0,b.Z)(/^.*?\?/,""));T.interceptors.request.use(async e=>(0,a.$e)(t=>{var n,o,a,i,s,l,u;if(t.setTag("orn.http.method",null===(n=e.method)||void 0===n?void 0:n.toUpperCase()),t.setTag("orn.http.url",null===(o=e.url)||void 0===o?void 0:o.replace(/\?.*$/,"")),t.setTag("orn.http.baseURL",e.baseURL),t.setTag("orn.span.parent",(null===(a=e.extra)||void 0===a?void 0:a.parent)||"none"),t.setTag("orn.span.feature",(null===(i=e.extra)||void 0===i?void 0:i.feature)||"none"),t.setTag("orn.span.network",navigator.onLine),null===(s=e.extra)||void 0===s?void 0:s.rootSpan){let t=(0,r.qp)({name:"FETCH_START",forceTransaction:!0,op:"http.client",parentSpan:null===(l=e.extra)||void 0===l?void 0:l.rootSpan,onlyIfParent:!0}),n=w((null===(u=e.url)||void 0===u?void 0:u.replace(/^.*?\?/,""))||"");t.setAttributes(n),t.setStatus({code:1,message:"ok"}),t.end()}else R.message("No Root Span For Request");return e}),e=>Promise.reject(e)),T.interceptors.response.use(e=>(0,a.$e)(t=>{var n,o,a,i,s;if(t.setTag("orn.http.method",null===(n=e.config.method)||void 0===n?void 0:n.toUpperCase()),t.setTag("orn.http.url",null===(o=e.config.url)||void 0===o?void 0:o.replace(/\?.*$/,"")),t.setTag("orn.http.status_code",e.status),t.setTag("orn.http.baseURL",e.config.baseURL),t.setTag("orn.span.parent",(null===(a=e.config.extra)||void 0===a?void 0:a.parent)||"none"),t.setTag("orn.span.feature",(null===(i=e.config.extra)||void 0===i?void 0:i.feature)||"none"),t.setTag("orn.span.network",navigator.onLine),e.config.extra.rootSpan){let t=(0,r.qp)({name:"FETCH_END",forceTransaction:!0,op:"http.client",parentSpan:e.config.extra.rootSpan,onlyIfParent:!0}),n=w((null===(s=e.config.url)||void 0===s?void 0:s.replace(/^.*?\?/,""))||"");t.setAttributes(n),t.setStatus({code:1,message:"ok"}),t.end()}else R.message("No Root Span For Response");return e}),e=>(0,a.$e)(t=>{var n,o,a,i,s,l,u,d,c,p,f,g,v,m,h,_,b,T;if(t.setTag("orn.http.method",null===(n=e.config.method)||void 0===n?void 0:n.toUpperCase()),t.setTag("orn.http.url",null===(o=e.config.url)||void 0===o?void 0:o.replace(/\?.*$/,"")),t.setTag("orn.http.status_code",e.request.status),t.setTag("orn.http.baseURL",e.config.baseURL),t.setTag("orn.span.parent",(null===(a=e.config.extra)||void 0===a?void 0:a.parent)||"none"),t.setTag("orn.span.feature",(null===(i=e.config.extra)||void 0===i?void 0:i.feature)||"none"),t.setTag("orn.span.network",navigator.onLine),e.config.extra.rootSpan){let t=e.response?"FETCH_END":"FETCH_END_ERROR",n=(0,r.qp)({name:t,forceTransaction:!0,op:"http.client",parentSpan:e.config.extra.rootSpan,onlyIfParent:!0}),o=w((null===(T=e.config.url)||void 0===T?void 0:T.replace(/^.*?\?/,""))||"");n.setAttributes(o),n.setStatus({code:1,message:"ok"}),n.end()}else R.message("No Root Span For Response");let S={url:(null===(s=e.config)||void 0===s?void 0:s.url)||"",method:(null===(l=e.config)||void 0===l?void 0:l.method)||"",status:(null===(u=e.response)||void 0===u?void 0:u.status)||"Unknown status",data:(null===(d=e.response)||void 0===d?void 0:d.data)||"No response data",headers:(null===(c=e.config)||void 0===c?void 0:c.headers)||{},responseHeaders:(null===(p=e.response)||void 0===p?void 0:p.headers)||{},params:(null===(f=e.config)||void 0===f?void 0:f.params)||{},time:new Date,timeout:(null===(g=e.config)||void 0===g?void 0:g.timeout)||"No timeout",environment:"production",traceId:null===(v=e.response)||void 0===v?void 0:v.headers["sentry-trace"]},y=(null===(m=e.response)||void 0===m?void 0:m.status)||"unknown",k=(null===(h=e.config)||void 0===h?void 0:h.url)||"unknown endpoint",x="".concat(y,": ").concat(k);return R.message(x,{extra:S,level:"error",tags:{httpStatus:(null===(_=e.response)||void 0===_?void 0:_.status)||"unknown",endpoint:(null===(b=e.config)||void 0===b?void 0:b.url)||"unknown",network:"error"},contexts:{axios:S}}),Promise.reject(e)}));let S={0:"deadline_exceeded",401:"unauthenticated",403:"permission_denied",404:"not_found",409:"already_exists",429:"resource_exhausted",501:"unimplemented",503:"unavailable"};class y{setUser(e){(0,o.av)({ssoId:e,id:e})}event(e,t){(0,o.eN)(e,t)}message(e,t){(0,o.uT)(e,t)}tag(e,t){(0,o.YA)(e,t)}scope(e){(0,a.$e)(e)}exception(e,t){(0,o.Tb)(e,t)}startSpan(e,t){return(0,r.GK)(e,t)}getTransactionStatusByCode(e){let t=S[e];return t||(t=e>503?"internal_error":"unknown_error"),{code:2,message:t}}async fetchWithTransaction(e,t,n){return new Promise(o=>{this.scope(async a=>(a.setTag("orn.span.type","backend"),this.startSpan({name:e,op:"http.client",forceTransaction:!0},async e=>{try{let a=(0,l.zf)("token"),r=(0,l.zf)("country"),i=(0,l.zf)("oiid"),u=localStorage.getItem("locale")||"en-US",c=s.i$[u],p=d(),f=await T(t.url,{method:t.method,headers:{Authorization:"Bearer ".concat(a),"accept-language":n||c,"X-Transaction-ID":p,uuid:p,"X-Country":r,oiid:i},extra:{...t.extra,rootSpan:e},data:t.body,timeout:t.timeout});null==e||e.setStatus({code:1,message:"ok"}),e.end(),o(f)}catch(n){let t=(0,i.Z)(0,["request","status"],n);throw e.setStatus(this.getTransactionStatusByCode(t)),e.end(),n}})))})}}let R=new y},34273:function(e,t,n){"use strict";n.d(t,{i$:function(){return c},ev:function(){return p},k1:function(){return d}});var o,a,r,i,s,l,u=n(22433);(o=i||(i={})).EN="en",o.RU="ru",o.DE="de",o.PT="pt",o.ES="es",(a=s||(s={})).EN="en-US",a.RU="ru-RU",a.DE="de-DE",a.PT="pt-BR",a.ES="es-ES";let d={en:"en-US",ru:"ru-RU",de:"de-DE",pt:"pt-BR",es:"es-ES"},c={"en-US":"en","ru-RU":"ru","de-DE":"de","pt-BR":"pt","es-ES":"es"};(r=l||(l={})).CP="Mp-1y-io1y-20.M-lt.cp",r.STR="str_m_1wsi_1msi_1ysi";let p=e=>{let t=new URLSearchParams(window.location.search).get("codeName"),n=(0,u.Z)(e)===i.RU?"Mp-1y-io1y-20.M-lt.cp":"str_m_1wsi_1msi_1ysi";return t||t||n}},90844:function(e,t,n){"use strict";n.d(t,{JG:function(){return a},m5:function(){return r},zf:function(){return o}});let o=e=>{if("undefined"==typeof document)return"";let t=e+"=",n=decodeURIComponent(document.cookie).split(";");for(let e=0;e<n.length;e++){let o=n[e];for(;" "==o.charAt(0);)o=o.substring(1);if(0==o.indexOf(t))return o.substring(t.length,o.length)}return""},a=function(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:365,o=new Date;o.setTime(o.getTime()+864e5*n);let a="expires="+o.toUTCString();document.cookie=e+"="+t+";"+a+";path=/"},r=()=>{let e=document.cookie.split("; ");for(let t=0;t<e.length;t++){let n=e[t],o=n.indexOf("="),a=o>-1?n.substr(0,o):n;document.cookie="".concat(a,"=;expires=Thu, 01 Jan 1970 00:00:00 GMT;path=/;");let r=location.pathname.split("/"),i=" path=";for(let e=0;e<r.length;e++)i+=("/"!==i.substr(-1)?"/":"")+r[e],document.cookie="".concat(a,"=;expires=Thu, 01 Jan 1970 00:00:00 GMT;").concat(i,";"),document.cookie="".concat(a,"=;expires=Thu, 01 Jan 1970 00:00:00 GMT;").concat(i,";domain=").concat(window.location.hostname,";")}}},52445:function(){},14282:function(e){e.exports={style:{fontFamily:"'__fontSuiBold_fbef89', '__fontSuiBold_Fallback_fbef89'"},className:"__className_fbef89",variable:"__variable_fbef89"}},49090:function(e){e.exports={style:{fontFamily:"'__fontSuiRegular_5dc67f', '__fontSuiRegular_Fallback_5dc67f'"},className:"__className_5dc67f",variable:"__variable_5dc67f"}},91574:function(e){e.exports={style:{fontFamily:"'__fontSuiSemiBold_885d78', '__fontSuiSemiBold_Fallback_885d78'"},className:"__className_885d78",variable:"__variable_885d78"}}},function(e){e.O(0,[22,971,264,744],function(){return e(e.s=2357)}),_N_E=e.O()}]);