/*! For license information please see main.d753818b.js.LICENSE.txt */ (()=>{var e={268:(e,t,n)=>{"use strict";n.d(t,{S:()=>r});const r=(0,n(9060).createContext)({tab:1,setTab:e=>{},profile:void 0,setProfile:e=>{},picture:void 0,setPicture:e=>{},notifications:void 0,setNotifications:e=>{},messages:void 0,setMessages:e=>{},expanded:!1})},1976:(e,t,n)=>{"use strict";n.d(t,{g:()=>l});var r=n(3280),o=n(1012),i=n(1908),a=n(8100),s=n(4340);e=n.hmd(e);const l=(()=>{let t,n={url:s._U.production.accounts},l={url:s._U.production.api},c="blueforest:dropin";const u=function(e,n,r){let o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},i=arguments.length>4?arguments[4]:void 0,a={method:n,headers:{"content-type":"application/json"}};"undefined"!==typeof e.host&&(a.headers.Host=e.host),"undefined"!==typeof t&&(a.headers.Authorization="Bearer "+t),"undefined"!==typeof i&&(a.body=JSON.stringify(i));let s="";const l=Object.keys(o);return 0!==l.length&&(s="?".concat(l.filter((e=>"undefined"!==typeof o[e])).map((e=>e+"="+o[e])).join("&"))),new Promise(((t,n)=>{const o="".concat(e.url,"/").concat(r).concat(s);return fetch(encodeURI(o),a).then((e=>e.text().then((e=>{try{return JSON.parse(e)}catch(t){return e}})))).then((e=>{"object"===typeof e&&"undefined"!==typeof e.error?n(e.error):t(e)}),n)}))},d={config:{setAccountAPI:(e,t)=>{n={url:e,host:t}},setRecipesAPI:(e,t)=>{l={url:e,host:t}},setRealm:e=>{c=e},setToken:e=>{t=e,r.cp.getItem("locale").then((e=>{e&&r.cp.removeItem("locale")}))},getToken:()=>t},account:{resolve:t=>"undefined"!==typeof e.hot||"tanum"===i.Y.name||"web"===o.default.OS?Promise.resolve():u({url:s._U.cmacgm.api},"POST","pipelines/execute?project=maoboa:app&id=maoboa:app:v3:users/resolve",{},t).then(i.u).catch((()=>{})),retrieve:()=>u(n,"POST",""),login:(e,t,r)=>d.account.resolve({email:e}).then((()=>u(n,"POST","login",void 0,{locale:a.O.get(),realm:c,email:e,password:t,captcha:r})))},recipes:{pipelines:{get:e=>{const n="pipelines/";return{execute:t=>u(l,"POST",n+"execute",e,t),url:()=>l.url+"/"+n+"execute?project="+e.project+"&id="+e.id+"&token="+t+"&locale="+a.O.get()}}},metrics:{get:e=>({add:function(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return t.platform=o.default.OS,u(l,"POST","metrics/add",e,t)}})}},request:u};return d})()},6720:(e,t,n)=>{"use strict";n.d(t,{O:()=>a,S:()=>i});var r=n(1012),o=n(7172);let i=function(e){return e.OFFLINE="/",e.LOGIN="/login",e.REGISTER="/register",e.RESET="/reset",e.WELCOME="/welcome",e.PROJECTS="/projects",e.COUNTDOWN="/countdown",e.VALIDATION="/validation",e.NOTIFICATIONS="/notifications",e.SETTINGS="/settings",e.INFO="/info",e.ACTIONS="/actions",e.IMPACT="/impact",e.CHAT="/chat",e.CHAT_MEMBERS="/chat/members",e.HIGHLIGHTS="/highlights",e.FORM="/form",e.PROGRAM="/program",e.PROGRAM_COMMITMENTS="/program/commitments",e}({});const a={web:"web"===r.default.OS,init(e,t,n){this.web&&(window.history.replaceState({page:this.page(e,n)},"",e),window.onpopstate=e=>{e.state&&e.state.page&&t(e.state.page)})},add(e,t){this.web&&window.history.pushState({page:this.page(e,t)},"",e)},goBack(){this.web&&window.history.back()},getCurrentPage(){var e,t,n;if(this.web)return null===(e=window)||void 0===e||null===(t=e.history)||void 0===t||null===(n=t.state)||void 0===n?void 0:n.page},page(e,t){switch(e){case i.OFFLINE:return t?void 0:o.g.OFFLINE;case i.LOGIN:return t?void 0:o.g.LOGIN;case i.REGISTER:return t?void 0:o.g.REGISTER;case i.RESET:return t?void 0:o.g.PASSWORD_RESET;case i.WELCOME:return t?void 0:o.g.WELCOME;case i.PROJECTS:return t?void 0:o.g.PROJECTS;case i.COUNTDOWN:return t?void 0:o.g.COUNTDOWN;case i.VALIDATION:return t?void 0:o.g.VALIDATION;case i.NOTIFICATIONS:return t?o.g.NOTIFICATIONS:void 0;case i.SETTINGS:return t?o.g.SETTINGS:void 0;case i.INFO:case i.ACTIONS:case i.IMPACT:return t?o.g.ADMIN:void 0;case i.CHAT:return t?o.g.CHAT:void 0;case i.CHAT_MEMBERS:return t?o.g.CHAT_MEMBERS:void 0;case i.HIGHLIGHTS:return t?o.g.HIGHLIGHTS:void 0;case i.FORM:return t?o.g.FORM:void 0;case i.PROGRAM:return t?o.g.ADMIN:void 0;case i.PROGRAM_COMMITMENTS:return t?o.g.PROGRAM_COMMITMENTS:void 0;default:return}}}},16:(e,t,n)=>{"use strict";n.d(t,{C:()=>Di});const r="undefined"===typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__;function o(e){return e&&e.Math==Math?e:void 0}const i="object"==typeof globalThis&&o(globalThis)||"object"==typeof window&&o(window)||"object"==typeof self&&o(self)||"object"==typeof n.g&&o(n.g)||function(){return this}()||{};function a(){return i}function s(e,t,n){const r=n||i,o=r.__SENTRY__=r.__SENTRY__||{};return o[e]||(o[e]=t())}const l=["debug","info","warn","error","log","assert","trace"],c={};function u(e){if(!("console"in i))return e();const t=i.console,n={},r=Object.keys(c);r.forEach((e=>{const r=c[e];n[e]=t[e],t[e]=r}));try{return e()}finally{r.forEach((e=>{t[e]=n[e]}))}}const d=function(){let e=!1;const t={enable:()=>{e=!0},disable:()=>{e=!1},isEnabled:()=>e};return r?l.forEach((n=>{t[n]=function(){for(var t=arguments.length,r=new Array(t),o=0;o{i.console[n]("".concat("Sentry Logger ","[").concat(n,"]:"),...r)}))}})):l.forEach((e=>{t[e]=()=>{}})),t}(),h=Object.prototype.toString;function p(e){switch(h.call(e)){case"[object Error]":case"[object Exception]":case"[object DOMException]":return!0;default:return w(e,Error)}}function f(e,t){return h.call(e)==="[object ".concat(t,"]")}function g(e){return f(e,"ErrorEvent")}function m(e){return f(e,"DOMError")}function y(e){return f(e,"String")}function v(e){return"object"===typeof e&&null!==e&&"__sentry_template_string__"in e&&"__sentry_template_values__"in e}function b(e){return null===e||v(e)||"object"!==typeof e&&"function"!==typeof e}function A(e){return f(e,"Object")}function x(e){return"undefined"!==typeof Event&&w(e,Event)}function S(e){return Boolean(e&&e.then&&"function"===typeof e.then)}function w(e,t){try{return e instanceof t}catch(n){return!1}}function C(e){return!("object"!==typeof e||null===e||!e.__isVue&&!e._isVue)}const _=a(),E=80;function R(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(!e)return"";try{let n=e;const r=5,o=[];let i=0,a=0;const s=" > ",l=s.length;let c;const u=Array.isArray(t)?t:t.keyAttrs,d=!Array.isArray(t)&&t.maxStringLength||E;for(;n&&i++1&&a+o.length*l+c.length>=d));)o.push(c),a+=c.length,n=n.parentNode;return o.reverse().join(s)}catch(n){return""}}function k(e,t){const n=e,r=[];let o,i,a,s,l;if(!n||!n.tagName)return"";if(_.HTMLElement&&n instanceof HTMLElement&&n.dataset&&n.dataset.sentryComponent)return n.dataset.sentryComponent;r.push(n.tagName.toLowerCase());const c=t&&t.length?t.filter((e=>n.getAttribute(e))).map((e=>[e,n.getAttribute(e)])):null;if(c&&c.length)c.forEach((e=>{r.push("[".concat(e[0],'="').concat(e[1],'"]'))}));else if(n.id&&r.push("#".concat(n.id)),o=n.className,o&&y(o))for(i=o.split(/\s+/),l=0;l1&&void 0!==arguments[1]?arguments[1]:0;return"string"!==typeof e||0===t||e.length<=t?e:"".concat(e.slice(0,t),"...")}function T(e,t){if(!Array.isArray(e))return"";const n=[];for(let o=0;o2&&void 0!==arguments[2]&&arguments[2];return!!y(e)&&(f(t,"RegExp")?t.test(e):!!y(t)&&(n?e===t:e.includes(t)))}function j(e){let t=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return(arguments.length>1&&void 0!==arguments[1]?arguments[1]:[]).some((n=>O(e,n,t)))}function P(e,t,n){if(!(t in e))return;const r=e[t],o=n(r);"function"===typeof o&&L(o,r),e[t]=o}function B(e,t,n){try{Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0})}catch(o){r&&d.log('Failed to add non-enumerable property "'.concat(t,'" to object'),e)}}function L(e,t){try{const n=t.prototype||{};e.prototype=t.prototype=n,B(e,"__sentry_original__",t)}catch(n){}}function D(e){return e.__sentry_original__}function M(e){if(p(e))return{message:e.message,name:e.name,stack:e.stack,...U(e)};if(x(e)){const t={type:e.type,target:N(e.target),currentTarget:N(e.currentTarget),...U(e)};return"undefined"!==typeof CustomEvent&&w(e,CustomEvent)&&(t.detail=e.detail),t}return e}function N(e){try{return t=e,"undefined"!==typeof Element&&w(t,Element)?R(e):Object.prototype.toString.call(e)}catch(n){return""}var t}function U(e){if("object"===typeof e&&null!==e){const t={};for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t}return{}}function F(e){return H(e,new Map)}function H(e,t){if(function(e){if(!A(e))return!1;try{const t=Object.getPrototypeOf(e).constructor.name;return!t||"Object"===t}catch(t){return!0}}(e)){const n=t.get(e);if(void 0!==n)return n;const r={};t.set(e,r);for(const o of Object.keys(e))"undefined"!==typeof e[o]&&(r[o]=H(e[o],t));return r}if(Array.isArray(e)){const n=t.get(e);if(void 0!==n)return n;const r=[];return t.set(e,r),e.forEach((e=>{r.push(H(e,t))})),r}return e}function G(){const e=i,t=e.crypto||e.msCrypto;let n=()=>16*Math.random();try{if(t&&t.randomUUID)return t.randomUUID().replace(/-/g,"");t&&t.getRandomValues&&(n=()=>{const e=new Uint8Array(1);return t.getRandomValues(e),e[0]})}catch(r){}return([1e7]+1e3+4e3+8e3+1e11).replace(/[018]/g,(e=>(e^(15&n())>>e/4).toString(16)))}function z(e){return e.exception&&e.exception.values?e.exception.values[0]:void 0}function V(e){const{message:t,event_id:n}=e;if(t)return t;const r=z(e);return r?r.type&&r.value?"".concat(r.type,": ").concat(r.value):r.type||r.value||n||"":n||""}function W(e,t,n){const r=e.exception=e.exception||{},o=r.values=r.values||[],i=o[0]=o[0]||{};i.value||(i.value=t||""),i.type||(i.type=n||"Error")}function Q(e,t){const n=z(e);if(!n)return;const r=n.mechanism;if(n.mechanism={type:"generic",handled:!0,...r,...t},t&&"data"in t){const e={...r&&r.data,...t.data};n.mechanism.data=e}}function Y(e){if(e&&e.__sentry_captured__)return!0;try{B(e,"__sentry_captured__",!0)}catch(t){}return!1}function K(e){return Array.isArray(e)?e:[e]}const q="undefined"===typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__;var X;function J(e){return new $((t=>{t(e)}))}function Z(e){return new $(((t,n)=>{n(e)}))}!function(e){e[e.PENDING=0]="PENDING";e[e.RESOLVED=1]="RESOLVED";e[e.REJECTED=2]="REJECTED"}(X||(X={}));class ${constructor(e){$.prototype.__init.call(this),$.prototype.__init2.call(this),$.prototype.__init3.call(this),$.prototype.__init4.call(this),this._state=X.PENDING,this._handlers=[];try{e(this._resolve,this._reject)}catch(t){this._reject(t)}}then(e,t){return new $(((n,r)=>{this._handlers.push([!1,t=>{if(e)try{n(e(t))}catch(o){r(o)}else n(t)},e=>{if(t)try{n(t(e))}catch(o){r(o)}else r(e)}]),this._executeHandlers()}))}catch(e){return this.then((e=>e),e)}finally(e){return new $(((t,n)=>{let r,o;return this.then((t=>{o=!1,r=t,e&&e()}),(t=>{o=!0,r=t,e&&e()})).then((()=>{o?n(r):t(r)}))}))}__init(){this._resolve=e=>{this._setResult(X.RESOLVED,e)}}__init2(){this._reject=e=>{this._setResult(X.REJECTED,e)}}__init3(){this._setResult=(e,t)=>{this._state===X.PENDING&&(S(t)?t.then(this._resolve,this._reject):(this._state=e,this._value=t,this._executeHandlers()))}}__init4(){this._executeHandlers=()=>{if(this._state===X.PENDING)return;const e=this._handlers.slice();this._handlers=[],e.forEach((e=>{e[0]||(this._state===X.RESOLVED&&e[1](this._value),this._state===X.REJECTED&&e[2](this._value),e[0]=!0)}))}}}function ee(){return s("globalEventProcessors",(()=>[]))}function te(e){ee().push(e)}function ne(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0;return new $(((o,i)=>{const a=e[r];if(null===t||"function"!==typeof a)o(t);else{const s=a({...t},n);q&&a.id&&null===s&&d.log('Event processor "'.concat(a.id,'" dropped event')),S(s)?s.then((t=>ne(e,t,n,r+1).then(o))).then(null,i):ne(e,s,n,r+1).then(o).then(null,i)}}))}const re=1e3;function oe(){return Date.now()/re}const ie=function(){const{performance:e}=i;if(!e||!e.now)return oe;const t=Date.now()-e.now(),n=void 0==e.timeOrigin?t:e.timeOrigin;return()=>(n+e.now())/re}();let ae;(()=>{const{performance:e}=i;if(!e||!e.now)return void(ae="none");const t=36e5,n=e.now(),r=Date.now(),o=e.timeOrigin?Math.abs(e.timeOrigin+n-r):t,a=ofunction(e){return F({sid:"".concat(e.sid),init:e.init,started:new Date(1e3*e.started).toISOString(),timestamp:new Date(1e3*e.timestamp).toISOString(),status:e.status,errors:e.errors,did:"number"===typeof e.did||"string"===typeof e.did?"".concat(e.did):void 0,duration:e.duration,abnormal_mechanism:e.abnormal_mechanism,attrs:{release:e.release,environment:e.environment,ip_address:e.ipAddress,user_agent:e.userAgent}})}(n)};return e&&ce(n,e),n}function ce(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(t.user&&(!e.ipAddress&&t.user.ip_address&&(e.ipAddress=t.user.ip_address),e.did||t.did||(e.did=t.user.id||t.user.email||t.user.username)),e.timestamp=t.timestamp||ie(),t.abnormal_mechanism&&(e.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(e.ignoreDuration=t.ignoreDuration),t.sid&&(e.sid=32===t.sid.length?t.sid:G()),void 0!==t.init&&(e.init=t.init),!e.did&&t.did&&(e.did="".concat(t.did)),"number"===typeof t.started&&(e.started=t.started),e.ignoreDuration)e.duration=void 0;else if("number"===typeof t.duration)e.duration=t.duration;else{const t=e.timestamp-e.started;e.duration=t>=0?t:0}t.release&&(e.release=t.release),t.environment&&(e.environment=t.environment),!e.ipAddress&&t.ipAddress&&(e.ipAddress=t.ipAddress),!e.userAgent&&t.userAgent&&(e.userAgent=t.userAgent),"number"===typeof t.errors&&(e.errors=t.errors),t.status&&(e.status=t.status)}function ue(e,t){let n={};t?n={status:t}:"ok"===e.status&&(n={status:"exited"}),ce(e,n)}const de=50,he=/\(error: (.*)\)/,pe=/captureMessage|captureException/;function fe(){for(var e=arguments.length,t=new Array(e),n=0;ne[0]-t[0])).map((e=>e[1]));return function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;const n=[],o=e.split("\n");for(let i=t;i1024)continue;const t=he.test(e)?e.replace(he,"$1"):e;if(!t.match(/\S*Error: /)){for(const e of r){const r=e(t);if(r){n.push(r);break}}if(n.length>=de)break}}return function(e){if(!e.length)return[];const t=Array.from(e);/sentryWrapped/.test(t[t.length-1].function||"")&&t.pop();t.reverse(),pe.test(t[t.length-1].function||"")&&(t.pop(),pe.test(t[t.length-1].function||"")&&t.pop());return t.slice(0,de).map((e=>({...e,filename:e.filename||t[t.length-1].filename,function:e.function||"?"})))}(n)}}const ge="";function me(e){try{return e&&"function"===typeof e&&e.name||ge}catch(t){return ge}}function ye(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:100,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1/0;try{return be("",e,t,n)}catch(r){return{ERROR:"**non-serializable** (".concat(r,")")}}}function ve(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:3,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:102400;const r=ye(e,t);return o=r,function(e){return~-encodeURI(e).split(/%..|./).length}(JSON.stringify(o))>n?ve(e,t-1,n):r;var o}function be(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1/0,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1/0,i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:function(){const e="function"===typeof WeakSet,t=e?new WeakSet:[];return[function(n){if(e)return!!t.has(n)||(t.add(n),!1);for(let e=0;e=o){h[n]="[MaxProperties ~]";break}const e=f[n];h[n]=be(n,e,u-1,o,i),p++}return s(t),h}const Ae=1;function xe(e){const{spanId:t,traceId:n}=e.spanContext(),{data:r,op:o,parent_span_id:i,status:a,tags:s,origin:l}=Se(e);return F({data:r,op:o,parent_span_id:i,span_id:t,status:a,tags:s,trace_id:n,origin:l})}function Se(e){return function(e){return"function"===typeof e.getSpanJSON}(e)?e.getSpanJSON():"function"===typeof e.toJSON?e.toJSON():{}}function we(e){const{traceFlags:t}=e.spanContext();return Boolean(t&Ae)}function Ce(e,t,n,r,o,a){const{normalizeDepth:s=3,normalizeMaxBreadth:l=1e3}=e,c={...t,event_id:t.event_id||n.event_id||G(),timestamp:t.timestamp||oe()},u=n.integrations||e.integrations.map((e=>e.name));!function(e,t){const{environment:n,release:r,dist:o,maxValueLength:i=250}=t;"environment"in e||(e.environment="environment"in t?n:se);void 0===e.release&&void 0!==r&&(e.release=r);void 0===e.dist&&void 0!==o&&(e.dist=o);e.message&&(e.message=I(e.message,i));const a=e.exception&&e.exception.values&&e.exception.values[0];a&&a.value&&(a.value=I(a.value,i));const s=e.request;s&&s.url&&(s.url=I(s.url,i))}(c,e),function(e,t){t.length>0&&(e.sdk=e.sdk||{},e.sdk.integrations=[...e.sdk.integrations||[],...t])}(c,u),void 0===t.type&&function(e,t){const n=i._sentryDebugIds;if(!n)return;let r;const o=_e.get(t);o?r=o:(r=new Map,_e.set(t,r));const a=Object.keys(n).reduce(((e,o)=>{let i;const a=r.get(o);a?i=a:(i=t(o),r.set(o,i));for(let t=i.length-1;t>=0;t--){const r=i[t];if(r.filename){e[r.filename]=n[o];break}}return e}),{});try{e.exception.values.forEach((e=>{e.stacktrace.frames.forEach((e=>{e.filename&&(e.debug_id=a[e.filename])}))}))}catch(s){}}(c,e.stackParser);const d=function(e,t){if(!t)return e;const n=e?e.clone():new Ve;return n.update(t),n}(r,n.captureContext);n.mechanism&&Q(c,n.mechanism);const h=o&&o.getEventProcessors?o.getEventProcessors():[],p=function(){ze||(ze=new Ve);return ze}().getScopeData();if(a){He(p,a.getScopeData())}if(d){He(p,d.getScopeData())}const f=[...n.attachments||[],...p.attachments];f.length&&(n.attachments=f),Fe(c,p);return ne([...h,...ee(),...p.eventProcessors],c,n).then((e=>(e&&function(e){const t={};try{e.exception.values.forEach((e=>{e.stacktrace.frames.forEach((e=>{e.debug_id&&(e.abs_path?t[e.abs_path]=e.debug_id:e.filename&&(t[e.filename]=e.debug_id),delete e.debug_id)}))}))}catch(r){}if(0===Object.keys(t).length)return;e.debug_meta=e.debug_meta||{},e.debug_meta.images=e.debug_meta.images||[];const n=e.debug_meta.images;Object.keys(t).forEach((e=>{n.push({type:"sourcemap",code_file:e,debug_id:t[e]})}))}(e),"number"===typeof s&&s>0?function(e,t,n){if(!e)return null;const r={...e,...e.breadcrumbs&&{breadcrumbs:e.breadcrumbs.map((e=>({...e,...e.data&&{data:ye(e.data,t,n)}})))},...e.user&&{user:ye(e.user,t,n)},...e.contexts&&{contexts:ye(e.contexts,t,n)},...e.extra&&{extra:ye(e.extra,t,n)}};e.contexts&&e.contexts.trace&&r.contexts&&(r.contexts.trace=e.contexts.trace,e.contexts.trace.data&&(r.contexts.trace.data=ye(e.contexts.trace.data,t,n)));e.spans&&(r.spans=e.spans.map((e=>{const r=Se(e).data;return r&&(e.data=ye(r,t,n)),e})));return r}(e,s,l):e)))}const _e=new WeakMap;function Ee(e){if(e)return function(e){return e instanceof Ve||"function"===typeof e}(e)||function(e){return Object.keys(e).some((e=>Re.includes(e)))}(e)?{captureContext:e}:e}const Re=["user","level","extra","contexts","tags","fingerprint","requestSession","propagationContext"];function ke(e,t){return Ze().captureEvent(e,t)}function Ie(e,t){Ze().addBreadcrumb(e,t)}function Te(){const e=Ze();for(var t=arguments.length,n=new Array(t),r=0;r(e.getStackTop().scope=t,r(t)))):e.withScope(r)}return e.withScope(n[0])}function Oe(){return Ze().getClient()}function je(){return Ze().getScope()}function Pe(e){const t=Oe(),n=$e(),r=je(),{release:o,environment:a=se}=t&&t.getOptions()||{},{userAgent:s}=i.navigator||{},l=le({release:o,environment:a,user:r.getUser()||n.getUser(),...s&&{userAgent:s},...e}),c=n.getSession();return c&&"ok"===c.status&&ce(c,{status:"exited"}),Be(),n.setSession(l),r.setSession(l),l}function Be(){const e=$e(),t=je(),n=t.getSession()||e.getSession();n&&ue(n),Le(),e.setSession(),t.setSession()}function Le(){const e=$e(),t=je(),n=Oe(),r=t.getSession()||e.getSession();r&&n&&n.captureSession&&n.captureSession(r)}function De(){arguments.length>0&&void 0!==arguments[0]&&arguments[0]?Be():Le()}function Me(e){return e.transaction}function Ne(e,t,n){const r=t.getOptions(),{publicKey:o}=t.getDsn()||{},{segment:i}=n&&n.getUser()||{},a=F({environment:r.environment||se,release:r.release,user_segment:i,public_key:o,trace_id:e});return t.emit&&t.emit("createDsc",a),a}function Ue(e){const t=Oe();if(!t)return{};const n=Ne(Se(e).trace_id||"",t,je()),r=Me(e);if(!r)return n;const o=r&&r._frozenDynamicSamplingContext;if(o)return o;const{sampleRate:i,source:a}=r.metadata;null!=i&&(n.sample_rate="".concat(i));const s=Se(r);return a&&"url"!==a&&(n.transaction=s.description),n.sampled=String(we(r)),t.emit&&t.emit("createDsc",n),n}function Fe(e,t){const{fingerprint:n,span:r,breadcrumbs:o,sdkProcessingMetadata:i}=t;!function(e,t){const{extra:n,tags:r,user:o,contexts:i,level:a,transactionName:s}=t,l=F(n);l&&Object.keys(l).length&&(e.extra={...l,...e.extra});const c=F(r);c&&Object.keys(c).length&&(e.tags={...c,...e.tags});const u=F(o);u&&Object.keys(u).length&&(e.user={...u,...e.user});const d=F(i);d&&Object.keys(d).length&&(e.contexts={...d,...e.contexts});a&&(e.level=a);s&&(e.transaction=s)}(e,t),r&&function(e,t){e.contexts={trace:xe(t),...e.contexts};const n=Me(t);if(n){e.sdkProcessingMetadata={dynamicSamplingContext:Ue(t),...e.sdkProcessingMetadata};const r=Se(n).description;r&&(e.tags={transaction:r,...e.tags})}}(e,r),function(e,t){e.fingerprint=e.fingerprint?K(e.fingerprint):[],t&&(e.fingerprint=e.fingerprint.concat(t));e.fingerprint&&!e.fingerprint.length&&delete e.fingerprint}(e,n),function(e,t){const n=[...e.breadcrumbs||[],...t];e.breadcrumbs=n.length?n:void 0}(e,o),function(e,t){e.sdkProcessingMetadata={...e.sdkProcessingMetadata,...t}}(e,i)}function He(e,t){const{extra:n,tags:r,user:o,contexts:i,level:a,sdkProcessingMetadata:s,breadcrumbs:l,fingerprint:c,eventProcessors:u,attachments:d,propagationContext:h,transactionName:p,span:f}=t;Ge(e,"extra",n),Ge(e,"tags",r),Ge(e,"user",o),Ge(e,"contexts",i),Ge(e,"sdkProcessingMetadata",s),a&&(e.level=a),p&&(e.transactionName=p),f&&(e.span=f),l.length&&(e.breadcrumbs=[...e.breadcrumbs,...l]),c.length&&(e.fingerprint=[...e.fingerprint,...c]),u.length&&(e.eventProcessors=[...e.eventProcessors,...u]),d.length&&(e.attachments=[...e.attachments,...d]),e.propagationContext={...e.propagationContext,...h}}function Ge(e,t,n){if(n&&Object.keys(n).length){e[t]={...e[t]};for(const r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[t][r]=n[r])}}let ze;class Ve{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext=We()}static clone(e){return e?e.clone():new Ve}clone(){const e=new Ve;return e._breadcrumbs=[...this._breadcrumbs],e._tags={...this._tags},e._extra={...this._extra},e._contexts={...this._contexts},e._user=this._user,e._level=this._level,e._span=this._span,e._session=this._session,e._transactionName=this._transactionName,e._fingerprint=this._fingerprint,e._eventProcessors=[...this._eventProcessors],e._requestSession=this._requestSession,e._attachments=[...this._attachments],e._sdkProcessingMetadata={...this._sdkProcessingMetadata},e._propagationContext={...this._propagationContext},e._client=this._client,e}setClient(e){this._client=e}getClient(){return this._client}addScopeListener(e){this._scopeListeners.push(e)}addEventProcessor(e){return this._eventProcessors.push(e),this}setUser(e){return this._user=e||{email:void 0,id:void 0,ip_address:void 0,segment:void 0,username:void 0},this._session&&ce(this._session,{user:e}),this._notifyScopeListeners(),this}getUser(){return this._user}getRequestSession(){return this._requestSession}setRequestSession(e){return this._requestSession=e,this}setTags(e){return this._tags={...this._tags,...e},this._notifyScopeListeners(),this}setTag(e,t){return this._tags={...this._tags,[e]:t},this._notifyScopeListeners(),this}setExtras(e){return this._extra={...this._extra,...e},this._notifyScopeListeners(),this}setExtra(e,t){return this._extra={...this._extra,[e]:t},this._notifyScopeListeners(),this}setFingerprint(e){return this._fingerprint=e,this._notifyScopeListeners(),this}setLevel(e){return this._level=e,this._notifyScopeListeners(),this}setTransactionName(e){return this._transactionName=e,this._notifyScopeListeners(),this}setContext(e,t){return null===t?delete this._contexts[e]:this._contexts[e]=t,this._notifyScopeListeners(),this}setSpan(e){return this._span=e,this._notifyScopeListeners(),this}getSpan(){return this._span}getTransaction(){const e=this._span;return e&&e.transaction}setSession(e){return e?this._session=e:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(e){if(!e)return this;if("function"===typeof e){const t=e(this);return t instanceof Ve?t:this}return e instanceof Ve?(this._tags={...this._tags,...e._tags},this._extra={...this._extra,...e._extra},this._contexts={...this._contexts,...e._contexts},e._user&&Object.keys(e._user).length&&(this._user=e._user),e._level&&(this._level=e._level),e._fingerprint&&(this._fingerprint=e._fingerprint),e._requestSession&&(this._requestSession=e._requestSession),e._propagationContext&&(this._propagationContext=e._propagationContext)):A(e)&&(this._tags={...this._tags,...e.tags},this._extra={...this._extra,...e.extra},this._contexts={...this._contexts,...e.contexts},e.user&&(this._user=e.user),e.level&&(this._level=e.level),e.fingerprint&&(this._fingerprint=e.fingerprint),e.requestSession&&(this._requestSession=e.requestSession),e.propagationContext&&(this._propagationContext=e.propagationContext)),this}clear(){return this._breadcrumbs=[],this._tags={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._requestSession=void 0,this._span=void 0,this._session=void 0,this._notifyScopeListeners(),this._attachments=[],this._propagationContext=We(),this}addBreadcrumb(e,t){const n="number"===typeof t?t:100;if(n<=0)return this;const r={timestamp:oe(),...e},o=this._breadcrumbs;return o.push(r),this._breadcrumbs=o.length>n?o.slice(-n):o,this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(e){return this._attachments.push(e),this}getAttachments(){return this.getScopeData().attachments}clearAttachments(){return this._attachments=[],this}getScopeData(){const{_breadcrumbs:e,_attachments:t,_contexts:n,_tags:r,_extra:o,_user:i,_level:a,_fingerprint:s,_eventProcessors:l,_propagationContext:c,_sdkProcessingMetadata:u,_transactionName:d,_span:h}=this;return{breadcrumbs:e,attachments:t,contexts:n,tags:r,extra:o,user:i,level:a,fingerprint:s||[],eventProcessors:l,propagationContext:c,sdkProcessingMetadata:u,transactionName:d,span:h}}applyToEvent(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[];Fe(e,this.getScopeData());return ne([...n,...ee(),...this._eventProcessors],e,t)}setSDKProcessingMetadata(e){return this._sdkProcessingMetadata={...this._sdkProcessingMetadata,...e},this}setPropagationContext(e){return this._propagationContext=e,this}getPropagationContext(){return this._propagationContext}captureException(e,t){const n=t&&t.event_id?t.event_id:G();if(!this._client)return d.warn("No client configured on scope - will not capture exception!"),n;const r=new Error("Sentry syntheticException");return this._client.captureException(e,{originalException:e,syntheticException:r,...t,event_id:n},this),n}captureMessage(e,t,n){const r=n&&n.event_id?n.event_id:G();if(!this._client)return d.warn("No client configured on scope - will not capture message!"),r;const o=new Error(e);return this._client.captureMessage(e,t,{originalException:e,syntheticException:o,...n,event_id:r},this),r}captureEvent(e,t){const n=t&&t.event_id?t.event_id:G();return this._client?(this._client.captureEvent(e,{...t,event_id:n},this),n):(d.warn("No client configured on scope - will not capture event!"),n)}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach((e=>{e(this)})),this._notifyingListeners=!1)}}function We(){return{traceId:G(),spanId:G().substring(16)}}const Qe="7.100.1",Ye=parseFloat(Qe),Ke=100;class qe{constructor(e,t,n){let r,o,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:Ye;this._version=i,t?r=t:(r=new Ve,r.setClient(e)),n?o=n:(o=new Ve,o.setClient(e)),this._stack=[{scope:r}],e&&this.bindClient(e),this._isolationScope=o}isOlderThan(e){return this._version(this.popScope(),e)),(e=>{throw this.popScope(),e})):(this.popScope(),n)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStack(){return this._stack}getStackTop(){return this._stack[this._stack.length-1]}captureException(e,t){const n=this._lastEventId=t&&t.event_id?t.event_id:G(),r=new Error("Sentry syntheticException");return this.getScope().captureException(e,{originalException:e,syntheticException:r,...t,event_id:n}),n}captureMessage(e,t,n){const r=this._lastEventId=n&&n.event_id?n.event_id:G(),o=new Error(e);return this.getScope().captureMessage(e,t,{originalException:e,syntheticException:o,...n,event_id:r}),r}captureEvent(e,t){const n=t&&t.event_id?t.event_id:G();return e.type||(this._lastEventId=n),this.getScope().captureEvent(e,{...t,event_id:n}),n}lastEventId(){return this._lastEventId}addBreadcrumb(e,t){const{scope:n,client:r}=this.getStackTop();if(!r)return;const{beforeBreadcrumb:o=null,maxBreadcrumbs:i=Ke}=r.getOptions&&r.getOptions()||{};if(i<=0)return;const a={timestamp:oe(),...e},s=o?u((()=>o(a,t))):a;null!==s&&(r.emit&&r.emit("beforeAddBreadcrumb",s,t),n.addBreadcrumb(s,i))}setUser(e){this.getScope().setUser(e),this.getIsolationScope().setUser(e)}setTags(e){this.getScope().setTags(e),this.getIsolationScope().setTags(e)}setExtras(e){this.getScope().setExtras(e),this.getIsolationScope().setExtras(e)}setTag(e,t){this.getScope().setTag(e,t),this.getIsolationScope().setTag(e,t)}setExtra(e,t){this.getScope().setExtra(e,t),this.getIsolationScope().setExtra(e,t)}setContext(e,t){this.getScope().setContext(e,t),this.getIsolationScope().setContext(e,t)}configureScope(e){const{scope:t,client:n}=this.getStackTop();n&&e(t)}run(e){const t=Je(this);try{e(this)}finally{Je(t)}}getIntegration(e){const t=this.getClient();if(!t)return null;try{return t.getIntegration(e)}catch(n){return q&&d.warn("Cannot retrieve integration ".concat(e.id," from the current Hub")),null}}startTransaction(e,t){const n=this._callExtensionMethod("startTransaction",e,t);if(q&&!n){this.getClient()?d.warn("Tracing extension 'startTransaction' has not been added. Call 'addTracingExtensions' before calling 'init':\nSentry.addTracingExtensions();\nSentry.init({...});\n"):d.warn("Tracing extension 'startTransaction' is missing. You should 'init' the SDK before calling 'startTransaction'")}return n}traceHeaders(){return this._callExtensionMethod("traceHeaders")}captureSession(){if(arguments.length>0&&void 0!==arguments[0]&&arguments[0])return this.endSession();this._sendSessionUpdate()}endSession(){const e=this.getStackTop().scope,t=e.getSession();t&&ue(t),this._sendSessionUpdate(),e.setSession()}startSession(e){const{scope:t,client:n}=this.getStackTop(),{release:r,environment:o=se}=n&&n.getOptions()||{},{userAgent:a}=i.navigator||{},s=le({release:r,environment:o,user:t.getUser(),...a&&{userAgent:a},...e}),l=t.getSession&&t.getSession();return l&&"ok"===l.status&&ce(l,{status:"exited"}),this.endSession(),t.setSession(s),s}shouldSendDefaultPii(){const e=this.getClient(),t=e&&e.getOptions();return Boolean(t&&t.sendDefaultPii)}_sendSessionUpdate(){const{scope:e,client:t}=this.getStackTop(),n=e.getSession();n&&t&&t.captureSession&&t.captureSession(n)}_callExtensionMethod(e){const t=Xe().__SENTRY__;if(t&&t.extensions&&"function"===typeof t.extensions[e]){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o0&&void 0!==arguments[0]?arguments[0]:Xe();return tt(e)&&!nt(e).isOlderThan(Ye)||rt(e,new qe),nt(e)}function tt(e){return!!(e&&e.__SENTRY__&&e.__SENTRY__.hub)}function nt(e){return s("hub",(()=>new qe),e)}function rt(e,t){if(!e)return!1;return(e.__SENTRY__=e.__SENTRY__||{}).hub=t,!0}const ot=[];function it(e){const t=e.defaultIntegrations||[],n=e.integrations;let r;t.forEach((e=>{e.isDefaultInstance=!0})),r=Array.isArray(n)?[...t,...n]:"function"===typeof n?K(n(t)):t;const o=function(e){const t={};return e.forEach((e=>{const{name:n}=e,r=t[n];r&&!r.isDefaultInstance&&e.isDefaultInstance||(t[n]=e)})),Object.keys(t).map((e=>t[e]))}(r),i=function(e,t){for(let n=0;n"Debug"===e.name));if(-1!==i){const[e]=o.splice(i,1);o.push(e)}return o}function at(e,t){for(const n of t)n&&n.afterAllSetup&&n.afterAllSetup(e)}function st(e,t,n){if(n[t.name])q&&d.log("Integration skipped because it was already installed: ".concat(t.name));else{if(n[t.name]=t,-1===ot.indexOf(t.name)&&(t.setupOnce(te,Ze),ot.push(t.name)),t.setup&&"function"===typeof t.setup&&t.setup(e),e.on&&"function"===typeof t.preprocessEvent){const n=t.preprocessEvent.bind(t);e.on("preprocessEvent",((t,r)=>n(t,r,e)))}if(e.addEventProcessor&&"function"===typeof t.processEvent){const n=t.processEvent.bind(t),r=Object.assign(((t,r)=>n(t,r,e)),{id:t.name});e.addEventProcessor(r)}q&&d.log("Integration installed: ".concat(t.name))}}function lt(e,t){return Object.assign((function(){return t(...arguments)}),{id:e})}const ct=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/],ut=[/^.*\/healthcheck$/,/^.*\/healthy$/,/^.*\/live$/,/^.*\/ready$/,/^.*\/heartbeat$/,/^.*\/health$/,/^.*\/healthz$/],dt="InboundFilters",ht=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return{name:dt,setupOnce(){},processEvent(t,n,r){const o=r.getOptions(),i=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return{allowUrls:[...e.allowUrls||[],...t.allowUrls||[]],denyUrls:[...e.denyUrls||[],...t.denyUrls||[]],ignoreErrors:[...e.ignoreErrors||[],...t.ignoreErrors||[],...e.disableErrorDefaults?[]:ct],ignoreTransactions:[...e.ignoreTransactions||[],...t.ignoreTransactions||[],...e.disableTransactionDefaults?[]:ut],ignoreInternal:void 0===e.ignoreInternal||e.ignoreInternal}}(e,o);return function(e,t){if(t.ignoreInternal&&function(e){try{return"SentryError"===e.exception.values[0].type}catch(t){}return!1}(e))return q&&d.warn("Event dropped due to being internal Sentry Error.\nEvent: ".concat(V(e))),!0;if(function(e,t){if(e.type||!t||!t.length)return!1;return function(e){const t=[];e.message&&t.push(e.message);let n;try{n=e.exception.values[e.exception.values.length-1]}catch(r){}n&&n.value&&(t.push(n.value),n.type&&t.push("".concat(n.type,": ").concat(n.value)));q&&0===t.length&&d.error("Could not extract message for event ".concat(V(e)));return t}(e).some((e=>j(e,t)))}(e,t.ignoreErrors))return q&&d.warn("Event dropped due to being matched by `ignoreErrors` option.\nEvent: ".concat(V(e))),!0;if(function(e,t){if("transaction"!==e.type||!t||!t.length)return!1;const n=e.transaction;return!!n&&j(n,t)}(e,t.ignoreTransactions))return q&&d.warn("Event dropped due to being matched by `ignoreTransactions` option.\nEvent: ".concat(V(e))),!0;if(function(e,t){if(!t||!t.length)return!1;const n=pt(e);return!!n&&j(n,t)}(e,t.denyUrls))return q&&d.warn("Event dropped due to being matched by `denyUrls` option.\nEvent: ".concat(V(e),".\nUrl: ").concat(pt(e))),!0;if(!function(e,t){if(!t||!t.length)return!0;const n=pt(e);return!n||j(n,t)}(e,t.allowUrls))return q&&d.warn("Event dropped due to not being matched by `allowUrls` option.\nEvent: ".concat(V(e),".\nUrl: ").concat(pt(e))),!0;return!1}(t,i)?null:t}}};lt(dt,ht);function pt(e){try{let n;try{n=e.exception.values[0].stacktrace.frames}catch(t){}return n?function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];for(let t=e.length-1;t>=0;t--){const n=e[t];if(n&&""!==n.filename&&"[native code]"!==n.filename)return n.filename||null}return null}(n):null}catch(n){return q&&d.error("Cannot extract url for event ".concat(V(e))),null}}let ft;const gt="FunctionToString",mt=new WeakMap,yt=()=>({name:gt,setupOnce(){ft=Function.prototype.toString;try{Function.prototype.toString=function(){const e=D(this),t=mt.has(Oe())&&void 0!==e?e:this;for(var n=arguments.length,r=new Array(n),o=0;o{console.warn("[Sentry] Cannot initialize SDK with `debug` option using a non-debug bundle.")})));je().update(t.initialScope);const n=new e(t);!function(e){const t=Ze(),n=t.getStackTop();n.client=e,n.scope.setClient(e)}(n),function(e){e.init?e.init():e.setupIntegrations&&e.setupIntegrations()}(n)}const bt=a();function At(){if(!("fetch"in bt))return!1;try{return new Headers,new Request("http://www.example.com"),new Response,!0}catch(e){return!1}}function xt(e){return e&&/^function fetch\(\)\s+\{\s+\[native code\]\s+\}$/.test(e.toString())}const St=a();const wt={},Ct={};function _t(e,t){wt[e]=wt[e]||[],wt[e].push(t)}function Et(e,t){Ct[e]||(t(),Ct[e]=!0)}function Rt(e,t){const n=e&&wt[e];if(n)for(const i of n)try{i(t)}catch(o){r&&d.error("Error while triggering instrumentation handler.\nType: ".concat(e,"\nName: ").concat(me(i),"\nError:"),o)}}const kt=i;let It;function Tt(e){const t="history";_t(t,e),Et(t,Ot)}function Ot(){if(!function(){const e=St.chrome,t=e&&e.app&&e.app.runtime,n="history"in St&&!!St.history.pushState&&!!St.history.replaceState;return!t&&n}())return;const e=kt.onpopstate;function t(e){return function(){for(var t=arguments.length,n=new Array(t),r=0;r2?n[2]:void 0;if(o){const e=It,t=String(o);It=t;Rt("history",{from:e,to:t})}return e.apply(this,n)}}kt.onpopstate=function(){const t=kt.location.href,n=It;It=t;if(Rt("history",{from:n,to:t}),e)try{for(var r=arguments.length,o=new Array(r),i=0;i1&&void 0!==arguments[1]&&arguments[1];const{host:n,path:r,pass:o,port:i,projectId:a,protocol:s,publicKey:l}=e;return"".concat(s,"://").concat(l).concat(t&&o?":".concat(o):"")+"@".concat(n).concat(i?":".concat(i):"","/").concat(r?"".concat(r,"/"):r).concat(a)}function Bt(e){return{protocol:e.protocol,publicKey:e.publicKey||"",pass:e.pass||"",host:e.host,port:e.port||"",path:e.path||"",projectId:e.projectId}}function Lt(e){const t="string"===typeof e?function(e){const t=jt.exec(e);if(!t)return void u((()=>{console.error("Invalid Sentry Dsn: ".concat(e))}));const[n,r,o="",i,a="",s]=t.slice(1);let l="",c=s;const d=c.split("/");if(d.length>1&&(l=d.slice(0,-1).join("/"),c=d.pop()),c){const e=c.match(/^\d+/);e&&(c=e[0])}return Bt({host:i,pass:o,path:l,projectId:c,port:a,protocol:n,publicKey:r})}(e):Bt(e);if(t&&function(e){if(!r)return!0;const{port:t,projectId:n,protocol:o}=e;return!["protocol","publicKey","host","projectId"].find((t=>!e[t]&&(d.error("Invalid Sentry Dsn: ".concat(t," missing")),!0)))&&(n.match(/^\d+$/)?function(e){return"http"===e||"https"===e}(o)?!t||!isNaN(parseInt(t,10))||(d.error("Invalid Sentry Dsn: Invalid port ".concat(t)),!1):(d.error("Invalid Sentry Dsn: Invalid protocol ".concat(o)),!1):(d.error("Invalid Sentry Dsn: Invalid projectId ".concat(n)),!1))}(t))return t}function Dt(e){return[e,arguments.length>1&&void 0!==arguments[1]?arguments[1]:[]]}function Mt(e,t){const[n,r]=e;return[n,[...r,t]]}function Nt(e,t){const n=e[1];for(const r of n){if(t(r,r[0].type))return!0}return!1}function Ut(e,t){return(t||new TextEncoder).encode(e)}function Ft(e,t){const[n,r]=e;let o=JSON.stringify(n);function i(e){"string"===typeof o?o="string"===typeof e?o+e:[Ut(o,t),e]:o.push("string"===typeof e?Ut(e,t):e)}for(const s of r){const[e,t]=s;if(i("\n".concat(JSON.stringify(e),"\n")),"string"===typeof t||t instanceof Uint8Array)i(t);else{let e;try{e=JSON.stringify(t)}catch(a){e=JSON.stringify(ye(t))}i(e)}}return"string"===typeof o?o:function(e){const t=e.reduce(((e,t)=>e+t.length),0),n=new Uint8Array(t);let r=0;for(const o of e)n.set(o,r),r+=o.length;return n}(o)}function Ht(e,t){const n="string"===typeof e.data?Ut(e.data,t):e.data;return[F({type:"attachment",length:n.length,filename:e.filename,content_type:e.contentType,attachment_type:e.attachmentType}),n]}const Gt={session:"session",sessions:"session",attachment:"attachment",transaction:"transaction",event:"error",client_report:"internal",user_report:"default",profile:"profile",replay_event:"replay",replay_recording:"replay",check_in:"monitor",feedback:"feedback",statsd:"unknown"};function zt(e){return Gt[e]}function Vt(e){if(!e||!e.sdk)return;const{name:t,version:n}=e.sdk;return{name:t,version:n}}class Wt extends Error{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"warn";super(e),this.message=e,this.name=new.target.prototype.constructor.name,Object.setPrototypeOf(this,new.target.prototype),this.logLevel=t}}const Qt="7";function Yt(e){const t=e.protocol?"".concat(e.protocol,":"):"",n=e.port?":".concat(e.port):"";return"".concat(t,"//").concat(e.host).concat(n).concat(e.path?"/".concat(e.path):"","/api/")}function Kt(e,t){return function(e){return Object.keys(e).map((t=>"".concat(encodeURIComponent(t),"=").concat(encodeURIComponent(e[t])))).join("&")}({sentry_key:e.publicKey,sentry_version:Qt,...t&&{sentry_client:"".concat(t.name,"/").concat(t.version)}})}function qt(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const n="string"===typeof t?t:t.tunnel,r="string"!==typeof t&&t._metadata?t._metadata.sdk:void 0;return n||"".concat(function(e){return"".concat(Yt(e)).concat(e.projectId,"/envelope/")}(e),"?").concat(Kt(e,r))}function Xt(e,t,n,r){const o=Vt(n),i=e.type&&"replay_event"!==e.type?e.type:"event";!function(e,t){t&&(e.sdk=e.sdk||{},e.sdk.name=e.sdk.name||t.name,e.sdk.version=e.sdk.version||t.version,e.sdk.integrations=[...e.sdk.integrations||[],...t.integrations||[]],e.sdk.packages=[...e.sdk.packages||[],...t.packages||[]])}(e,n&&n.sdk);const a=function(e,t,n,r){const o=e.sdkProcessingMetadata&&e.sdkProcessingMetadata.dynamicSamplingContext;return{event_id:e.event_id,sent_at:(new Date).toISOString(),...t&&{sdk:t},...!!n&&r&&{dsn:Pt(r)},...o&&{trace:F({...o})}}}(e,o,r,t);delete e.sdkProcessingMetadata;return Dt(a,[[{type:i},e]])}function Jt(e,t,n,r){const o={sent_at:(new Date).toISOString()};n&&n.sdk&&(o.sdk={name:n.sdk.name,version:n.sdk.version}),r&&t&&(o.dsn=Pt(t));const i=function(e){const t=function(e){let t="";for(const n of e){const e=Object.entries(n.tags),r=e.length>0?"|#".concat(e.map((e=>{let[t,n]=e;return"".concat(t,":").concat(n)})).join(",")):"";t+="".concat(n.name,"@").concat(n.unit,":").concat(n.metric,"|").concat(n.metricType).concat(r,"|T").concat(n.timestamp,"\n")}return t}(e);return[{type:"statsd",length:t.length},t]}(e);return Dt(o,[i])}const Zt="Not capturing exception because it's already been captured.";class $t{constructor(e){if(this._options=e,this._integrations={},this._integrationsInitialized=!1,this._numProcessing=0,this._outcomes={},this._hooks={},this._eventProcessors=[],e.dsn?this._dsn=Lt(e.dsn):q&&d.warn("No DSN provided, client will not send events."),this._dsn){const t=qt(this._dsn,e);this._transport=e.transport({recordDroppedEvent:this.recordDroppedEvent.bind(this),...e.transportOptions,url:t})}}captureException(e,t,n){if(Y(e))return void(q&&d.log(Zt));let r=t&&t.event_id;return this._process(this.eventFromException(e,t).then((e=>this._captureEvent(e,t,n))).then((e=>{r=e}))),r}captureMessage(e,t,n,r){let o=n&&n.event_id;const i=v(e)?e:String(e),a=b(e)?this.eventFromMessage(i,t,n):this.eventFromException(e,n);return this._process(a.then((e=>this._captureEvent(e,n,r))).then((e=>{o=e}))),o}captureEvent(e,t,n){if(t&&t.originalException&&Y(t.originalException))return void(q&&d.log(Zt));let r=t&&t.event_id;const o=(e.sdkProcessingMetadata||{}).capturedSpanScope;return this._process(this._captureEvent(e,t,o||n).then((e=>{r=e}))),r}captureSession(e){"string"!==typeof e.release?q&&d.warn("Discarded session because of missing or non-string release"):(this.sendSession(e),ce(e,{init:!1}))}getDsn(){return this._dsn}getOptions(){return this._options}getSdkMetadata(){return this._options._metadata}getTransport(){return this._transport}flush(e){const t=this._transport;return t?(this.metricsAggregator&&this.metricsAggregator.flush(),this._isClientDoneProcessing(e).then((n=>t.flush(e).then((e=>n&&e))))):J(!0)}close(e){return this.flush(e).then((e=>(this.getOptions().enabled=!1,this.metricsAggregator&&this.metricsAggregator.close(),e)))}getEventProcessors(){return this._eventProcessors}addEventProcessor(e){this._eventProcessors.push(e)}setupIntegrations(e){(e&&!this._integrationsInitialized||this._isEnabled()&&!this._integrationsInitialized)&&this._setupIntegrations()}init(){this._isEnabled()&&this._setupIntegrations()}getIntegrationById(e){return this.getIntegrationByName(e)}getIntegrationByName(e){return this._integrations[e]}getIntegration(e){try{return this._integrations[e.id]||null}catch(t){return q&&d.warn("Cannot retrieve integration ".concat(e.id," from the current Client")),null}}addIntegration(e){const t=this._integrations[e.name];st(this,e,this._integrations),t||at(this,[e])}sendEvent(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.emit("beforeSendEvent",e,t);let n=Xt(e,this._dsn,this._options._metadata,this._options.tunnel);for(const o of t.attachments||[])n=Mt(n,Ht(o,this._options.transportOptions&&this._options.transportOptions.textEncoder));const r=this._sendEnvelope(n);r&&r.then((t=>this.emit("afterSendEvent",e,t)),null)}sendSession(e){const t=function(e,t,n,r){const o=Vt(n);return Dt({sent_at:(new Date).toISOString(),...o&&{sdk:o},...!!r&&t&&{dsn:Pt(t)}},["aggregates"in e?[{type:"sessions"},e]:[{type:"session"},e.toJSON()]])}(e,this._dsn,this._options._metadata,this._options.tunnel);this._sendEnvelope(t)}recordDroppedEvent(e,t,n){if(this._options.sendClientReports){const n="".concat(e,":").concat(t);q&&d.log('Adding outcome: "'.concat(n,'"')),this._outcomes[n]=this._outcomes[n]+1||1}}captureAggregateMetrics(e){q&&d.log("Flushing aggregated metrics, number of metrics: ".concat(e.length));const t=Jt(e,this._dsn,this._options._metadata,this._options.tunnel);this._sendEnvelope(t)}on(e,t){this._hooks[e]||(this._hooks[e]=[]),this._hooks[e].push(t)}emit(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;re(...n)))}_setupIntegrations(){const{integrations:e}=this._options;this._integrations=function(e,t){const n={};return t.forEach((t=>{t&&st(e,t,n)})),n}(this,e),at(this,e),this._integrationsInitialized=!0}_updateSessionFromEvent(e,t){let n=!1,r=!1;const o=t.exception&&t.exception.values;if(o){r=!0;for(const e of o){const t=e.mechanism;if(t&&!1===t.handled){n=!0;break}}}const i="ok"===e.status;(i&&0===e.errors||i&&n)&&(ce(e,{...n&&{status:"crashed"},errors:e.errors||Number(r||n)}),this.captureSession(e))}_isClientDoneProcessing(e){return new $((t=>{let n=0;const r=setInterval((()=>{0==this._numProcessing?(clearInterval(r),t(!0)):(n+=1,e&&n>=e&&(clearInterval(r),t(!1)))}),1)}))}_isEnabled(){return!1!==this.getOptions().enabled&&void 0!==this._transport}_prepareEvent(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:$e();const o=this.getOptions(),i=Object.keys(this._integrations);return!t.integrations&&i.length>0&&(t.integrations=i),this.emit("preprocessEvent",e,t),Ce(o,e,t,n,this,r).then((e=>{if(null===e)return e;const t={...r.getPropagationContext(),...n?n.getPropagationContext():void 0};if(!(e.contexts&&e.contexts.trace)&&t){const{traceId:r,spanId:o,parentSpanId:i,dsc:a}=t;e.contexts={trace:{trace_id:r,span_id:o,parent_span_id:i},...e.contexts};const s=a||Ne(r,this,n);e.sdkProcessingMetadata={dynamicSamplingContext:s,...e.sdkProcessingMetadata}}return e}))}_captureEvent(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0;return this._processEvent(e,t,n).then((e=>e.event_id),(e=>{if(q){const t=e;"log"===t.logLevel?d.log(t.message):d.warn(t)}}))}_processEvent(e,t,n){const r=this.getOptions(),{sampleRate:o}=r,i=tn(e),a=en(e),s=e.type||"error",l="before send for type `".concat(s,"`");if(a&&"number"===typeof o&&Math.random()>o)return this.recordDroppedEvent("sample_rate","error",e),Z(new Wt("Discarding event because it's not included in the random sample (sampling rate = ".concat(o,")"),"log"));const c="replay_event"===s?"replay":s,u=(e.sdkProcessingMetadata||{}).capturedSpanIsolationScope;return this._prepareEvent(e,t,n,u).then((n=>{if(null===n)throw this.recordDroppedEvent("event_processor",c,e),new Wt("An event processor returned `null`, will not send event.","log");if(t.data&&!0===t.data.__sentry__)return n;const o=function(e,t,n){const{beforeSend:r,beforeSendTransaction:o}=e;if(en(t)&&r)return r(t,n);if(tn(t)&&o)return o(t,n);return t}(r,n,t);return function(e,t){const n="".concat(t," must return `null` or a valid event.");if(S(e))return e.then((e=>{if(!A(e)&&null!==e)throw new Wt(n);return e}),(e=>{throw new Wt("".concat(t," rejected with ").concat(e))}));if(!A(e)&&null!==e)throw new Wt(n);return e}(o,l)})).then((r=>{if(null===r)throw this.recordDroppedEvent("before_send",c,e),new Wt("".concat(l," returned `null`, will not send event."),"log");const o=n&&n.getSession();!i&&o&&this._updateSessionFromEvent(o,r);const a=r.transaction_info;if(i&&a&&r.transaction!==e.transaction){const e="custom";r.transaction_info={...a,source:e}}return this.sendEvent(r,t),r})).then(null,(e=>{if(e instanceof Wt)throw e;throw this.captureException(e,{data:{__sentry__:!0},originalException:e}),new Wt("Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.\nReason: ".concat(e))}))}_process(e){this._numProcessing++,e.then((e=>(this._numProcessing--,e)),(e=>(this._numProcessing--,e)))}_sendEnvelope(e){if(this.emit("beforeEnvelope",e),this._isEnabled()&&this._transport)return this._transport.send(e).then(null,(e=>{q&&d.error("Error while sending event:",e)}));q&&d.error("Transport disabled")}_clearOutcomes(){const e=this._outcomes;return this._outcomes={},Object.keys(e).map((t=>{const[n,r]=t.split(":");return{reason:n,category:r,quantity:e[t]}}))}}function en(e){return void 0===e.type}function tn(e){return"transaction"===e.type}const nn="undefined"===typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__;function rn(e,t){const n=an(e,t),r={type:t&&t.name,value:ln(t)};return n.length&&(r.stacktrace={frames:n}),void 0===r.type&&""===r.value&&(r.value="Unrecoverable error caught"),r}function on(e,t){return{exception:{values:[rn(e,t)]}}}function an(e,t){const n=t.stacktrace||t.stack||"",r=function(e){if(e){if("number"===typeof e.framesToPop)return e.framesToPop;if(sn.test(e.message))return 1}return 0}(t);try{return e(n,r)}catch(o){}return[]}const sn=/Minified React error #\d+;/i;function ln(e){const t=e&&e.message;return t?t.error&&"string"===typeof t.error.message?t.error.message:t:"No error message"}function cn(e,t,n,r,o){let i;if(g(t)&&t.error){return on(e,t.error)}if(m(t)||f(t,"DOMException")){const o=t;if("stack"in t)i=on(e,t);else{const t=o.name||(m(o)?"DOMError":"DOMException"),a=o.message?"".concat(t,": ").concat(o.message):t;i=un(e,a,n,r),W(i,a)}return"code"in o&&(i.tags={...i.tags,"DOMException.code":"".concat(o.code)}),i}if(p(t))return on(e,t);if(A(t)||x(t)){return i=function(e,t,n,r){const o=Oe(),i=o&&o.getOptions().normalizeDepth,a={exception:{values:[{type:x(t)?t.constructor.name:r?"UnhandledRejection":"Error",value:dn(t,{isUnhandledRejection:r})}]},extra:{__serialized__:ve(t,i)}};if(n){const t=an(e,n);t.length&&(a.exception.values[0].stacktrace={frames:t})}return a}(e,t,n,o),Q(i,{synthetic:!0}),i}return i=un(e,t,n,r),W(i,"".concat(t),void 0),Q(i,{synthetic:!0}),i}function un(e,t,n,r){const o={};if(r&&n){const r=an(e,n);r.length&&(o.exception={values:[{value:t,stacktrace:{frames:r}}]})}if(v(t)){const{__sentry_template_string__:e,__sentry_template_values__:n}=t;return o.logentry={message:e,params:n},o}return o.message=t,o}function dn(e,t){let{isUnhandledRejection:n}=t;const r=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:40;const n=Object.keys(M(e));if(n.sort(),!n.length)return"[object has no keys]";if(n[0].length>=t)return I(n[0],t);for(let r=n.length;r>0;r--){const e=n.slice(0,r).join(", ");if(!(e.length>t))return r===n.length?e:I(e,t)}return""}(e),o=n?"promise rejection":"exception";if(g(e))return"Event `ErrorEvent` captured as ".concat(o," with message `").concat(e.message,"`");if(x(e)){const t=function(e){try{const t=Object.getPrototypeOf(e);return t?t.constructor.name:void 0}catch(t){}}(e);return"Event `".concat(t,"` (type=").concat(e.type,") captured as ").concat(o)}return"Object captured as ".concat(o," with keys: ").concat(r)}const hn=i;let pn=0;function fn(){return pn>0}function gn(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0;if("function"!==typeof e)return e;try{const t=e.__sentry_wrapped__;if(t)return t;if(D(e))return e}catch(o){return e}const r=function(){const r=Array.prototype.slice.call(arguments);try{n&&"function"===typeof n&&n.apply(this,arguments);const o=r.map((e=>gn(e,t)));return e.apply(this,o)}catch(o){throw pn++,setTimeout((()=>{pn--})),Te((e=>{var n,i;e.addEventProcessor((e=>(t.mechanism&&(W(e,void 0,void 0),Q(e,t.mechanism)),e.extra={...e.extra,arguments:r},e))),n=o,Ze().captureException(n,Ee(i))})),o}};try{for(const t in e)Object.prototype.hasOwnProperty.call(e,t)&&(r[t]=e[t])}catch(i){}L(r,e),B(e,"__sentry_wrapped__",r);try{Object.getOwnPropertyDescriptor(r,"name").configurable&&Object.defineProperty(r,"name",{get:()=>e.name})}catch(i){}return r}class mn extends $t{constructor(e){!function(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[t],r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"npm";const o=e._metadata||{};o.sdk||(o.sdk={name:"sentry.javascript.".concat(t),packages:n.map((e=>({name:"".concat(r,":@sentry/").concat(e),version:Qe}))),version:Qe}),e._metadata=o}(e,"browser",["browser"],hn.SENTRY_SDK_SOURCE||"npm"),super(e),e.sendClientReports&&hn.document&&hn.document.addEventListener("visibilitychange",(()=>{"hidden"===hn.document.visibilityState&&this._flushOutcomes()}))}eventFromException(e,t){return function(e,t,n,r){const o=cn(e,t,n&&n.syntheticException||void 0,r);return Q(o),o.level="error",n&&n.event_id&&(o.event_id=n.event_id),J(o)}(this._options.stackParser,e,t,this._options.attachStacktrace)}eventFromMessage(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"info",n=arguments.length>2?arguments[2]:void 0;return function(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"info",r=arguments.length>3?arguments[3]:void 0,o=arguments.length>4?arguments[4]:void 0;const i=un(e,t,r&&r.syntheticException||void 0,o);return i.level=n,r&&r.event_id&&(i.event_id=r.event_id),J(i)}(this._options.stackParser,e,t,n,this._options.attachStacktrace)}captureUserFeedback(e){if(!this._isEnabled())return void(nn&&d.warn("SDK not enabled, will not capture user feedback."));const t=function(e,t){let{metadata:n,tunnel:r,dsn:o}=t;const i={event_id:e.event_id,sent_at:(new Date).toISOString(),...n&&n.sdk&&{sdk:{name:n.sdk.name,version:n.sdk.version}},...!!r&&!!o&&{dsn:Pt(o)}},a=function(e){return[{type:"user_report"},e]}(e);return Dt(i,[a])}(e,{metadata:this.getSdkMetadata(),dsn:this.getDsn(),tunnel:this.getOptions().tunnel});this._sendEnvelope(t)}_prepareEvent(e,t,n){return e.platform=e.platform||"javascript",super._prepareEvent(e,t,n)}_flushOutcomes(){const e=this._clearOutcomes();if(0===e.length)return void(nn&&d.log("No outcomes to send"));if(!this._dsn)return void(nn&&d.log("No dsn provided, will not send outcomes"));nn&&d.log("Sending outcomes:",e);const t=(n=e,Dt((r=this._options.tunnel&&Pt(this._dsn))?{dsn:r}:{},[[{type:"client_report"},{timestamp:o||oe(),discarded_events:n}]]));var n,r,o;this._sendEnvelope(t)}}function yn(){"console"in i&&l.forEach((function(e){e in i.console&&P(i.console,e,(function(t){return c[e]=t,function(){for(var t=arguments.length,n=new Array(t),r=0;r{const n=vn[t]&&vn[t].prototype;n&&n.hasOwnProperty&&n.hasOwnProperty("addEventListener")&&(P(n,"addEventListener",(function(t){return function(n,r,o){if("click"===n||"keypress"==n)try{const r=this,i=r.__sentry_instrumentation_handlers__=r.__sentry_instrumentation_handlers__||{},a=i[n]=i[n]||{refCount:0};if(!a.handler){const r=Cn(e);a.handler=r,t.call(this,n,r,o)}a.refCount++}catch(i){}return t.call(this,n,r,o)}})),P(n,"removeEventListener",(function(e){return function(t,n,r){if("click"===t||"keypress"==t)try{const n=this,o=n.__sentry_instrumentation_handlers__||{},i=o[t];i&&(i.refCount--,i.refCount<=0&&(e.call(this,t,i.handler,r),i.handler=void 0,delete o[t]),0===Object.keys(o).length&&delete n.__sentry_instrumentation_handlers__)}catch(o){}return e.call(this,t,n,r)}})))}))}function Cn(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return n=>{if(!n||n._sentryCaptured)return;const r=function(e){try{return e.target}catch(t){return null}}(n);if(function(e,t){return"keypress"===e&&(!t||!t.tagName||"INPUT"!==t.tagName&&"TEXTAREA"!==t.tagName&&!t.isContentEditable)}(n.type,r))return;B(n,"_sentryCaptured",!0),r&&!r._sentryId&&B(r,"_sentryId",G());const o="keypress"===n.type?"input":n.type;if(!function(e){if(e.type!==xn)return!1;try{if(!e.target||e.target._sentryId!==Sn)return!1}catch(t){}return!0}(n)){e({event:n,name:o,global:t}),xn=n.type,Sn=r?r._sentryId:void 0}clearTimeout(An),An=vn.setTimeout((()=>{Sn=void 0,xn=void 0}),bn)}}const _n=i,En="__sentry_xhr_v3__";function Rn(){if(!_n.XMLHttpRequest)return;const e=XMLHttpRequest.prototype;P(e,"open",(function(e){return function(){const t=Date.now();for(var n=arguments.length,r=new Array(n),o=0;o{const e=this[En];if(e&&4===this.readyState){try{e.status_code=this.status}catch(n){}Rt("xhr",{args:[i,a],endTimestamp:Date.now(),startTimestamp:t,xhr:this})}};return"onreadystatechange"in this&&"function"===typeof this.onreadystatechange?P(this,"onreadystatechange",(function(e){return function(){s();for(var t=arguments.length,n=new Array(t),r=0;r(Rt("fetch",{...s,endTimestamp:Date.now(),response:e}),e)),(e=>{throw Rt("fetch",{...s,endTimestamp:Date.now(),error:e}),e}))}}))}function In(e,t){return!!e&&"object"===typeof e&&!!e[t]}function Tn(e){return"string"===typeof e?e:e?In(e,"url")?e.url:e.toString?e.toString():"":""}const On=["fatal","error","warning","log","info","debug"];function jn(e){return"warn"===e?"warning":On.includes(e)?e:"log"}function Pn(e){if(!e)return{};const t=e.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!t)return{};const n=t[6]||"",r=t[8]||"";return{host:t[4],path:t[5],protocol:t[2],search:n,hash:r,relative:t[5]+n+r}}const Bn=1024,Ln="Breadcrumbs",Dn=function(){const e={console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0,...arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}};return{name:Ln,setupOnce(){},setup(t){var n;e.console&&function(e){const t="console";_t(t,e),Et(t,yn)}(function(e){return function(t){if(Oe()!==e)return;const n={category:"console",data:{arguments:t.args,logger:"console"},level:jn(t.level),message:T(t.args," ")};if("assert"===t.level){if(!1!==t.args[0])return;n.message="Assertion failed: ".concat(T(t.args.slice(1)," ")||"console.assert"),n.data.arguments=t.args.slice(1)}Ie(n,{input:t.args,level:t.level})}}(t)),e.dom&&(n=function(e,t){return function(n){if(Oe()!==e)return;let r,o,i="object"===typeof t?t.serializeAttribute:void 0,a="object"===typeof t&&"number"===typeof t.maxStringLength?t.maxStringLength:void 0;a&&a>Bn&&(nn&&d.warn("`dom.maxStringLength` cannot exceed ".concat(Bn,", but a value of ").concat(a," was configured. Sentry will use ").concat(Bn," instead.")),a=Bn),"string"===typeof i&&(i=[i]);try{const e=n.event,t=function(e){return!!e&&!!e.target}(e)?e.target:e;r=R(t,{keyAttrs:i,maxStringLength:a}),o=function(e){if(!_.HTMLElement)return null;let t=e;for(let n=0;n<5;n++){if(!t)return null;if(t instanceof HTMLElement&&t.dataset.sentryComponent)return t.dataset.sentryComponent;t=t.parentNode}return null}(t)}catch(l){r=""}if(0===r.length)return;const s={category:"ui.".concat(n.name),message:r};o&&(s.data={"ui.component_name":o}),Ie(s,{event:n.event,name:n.name,global:n.global})}}(t,e.dom),_t("dom",n),Et("dom",wn)),e.xhr&&function(e){_t("xhr",e),Et("xhr",Rn)}(function(e){return function(t){if(Oe()!==e)return;const{startTimestamp:n,endTimestamp:r}=t,o=t.xhr[En];if(!n||!r||!o)return;const{method:i,url:a,status_code:s,body:l}=o;Ie({category:"xhr",data:{method:i,url:a,status_code:s},type:"http"},{xhr:t.xhr,input:l,startTimestamp:n,endTimestamp:r})}}(t)),e.fetch&&function(e){const t="fetch";_t(t,e),Et(t,kn)}(function(e){return function(t){if(Oe()!==e)return;const{startTimestamp:n,endTimestamp:r}=t;if(r&&(!t.fetchData.url.match(/sentry_key/)||"POST"!==t.fetchData.method))if(t.error){Ie({category:"fetch",data:t.fetchData,level:"error",type:"http"},{data:t.error,input:t.args,startTimestamp:n,endTimestamp:r})}else{const e=t.response;Ie({category:"fetch",data:{...t.fetchData,status_code:e&&e.status},type:"http"},{input:t.args,response:e,startTimestamp:n,endTimestamp:r})}}}(t)),e.history&&Tt(function(e){return function(t){if(Oe()!==e)return;let n=t.from,r=t.to;const o=Pn(hn.location.href);let i=n?Pn(n):void 0;const a=Pn(r);i&&i.path||(i=o),o.protocol===a.protocol&&o.host===a.host&&(r=a.relative),o.protocol===i.protocol&&o.host===i.host&&(n=i.relative),Ie({category:"navigation",data:{from:n,to:r}})}}(t)),e.sentry&&t.on&&t.on("beforeSendEvent",function(e){return function(t){Oe()===e&&Ie({category:"sentry.".concat("transaction"===t.type?"transaction":"event"),event_id:t.event_id,level:t.level,message:V(t)},{event:t})}}(t))}}};lt(Ln,Dn);const Mn="Dedupe",Nn=()=>{let e;return{name:Mn,setupOnce(){},processEvent(t){if(t.type)return t;try{if(function(e,t){if(!t)return!1;if(function(e,t){const n=e.message,r=t.message;if(!n&&!r)return!1;if(n&&!r||!n&&r)return!1;if(n!==r)return!1;if(!Fn(e,t))return!1;if(!Un(e,t))return!1;return!0}(e,t))return!0;if(function(e,t){const n=Hn(t),r=Hn(e);if(!n||!r)return!1;if(n.type!==r.type||n.value!==r.value)return!1;if(!Fn(e,t))return!1;if(!Un(e,t))return!1;return!0}(e,t))return!0;return!1}(t,e))return nn&&d.warn("Event dropped due to being a duplicate of previously captured event."),null}catch(n){}return e=t}}};lt(Mn,Nn);function Un(e,t){let n=Gn(e),r=Gn(t);if(!n&&!r)return!0;if(n&&!r||!n&&r)return!1;if(r.length!==n.length)return!1;for(let o=0;o0&&void 0!==arguments[0]?arguments[0]:{}};return{name:Yn,setupOnce(){Error.stackTraceLimit=50},setup(t){e.onerror&&(!function(e){!function(e){const t="error";_t(t,e),Et(t,Vn)}((t=>{const{stackParser:n,attachStacktrace:r}=Jn();if(Oe()!==e||fn())return;const{msg:o,url:i,line:a,column:s,error:l}=t,c=void 0===l&&y(o)?function(e,t,n,r){const o=/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?(.*)$/i;let i=g(e)?e.message:e,a="Error";const s=i.match(o);s&&(a=s[1],i=s[2]);const l={exception:{values:[{type:a,value:i}]}};return qn(l,t,n,r)}(o,i,a,s):qn(cn(n,l||o,void 0,r,!1),i,a,s);c.level="error",ke(c,{originalException:l,mechanism:{handled:!1,type:"onerror"}})}))}(t),Xn("onerror")),e.onunhandledrejection&&(!function(e){!function(e){const t="unhandledrejection";_t(t,e),Et(t,Qn)}((t=>{const{stackParser:n,attachStacktrace:r}=Jn();if(Oe()!==e||fn())return;const o=function(e){if(b(e))return e;const t=e;try{if("reason"in t)return t.reason;if("detail"in t&&"reason"in t.detail)return t.detail.reason}catch(n){}return e}(t),i=b(o)?{exception:{values:[{type:"UnhandledRejection",value:"Non-Error promise rejection captured with value: ".concat(String(o))}]}}:cn(n,o,void 0,r,!0);i.level="error",ke(i,{originalException:o,mechanism:{handled:!1,type:"onunhandledrejection"}})}))}(t),Xn("onunhandledrejection"))}}};lt(Yn,Kn);function qn(e,t,n,r){const o=e.exception=e.exception||{},i=o.values=o.values||[],a=i[0]=i[0]||{},s=a.stacktrace=a.stacktrace||{},l=s.frames=s.frames||[],c=isNaN(parseInt(r,10))?void 0:r,u=isNaN(parseInt(n,10))?void 0:n,d=y(t)&&t.length>0?t:function(){try{return _.document.location.href}catch(e){return""}}();return 0===l.length&&l.push({colno:c,filename:d,function:"?",in_app:!0,lineno:u}),e}function Xn(e){nn&&d.log("Global Handler attached: ".concat(e))}function Jn(){const e=Oe();return e&&e.getOptions()||{stackParser:()=>[],attachStacktrace:!1}}const Zn="HttpContext",$n=()=>({name:Zn,setupOnce(){},preprocessEvent(e){if(!hn.navigator&&!hn.location&&!hn.document)return;const t=e.request&&e.request.url||hn.location&&hn.location.href,{referrer:n}=hn.document||{},{userAgent:r}=hn.navigator||{},o={...e.request&&e.request.headers,...n&&{Referer:n},...r&&{"User-Agent":r}},i={...e.request,...t&&{url:t},headers:o};e.request=i}});lt(Zn,$n);function er(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:250,r=arguments.length>3?arguments[3]:void 0,o=arguments.length>4?arguments[4]:void 0,i=arguments.length>5?arguments[5]:void 0,a=arguments.length>6?arguments[6]:void 0;if(!i.exception||!i.exception.values||!a||!w(a.originalException,Error))return;const s=i.exception.values.length>0?i.exception.values[i.exception.values.length-1]:void 0;var l,c;s&&(i.exception.values=(l=tr(e,t,o,a.originalException,r,i.exception.values,s,0),c=n,l.map((e=>(e.value&&(e.value=I(e.value,c)),e)))))}function tr(e,t,n,r,o,i,a,s){if(i.length>=n+1)return i;let l=[...i];if(w(r[o],Error)){nr(a,s);const i=e(t,r[o]),c=l.length;rr(i,o,c,s),l=tr(e,t,n,r[o],o,[i,...l],i,c)}return Array.isArray(r.errors)&&r.errors.forEach(((r,i)=>{if(w(r,Error)){nr(a,s);const c=e(t,r),u=l.length;rr(c,"errors[".concat(i,"]"),u,s),l=tr(e,t,n,r,o,[c,...l],c,u)}})),l}function nr(e,t){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,is_exception_group:!0,exception_id:t}}function rr(e,t,n,r){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,type:"chained",source:t,exception_id:n,parent_id:r}}const or="LinkedErrors",ir=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const t=e.limit||5,n=e.key||"cause";return{name:or,setupOnce(){},preprocessEvent(e,r,o){const i=o.getOptions();er(rn,i.stackParser,i.maxValueLength,n,t,e,r)}}},ar=(lt(or,ir),["EventTarget","Window","Node","ApplicationCache","AudioTrackList","BroadcastChannel","ChannelMergerNode","CryptoOperation","EventSource","FileReader","HTMLUnknownElement","IDBDatabase","IDBRequest","IDBTransaction","KeyOperation","MediaController","MessagePort","ModalWindow","Notification","SVGElementInstance","Screen","SharedWorker","TextTrack","TextTrackCue","TextTrackList","WebSocket","WebSocketWorker","Worker","XMLHttpRequest","XMLHttpRequestEventTarget","XMLHttpRequestUpload"]),sr="TryCatch",lr=function(){const e={XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,...arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}};return{name:sr,setupOnce(){e.setTimeout&&P(hn,"setTimeout",cr),e.setInterval&&P(hn,"setInterval",cr),e.requestAnimationFrame&&P(hn,"requestAnimationFrame",ur),e.XMLHttpRequest&&"XMLHttpRequest"in hn&&P(XMLHttpRequest.prototype,"send",dr);const t=e.eventTarget;if(t){(Array.isArray(t)?t:ar).forEach(hr)}}}};lt(sr,lr);function cr(e){return function(){for(var t=arguments.length,n=new Array(t),r=0;r{e in t&&"function"===typeof t[e]&&P(t,e,(function(t){const n={mechanism:{data:{function:e,handler:me(t)},handled:!1,type:"instrument"}},r=D(t);return r&&(n.mechanism.data.handler=me(r)),gn(t,n)}))}));for(var n=arguments.length,r=new Array(n),o=0;o|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,mr=/\((\S*)(?::(\d+))(?::(\d+))\)/,yr=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,vr=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,br=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:[-a-z]+):.*?):(\d+)(?::(\d+))?\)?\s*$/i,Ar=fe(...[[30,e=>{const t=gr.exec(e);if(t){if(t[2]&&0===t[2].indexOf("eval")){const e=mr.exec(t[2]);e&&(t[2]=e[1],t[3]=e[2],t[4]=e[3])}const[e,n]=xr(t[1]||pr,t[2]);return fr(n,e,t[3]?+t[3]:void 0,t[4]?+t[4]:void 0)}}],[50,e=>{const t=yr.exec(e);if(t){if(t[3]&&t[3].indexOf(" > eval")>-1){const e=vr.exec(t[3]);e&&(t[1]=t[1]||"eval",t[3]=e[1],t[4]=e[2],t[5]="")}let e=t[3],n=t[1]||pr;return[n,e]=xr(n,e),fr(e,n,t[4]?+t[4]:void 0,t[5]?+t[5]:void 0)}}],[40,e=>{const t=br.exec(e);return t?fr(t[2],t[1]||pr,+t[3],t[4]?+t[4]:void 0):void 0}]]),xr=(e,t)=>{const n=-1!==e.indexOf("safari-extension"),r=-1!==e.indexOf("safari-web-extension");return n||r?[-1!==e.indexOf("@")?e.split("@")[0]:pr,n?"safari-extension:".concat(t):"safari-web-extension:".concat(t)]:[e,t]};function Sr(e){const t=[];function n(e){return t.splice(t.indexOf(e),1)[0]}return{$:t,add:function(r){if(!(void 0===e||t.lengthn(o))).then(null,(()=>n(o).then(null,(()=>{})))),o},drain:function(e){return new $(((n,r)=>{let o=t.length;if(!o)return n(!0);const i=setTimeout((()=>{e&&e>0&&n(!1)}),e);t.forEach((e=>{J(e).then((()=>{--o||(clearTimeout(i),n(!0))}),r)}))}))}}}const wr=6e4;function Cr(e,t){let{statusCode:n,headers:r}=t,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Date.now();const i={...e},a=r&&r["x-sentry-rate-limits"],s=r&&r["retry-after"];if(a)for(const l of a.trim().split(",")){const[e,t]=l.split(":",2),n=parseInt(e,10),r=1e3*(isNaN(n)?60:n);if(t)for(const a of t.split(";"))i[a]=o+r;else i.all=o+r}else s?i.all=o+function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Date.now();const n=parseInt("".concat(e),10);if(!isNaN(n))return 1e3*n;const r=Date.parse("".concat(e));return isNaN(r)?wr:r-t}(s,o):429===n&&(i.all=o+6e4);return i}const _r=30;function Er(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Sr(e.bufferSize||_r),r={};function o(o){const i=[];if(Nt(o,((t,n)=>{const o=zt(n);if(function(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Date.now();return function(e,t){return e[t]||e.all||0}(e,t)>n}(r,o)){const r=Rr(t,n);e.recordDroppedEvent("ratelimit_backoff",o,r)}else i.push(t)})),0===i.length)return J();const a=Dt(o[0],i),s=t=>{Nt(a,((n,r)=>{const o=Rr(n,r);e.recordDroppedEvent(t,zt(r),o)}))};return n.add((()=>t({body:Ft(a,e.textEncoder)}).then((e=>(void 0!==e.statusCode&&(e.statusCode<200||e.statusCode>=300)&&q&&d.warn("Sentry responded with status code ".concat(e.statusCode," to sent event.")),r=Cr(r,e),e)),(e=>{throw s("network_error"),e})))).then((e=>e),(e=>{if(e instanceof Wt)return q&&d.error("Skipped sending event because buffer is full."),s("queue_overflow"),J();throw e}))}return o.__sentry__baseTransport__=!0,{send:o,flush:e=>n.drain(e)}}function Rr(e,t){if("event"===t||"transaction"===t)return Array.isArray(e)?e[1]:void 0}let kr;function Ir(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(){if(kr)return kr;if(xt(hn.fetch))return kr=hn.fetch.bind(hn);const e=hn.document;let t=hn.fetch;if(e&&"function"===typeof e.createElement)try{const n=e.createElement("iframe");n.hidden=!0,e.head.appendChild(n);const r=n.contentWindow;r&&r.fetch&&(t=r.fetch),e.head.removeChild(n)}catch(n){nn&&d.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",n)}return kr=t.bind(hn)}(),n=0,r=0;return Er(e,(function(o){const i=o.body.length;n+=i,r++;const a={body:o.body,method:"POST",referrerPolicy:"origin",headers:e.headers,keepalive:n<=6e4&&r<15,...e.fetchOptions};try{return t(e.url,a).then((e=>(n-=i,r--,{statusCode:e.status,headers:{"x-sentry-rate-limits":e.headers.get("X-Sentry-Rate-Limits"),"retry-after":e.headers.get("Retry-After")}})))}catch(s){return kr=void 0,n-=i,r--,Z(s)}}))}const Tr=4;function Or(e){return Er(e,(function(t){return new $(((n,r)=>{const o=new XMLHttpRequest;o.onerror=r,o.onreadystatechange=()=>{o.readyState===Tr&&n({statusCode:o.status,headers:{"x-sentry-rate-limits":o.getResponseHeader("X-Sentry-Rate-Limits"),"retry-after":o.getResponseHeader("Retry-After")}})},o.open("POST",e.url);for(const t in e.headers)Object.prototype.hasOwnProperty.call(e.headers,t)&&o.setRequestHeader(t,e.headers[t]);o.send(t.body)}))}))}const jr=[ht(),yt(),lr(),Dn(),Kn(),ir(),Nn(),$n()];var Pr=n(9784),Br=n(7036),Lr=n(2844),Dr=n(1928),Mr=n(2012),Nr=n(2628),Ur=n(8104),Fr=n(7988);const Hr=(0,Fr.m)(),Gr=80;function zr(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(!e)return"";try{let n=e;const r=5,o=[];let i=0,a=0;const s=" > ",l=s.length;let c;const u=Array.isArray(t)?t:t.keyAttrs,d=!Array.isArray(t)&&t.maxStringLength||Gr;for(;n&&i++1&&a+o.length*l+c.length>=d));)o.push(c),a+=c.length,n=n.parentNode;return o.reverse().join(s)}catch(n){return""}}function Vr(e,t){const n=e,r=[];let o,i,a,s,l;if(!n||!n.tagName)return"";if(Hr.HTMLElement&&n instanceof HTMLElement&&n.dataset&&n.dataset.sentryComponent)return n.dataset.sentryComponent;r.push(n.tagName.toLowerCase());const c=t&&t.length?t.filter((e=>n.getAttribute(e))).map((e=>[e,n.getAttribute(e)])):null;if(c&&c.length)c.forEach((e=>{r.push("[".concat(e[0],'="').concat(e[1],'"]'))}));else if(n.id&&r.push("#".concat(n.id)),o=n.className,o&&(0,Ur.ct)(o))for(i=o.split(/\s+/),l=0;le.length>0&&","!==e)).length}var Zr=n(9944);const $r=(e,t,n)=>{let r,o;return i=>{t.value>=0&&(i||n)&&(o=t.value-(r||0),(o||void 0===r)&&(r=t.value,t.delta=o,e(t)))}},eo=()=>Kr.__WEB_VITALS_POLYFILL__?Kr.performance&&(performance.getEntriesByType&&performance.getEntriesByType("navigation")[0]||(()=>{const e=Kr.performance.timing,t=Kr.performance.navigation.type,n={entryType:"navigation",startTime:0,type:2==t?"back_forward":1===t?"reload":"navigate"};for(const r in e)"navigationStart"!==r&&"toJSON"!==r&&(n[r]=Math.max(e[r]-e.navigationStart,0));return n})()):Kr.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0],to=()=>{const e=eo();return e&&e.activationStart||0},no=(e,t)=>{const n=eo();let r="navigate";return n&&(r=Kr.document.prerendering||to()>0?"prerender":n.type.replace(/_/g,"-")),{name:e,value:"undefined"===typeof t?-1:t,rating:"good",delta:0,entries:[],id:"v3-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:r}},ro=(e,t,n)=>{try{if(PerformanceObserver.supportedEntryTypes.includes(e)){const r=new PerformanceObserver((e=>{t(e.getEntries())}));return r.observe(Object.assign({type:e,buffered:!0},n||{})),r}}catch(r){}},oo=(e,t)=>{const n=r=>{"pagehide"!==r.type&&"hidden"!==Kr.document.visibilityState||(e(r),t&&(removeEventListener("visibilitychange",n,!0),removeEventListener("pagehide",n,!0)))};addEventListener("visibilitychange",n,!0),addEventListener("pagehide",n,!0)},io=e=>{const t=no("CLS",0);let n,r=0,o=[];const i=e=>{e.forEach((e=>{if(!e.hadRecentInput){const i=o[0],a=o[o.length-1];r&&0!==o.length&&e.startTime-a.startTime<1e3&&e.startTime-i.startTime<5e3?(r+=e.value,o.push(e)):(r=e.value,o=[e]),r>t.value&&(t.value=r,t.entries=o,n&&n())}}))},a=ro("layout-shift",i);if(a){n=$r(e,t);const r=()=>{i(a.takeRecords()),n(!0)};return oo(r),r}};let ao=-1;const so=()=>(ao<0&&(ao="hidden"!==Kr.document.visibilityState||Kr.document.prerendering?1/0:0,oo((e=>{let{timeStamp:t}=e;ao=t}),!0)),{get firstHiddenTime(){return ao}}),lo=e=>{const t=so(),n=no("FID");let r;const o=e=>{e.startTime{e.forEach(o)},a=ro("first-input",i);r=$r(e,n),a&&oo((()=>{i(a.takeRecords()),a.disconnect()}),!0)},co={},uo=e=>{const t=so(),n=no("LCP");let r;const o=e=>{const o=e[e.length-1];if(o){const e=Math.max(o.startTime-to(),0);e{co[n.id]||(o(i.takeRecords()),i.disconnect(),co[n.id]=!0,r(!0))};return["keydown","click"].forEach((e=>{addEventListener(e,t,{once:!0,capture:!0})})),oo(t,!0),t}},ho={},po={};let fo,go,mo;function yo(e,t){return wo(e,t),po[e]||(!function(e){const t={};"event"===e&&(t.durationThreshold=0);ro(e,(t=>{vo(e,{entries:t})}),t)}(e),po[e]=!0),Co(e,t)}function vo(e,t){const n=ho[e];if(n&&n.length)for(const o of n)try{o(t)}catch(r){Qr&&Mr.QE.error("Error while triggering instrumentation handler.\nType: ".concat(e,"\nName: ").concat((0,Zr.kJ)(o),"\nError:"),r)}}function bo(){return io((e=>{vo("cls",{metric:e}),fo=e}))}function Ao(){return lo((e=>{vo("fid",{metric:e}),go=e}))}function xo(){return uo((e=>{vo("lcp",{metric:e}),mo=e}))}function So(e,t,n,r){let o,i=arguments.length>4&&void 0!==arguments[4]&&arguments[4];return wo(e,t),po[e]||(o=n(),po[e]=!0),r&&t({metric:r}),Co(e,t,i?o:void 0)}function wo(e,t){ho[e]=ho[e]||[],ho[e].push(t)}function Co(e,t,n){return()=>{n&&n();const r=ho[e];if(!r)return;const o=r.indexOf(t);-1!==o&&r.splice(o,1)}}function _o(e){return"number"===typeof e&&isFinite(e)}function Eo(e,t){let{startTimestamp:n,...r}=t;return n&&e.startTimestamp>n&&(e.startTimestamp=n),e.startChild({startTimestamp:n,...r})}const Ro=2147483647;function ko(e){return e/1e3}function Io(){return Kr&&Kr.addEventListener&&Kr.performance}let To,Oo,jo=0,Po={};function Bo(){const e=Io();if(e&&qr.W2){e.mark&&Kr.performance.mark("sentry-tracing-init");const t=function(){return e=e=>{let{metric:t}=e;const n=t.entries[t.entries.length-1];if(!n)return;const r=ko(qr.W2),o=ko(n.startTime);Qr&&Mr.QE.log("[Measurements] Adding FID"),Po.fid={value:t.value,unit:"millisecond"},Po["mark.fid"]={value:r+o,unit:"second"}},So("fid",e,Ao,go);var e}(),n=function(e){return So("cls",e,bo,fo,arguments.length>1&&void 0!==arguments[1]&&arguments[1])}((e=>{let{metric:t}=e;const n=t.entries[t.entries.length-1];n&&(Qr&&Mr.QE.log("[Measurements] Adding CLS"),Po.cls={value:t.value,unit:""},Oo=n)}),!0),r=function(e){return So("lcp",e,xo,mo,arguments.length>1&&void 0!==arguments[1]&&arguments[1])}((e=>{let{metric:t}=e;const n=t.entries[t.entries.length-1];n&&(Qr&&Mr.QE.log("[Measurements] Adding LCP"),Po.lcp={value:t.value,unit:"millisecond"},To=n)}),!0);return()=>{t(),n(),r()}}return()=>{}}function Lo(e){const t=Io();if(!t||!Kr.performance.getEntries||!qr.W2)return;Qr&&Mr.QE.log("[Tracing] Adding & adjusting spans using Performance API");const n=ko(qr.W2),r=t.getEntries();let o,i;const{op:a,start_timestamp:s}=(0,Yr.U0)(e);if(r.slice(jo).forEach((t=>{const r=ko(t.startTime),a=ko(t.duration);if(!("navigation"===e.op&&s&&n+r{Do(e,t,r,n)})),Do(e,t,"secureConnection",n,"TLS/SSL","connectEnd"),Do(e,t,"fetch",n,"cache","domainLookupStart"),Do(e,t,"domainLookup",n,"DNS"),function(e,t,n){t.responseEnd&&(Eo(e,{op:"browser",origin:"auto.browser.browser.metrics",description:"request",startTimestamp:n+ko(t.requestStart),endTimestamp:n+ko(t.responseEnd)}),Eo(e,{op:"browser",origin:"auto.browser.browser.metrics",description:"response",startTimestamp:n+ko(t.responseStart),endTimestamp:n+ko(t.responseEnd)}))}(e,t,n)}(e,t,n),o=n+ko(t.responseStart),i=n+ko(t.requestStart);break;case"mark":case"paint":case"measure":{!function(e,t,n,r,o){const i=o+n,a=i+r;Eo(e,{description:t.name,endTimestamp:a,op:t.entryType,origin:"auto.resource.browser.metrics",startTimestamp:i})}(e,t,r,a,n);const o=so(),i=t.startTime{if(!Po[e]||!s||n>=s)return;const t=Po[e].value,r=n+ko(t),o=Math.abs(1e3*(r-s)),i=o-t;Qr&&Mr.QE.log("[Measurements] Normalized ".concat(e," from ").concat(t," to ").concat(o," (").concat(i,")")),Po[e].value=o}));const t=Po["mark.fid"];t&&Po.fid&&(Eo(e,{description:"first input delay",endTimestamp:t.value+ko(Po.fid.value),op:"ui.action",origin:"auto.ui.browser.metrics",startTimestamp:t.value}),delete Po["mark.fid"]),"fcp"in Po||delete Po.cls,Object.keys(Po).forEach((e=>{!function(e,t,n){const r=(0,Lr.gB)();r&&r.setMeasurement(e,t,n)}(e,Po[e].value,Po[e].unit)})),function(e){To&&(Qr&&Mr.QE.log("[Measurements] Adding LCP Data"),To.element&&e.setTag("lcp.element",zr(To.element)),To.id&&e.setTag("lcp.id",To.id),To.url&&e.setTag("lcp.url",To.url.trim().slice(0,200)),e.setTag("lcp.size",To.size));Oo&&Oo.sources&&(Qr&&Mr.QE.log("[Measurements] Adding CLS Data"),Oo.sources.forEach(((t,n)=>e.setTag("cls.source.".concat(n+1),zr(t.node)))))}(e)}To=void 0,Oo=void 0,Po={}}function Do(e,t,n,r,o,i){const a=i?t[i]:t["".concat(n,"End")],s=t["".concat(n,"Start")];s&&a&&Eo(e,{op:"browser",origin:"auto.browser.browser.metrics",description:o||n,startTimestamp:r+ko(s),endTimestamp:r+ko(a)})}function Mo(e,t,n,r){const o=t[n];null!=o&&o{const t={...a,endTimestamp:Date.now(),response:e};return(0,qo.mw)("fetch",t),e}),(e=>{const t={...a,endTimestamp:Date.now(),error:e};throw(0,qo.mw)("fetch",t),e}))}}))}function Jo(e,t){return!!e&&"object"===typeof e&&!!e[t]}function Zo(e){return"string"===typeof e?e:e?Jo(e,"url")?e.url:e.toString?e.toString():"":""}const $o=Fr.GLOBAL_OBJ,ei="__sentry_xhr_v3__";function ti(){if(!$o.XMLHttpRequest)return;const e=XMLHttpRequest.prototype;(0,Vo.ym)(e,"open",(function(e){return function(){const t=Date.now();for(var n=arguments.length,r=new Array(n),o=0;o{const e=this[ei];if(e&&4===this.readyState){try{e.status_code=this.status}catch(n){}const r={args:[i,a],endTimestamp:Date.now(),startTimestamp:t,xhr:this};(0,qo.mw)("xhr",r)}};return"onreadystatechange"in this&&"function"===typeof this.onreadystatechange?(0,Vo.ym)(this,"onreadystatechange",(function(e){return function(){s();for(var t=arguments.length,n=new Array(t),r=0;r2&&void 0!==arguments[2]&&arguments[2];return(arguments.length>1&&void 0!==arguments[1]?arguments[1]:[]).some((n=>function(e,t){let n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return!!(0,Ur.ct)(e)&&((0,Ur.QX)(t)?t.test(e):!!(0,Ur.ct)(t)&&(n?e===t:e.includes(t)))}(e,n,t)))}var ri=n(5632);function oi(e,t,n,r){let o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"auto.http.browser";if(!(0,No.K)()||!e.fetchData)return;const i=t(e.fetchData.url);if(e.endTimestamp&&i){const t=e.fetchData.__span;if(!t)return;const n=r[t];if(n){if(e.response){(0,Uo.iI)(n,e.response.status);const t=e.response&&e.response.headers&&e.response.headers.get("content-length");if(t){const e=parseInt(t);e>0&&n.setAttribute("http.response_content_length",e)}}else e.error&&n.setStatus("internal_error");n.end(),delete r[t]}return}const a=(0,Fo.ao)(),s=(0,Fo.gf)(),{method:l,url:c}=e.fetchData,u=i?(0,Go.Yz)({name:"".concat(l," ").concat(c),onlyIfParent:!0,attributes:{url:c,type:"fetch","http.method":l,[Dr.ec]:o},op:"http.client"}):void 0;if(u&&(e.fetchData.__span=u.spanContext().spanId,r[u.spanContext().spanId]=u),n(e.fetchData.url)&&s){const t=e.args[0];e.args[1]=e.args[1]||{};const n=e.args[1];n.headers=function(e,t,n,r,o){const i=o||n.getSpan(),a=(0,Ho.Ud)(),{traceId:s,spanId:l,sampled:c,dsc:u}={...a.getPropagationContext(),...n.getPropagationContext()},d=i?(0,Yr.eA)(i):(0,Nr.mA)(s,l,c),h=(0,ri.wd)(u||(i?(0,zo.w)(i):(0,zo.g)(s,t,n))),p=r.headers||("undefined"!==typeof Request&&(0,Ur.aG)(e,Request)?e.headers:void 0);if(p){if("undefined"!==typeof Headers&&(0,Ur.aG)(p,Headers)){const e=new Headers(p);return e.append("sentry-trace",d),h&&e.append(ri.a8,h),e}if(Array.isArray(p)){const e=[...p,["sentry-trace",d]];return h&&e.push([ri.a8,h]),e}{const e="baggage"in p?p.baggage:void 0,t=[];return Array.isArray(e)?t.push(...e):e&&t.push(e),h&&t.push(h),{...p,"sentry-trace":d,baggage:t.length>0?t.join(","):void 0}}}return{"sentry-trace":d,baggage:h}}(t,s,a,n,u)}return u}const ii=["localhost",/^\/(?!\/)/],ai={traceFetch:!0,traceXHR:!0,enableHTTPTimings:!0,tracingOrigins:ii,tracePropagationTargets:ii};function si(e){const{traceFetch:t,traceXHR:n,tracePropagationTargets:r,tracingOrigins:o,shouldCreateSpanForRequest:i,enableHTTPTimings:a}={traceFetch:ai.traceFetch,traceXHR:ai.traceXHR,...e},s="function"===typeof i?i:e=>!0,l=e=>function(e,t){return ni(e,t||ii)}(e,r||o),c={};var u;t&&function(e){const t="fetch";(0,qo.st)(t,e),(0,qo.qA)(t,Xo)}((e=>{const t=oi(e,s,l,c);a&&t&&li(t)})),n&&(u=e=>{const t=function(e,t,n,r){const o=e.xhr,i=o&&o[ei];if(!(0,No.K)()||!o||o.__sentry_own_request__||!i)return;const a=t(i.url);if(e.endTimestamp&&a){const e=o.__sentry_xhr_span_id__;if(!e)return;const t=r[e];return void(t&&void 0!==i.status_code&&((0,Uo.iI)(t,i.status_code),t.end(),delete r[e]))}const s=(0,Fo.ao)(),l=(0,Ho.Ud)(),c=a?(0,Go.Yz)({name:"".concat(i.method," ").concat(i.url),onlyIfParent:!0,attributes:{type:"xhr","http.method":i.method,url:i.url,[Dr.ec]:"auto.http.browser"},op:"http.client"}):void 0;c&&(o.__sentry_xhr_span_id__=c.spanContext().spanId,r[o.__sentry_xhr_span_id__]=c);const u=(0,Fo.gf)();if(o.setRequestHeader&&n(i.url)&&u){const{traceId:e,spanId:t,sampled:n,dsc:r}={...l.getPropagationContext(),...s.getPropagationContext()};!function(e,t,n){try{e.setRequestHeader("sentry-trace",t),n&&e.setRequestHeader(ri.a8,n)}catch(r){}}(o,c?(0,Yr.eA)(c):(0,Nr.mA)(e,t,n),(0,ri.wd)(r||(c?(0,zo.w)(c):(0,zo.g)(e,u,s))))}return c}(e,s,l,c);a&&t&&li(t)},(0,qo.st)("xhr",u),(0,qo.qA)("xhr",ti))}function li(e){const{url:t}=(0,Yr.U0)(e).data||{};if(!t||"string"!==typeof t)return;const n=yo("resource",(r=>{let{entries:o}=r;o.forEach((r=>{if(function(e){return"resource"===e.entryType&&"initiatorType"in e&&"string"===typeof e.nextHopProtocol&&("fetch"===e.initiatorType||"xmlhttprequest"===e.initiatorType)}(r)&&r.name.endsWith(t)){(function(e){const{name:t,version:n}=function(e){let t="unknown",n="unknown",r="";for(const o of e){if("/"===o){[t,n]=e.split("/");break}if(!isNaN(Number(o))){t="h"===r?"http":r,n=e.split(r)[1];break}r+=o}r===e&&(t=r);return{name:t,version:n}}(e.nextHopProtocol),r=[];if(r.push(["network.protocol.version",n],["network.protocol.name",t]),!qr.W2)return r;return[...r,["http.request.redirect_start",ci(e.redirectStart)],["http.request.fetch_start",ci(e.fetchStart)],["http.request.domain_lookup_start",ci(e.domainLookupStart)],["http.request.domain_lookup_end",ci(e.domainLookupEnd)],["http.request.connect_start",ci(e.connectStart)],["http.request.secure_connection_start",ci(e.secureConnectionStart)],["http.request.connection_end",ci(e.connectEnd)],["http.request.request_start",ci(e.requestStart)],["http.request.response_start",ci(e.responseStart)],["http.request.response_end",ci(e.responseEnd)]]})(r).forEach((t=>e.setAttribute(...t))),setTimeout(n)}}))}))}function ci(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;return((qr.W2||performance.timeOrigin)+e)/1e3}const ui=(0,Fr.m)();const di=Fr.GLOBAL_OBJ;let hi;function pi(){if(!function(){const e=ui.chrome,t=e&&e.app&&e.app.runtime,n="history"in ui&&!!ui.history.pushState&&!!ui.history.replaceState;return!t&&n}())return;const e=di.onpopstate;function t(e){return function(){for(var t=arguments.length,n=new Array(t),r=0;r2?n[2]:void 0;if(o){const e=hi,t=String(o);hi=t;const n={from:e,to:t};(0,qo.mw)("history",n)}return e.apply(this,n)}}di.onpopstate=function(){const t=di.location.href,n=hi;hi=t;const r={from:n,to:t};if((0,qo.mw)("history",r),e)try{for(var o=arguments.length,i=new Array(o),a=0;a1&&void 0!==arguments[1])||arguments[1],n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];if(!Kr||!Kr.location)return void(Qr&&Mr.QE.warn("Could not initialize routing instrumentation due to invalid location"));let r,o=Kr.location.href;t&&(r=e({name:Kr.location.pathname,startTimestamp:qr.W2?qr.W2/1e3:void 0,op:"pageload",origin:"auto.pageload.browser",metadata:{source:"url"}})),n&&function(e){const t="history";(0,qo.st)(t,e),(0,qo.qA)(t,pi)}((t=>{let{to:n,from:i}=t;void 0===i&&o&&-1!==o.indexOf(n)?o=void 0:i!==n&&(o=void 0,r&&(Qr&&Mr.QE.log("[Tracing] Finishing current transaction with op: ".concat(r.op)),r.end()),r=e({name:Kr.location.pathname,op:"navigation",origin:"auto.navigation.browser",metadata:{source:"url"}}))}))},startTransactionOnLocationChange:!0,startTransactionOnPageLoad:!0,enableLongTask:!0,_experiments:{},...ai};function gi(e){const t=(n="meta[name=".concat(e,"]"),Hr.document&&Hr.document.querySelector?Hr.document.querySelector(n):null);var n;return t?t.getAttribute("content"):void 0}function mi(e){let t,n=e[0],r=1;for(;re(),"access",e=>e.getClient,"call",e=>e(),"optionalAccess",e=>e.getOptions,"call",e=>e()]);return"sentry"!==(mi([t,"optionalAccess",e=>e.instrumenter])||"sentry")}class Ai{static __initStatic(){this.id="Apollo"}constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{useNestjs:!1};this.name=Ai.id,this._useNest=!!e.useNestjs}loadDependency(){return this._useNest?this._module=this._module||(0,yi.kf)("@nestjs/graphql"):this._module=this._module||(0,yi.kf)("apollo-server-core"),this._module}setupOnce(e,t){if(bi(t))Qr&&Mr.QE.log("Apollo Integration is skipped because of instrumenter configuration.");else if(this._useNest){const e=this.loadDependency();if(!e)return void(Qr&&Mr.QE.error("Apollo-NestJS Integration was unable to require @nestjs/graphql package."));(0,Vo.ym)(e.GraphQLFactory.prototype,"mergeWithSchema",(function(e){return function(){(0,Vo.ym)(this.resolversExplorerService,"explore",(function(e){return function(){return xi((0,vi.gV)(e.call(this)),t)}}));for(var n=arguments.length,r=new Array(n),o=0;o(Object.keys(e).forEach((n=>{Object.keys(e[n]).forEach((r=>{"function"===typeof e[n][r]&&function(e,t,n,r){(0,Vo.ym)(e[t],n,(function(e){return function(){const o=mi([r().getScope().getSpan(),"optionalAccess",e=>e.startChild,"call",e=>e({description:"".concat(t,".").concat(n),op:"graphql.resolve",origin:"auto.graphql.apollo"})]);for(var i=arguments.length,a=new Array(i),s=0;s(mi([o,"optionalAccess",e=>e.end,"call",e=>e()]),e))):(mi([o,"optionalAccess",e=>e.end,"call",e=>e()]),l)}}))}(e,n,r,t)}))})),e)))}Ai.__initStatic();function Si(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const n=e.method&&e.method.toUpperCase();let r="",o="url";t.customRoute||e.route?(r=t.customRoute||"".concat(e.baseUrl||"").concat(e.route&&e.route.path),o="route"):(e.originalUrl||e.url)&&(r=Xr(e.originalUrl||e.url||""));let i="";return t.method&&n&&(i+=n),t.method&&t.path&&(i+=" "),t.path&&r&&(i+=r),[i,o]}class wi{static __initStatic(){this.id="Express"}constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.name=wi.id,this._router=e.router||e.app,this._methods=(Array.isArray(e.methods)?e.methods:[]).concat("use")}setupOnce(e,t){this._router?bi(t)?Qr&&Mr.QE.log("Express Integration is skipped because of instrumenter configuration."):(function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];t.forEach((t=>function(e,t){const n=e[t];return e[t]=function(){for(var e=arguments.length,r=new Array(e),o=0;o"function"===typeof e?Ci(e,t):Array.isArray(e)?e.map((e=>"function"===typeof e?Ci(e,t):e)):e))}(r,t))},e}(e,t)))}(this._router,this._methods),function(e){const t="settings"in e;t&&void 0===e._router&&e.lazyrouter&&e.lazyrouter();const n=t?e._router:e;if(!n)return Qr&&Mr.QE.debug("Cannot instrument router for URL Parameterization (did not find a valid router)."),void(Qr&&Mr.QE.debug("Routing instrumentation is currently only supported in Express 4."));const r=Object.getPrototypeOf(n),o=r.process_params;r.process_params=function(e,t,n,r,i){n._reconstructedRoute||(n._reconstructedRoute="");const{layerRoutePath:a,isRegex:s,isArray:l,numExtraSegments:c}=function(e){let t=mi([e,"access",e=>e.route,"optionalAccess",e=>e.path]);const n=(0,Ur.QX)(t),r=Array.isArray(t);if(!t){const[n]=Fr.GLOBAL_OBJ.process.versions.node.split(".").map(Number);n>=16&&(t=_i(e.path,e.regexp,e.keys))}if(!t)return{isRegex:n,isArray:r,numExtraSegments:0};const o=r?Math.max((a=t,a.reduce(((e,t)=>e+Jr(t.toString())),0)-Jr(e.path||"")),0):0,i=function(e,t){if(e)return t.map((e=>e.toString())).join(",");return t&&t.toString()}(r,t);var a;return{layerRoutePath:i,isRegex:n,isArray:r,numExtraSegments:o}}(e);let u;(a||s||l)&&(n._hasParameters=!0),u=a||(function(e,t,n){const r=mi([Xr(e||""),"optionalAccess",e=>e.split,"call",e=>e("/"),"access",e=>e.filter,"call",e=>e((e=>!!e))]);let o=0;const i=mi([t,"optionalAccess",e=>e.split,"call",e=>e("/"),"access",e=>e.filter,"call",e=>e((e=>!!e)),"access",e=>e.length])||0;return mi([n,"optionalAccess",e=>e.split,"call",e=>e("/"),"access",e=>e.filter,"call",e=>e((e=>mi([r,"optionalAccess",e=>e[i+o]])===e&&(o+=1,!0))),"access",e=>e.join,"call",e=>e("/")])}(n.originalUrl,n._reconstructedRoute,e.path)||"");const d=u.split("/").filter((e=>e.length>0&&(s||l||!e.includes("*")))).join("/");d&&d.length>0&&(n._reconstructedRoute+="/".concat(d).concat(s?"/":""));if(Jr(Xr(n.originalUrl||""))+c===Jr(n._reconstructedRoute)){n._hasParameters||n._reconstructedRoute!==n.originalUrl&&(n._reconstructedRoute=n.originalUrl?Xr(n.originalUrl):n.originalUrl);const e=r.__sentry_transaction,t=e&&(0,Yr.U0)(e).data||{};if(e&&"custom"!==t[Dr.y_]){const t=n._reconstructedRoute||"/",[r,o]=Si(n,{path:!0,method:!0,customRoute:t});e.updateName(r),e.setAttribute(Dr.y_,o)}}return o.call(this,e,t,n,r,i)}}(this._router)):Qr&&Mr.QE.error("ExpressIntegration is missing an Express instance")}}function Ci(e,t){const n=e.length;switch(n){case 2:return function(n,r){const o=r.__sentry_transaction;if(o){const n=o.startChild({description:e.name,op:"middleware.express.".concat(t),origin:"auto.middleware.express"});r.once("finish",(()=>{n.end()}))}return e.call(this,n,r)};case 3:return function(n,r,o){const i=mi([r.__sentry_transaction,"optionalAccess",e=>e.startChild,"call",n=>n({description:e.name,op:"middleware.express.".concat(t),origin:"auto.middleware.express"})]);e.call(this,n,r,(function(){mi([i,"optionalAccess",e=>e.end,"call",e=>e()]);for(var e=arguments.length,t=new Array(e),n=0;ne.startChild,"call",n=>n({description:e.name,op:"middleware.express.".concat(t),origin:"auto.middleware.express"})]);e.call(this,n,r,o,(function(){mi([a,"optionalAccess",e=>e.end,"call",e=>e()]);for(var e=arguments.length,t=new Array(e),n=0;n{if(!e||!t||!n||0===Object.keys(n).length||!mi([n,"access",e=>e[0],"optionalAccess",e=>e.offset]))return;const r=n.sort(((e,t)=>e.offset-t.offset)),o=new RegExp(t,"".concat(t.flags,"d")).exec(e);if(!o||!o.indices)return;const[,...i]=o.indices;if(i.length!==r.length)return;let a=e,s=0;return i.forEach(((e,t)=>{if(e){const[n,o]=e,i=a.substring(0,n-s),l=":".concat(r[t].name),c=a.substring(o-s);a=i+l+c,s+=o-n-l.length}})),a};class Ei{static __initStatic(){this.id="GraphQL"}constructor(){this.name=Ei.id}loadDependency(){return this._module=this._module||(0,yi.kf)("graphql/execution/execute.js")}setupOnce(e,t){if(bi(t))return void(Qr&&Mr.QE.log("GraphQL Integration is skipped because of instrumenter configuration."));const n=this.loadDependency();n?(0,Vo.ym)(n,"execute",(function(e){return function(){const n=t().getScope(),r=n.getSpan(),o=mi([r,"optionalAccess",e=>e.startChild,"call",e=>e({description:"execute",op:"graphql.execute",origin:"auto.graphql.graphql"})]);mi([n,"optionalAccess",e=>e.setSpan,"call",e=>e(o)]);for(var i=arguments.length,a=new Array(i),s=0;s(mi([o,"optionalAccess",e=>e.end,"call",e=>e()]),mi([n,"optionalAccess",e=>e.setSpan,"call",e=>e(r)]),e))):(mi([o,"optionalAccess",e=>e.end,"call",e=>e()]),mi([n,"optionalAccess",e=>e.setSpan,"call",e=>e(r)]),l)}})):Qr&&Mr.QE.error("GraphQL Integration was unable to require graphql/execution package.")}}Ei.__initStatic();const Ri=["aggregate","bulkWrite","countDocuments","createIndex","createIndexes","deleteMany","deleteOne","distinct","drop","dropIndex","dropIndexes","estimatedDocumentCount","find","findOne","findOneAndDelete","findOneAndReplace","findOneAndUpdate","indexes","indexExists","indexInformation","initializeOrderedBulkOp","insertMany","insertOne","isCapped","mapReduce","options","parallelCollectionScan","rename","replaceOne","stats","updateMany","updateOne"],ki={bulkWrite:["operations"],countDocuments:["query"],createIndex:["fieldOrSpec"],createIndexes:["indexSpecs"],deleteMany:["filter"],deleteOne:["filter"],distinct:["key","query"],dropIndex:["indexName"],find:["query"],findOne:["query"],findOneAndDelete:["filter"],findOneAndReplace:["filter","replacement"],findOneAndUpdate:["filter","update"],indexExists:["indexes"],insertMany:["docs"],insertOne:["doc"],mapReduce:["map","reduce"],rename:["newName"],replaceOne:["filter","doc"],updateMany:["filter","update"],updateOne:["filter","update"]};class Ii{static __initStatic(){this.id="Mongo"}constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.name=Ii.id,this._operations=Array.isArray(e.operations)?e.operations:Ri,this._describeOperations=!("describeOperations"in e)||e.describeOperations,this._useMongoose=!!e.useMongoose}loadDependency(){const e=this._useMongoose?"mongoose":"mongodb";return this._module=this._module||(0,yi.kf)(e)}setupOnce(e,t){if(bi(t))return void(Qr&&Mr.QE.log("Mongo Integration is skipped because of instrumenter configuration."));const n=this.loadDependency();if(n)this._instrumentOperations(n.Collection,this._operations,t);else{const e=this._useMongoose?"mongoose":"mongodb";Qr&&Mr.QE.error("Mongo Integration was unable to require `".concat(e,"` package."))}}_instrumentOperations(e,t,n){t.forEach((t=>this._patchOperation(e,t,n)))}_patchOperation(e,t,n){if(!(t in e.prototype))return;const r=this._getSpanContextFromOperationArguments.bind(this);(0,Vo.ym)(e.prototype,t,(function(e){return function(){for(var o=arguments.length,i=new Array(o),a=0;ae.getOptions,"call",e=>e(),"access",e=>e.sendDefaultPii]);if("function"!==typeof s||"mapReduce"===t&&2===i.length){const n=mi([d,"optionalAccess",e=>e.startChild,"call",e=>e(r(this,t,i,h))]),o=e.call(this,...i);if((0,Ur.Oe)(o))return o.then((e=>(mi([n,"optionalAccess",e=>e.end,"call",e=>e()]),e)));if((p=o)&&"object"===typeof p&&p.once&&"function"===typeof p.once){const e=o;try{e.once("close",(()=>{mi([n,"optionalAccess",e=>e.end,"call",e=>e()])}))}catch(g){mi([n,"optionalAccess",e=>e.end,"call",e=>e()])}return e}return mi([n,"optionalAccess",e=>e.end,"call",e=>e()]),o}var p;const f=mi([d,"optionalAccess",e=>e.startChild,"call",e=>e(r(this,t,i.slice(0,-1)))]);return e.call(this,...i.slice(0,-1),(function(e,t){mi([f,"optionalAccess",e=>e.end,"call",e=>e()]),s(e,t)}))}}))}_getSpanContextFromOperationArguments(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]&&arguments[3];const o={"db.system":"mongodb","db.name":e.dbName,"db.operation":t,"db.mongodb.collection":e.collectionName},i={op:"db",origin:"auto.db.mongo",description:t,data:o},a=ki[t],s=Array.isArray(this._describeOperations)?this._describeOperations.includes(t):this._describeOperations;if(!a||!s||!r)return i;try{if("mapReduce"===t){const[e,t]=n;o[a[0]]="string"===typeof e?e:e.name||"",o[a[1]]="string"===typeof t?t:t.name||""}else for(let e=0;e(r||(r=t.config),e.apply(t,n))})}catch(i){Qr&&Mr.QE.error("Mysql Integration was unable to instrument `mysql` config.")}function o(e){if(!e)return;const t=r?{"server.address":r.host,"server.port":r.port,"db.user":r.user}:{};Object.keys(t).forEach((n=>{e.setAttribute(n,t[n])})),e.end()}(0,Vo.ym)(n,"createQuery",(function(e){return function(n,r,i){const a=mi([t().getScope().getSpan(),"optionalAccess",e=>e.startChild,"call",e=>e({description:"string"===typeof n?n:n.sql,op:"db",origin:"auto.db.mysql",data:{"db.system":"mysql"}})]);if("function"===typeof i)return e.call(this,n,r,(function(e,t,n){o(a),i(e,t,n)}));if("function"===typeof r)return e.call(this,n,(function(e,t,n){o(a),r(e,t,n)}));const s=e.call(this,n,r);return s.on("end",(()=>{o(a)})),s}}))}}Ti.__initStatic();class Oi{static __initStatic(){this.id="Postgres"}constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.name=Oi.id,this._usePgNative=!!e.usePgNative,this._module=e.module}loadDependency(){return this._module=this._module||(0,yi.kf)("pg")}setupOnce(e,t){if(bi(t))return void(Qr&&Mr.QE.log("Postgres Integration is skipped because of instrumenter configuration."));const n=this.loadDependency();if(!n)return void(Qr&&Mr.QE.error("Postgres Integration was unable to require `pg` package."));const r=this._usePgNative?mi([n,"access",e=>e.native,"optionalAccess",e=>e.Client]):n.Client;r?(0,Vo.ym)(r.prototype,"query",(function(e){return function(n,r,o){const i=t().getScope().getSpan(),a={"db.system":"postgresql"};try{this.database&&(a["db.name"]=this.database),this.host&&(a["server.address"]=this.host),this.port&&(a["server.port"]=this.port),this.user&&(a["db.user"]=this.user)}catch(c){}const s=mi([i,"optionalAccess",e=>e.startChild,"call",e=>e({description:"string"===typeof n?n:n.text,op:"db",origin:"auto.db.postgres",data:a})]);if("function"===typeof o)return e.call(this,n,r,(function(e,t){mi([s,"optionalAccess",e=>e.end,"call",e=>e()]),o(e,t)}));if("function"===typeof r)return e.call(this,n,(function(e,t){mi([s,"optionalAccess",e=>e.end,"call",e=>e()]),r(e,t)}));const l="undefined"!==typeof r?e.call(this,n,r):e.call(this,n);return(0,Ur.Oe)(l)?l.then((e=>(mi([s,"optionalAccess",e=>e.end,"call",e=>e()]),e))):(mi([s,"optionalAccess",e=>e.end,"call",e=>e()]),l)}})):Qr&&Mr.QE.error("Postgres Integration was unable to access 'pg-native' bindings.")}}Oi.__initStatic();class ji{static __initStatic(){this.id="Prisma"}constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(this.name=ji.id,(t=e.client)&&t.$use&&!e.client._sentryInstrumented){(0,Vo.QB)(e.client,"_sentryInstrumented",!0);const t={};try{const n=e.client._engineConfig;if(n){const{activeProvider:e,clientVersion:r}=n;e&&(t["db.system"]=e),r&&(t["db.prisma.version"]=r)}}catch(n){}e.client.$use(((e,n)=>{if(bi(Ho.WS))return n(e);const r=e.action,o=e.model;return(0,Go.MQ)({name:o?"".concat(o," ").concat(r):r,onlyIfParent:!0,op:"db.prisma",attributes:{[Dr.ec]:"auto.db.prisma"},data:{...t,"db.operation":r}},(()=>n(e)))}))}else Qr&&Mr.QE.warn("Unsupported Prisma client provided to PrismaIntegration. Provided client:",e.client);var t}setupOnce(){}}ji.__initStatic();var Pi=n(8668);const Bi=class{constructor(e){this.name="BrowserTracing",this._hasSetTracePropagationTargets=!1,(0,Br.W)(),Qr&&(this._hasSetTracePropagationTargets=!(!e||!e.tracePropagationTargets&&!e.tracingOrigins)),this.options={...fi,...e},void 0!==this.options._experiments.enableLongTask&&(this.options.enableLongTask=this.options._experiments.enableLongTask),e&&!e.tracePropagationTargets&&e.tracingOrigins&&(this.options.tracePropagationTargets=e.tracingOrigins),this._collectWebVitals=Bo(),this.options.enableLongTask&&yo("longtask",(e=>{let{entries:t}=e;for(const n of t){const e=(0,Lr.gB)();if(!e)return;const t=ko(qr.W2+n.startTime),r=ko(n.duration);e.startChild({description:"Main UI thread blocked",op:"ui.long-task",origin:"auto.ui.browser.metrics",startTimestamp:t,endTimestamp:t+r})}})),this.options._experiments.enableInteractions&&yo("event",(e=>{let{entries:t}=e;for(const n of t){const e=(0,Lr.gB)();if(!e)return;if("click"===n.name){const t=ko(qr.W2+n.startTime),r=ko(n.duration),o={description:zr(n.target),op:"ui.interaction.".concat(n.name),origin:"auto.ui.browser.metrics",startTimestamp:t,endTimestamp:t+r},i=Wr(n.target);i&&(o.attributes={"ui.component_name":i}),e.startChild(o)}}}))}setupOnce(e,t){this._getCurrentHub=t;const n=t().getClient(),r=n&&n.getOptions(),{routingInstrumentation:o,startTransactionOnLocationChange:i,startTransactionOnPageLoad:a,markBackgroundTransactions:s,traceFetch:l,traceXHR:c,shouldCreateSpanForRequest:u,enableHTTPTimings:d,_experiments:h}=this.options,p=r&&r.tracePropagationTargets,f=p||this.options.tracePropagationTargets;Qr&&this._hasSetTracePropagationTargets&&p&&Mr.QE.warn("[Tracing] The `tracePropagationTargets` option was set in the BrowserTracing integration and top level `Sentry.init`. The top level `Sentry.init` value is being used."),o((e=>{const n=this._createRouteTransaction(e);return this.options._experiments.onStartRouteTransaction&&this.options._experiments.onStartRouteTransaction(n,e,t),n}),a,i),s&&(Kr&&Kr.document?Kr.document.addEventListener("visibilitychange",(()=>{const e=(0,Lr.gB)();if(Kr.document.hidden&&e){const t="cancelled",{op:n,status:r}=(0,Yr.U0)(e);Qr&&Mr.QE.log("[Tracing] Transaction: ".concat(t," -> since tab moved to the background, op: ").concat(n)),r||e.setStatus(t),e.setTag("visibilitychange","document.hidden"),e.end()}})):Qr&&Mr.QE.warn("[Tracing] Could not set up background tab detection due to lack of global document")),h.enableInteractions&&this._registerInteractionListener(),si({traceFetch:l,traceXHR:c,tracePropagationTargets:f,shouldCreateSpanForRequest:u,enableHTTPTimings:d})}_createRouteTransaction(e){if(!this._getCurrentHub)return void(Qr&&Mr.QE.warn("[Tracing] Did not create ".concat(e.op," transaction because _getCurrentHub is invalid.")));const t=this._getCurrentHub(),{beforeNavigate:n,idleTimeout:r,finalTimeout:o,heartbeatInterval:i}=this.options,a="pageload"===e.op;let s;if(a){const t=a?gi("sentry-trace"):"",n=a?gi("baggage"):void 0,{traceId:r,dsc:o,parentSpanId:i,sampled:l}=(0,Nr.Ib)(t,n);s={traceId:r,parentSpanId:i,parentSampled:l,...e,metadata:{...e.metadata,dynamicSamplingContext:o},trimEnd:!0}}else s={trimEnd:!0,...e};const l="function"===typeof n?n(s):s,c=void 0===l?{...s,sampled:!1}:l;c.metadata=c.name!==s.name?{...c.metadata,source:"custom"}:c.metadata,this._latestRouteName=c.name,this._latestRouteSource=function(e){const t=e.attributes&&e.attributes[Dr.y_],n=e.data&&e.data[Dr.y_],r=e.metadata&&e.metadata.source;return t||n||r}(c),!1===c.sampled&&Qr&&Mr.QE.log("[Tracing] Will not send ".concat(c.op," transaction because of beforeNavigate.")),Qr&&Mr.QE.log("[Tracing] Starting ".concat(c.op," transaction on scope"));const{location:u}=Kr,d=(0,Br.I)(t,c,r,o,!0,{location:u},i,a);return a&&(Kr.document.addEventListener("readystatechange",(()=>{["interactive","complete"].includes(Kr.document.readyState)&&d.sendAutoFinishSignal()})),["interactive","complete"].includes(Kr.document.readyState)&&d.sendAutoFinishSignal()),d.registerBeforeFinishCallback((e=>{this._collectWebVitals(),Lo(e)})),d}_registerInteractionListener(){let e;const t=()=>{const{idleTimeout:t,finalTimeout:n,heartbeatInterval:r}=this.options,o="ui.action.click",i=(0,Lr.gB)();if(i&&i.op&&["navigation","pageload"].includes(i.op))return void(Qr&&Mr.QE.warn("[Tracing] Did not create ".concat(o," transaction because a pageload or navigation transaction is in progress.")));if(e&&(e.setFinishReason("interactionInterrupted"),e.end(),e=void 0),!this._getCurrentHub)return void(Qr&&Mr.QE.warn("[Tracing] Did not create ".concat(o," transaction because _getCurrentHub is invalid.")));if(!this._latestRouteName)return void(Qr&&Mr.QE.warn("[Tracing] Did not create ".concat(o," transaction because _latestRouteName is missing.")));const a=this._getCurrentHub(),{location:s}=Kr,l={name:this._latestRouteName,op:o,trimEnd:!0,data:{[Dr.y_]:this._latestRouteSource||"url"}};e=(0,Br.I)(a,l,t,n,!0,{location:s},r)};["click"].forEach((e=>{addEventListener(e,t,{once:!1,capture:!0})}))}},Li={BrowserTracing:Bi,Apollo:Ai,Express:wi,GraphQL:Ei,Mongo:Ii,Mysql:Ti,Postgres:Oi,Prisma:ji};("undefined"===typeof __SENTRY_TRACING__||__SENTRY_TRACING__)&&(0,Pi.M)(),"undefined"===typeof(e=n.hmd(e)).hot&&function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};void 0===e.defaultIntegrations&&(e.defaultIntegrations=[...jr]),void 0===e.release&&("string"===typeof __SENTRY_RELEASE__&&(e.release=__SENTRY_RELEASE__),hn.SENTRY_RELEASE&&hn.SENTRY_RELEASE.id&&(e.release=hn.SENTRY_RELEASE.id)),void 0===e.autoSessionTracking&&(e.autoSessionTracking=!0),void 0===e.sendClientReports&&(e.sendClientReports=!0);const t={...e,stackParser:(n=e.stackParser||Ar,Array.isArray(n)?fe(...n):n),integrations:it(e),transport:e.transport||(At()?Ir:Or)};var n;vt(mn,t),e.autoSessionTracking&&("undefined"!==typeof hn.document?(Pe({ignoreDuration:!0}),De(),Tt((e=>{let{from:t,to:n}=e;void 0!==t&&t!==n&&(Pe({ignoreDuration:!0}),De())}))):nn&&d.warn("Session tracking in non-browser environment with @sentry/browser is not supported."))}({dsn:"https://30a96b7291ce47fa8ffd10adbd158652@sentry.maoboa.blueforest.cc/2",integrations:[new Li.BrowserTracing],tracesSampleRate:1});const Di=(e,t)=>{!function(e,t){Ze().setTag(e,t)}(e,t)}},1908:(e,t,n)=>{"use strict";n.d(t,{Y:()=>o,u:()=>i});var r=n(3280);const o={name:"production"},i=e=>{console.log("resolving",e),e&&(o.name=e,r.cp.setItem("resolving",e))}},9020:(e,t,n)=>{"use strict";n.d(t,{K:()=>g,q:()=>p});var r=n(9060),o=n(1020),i=n(8884),a=n(1012),s=n(3768),l=n(7172),c=n(3280),u=n(8440),d=n(268),h=n(2496);e=n.hmd(e);const p=!1;let f=!0;function g(t){const n=r.useContext(d.S);p&&"undefined"!==e.hot&&(f?(f=!1,c.cp.getItem("currentPage").then((e=>{null!==e&&e!==l.g.LOADING?(console.log("Back to previous page :",e),t.navigate(e)):c.cp.setItem("currentPage",l.g.LOADING)})).catch((e=>{console.log("[ERROR]",e)}))):(console.log("Setting currentPage :",t.name),c.cp.setItem("currentPage",t.name)));const g="calc(100vh - 64px)";return(0,h.jsxs)(s.c.Host,{children:[(0,h.jsx)(o.c,{backgroundColor:u.y.BLUE_DARK}),(0,h.jsx)(i.c,{style:[n.expanded?{minHeight:g,bottom:0}:"web"===a.default.OS?{height:g}:{flex:1,backgroundColor:u.y.BLUE_DARK},t.style],onStartShouldSetResponder:t.onStartShouldSetResponder,children:t.children}),(0,h.jsx)(i.c,{style:{flex:0,backgroundColor:u.y.BLUE_DARK}})]})}},4340:(e,t,n)=>{"use strict";n.d(t,{Av:()=>l,Ke:()=>u,Ki:()=>d,_U:()=>c,kB:()=>h});var r=n(1012),o=n(3400),i=n(8100),a=n(1976),s=n(1908);e=n.hmd(e);const l={},c={production:{accounts:"https://api.account.dropin.maoboa.blueforest.cc",api:"https://api.dropin.maoboa.blueforest.cc/v0",chat:"wss://chat.maoboa.blueforest.cc"},cmacgm:{accounts:"https://api.account.dropin.cmacgm.maoboa.co",api:"https://api.dropin.cmacgm.maoboa.co/v0",chat:"wss://chat.cmacgm.maoboa.co"},tanum:{accounts:"https://api.account.dropin.tanum.maoboa.blueforest.cc",api:"https://api.dropin.tanum.maoboa.blueforest.cc/v0",chat:"wss://chat.tanum.maoboa.blueforest.cc"}},u=()=>"undefined"!==typeof e.hot?"ws://".concat("android"===r.default.OS?"10.0.2.2":"localhost",":8090"):"cmacgm"===s.Y.name?c.cmacgm.chat:"tanum"===s.Y.name?c.tanum.chat:c.production.chat,d=t=>{let n;return n="undefined"!==typeof e.hot?"http://".concat("android"===r.default.OS?"10.0.2.2":"localhost",":8080"):"tanum"===s.Y.name?"https://oauth.tanum.maoboa.blueforest.cc":"cmacgm"===s.Y.name?"https://oauth.cmacgm.maoboa.co":"https://oauth.maoboa.blueforest.cc","".concat(n,"/v1/").concat(t,"/login?l=").concat(i.O.get())+"".concat("web"===r.default.OS?"":"&m=1")},h=e=>{if("web"===r.default.OS)window.open(e,"_blank");else{let t=e;-1!==e.indexOf("maoboa.co")&&(t+=(-1!==e.indexOf("?")?"&":"?")+"token="+a.g.config.getToken()),Promise.resolve(o.c.openURL(t))}}},7172:(e,t,n)=>{"use strict";n.d(t,{g:()=>r});let r=function(e){return e.LOADING="Loading",e.OFFLINE="Offline",e.LOGIN="Login",e.REGISTER="Register",e.PASSWORD_RESET="PasswordReset",e.WELCOME="Welcome",e.PROJECTS="Projects",e.PROJECT_INFO="ProjectInfo",e.COUNTDOWN="Countdown",e.VALIDATION="Validation",e.ADMIN="Admin",e.SETTINGS="Settings",e.NOTIFICATIONS="Notifications",e.CHAT="Chat",e.CHAT_MEMBERS="ChatMembers",e.COMMUNITY_MEMBERS="CommunityMembers",e.HIGHLIGHTS="Highlights",e.HIGHLIGHT_DETAILS="HighlightDetails",e.NEW_MESSAGE="NewMessage",e.FEED_LIKES="FeedLikes",e.TEAMS_RANKING="TeamsRanking",e.FORM="Form",e.PROGRAM_COMMITMENTS="ProgramCommitments",e}({})},6092:(e,t,n)=>{"use strict";var r=n(1012),o=n(788),i=n(1020),a=n(3280),s=(n(16),n(1976)),l=n(4340),c=n(1908),u=n(8440),d=n(9060),h=n.t(d,2),p=n(3336),f=n(992),g=n(5048),m=n.n(g),y=n(2536),v=n(2763),b=n(3040);const A={WebkitTransition:"webkitTransitionEnd",Transition:"transitionEnd",MozTransition:"transitionend",MSTransition:"msTransitionEnd",OTransition:"oTransitionEnd"};function x(e){let{children:t,style:n,onInsetsChange:r}=e;return d.useEffect((()=>{if("undefined"===typeof document)return;const e=function(){const e=document.createElement("div"),{style:t}=e;return t.position="fixed",t.left="0",t.top="0",t.width="0",t.height="0",t.zIndex="-1",t.overflow="hidden",t.visibility="hidden",t.transitionDuration="0.05s",t.transitionProperty="padding",t.transitionDelay="0s",t.paddingTop=_("top"),t.paddingBottom=_("bottom"),t.paddingLeft=_("left"),t.paddingRight=_("right"),e}();document.body.appendChild(e);const t=()=>{const{paddingTop:t,paddingBottom:n,paddingLeft:o,paddingRight:i}=window.getComputedStyle(e),a={top:t?parseInt(t,10):0,bottom:n?parseInt(n,10):0,left:o?parseInt(o,10):0,right:i?parseInt(i,10):0},s={x:0,y:0,width:document.documentElement.offsetWidth,height:document.documentElement.offsetHeight};r({nativeEvent:{insets:a,frame:s}})};return e.addEventListener(w(),t),t(),()=>{document.body.removeChild(e),e.removeEventListener(w(),t)}}),[r]),d.createElement(p.c,{style:n},t)}let S=null;function w(){if(null!=S)return S;const e=document.createElement("invalidtype");S=A.Transition;for(const t in A)if(void 0!==e.style[t]){S=A[t];break}return S}let C=null;function _(e){return"".concat(function(){if(null!==C)return C;const{CSS:e}=window;return C=e&&e.supports&&e.supports("top: constant(safe-area-inset-top)")?"constant":"env",C}(),"(safe-area-inset-").concat(e,")")}function E(){return E=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{nativeEvent:{frame:t,insets:n}}=e;y((e=>!t||t.height===e.height&&t.width===e.width&&t.x===e.x&&t.y===e.y?e:t)),g((e=>e&&n.bottom===e.bottom&&n.left===e.left&&n.right===e.right&&n.top===e.top?e:n))}),[]);return d.createElement(x,E({style:[T.fill,c],onInsetsChange:b},u),null!=f?d.createElement(k.Provider,{value:m},d.createElement(R.Provider,{value:f},a)):null)}const T=b.c.create({fill:{flex:1}});const O="No safe area value available. Make sure you are rendering `` at the top of your app.";function j(){const e=d.useContext(R);if(null==e)throw new Error(O);return e}R.Consumer;const{width:P=0,height:B=0}=v.c.get("window"),L=(r.default.OS,{frame:{x:0,y:0,width:P,height:B},insets:{top:0,left:0,right:0,bottom:0}});function D(e){let{children:t,style:n}=e;return d.createElement(R.Consumer,null,(e=>e?d.createElement(p.c,{style:[M.container,n]},t):d.createElement(I,{initialMetrics:L,style:n},t)))}D.initialMetrics=L;const M=b.c.create({container:{flex:1}});var N;const U="__react_navigation__elements_contexts";function F(e,t){let r=n.g[U].get(e);return r||(r=d.createContext(t),r.displayName=e,n.g[U].set(e,r),r)}n.g[U]=null!==(N=n.g[U])&&void 0!==N?N:new Map;const H=F("HeaderShownContext",!1),G=d.createContext(!1),z=e=>{let{children:t}=e;return d.createElement(d.Fragment,null,t)},V=p.c,W=3,Q=4,Y=5,K=F("HeaderBackContext",void 0);function q(e,t){return"string"===typeof e.headerTitle?e.headerTitle:void 0!==e.title?e.title:t}var X=n(124),J=n(4592);const{add:Z}=X.default;function $(e){let{current:t,next:n}=e;const r=Z(t.progress.interpolate({inputRange:[0,1],outputRange:[0,1],extrapolate:"clamp"}),n?n.progress.interpolate({inputRange:[0,1],outputRange:[0,1],extrapolate:"clamp"}):0),o=r.interpolate({inputRange:[0,1,2],outputRange:[0,1,0]});return{leftButtonStyle:{opacity:o},rightButtonStyle:{opacity:o},titleStyle:{opacity:o},backgroundStyle:{opacity:r.interpolate({inputRange:[0,1,1.9,2],outputRange:[0,1,1,0]})}}}function ee(e){let{current:t,next:n,layouts:{screen:r}}=e;const o=[{translateX:Z(t.progress.interpolate({inputRange:[0,1],outputRange:[0,1],extrapolate:"clamp"}),n?n.progress.interpolate({inputRange:[0,1],outputRange:[0,1],extrapolate:"clamp"}):0).interpolate({inputRange:[0,1,2],outputRange:J.c.getConstants().isRTL?[-r.width,0,r.width]:[r.width,0,-r.width]})}];return{leftButtonStyle:{transform:o},rightButtonStyle:{transform:o},titleStyle:{transform:o},backgroundStyle:{transform:o}}}function te(e){let{current:t,next:n,layouts:{screen:r}}=e;const o=[{translateX:Z(t.progress.interpolate({inputRange:[0,1],outputRange:[0,1],extrapolate:"clamp"}),n?n.progress.interpolate({inputRange:[0,1],outputRange:[0,1],extrapolate:"clamp"}):0).interpolate({inputRange:[0,1,2],outputRange:J.c.getConstants().isRTL?[r.width,0,-r.width]:[-r.width,0,r.width]})}];return{leftButtonStyle:{transform:o},rightButtonStyle:{transform:o},titleStyle:{transform:o},backgroundStyle:{transform:o}}}function ne(e){let{current:t,next:n,layouts:{header:r}}=e;const o=[{translateY:Z(t.progress.interpolate({inputRange:[0,1],outputRange:[0,1],extrapolate:"clamp"}),n?n.progress.interpolate({inputRange:[0,1],outputRange:[0,1],extrapolate:"clamp"}):0).interpolate({inputRange:[0,1,2],outputRange:[-r.height,0,-r.height]})}];return{leftButtonStyle:{transform:o},rightButtonStyle:{transform:o},titleStyle:{transform:o},backgroundStyle:{transform:o}}}function re(){return{}}const oe={dark:!1,colors:{primary:"rgb(0, 122, 255)",background:"rgb(242, 242, 242)",card:"rgb(255, 255, 255)",text:"rgb(28, 28, 30)",border:"rgb(216, 216, 216)",notification:"rgb(255, 59, 48)"}},ie=d.createContext(oe);ie.displayName="ThemeContext";const ae=ie;function se(){return d.useContext(ae)}var le=n(8704);function ce(e){let{children:t}=e;return t}var ue=n(4914),de=n(9296);function he(){return he=Object.assign?Object.assign.bind():function(e){for(var t=1;t=21;function ge(e){let{onPressIn:t,onPressOut:n,android_ripple:r,pressColor:o,pressOpacity:i=.3,style:a,...s}=e;const{dark:l}=se(),[c]=d.useState((()=>new X.default.Value(1))),u=(e,t)=>{fe||X.default.timing(c,{toValue:e,duration:t,easing:de.c.inOut(de.c.quad),useNativeDriver:!0}).start()};return d.createElement(pe,he({onPressIn:e=>{u(i,0),null===t||void 0===t||t(e)},onPressOut:e=>{u(1,200),null===n||void 0===n||n(e)},android_ripple:fe?{color:void 0!==o?o:l?"rgba(255, 255, 255, .32)":"rgba(0, 0, 0, .32)",...r}:void 0,style:[{opacity:fe?1:c},a]},s))}function me(e){let{disabled:t,allowFontScaling:o,backImage:i,label:a,labelStyle:s,labelVisible:l="ios"===r.default.OS,onLabelLayout:c,onPress:u,pressColor:h,pressOpacity:f,screenLayout:g,tintColor:m,titleLayout:y,truncatedLabel:v="Back",accessibilityLabel:b=(a&&"Back"!==a?"".concat(a,", back"):"Go back"),testID:A,style:x}=e;const{colors:S}=se(),[w,C]=d.useState(void 0),_=void 0!==m?m:r.default.select({ios:S.primary,default:S.text}),E=e=>{null===c||void 0===c||c(e),C(e.nativeEvent.layout.x+e.nativeEvent.layout.width)};return d.createElement(ge,{disabled:t,accessible:!0,accessibilityRole:"button",accessibilityLabel:b,testID:A,onPress:t?void 0:()=>u&&requestAnimationFrame(u),pressColor:h,pressOpacity:f,android_ripple:ye,style:[ve.container,t&&ve.disabled,x],hitSlop:r.default.select({ios:void 0,default:{top:16,right:16,bottom:16,left:16}})},d.createElement(d.Fragment,null,i?i({tintColor:_}):d.createElement(le.c,{style:[ve.icon,Boolean(l)&&ve.iconWithLabel,Boolean(_)&&{tintColor:_}],source:n(3204),fadeDuration:0}),(()=>{const e=!a||w&&y&&g&&(g.width-y.width)/2=23,radius:20},ve=b.c.create({container:{alignItems:"center",flexDirection:"row",minWidth:b.c.hairlineWidth,...r.default.select({ios:null,default:{marginVertical:3,marginHorizontal:11}})},disabled:{opacity:.5},label:{fontSize:17,letterSpacing:.35},labelWrapper:{flexDirection:"row",alignItems:"flex-start"},icon:r.default.select({ios:{height:21,width:13,marginLeft:8,marginRight:22,marginVertical:12,resizeMode:"contain",transform:[{scaleX:J.c.getConstants().isRTL?-1:1}]},default:{height:24,width:24,margin:3,resizeMode:"contain",transform:[{scaleX:J.c.getConstants().isRTL?-1:1}]}}),iconWithLabel:"ios"===r.default.OS?{marginRight:6}:{},iconMaskContainer:{flex:1,flexDirection:"row",justifyContent:"center"},iconMaskFillerRect:{flex:1,backgroundColor:"#000"},iconMask:{height:21,width:13,marginLeft:-14.5,marginVertical:12,alignSelf:"center",resizeMode:"contain",transform:[{scaleX:J.c.getConstants().isRTL?-1:1}]}});function be(e,t,n){let o;const i=e.width>e.height;return o="ios"===r.default.OS?r.default.isPad||r.default.isTV?t?56:50:i?32:t?56:44:"android"===r.default.OS?56:64,o+n}function Ae(){return Ae=Object.assign?Object.assign.bind():function(e){for(var t=1;t50?t.top-5:t.top,{layout:a=n,modal:s=!1,title:l,headerTitle:c,headerTitleAlign:u=r.default.select({ios:"center",default:"left"}),headerLeft:h,headerLeftLabelVisible:f,headerTransparent:g,headerTintColor:m,headerBackground:y,headerRight:v,headerTitleAllowFontScaling:A,headerTitleStyle:x,headerLeftContainerStyle:S,headerRightContainerStyle:w,headerTitleContainerStyle:C,headerBackgroundContainerStyle:_,headerStyle:E,headerShadowVisible:R,headerPressColor:I,headerPressOpacity:T,headerStatusBarHeight:P=(o?0:i)}=e,B=be(a,s,P),{height:L=B,minHeight:D,maxHeight:M,backgroundColor:N,borderBottomColor:U,borderBottomEndRadius:F,borderBottomLeftRadius:G,borderBottomRightRadius:z,borderBottomStartRadius:V,borderBottomWidth:W,borderColor:Q,borderEndColor:Y,borderEndWidth:K,borderLeftColor:q,borderLeftWidth:J,borderRadius:Z,borderRightColor:$,borderRightWidth:ee,borderStartColor:te,borderStartWidth:ne,borderStyle:re,borderTopColor:oe,borderTopEndRadius:ie,borderTopLeftRadius:ae,borderTopRightRadius:se,borderTopStartRadius:le,borderTopWidth:ce,borderWidth:ue,boxShadow:de,elevation:he,shadowColor:pe,shadowOffset:fe,shadowOpacity:ge,shadowRadius:me,opacity:ye,transform:ve,...Ae}=b.c.flatten(E||{});const Se={backgroundColor:N,borderBottomColor:U,borderBottomEndRadius:F,borderBottomLeftRadius:G,borderBottomRightRadius:z,borderBottomStartRadius:V,borderBottomWidth:W,borderColor:Q,borderEndColor:Y,borderEndWidth:K,borderLeftColor:q,borderLeftWidth:J,borderRadius:Z,borderRightColor:$,borderRightWidth:ee,borderStartColor:te,borderStartWidth:ne,borderStyle:re,borderTopColor:oe,borderTopEndRadius:ie,borderTopLeftRadius:ae,borderTopRightRadius:se,borderTopStartRadius:le,borderTopWidth:ce,borderWidth:ue,boxShadow:de,elevation:he,shadowColor:pe,shadowOffset:fe,shadowOpacity:ge,shadowRadius:me,opacity:ye,transform:ve};for(const r in Se)void 0===Se[r]&&delete Se[r];const we=[Se,!1===R&&{elevation:0,shadowOpacity:0,borderBottomWidth:0}],_e=h?h({tintColor:m,pressColor:I,pressOpacity:T,labelVisible:f}):null,Ee=v?v({tintColor:m,pressColor:I,pressOpacity:T}):null,ke="function"!==typeof c?e=>d.createElement(xe,e):c;return d.createElement(d.Fragment,null,d.createElement(X.default.View,{pointerEvents:"box-none",style:[b.c.absoluteFill,{zIndex:0},_]},y?y({style:we}):g?null:d.createElement(Ce,{style:we})),d.createElement(X.default.View,{pointerEvents:"box-none",style:[{height:L,minHeight:D,maxHeight:M,opacity:ye,transform:ve}]},d.createElement(p.c,{pointerEvents:"none",style:{height:P}}),d.createElement(p.c,{pointerEvents:"box-none",style:Re.content},d.createElement(X.default.View,{pointerEvents:"box-none",style:[Re.left,"center"===u&&Re.expand,{marginStart:t.left},S]},_e),d.createElement(X.default.View,{pointerEvents:"box-none",style:[Re.title,{maxWidth:"center"===u?a.width-2*((_e?!1!==f?80:32:16)+Math.max(t.left,t.right)):a.width-((_e?72:16)+(Ee?72:16)+t.left-t.right)},C]},ke({children:l,allowFontScaling:A,tintColor:m,style:x})),d.createElement(X.default.View,{pointerEvents:"box-none",style:[Re.right,Re.expand,{marginEnd:t.right},w]},Ee))))}const Re=b.c.create({content:{flex:1,flexDirection:"row",alignItems:"stretch"},title:{marginHorizontal:16,justifyContent:"center"},left:{justifyContent:"center",alignItems:"flex-start"},right:{justifyContent:"center",alignItems:"flex-end"},expand:{flexGrow:1,flexBasis:0}});function ke(e){let t,n;return function(){let r=!1;for(var o=arguments.length,i=new Array(o),a=0;a{const{height:t,width:n}=e.nativeEvent.layout;i((e=>e&&t===e.height&&n===e.width?e:{height:t,width:n}))},s=e=>{const{height:r,width:o}=e.nativeEvent.layout;t&&r===t.height&&o===t.width||n({height:r,width:o})},l=ke(((e,t,n,r,o,i,a)=>e({current:{progress:n},next:r&&{progress:r},layouts:{header:{height:a,width:t.width},screen:t,title:o,leftLabel:i}}))),{progress:c,layout:u,modal:h,onGoBack:p,headerTitle:f,headerLeft:g=(p?e=>d.createElement(me,e):void 0),headerRight:m,headerBackImage:y,headerBackTitle:v,headerBackTitleVisible:A="ios"===r.default.OS,headerTruncatedBackTitle:x,headerBackAccessibilityLabel:S,headerBackTestID:w,headerBackAllowFontScaling:C,headerBackTitleStyle:_,headerTitleContainerStyle:E,headerLeftContainerStyle:R,headerRightContainerStyle:k,headerBackgroundContainerStyle:I,headerStyle:T,headerStatusBarHeight:O,styleInterpolator:j,...P}=e,B=be(u,h,O),{height:L=B}=b.c.flatten(T||{}),{titleStyle:D,leftButtonStyle:M,leftLabelStyle:N,rightButtonStyle:U,backgroundStyle:F}=l(j,u,c.current,c.next,o,v?t:void 0,"number"===typeof L?L:B),H=g?e=>g({...e,backImage:y,accessibilityLabel:S,testID:w,allowFontScaling:C,onPress:p,label:v,truncatedLabel:x,labelStyle:[N,_],onLabelLayout:s,screenLayout:u,titleLayout:o,canGoBack:Boolean(p)}):void 0,G=m?e=>m({...e,canGoBack:Boolean(p)}):void 0,z="function"!==typeof f?e=>d.createElement(xe,Ie({},e,{onLayout:a})):e=>f({...e,onLayout:a});return d.createElement(Ee,Ie({modal:h,layout:u,headerTitle:z,headerLeft:H,headerLeftLabelVisible:A,headerRight:G,headerTitleContainerStyle:[D,E],headerLeftContainerStyle:[M,R],headerRightContainerStyle:[U,k],headerBackgroundContainerStyle:[F,I],headerStyle:T,headerStatusBarHeight:O},P))}function Oe(){return Oe=Object.assign?Object.assign.bind():function(e){for(var t=1;t{n=void 0}),t)}}}((()=>{a.isFocused()&&a.canGoBack()&&a.dispatch({...f.ay.pop(),source:i.key})}),50),[a,i.key]),h=d.useContext(G),p=d.useContext(H),g=void 0!==o.headerStatusBarHeight?o.headerStatusBarHeight:h||p?0:l.top;return d.createElement(Te,Oe({},o,{title:q(o,i.name),progress:r,layout:n,modal:h,headerBackTitle:void 0!==o.headerBackTitle?o.headerBackTitle:c,headerStatusBarHeight:g,onGoBack:t?u:void 0,styleInterpolator:s}))}));function Pe(e){let{mode:t,scenes:n,layout:r,getPreviousScene:o,getFocusedRoute:i,onContentHeightChange:a,style:s}=e;const l=i(),c=d.useContext(K);return d.createElement(X.default.View,{pointerEvents:"box-none",style:s},n.slice(-3).map(((e,n,i)=>{var s,u;if("screen"===t&&n!==i.length-1||!e)return null;const{header:h,headerMode:g,headerShown:m=!0,headerTransparent:y,headerStyleInterpolator:v}=e.descriptor.options;if(g!==t||!m)return null;const b=l.key===e.descriptor.route.key,A=o({route:e.descriptor.route});let x=c;if(A){const{options:e,route:t}=A.descriptor;x=A?{title:q(e,t.name)}:c}const S=null===(s=i[n-1])||void 0===s?void 0:s.descriptor,w=null===(u=i[n+1])||void 0===u?void 0:u.descriptor,{headerShown:C=!0,headerMode:_}=(null===S||void 0===S?void 0:S.options)||{},E=i.slice(n+1).find((e=>{const{headerShown:t=!0,headerMode:n}=(null===e||void 0===e?void 0:e.descriptor.options)||{};return!1===t||"screen"===n})),{gestureDirection:R}=(null===E||void 0===E?void 0:E.descriptor.options)||{},k=(!1===C||"screen"===_)&&!w||E,I={layout:r,back:x,progress:e.progress,options:e.descriptor.options,route:e.descriptor.route,navigation:e.descriptor.navigation,styleInterpolator:"float"===t?k?"vertical"===R||"vertical-inverted"===R?ne:"horizontal-inverted"===R?te:ee:v:re};return d.createElement(f.AH.Provider,{key:e.descriptor.route.key,value:e.descriptor.navigation},d.createElement(f._2.Provider,{value:e.descriptor.route},d.createElement(p.c,{onLayout:a?t=>{const{height:n}=t.nativeEvent.layout;a({route:e.descriptor.route,height:n})}:void 0,pointerEvents:b?"box-none":"none",accessibilityElementsHidden:!b,importantForAccessibility:b?"auto":"no-hide-descendants",style:"float"===t&&!b||y?Be.header:null},void 0!==h?h(I):d.createElement(je,I))))})))}const Be=b.c.create({header:{position:"absolute",top:0,left:0,right:0}});function Le(){return Le=Object.assign?Object.assign.bind():function(e){for(var t=1;t20,c=a.width>a.height,u=c?0:10,d=s.top,h=a.height/a.width,p=Ge(n.progress.interpolate({inputRange:[0,1],outputRange:[0,1],extrapolate:"clamp"}),o?o.progress.interpolate({inputRange:[0,1],outputRange:[0,1],extrapolate:"clamp"}):0),f=0===t,g=ze(p.interpolate({inputRange:[0,1,2],outputRange:[a.height,f?0:u,(f?d:0)-u*h]}),i),m=p.interpolate({inputRange:[0,1,1.0001,2],outputRange:[0,.3,1,1]}),y=c?1:p.interpolate({inputRange:[0,1,2],outputRange:[1,1,a.width?1-2*u/a.width:1]}),v=c?0:f?p.interpolate({inputRange:[0,1,1.0001,2],outputRange:[0,0,l?38:0,10]}):10;return{cardStyle:{overflow:"hidden",borderTopLeftRadius:v,borderTopRightRadius:v,borderBottomLeftRadius:l?v:0,borderBottomRightRadius:l?v:0,marginTop:f?0:d,marginBottom:f?0:u,transform:[{translateY:g},{scale:y}]},overlayStyle:{opacity:m}}}function We(){return{}}const Qe={animation:"spring",config:{stiffness:1e3,damping:500,mass:3,overshootClamping:!0,restDisplacementThreshold:10,restSpeedThreshold:10}},Ye={animation:"timing",config:{duration:350,easing:de.c.out(de.c.poly(5))}},Ke={animation:"timing",config:{duration:150,easing:de.c.in(de.c.linear)}},qe={animation:"timing",config:{duration:425,easing:de.c.bezier(.35,.45,0,1)}},Xe={animation:"timing",config:{duration:400,easing:de.c.bezier(.35,.45,0,1)}},Je={animation:"timing",config:{duration:250,easing:e=>Math.cos((e+1)*Math.PI)/2+.5}},Ze={animation:"timing",config:{duration:200,easing:e=>1===e?1:Math.pow(e,2)}},$e={gestureDirection:"horizontal",transitionSpec:{open:Qe,close:Qe},cardStyleInterpolator:function(e){let{current:t,next:n,inverted:r,layouts:{screen:o}}=e;return{cardStyle:{transform:[{translateX:ze(t.progress.interpolate({inputRange:[0,1],outputRange:[o.width,0],extrapolate:"clamp"}),r)},{translateX:n?ze(n.progress.interpolate({inputRange:[0,1],outputRange:[0,-.3*o.width],extrapolate:"clamp"}),r):0}]},overlayStyle:{opacity:t.progress.interpolate({inputRange:[0,1],outputRange:[0,.07],extrapolate:"clamp"})},shadowStyle:{shadowOpacity:t.progress.interpolate({inputRange:[0,1],outputRange:[0,.3],extrapolate:"clamp"})}}},headerStyleInterpolator:$},et={gestureDirection:"vertical",transitionSpec:{open:Qe,close:Qe},cardStyleInterpolator:Ve,headerStyleInterpolator:$},tt={gestureDirection:"vertical",transitionSpec:{open:Ye,close:Ke},cardStyleInterpolator:function(e){let{current:t,inverted:n,layouts:{screen:r},closing:o}=e;const i=ze(t.progress.interpolate({inputRange:[0,1],outputRange:[.08*r.height,0],extrapolate:"clamp"}),n);return{cardStyle:{opacity:He(o,t.progress,t.progress.interpolate({inputRange:[0,.5,.9,1],outputRange:[0,.25,.7,1],extrapolate:"clamp"})),transform:[{translateY:i}]}}},headerStyleInterpolator:$},nt={gestureDirection:"vertical",transitionSpec:{open:qe,close:qe},cardStyleInterpolator:function(e){let{current:t,next:n,inverted:r,layouts:{screen:o}}=e;return{containerStyle:{overflow:"hidden",transform:[{translateY:ze(t.progress.interpolate({inputRange:[0,1],outputRange:[o.height,0],extrapolate:"clamp"}),r)}]},cardStyle:{transform:[{translateY:ze(t.progress.interpolate({inputRange:[0,1],outputRange:[o.height*(95.9/100)*-1,0],extrapolate:"clamp"}),r)},{translateY:n?ze(n.progress.interpolate({inputRange:[0,1],outputRange:[0,.02*o.height*-1],extrapolate:"clamp"}),r):0}]},overlayStyle:{opacity:t.progress.interpolate({inputRange:[0,.36,1],outputRange:[0,.1,.1],extrapolate:"clamp"})}}},headerStyleInterpolator:$},rt={gestureDirection:"horizontal",transitionSpec:{open:Xe,close:Xe},cardStyleInterpolator:function(e){let{current:t,next:n,closing:r}=e;const o=Ge(t.progress.interpolate({inputRange:[0,1],outputRange:[0,1],extrapolate:"clamp"}),n?n.progress.interpolate({inputRange:[0,1],outputRange:[0,1],extrapolate:"clamp"}):0);return{cardStyle:{opacity:o.interpolate({inputRange:[0,.75,.875,1,1.0825,1.2075,2],outputRange:[0,0,1,1,1,1,0]}),transform:[{scale:He(r,t.progress.interpolate({inputRange:[0,1],outputRange:[.925,1],extrapolate:"clamp"}),o.interpolate({inputRange:[0,1,2],outputRange:[.85,1,1.075]}))}]}}},headerStyleInterpolator:$},ot={gestureDirection:"vertical",transitionSpec:{open:Je,close:Ze},cardStyleInterpolator:function(e){let{current:t,inverted:n,layouts:{screen:r},closing:o}=e;const i=ze(t.progress.interpolate({inputRange:[0,1],outputRange:[.8*r.height,0],extrapolate:"clamp"}),n);return{cardStyle:{opacity:He(o,t.progress,t.progress.interpolate({inputRange:[0,1],outputRange:[0,1],extrapolate:"clamp"})),transform:[{translateY:i}]},overlayStyle:{opacity:t.progress.interpolate({inputRange:[0,1],outputRange:[0,.3],extrapolate:"clamp"})}}},headerStyleInterpolator:$},it={gestureDirection:"vertical",transitionSpec:{open:Je,close:Ze},cardStyleInterpolator:function(e){let{current:{progress:t}}=e;return{cardStyle:{opacity:t.interpolate({inputRange:[0,.5,.9,1],outputRange:[0,.25,.7,1]})},overlayStyle:{opacity:t.interpolate({inputRange:[0,1],outputRange:[0,.5],extrapolate:"clamp"})}}},headerStyleInterpolator:$},at=r.default.select({ios:$e,android:r.default.Version>=29?rt:r.default.Version>=28?nt:tt,default:rt}),st=r.default.select({ios:et,default:ot});function lt(e,t){for(var n=e.length-1;n>=0;n--)if(t(e[n]))return n;return-1}function ct(e){switch(e){case"vertical":return 1;case"vertical-inverted":return-1;case"horizontal":return J.c.getConstants().isRTL?-1:1;case"horizontal-inverted":return J.c.getConstants().isRTL?1:-1}}function ut(e,t){const n=ct(t);switch(t){case"vertical":case"vertical-inverted":return e.height*n;case"horizontal":case"horizontal-inverted":return e.width*n}}function dt(){return dt=Object.assign?Object.assign.bind():function(e){for(var t=1;t{let{enabled:t,...n}=e;return null!=ht?d.createElement(ht.ScreenContainer,dt({enabled:t},n)):d.createElement(p.c,n)},ft=e=>{let{enabled:t,active:n,...r}=e;return null!=ht?d.createElement(ht.Screen,dt({enabled:t,activityState:n},r)):d.createElement(p.c,r)};var gt=n(5748);const mt=d.createContext(void 0);function yt(e){var t,n;let{dark:r,layout:o,insets:a,style:s}=e;const{dark:l}=se(),[c,u]=d.useState(!0),h=1-20/o.width,p=(a.top-34)*h,f=b.c.flatten(s),g=null===f||void 0===f||null===(t=f.transform)||void 0===t||null===(n=t.find((e=>void 0!==e.translateY)))||void 0===n?void 0:n.translateY;d.useEffect((()=>{const e=null===g||void 0===g?void 0:g.addListener((e=>{let{value:t}=e;u(tnull===g||void 0===g?void 0:g.removeListener(e)}),[p,g]);const m=null!==r&&void 0!==r?r:!l;return d.createElement(i.c,{animated:!0,barStyle:c&&m?"dark-content":"light-content"})}function vt(){return vt=Object.assign?Object.assign.bind():function(e){for(var t=1;t({setPointerEvents:c}))),d.useEffect((()=>{if("undefined"===typeof document||!document.body)return;const e=document.body.clientWidth,t=document.body.clientHeight;s(e===r.width&&t===r.height)}),[r.height,r.width]),d.createElement(p.c,vt({},i,{pointerEvents:l,style:[n&&a?At.page:At.card,o]}))})),At=b.c.create({page:{minHeight:"100%"},card:{flex:1,overflow:"hidden"}});function xt(){return xt=Object.assign?Object.assign.bind():function(e){for(var t=1;t{if(e){return null!=b.c.flatten(e).opacity}return!1};class Ct extends d.Component{constructor(){super(...arguments),(0,y.c)(this,"isCurrentlyMounted",!1),(0,y.c)(this,"isClosing",new X.default.Value(0)),(0,y.c)(this,"inverted",new X.default.Value(ct(this.props.gestureDirection))),(0,y.c)(this,"layout",{width:new X.default.Value(this.props.layout.width),height:new X.default.Value(this.props.layout.height)}),(0,y.c)(this,"isSwiping",new X.default.Value(0)),(0,y.c)(this,"animate",(e=>{let{closing:t,velocity:n}=e;const{gesture:r,transitionSpec:o,onOpen:i,onClose:a,onTransition:s}=this.props,l=this.getAnimateToValue({...this.props,closing:t});this.lastToValue=l,this.isClosing.setValue(t?1:0);const c=t?o.close:o.open,u="spring"===c.animation?X.default.spring:X.default.timing;this.setPointerEventsEnabled(!t),this.handleStartInteraction(),clearTimeout(this.pendingGestureCallback),null===s||void 0===s||s({closing:t,gesture:void 0!==n}),u(r,{...c.config,velocity:n,toValue:l,useNativeDriver:St,isInteraction:!1}).start((e=>{let{finished:n}=e;this.handleEndInteraction(),clearTimeout(this.pendingGestureCallback),n&&(t?a():i(),this.isCurrentlyMounted&&this.forceUpdate())}))})),(0,y.c)(this,"getAnimateToValue",(e=>{let{closing:t,layout:n,gestureDirection:r}=e;return t?ut(n,r):0})),(0,y.c)(this,"setPointerEventsEnabled",(e=>{var t;const n=e?"box-none":"none";null===(t=this.ref.current)||void 0===t||t.setPointerEvents(n)})),(0,y.c)(this,"handleStartInteraction",(()=>{void 0===this.interactionHandle&&(this.interactionHandle=gt.c.createInteractionHandle())})),(0,y.c)(this,"handleEndInteraction",(()=>{void 0!==this.interactionHandle&&(gt.c.clearInteractionHandle(this.interactionHandle),this.interactionHandle=void 0)})),(0,y.c)(this,"handleGestureStateChange",(e=>{let{nativeEvent:t}=e;const{layout:n,onClose:r,onGestureBegin:o,onGestureCanceled:i,onGestureEnd:a,gestureDirection:s,gestureVelocityImpact:l}=this.props;switch(t.state){case Q:this.isSwiping.setValue(1),this.handleStartInteraction(),null===o||void 0===o||o();break;case W:{this.isSwiping.setValue(0),this.handleEndInteraction();const e="vertical"===s||"vertical-inverted"===s?t.velocityY:t.velocityX;this.animate({closing:this.props.closing,velocity:e}),null===i||void 0===i||i();break}case Y:{let e,o,i;this.isSwiping.setValue(0),"vertical"===s||"vertical-inverted"===s?(e=n.height,o=t.translationY,i=t.velocityY):(e=n.width,o=t.translationX,i=t.velocityX);const c=(o+i*l)*ct(s)>e/2?0!==i||0!==o:this.props.closing;this.animate({closing:c,velocity:i}),c&&(this.pendingGestureCallback=setTimeout((()=>{r(),this.forceUpdate()}),32)),null===a||void 0===a||a();break}}})),(0,y.c)(this,"getInterpolatedStyle",ke(((e,t)=>e(t)))),(0,y.c)(this,"getCardAnimation",ke(((e,t,n,r,o,i,a,s)=>({index:e,current:{progress:t},next:n&&{progress:n},closing:this.isClosing,swiping:this.isSwiping,inverted:this.inverted,layouts:{screen:r},insets:{top:o,right:i,bottom:a,left:s}})))),(0,y.c)(this,"ref",d.createRef())}componentDidMount(){this.animate({closing:this.props.closing}),this.isCurrentlyMounted=!0}componentDidUpdate(e){const{layout:t,gestureDirection:n,closing:r}=this.props,{width:o,height:i}=t;o!==e.layout.width&&this.layout.width.setValue(o),i!==e.layout.height&&this.layout.height.setValue(i),n!==e.gestureDirection&&this.inverted.setValue(ct(n));const a=this.getAnimateToValue(this.props);this.getAnimateToValue(e)===a&&this.lastToValue===a||this.animate({closing:r})}componentWillUnmount(){this.props.gesture.stopAnimation(),this.isCurrentlyMounted=!1,this.handleEndInteraction()}gestureActivationCriteria(){const{layout:e,gestureDirection:t,gestureResponseDistance:n}=this.props,r=!0,o=void 0!==n?n:"vertical"===t||"vertical-inverted"===t?135:50;if("vertical"===t)return{maxDeltaX:15,minOffsetY:5,hitSlop:{bottom:-e.height+o},enableTrackpadTwoFingerGesture:r};if("vertical-inverted"===t)return{maxDeltaX:15,minOffsetY:-5,hitSlop:{top:-e.height+o},enableTrackpadTwoFingerGesture:r};{const n=-e.width+o;return 1===ct(t)?{minOffsetX:5,maxDeltaY:20,hitSlop:{right:n},enableTrackpadTwoFingerGesture:r}:{minOffsetX:-5,maxDeltaY:20,hitSlop:{left:n},enableTrackpadTwoFingerGesture:r}}}render(){const{styleInterpolator:e,interpolationIndex:t,current:n,gesture:o,next:i,layout:a,insets:s,overlay:l,overlayEnabled:c,shadowEnabled:u,gestureEnabled:h,gestureDirection:f,pageOverflowEnabled:g,headerDarkContent:m,children:y,containerStyle:v,contentStyle:A,...x}=this.props,S=this.getCardAnimation(t,n,i,a,s.top,s.right,s.bottom,s.left),w=this.getInterpolatedStyle(e,S),{containerStyle:C,cardStyle:_,overlayStyle:E,shadowStyle:R}=w,k=h?X.default.event([{nativeEvent:"vertical"===f||"vertical-inverted"===f?{translationY:o}:{translationX:o}}],{useNativeDriver:St}):void 0,{backgroundColor:I}=b.c.flatten(A||{}),T="string"===typeof I&&0===Ne()(I).alpha();return d.createElement(mt.Provider,{value:S},"ios"===r.default.OS&&c&&i&&_t(e)?d.createElement(yt,{dark:m,layout:a,insets:s,style:_}):null,d.createElement(X.default.View,{style:{opacity:n},collapsable:!1}),d.createElement(p.c,xt({pointerEvents:"box-none",collapsable:!1},x),c?d.createElement(p.c,{pointerEvents:"box-none",style:b.c.absoluteFill},l({style:E})):null,d.createElement(X.default.View,{style:[Et.container,C,v],pointerEvents:"box-none"},d.createElement(z,xt({enabled:0!==a.width&&h,onGestureEvent:k,onHandlerStateChange:this.handleGestureStateChange},this.gestureActivationCriteria()),d.createElement(X.default.View,{needsOffscreenAlphaCompositing:wt(_),style:[Et.container,_]},u&&R&&!T?d.createElement(X.default.View,{style:[Et.shadow,"horizontal"===f?[Et.shadowHorizontal,Et.shadowLeft]:"horizontal-inverted"===f?[Et.shadowHorizontal,Et.shadowRight]:"vertical"===f?[Et.shadowVertical,Et.shadowTop]:[Et.shadowVertical,Et.shadowBottom],{backgroundColor:I},R],pointerEvents:"none"}):null,d.createElement(bt,{ref:this.ref,enabled:g,layout:a,style:A},y))))))}}(0,y.c)(Ct,"defaultProps",{shadowEnabled:!1,gestureEnabled:!0,gestureVelocityImpact:.3,overlay:e=>{let{style:t}=e;return t?d.createElement(X.default.View,{pointerEvents:"none",style:[Et.overlay,t]}):null}});const _t=e=>e===Ve||"forModalPresentationIOS"===e.name,Et=b.c.create({container:{flex:1},overlay:{flex:1,backgroundColor:"#000"},shadow:{position:"absolute",shadowRadius:5,shadowColor:"#000",shadowOpacity:.3},shadowHorizontal:{top:0,bottom:0,width:3,shadowOffset:{width:-1,height:1}},shadowLeft:{left:0},shadowRight:{right:0},shadowVertical:{left:0,right:0,height:3,shadowOffset:{width:1,height:-1}},shadowTop:{top:0},shadowBottom:{bottom:0}}),Rt=F("HeaderHeightContext",void 0);var kt=n(9984),It=n(3168);function Tt(e){let{interpolationIndex:t,index:n,active:r,closing:o,gesture:i,focused:a,modal:s,getPreviousScene:l,getFocusedRoute:c,headerDarkContent:u,hasAbsoluteFloatHeader:h,headerHeight:f,onHeaderHeightChange:g,isParentHeaderShown:m,isNextScreenTransparent:y,detachCurrentScreen:v,layout:A,onCloseRoute:x,onOpenRoute:S,onGestureCancel:w,onGestureEnd:C,onGestureStart:_,onTransitionEnd:E,onTransitionStart:R,renderHeader:k,renderScene:I,safeAreaInsetBottom:T,safeAreaInsetLeft:O,safeAreaInsetRight:j,safeAreaInsetTop:P,scene:B}=e;const L=d.useContext(Rt),{onPageChangeStart:D,onPageChangeCancel:M,onPageChangeConfirm:N}=function(e){const t=d.useRef(void 0),n=d.useRef(0),r=d.useRef(),o=d.useCallback((()=>{void 0!==r.current&&(clearTimeout(r.current),r.current=void 0)}),[]),i=d.useCallback((()=>{if(!e())return;o();const r=kt.c.State.currentlyFocusedInput();null===r||void 0===r||r.blur(),t.current=r,n.current=Date.now()}),[o,e]),a=d.useCallback((n=>{if(e()){if(o(),n)It.c.dismiss();else{const e=t.current;null===e||void 0===e||e.blur()}t.current=void 0}}),[o,e]),s=d.useCallback((()=>{if(!e())return;o();const i=t.current;i&&(Date.now()-n.current<100?r.current=setTimeout((()=>{null===i||void 0===i||i.focus(),t.current=void 0}),100):(null===i||void 0===i||i.focus(),t.current=void 0))}),[o,e]);return d.useEffect((()=>()=>o()),[o]),{onPageChangeStart:i,onPageChangeConfirm:a,onPageChangeCancel:s}}(d.useCallback((()=>{const{options:e,navigation:t}=B.descriptor;return t.isFocused()&&!1!==e.keyboardHandlingEnabled}),[B.descriptor])),U={top:P,right:j,bottom:T,left:O},{colors:F}=se(),[z,V]=d.useState("box-none");d.useEffect((()=>{var e,t;const n=null===(e=B.progress.next)||void 0===e||null===(t=e.addListener)||void 0===t?void 0:t.call(e,(e=>{let{value:t}=e;V(t<=.1?"box-none":"none")}));return()=>{var e,t;n&&(null===(e=B.progress.next)||void 0===e||null===(t=e.removeListener)||void 0===t||t.call(e,n))}}),[z,B.progress.next]);const{presentation:W,animationEnabled:Q,cardOverlay:Y,cardOverlayEnabled:X,cardShadowEnabled:J,cardStyle:Z,cardStyleInterpolator:$,gestureDirection:ee,gestureEnabled:te,gestureResponseDistance:ne,gestureVelocityImpact:re,headerMode:oe,headerShown:ie,transitionSpec:ae}=B.descriptor.options,le=l({route:B.descriptor.route});let ce;if(le){const{options:e,route:t}=le.descriptor;ce=q(e,t.name)}const ue=d.useMemo((()=>void 0!==ce?{title:ce}:void 0),[ce]);return d.createElement(Ct,{interpolationIndex:t,gestureDirection:ee,layout:A,insets:U,gesture:i,current:B.progress.current,next:B.progress.next,closing:o,onOpen:()=>{const{route:e}=B.descriptor;E({route:e},!1),S({route:e})},onClose:()=>{const{route:e}=B.descriptor;E({route:e},!0),x({route:e})},overlay:Y,overlayEnabled:X,shadowEnabled:J,onTransition:e=>{let{closing:t,gesture:n}=e;const{route:o}=B.descriptor;n?r&&t?null===N||void 0===N||N(!1):null===M||void 0===M||M():null===N||void 0===N||N(!0),null===R||void 0===R||R({route:o},t)},onGestureBegin:()=>{const{route:e}=B.descriptor;D(),_({route:e})},onGestureCanceled:()=>{const{route:e}=B.descriptor;M(),w({route:e})},onGestureEnd:()=>{const{route:e}=B.descriptor;C({route:e})},gestureEnabled:0!==n&&te,gestureResponseDistance:ne,gestureVelocityImpact:re,transitionSpec:ae,styleInterpolator:$,accessibilityElementsHidden:!a,importantForAccessibility:a?"auto":"no-hide-descendants",pointerEvents:r?"box-none":z,pageOverflowEnabled:"float"!==oe&&"modal"!==W,headerDarkContent:u,containerStyle:h&&"screen"!==oe?{marginTop:f}:null,contentStyle:[{backgroundColor:"transparentModal"===W?"transparent":F.background},Z],style:[{overflow:r?void 0:"hidden",display:!1!==Q||!1!==y||!1===v||a?"flex":"none"},b.c.absoluteFill]},d.createElement(p.c,{style:jt.container},d.createElement(G.Provider,{value:s},d.createElement(p.c,{style:jt.scene},d.createElement(K.Provider,{value:ue},d.createElement(H.Provider,{value:m||!1!==ie},d.createElement(Rt.Provider,{value:ie?f:null!==L&&void 0!==L?L:0},I({route:B.descriptor.route}))))),"float"!==oe?k({mode:"screen",layout:A,scenes:[le,B],getPreviousScene:l,getFocusedRoute:c,onContentHeightChange:g}):null)))}const Ot=d.memo(Tt),jt=b.c.create({container:{flex:1,flexDirection:"column-reverse"},scene:{flex:1}}),Pt=Object.freeze({options:{}}),Bt=(e,t)=>{const{cardStyleInterpolator:n}=e[t].descriptor.options;let r=0;for(let i=t-1;i>=0;i--){var o;if((null===(o=e[i])||void 0===o?void 0:o.descriptor.options.cardStyleInterpolator)!==n)break;r++}return r},Lt=(e,t,n)=>{if(n)return!0;const{cardStyleInterpolator:r}=e.descriptor.options;return _t(r)&&0!==t},Dt=(e,t,n,r,o,i)=>e.reduce(((a,s,l)=>{const{headerStatusBarHeight:c=(n?0:t.top),headerStyle:u}=s.descriptor.options,d=b.c.flatten(u||{}),h="height"in d&&"number"===typeof d.height?d.height:i[s.route.key],p=Bt(e,l),f=Lt(s,p,r);return a[s.route.key]="number"===typeof h?h:be(o,f,c),a}),{}),Mt=(e,t)=>{const{presentation:n,gestureDirection:r=("modal"===n?st.gestureDirection:at.gestureDirection)}=(null===t||void 0===t?void 0:t.options)||{};return ut(e,r)},Nt=(e,t,n)=>{const r=Mt({width:Math.max(1,t.width),height:Math.max(1,t.height)},n);return r>0?e.interpolate({inputRange:[0,r],outputRange:[1,0]}):e.interpolate({inputRange:[r,0],outputRange:[0,1]})};class Ut extends d.Component{static getDerivedStateFromProps(e,t){if(e.routes===t.routes&&e.descriptors===t.descriptors)return null;const n=e.routes.reduce(((n,r)=>{const o=e.descriptors[r.key],{animationEnabled:i}=(null===o||void 0===o?void 0:o.options)||{};return n[r.key]=t.gestures[r.key]||new X.default.Value(e.openingRouteKeys.includes(r.key)&&!1!==i?Mt(t.layout,o):0),n}),{}),o=e.routes.map(((o,i,a)=>{var s;const l=a[i-1],c=a[i+1],u=t.scenes[i],d=n[o.key],h=l?n[l.key]:void 0,p=c?n[c.key]:void 0,f=e.descriptors[o.key]||t.descriptors[o.key]||(u?u.descriptor:Pt),g=e.descriptors[null===c||void 0===c?void 0:c.key]||t.descriptors[null===c||void 0===c?void 0:c.key],m=e.descriptors[null===l||void 0===l?void 0:l.key]||t.descriptors[null===l||void 0===l?void 0:l.key],y=i!==a.length-1&&g&&"transparentModal"!==g.options.presentation?g.options:f.options;let v="modal"===y.presentation?st:"transparentModal"===y.presentation?it:at;const{animationEnabled:b="web"!==r.default.OS&&"windows"!==r.default.OS&&"macos"!==r.default.OS,gestureEnabled:A="ios"===r.default.OS&&b,gestureDirection:x=v.gestureDirection,transitionSpec:S=v.transitionSpec,cardStyleInterpolator:w=(!1===b?We:v.cardStyleInterpolator),headerStyleInterpolator:C=v.headerStyleInterpolator,cardOverlayEnabled:_="ios"!==r.default.OS&&"transparentModal"!==y.presentation||_t(w)}=y,E=null!==(s=f.options.headerMode)&&void 0!==s?s:"modal"===y.presentation||"transparentModal"===y.presentation||"modal"===(null===g||void 0===g?void 0:g.options.presentation)||"transparentModal"===(null===g||void 0===g?void 0:g.options.presentation)||_t(w)||"ios"!==r.default.OS||void 0!==f.options.header?"screen":"float",R={route:o,descriptor:{...f,options:{...f.options,animationEnabled:b,cardOverlayEnabled:_,cardStyleInterpolator:w,gestureDirection:x,gestureEnabled:A,headerStyleInterpolator:C,transitionSpec:S,headerMode:E}},progress:{current:Nt(d,t.layout,f),next:p&&"transparentModal"!==(null===g||void 0===g?void 0:g.options.presentation)?Nt(p,t.layout,g):void 0,previous:h?Nt(h,t.layout,m):void 0},__memo:[t.layout,f,g,m,d,p,h]};return u&&R.__memo.every(((e,t)=>u.__memo[t]===e))?u:R}));return{routes:e.routes,scenes:o,gestures:n,descriptors:e.descriptors,headerHeights:Dt(o,e.insets,e.isParentHeaderShown,e.isParentModal,t.layout,t.headerHeights)}}constructor(e){super(e),(0,y.c)(this,"handleLayout",(e=>{const{height:t,width:n}=e.nativeEvent.layout,r={width:n,height:t};this.setState(((e,o)=>t===e.layout.height&&n===e.layout.width?null:{layout:r,headerHeights:Dt(e.scenes,o.insets,o.isParentHeaderShown,o.isParentModal,r,e.headerHeights)}))})),(0,y.c)(this,"handleHeaderLayout",(e=>{let{route:t,height:n}=e;this.setState((e=>{let{headerHeights:r}=e;return r[t.key]===n?null:{headerHeights:{...r,[t.key]:n}}}))})),(0,y.c)(this,"getFocusedRoute",(()=>{const{state:e}=this.props;return e.routes[e.index]})),(0,y.c)(this,"getPreviousScene",(e=>{let{route:t}=e;const{getPreviousRoute:n}=this.props,{scenes:r}=this.state,o=n({route:t});if(o){return r.find((e=>e.descriptor.route.key===o.key))}})),this.state={routes:[],scenes:[],gestures:{},layout:D.initialMetrics.frame,descriptors:this.props.descriptors,headerHeights:{}}}render(){const{insets:e,state:t,routes:n,closingRouteKeys:o,onOpenRoute:i,onCloseRoute:a,renderHeader:s,renderScene:l,isParentHeaderShown:c,isParentModal:u,onTransitionStart:h,onTransitionEnd:p,onGestureStart:f,onGestureEnd:g,onGestureCancel:m,detachInactiveScreens:y="web"===r.default.OS||"android"===r.default.OS||"ios"===r.default.OS}=this.props,{scenes:v,layout:A,gestures:x,headerHeights:S}=this.state,w=t.routes[t.index],C=S[w.key],_=this.state.scenes.slice(-2).some((e=>{var t;const n=null!==(t=e.descriptor.options)&&void 0!==t?t:{},{headerMode:r,headerTransparent:o,headerShown:i=!0}=n;return!(!o&&!1!==i&&"screen"!==r)}));let E=1;for(let r=v.length-1;r>=0;r--){const{options:e}=v[r].descriptor,{detachPreviousScreen:t="transparentModal"!==e.presentation&&(!_t(e.cardStyleInterpolator)||r!==lt(v,(e=>{const{cardStyleInterpolator:t}=e.descriptor.options;return t===Ve||"forModalPresentationIOS"===(null===t||void 0===t?void 0:t.name)})))}=e;if(!1===t)E++;else if(r<=v.length-2)break}const R=d.createElement(d.Fragment,{key:"header"},s({mode:"float",layout:A,scenes:v,getPreviousScene:this.getPreviousScene,getFocusedRoute:this.getFocusedRoute,onContentHeightChange:this.handleHeaderLayout,style:[Ft.floating,_&&[{height:C},Ft.absolute]]}));return d.createElement(De,null,_?null:R,d.createElement(pt,{enabled:y,style:Ft.container,onLayout:this.handleLayout},n.map(((t,n,r)=>{var C,R;const k=w.key===t.key,I=x[t.key],T=v[n];let O=1;if(n=r.length-E?1:0;O=e?e.progress.current.interpolate({inputRange:[0,.99999,1],outputRange:[1,1,t],extrapolate:"clamp"}):1}const{headerShown:j=!0,headerTransparent:P,headerStyle:B,headerTintColor:L,freezeOnBlur:D}=T.descriptor.options,M=e.top,N=e.right,U=e.bottom,F=e.left,H=!1!==j?S[t.key]:0;let G;if(j)if("string"===typeof L)G=Ne()(L).isDark();else{const e=b.c.flatten(B);e&&"backgroundColor"in e&&"string"===typeof e.backgroundColor&&(G=!Ne()(e.backgroundColor).isDark())}const z=Bt(v,n),V=Lt(T,z,u),W="transparentModal"===(null===(C=v[n+1])||void 0===C?void 0:C.descriptor.options.presentation),Q=!1!==(null===(R=v[n+1])||void 0===R?void 0:R.descriptor.options.detachPreviousScreen);return d.createElement(ft,{key:t.key,style:b.c.absoluteFill,enabled:y,active:O,freezeOnBlur:D,pointerEvents:"box-none"},d.createElement(Ot,{index:n,interpolationIndex:z,modal:V,active:n===r.length-1,focused:k,closing:o.includes(t.key),layout:A,gesture:I,scene:T,safeAreaInsetTop:M,safeAreaInsetRight:N,safeAreaInsetBottom:U,safeAreaInsetLeft:F,onGestureStart:f,onGestureCancel:m,onGestureEnd:g,headerHeight:H,isParentHeaderShown:c,onHeaderHeightChange:this.handleHeaderLayout,getPreviousScene:this.getPreviousScene,getFocusedRoute:this.getFocusedRoute,headerDarkContent:G,hasAbsoluteFloatHeader:_&&!P,renderHeader:s,renderScene:l,onOpenRoute:i,onCloseRoute:a,onTransitionStart:h,onTransitionEnd:p,isNextScreenTransparent:W,detachCurrentScreen:Q}))}))),_?R:null)}}const Ft=b.c.create({container:{flex:1},absolute:{position:"absolute",top:0,left:0,right:0},floating:{zIndex:1}});function Ht(){return Ht=Object.assign?Object.assign.bind():function(e){for(var t=1;t{let{route:t}=e;const{closingRouteKeys:n,replacingRouteKeys:r}=this.state,o=this.state.routes.filter((e=>e.key===t.key||!n.includes(e.key)&&!r.includes(e.key))),i=o.findIndex((e=>e.key===t.key));return o[i-1]})),(0,y.c)(this,"renderScene",(e=>{let{route:t}=e;const n=this.state.descriptors[t.key]||this.props.descriptors[t.key];return n?n.render():null})),(0,y.c)(this,"renderHeader",(e=>d.createElement(Pe,e))),(0,y.c)(this,"handleOpenRoute",(e=>{let{route:t}=e;const{state:n,navigation:r}=this.props,{closingRouteKeys:o,replacingRouteKeys:i}=this.state;o.some((e=>e===t.key))&&i.every((e=>e!==t.key))&&n.routeNames.includes(t.name)&&!n.routes.some((e=>e.key===t.key))?r.navigate(t):this.setState((e=>({routes:e.replacingRouteKeys.length?e.routes.filter((t=>!e.replacingRouteKeys.includes(t.key))):e.routes,openingRouteKeys:e.openingRouteKeys.filter((e=>e!==t.key)),closingRouteKeys:e.closingRouteKeys.filter((e=>e!==t.key)),replacingRouteKeys:[]})))})),(0,y.c)(this,"handleCloseRoute",(e=>{let{route:t}=e;const{state:n,navigation:r}=this.props;n.routes.some((e=>e.key===t.key))?r.dispatch({...f.ay.pop(),source:t.key,target:n.key}):this.setState((e=>({routes:e.routes.filter((e=>e.key!==t.key)),openingRouteKeys:e.openingRouteKeys.filter((e=>e!==t.key)),closingRouteKeys:e.closingRouteKeys.filter((e=>e!==t.key))})))})),(0,y.c)(this,"handleTransitionStart",((e,t)=>{let{route:n}=e;return this.props.navigation.emit({type:"transitionStart",data:{closing:t},target:n.key})})),(0,y.c)(this,"handleTransitionEnd",((e,t)=>{let{route:n}=e;return this.props.navigation.emit({type:"transitionEnd",data:{closing:t},target:n.key})})),(0,y.c)(this,"handleGestureStart",(e=>{let{route:t}=e;this.props.navigation.emit({type:"gestureStart",target:t.key})})),(0,y.c)(this,"handleGestureEnd",(e=>{let{route:t}=e;this.props.navigation.emit({type:"gestureEnd",target:t.key})})),(0,y.c)(this,"handleGestureCancel",(e=>{let{route:t}=e;this.props.navigation.emit({type:"gestureCancel",target:t.key})}))}static getDerivedStateFromProps(e,t){if((e.state.routes===t.previousRoutes||(n=e.state.routes.map((e=>e.key)),r=t.previousRoutes.map((e=>e.key)),n.length===r.length&&n.every(((e,t)=>e===r[t]))))&&t.routes.length){let n=t.routes,r=t.previousRoutes,o=e.descriptors,i=t.previousDescriptors;if(e.descriptors!==t.previousDescriptors&&(o=t.routes.reduce(((n,r)=>(n[r.key]=e.descriptors[r.key]||t.descriptors[r.key],n)),{}),i=e.descriptors),e.state.routes!==t.previousRoutes){const o=e.state.routes.reduce(((e,t)=>(e[t.key]=t,e)),{});n=t.routes.map((e=>o[e.key]||e)),r=e.state.routes}return{routes:n,previousRoutes:r,descriptors:o,previousDescriptors:i}}var n,r;let o=e.state.index{const r=e.descriptors[n]||t.descriptors[n];return!r||!1!==r.options.animationEnabled};if(c&&c.key!==u.key?l.some((e=>e.key===u.key))?o.some((e=>e.key===c.key))||d(c.key)&&!a.includes(c.key)&&(a=[...a,c.key],i=i.filter((e=>e!==c.key)),s=s.filter((e=>e!==c.key)),o=[...o,c]):d(u.key)&&!i.includes(u.key)&&(i=[...i,u.key],a=a.filter((e=>e!==u.key)),s=s.filter((e=>e!==u.key)),o.some((e=>e.key===c.key))||(i=i.filter((e=>e!==c.key)),"pop"===(n=>{var r;return null!==(r=(e.descriptors[n]||t.descriptors[n]).options.animationTypeForReplace)&&void 0!==r?r:"push"})(u.key)?(a=[...a,c.key],i=i.filter((e=>e!==u.key)),o=[...o,c]):(s=[...s,c.key],a=a.filter((e=>e!==c.key)),o=o.slice(),o.splice(o.length-1,0,c)))):(s.length||a.length)&&(o=o.slice(),o.splice(o.length-1,0,...t.routes.filter((e=>{let{key:t}=e;return!!d(t)&&(s.includes(t)||a.includes(t))})))),!o.length)throw new Error("There should always be at least one route in the navigation state.");const h=o.reduce(((n,r)=>(n[r.key]=e.descriptors[r.key]||t.descriptors[r.key],n)),{});return{routes:o,previousRoutes:e.state.routes,previousDescriptors:e.descriptors,openingRouteKeys:i,closingRouteKeys:a,replacingRouteKeys:s,descriptors:h}}render(){const{state:e,descriptors:t,...n}=this.props,{routes:r,descriptors:o,openingRouteKeys:i,closingRouteKeys:a}=this.state;return d.createElement(Gt,{style:Vt.container},d.createElement(D,null,d.createElement(R.Consumer,null,(t=>d.createElement(G.Consumer,null,(s=>d.createElement(H.Consumer,null,(l=>d.createElement(Ut,Ht({insets:t,isParentHeaderShown:l,isParentModal:s,getPreviousRoute:this.getPreviousRoute,routes:r,openingRouteKeys:i,closingRouteKeys:a,onOpenRoute:this.handleOpenRoute,onCloseRoute:this.handleCloseRoute,onTransitionStart:this.handleTransitionStart,onTransitionEnd:this.handleTransitionEnd,renderHeader:this.renderHeader,renderScene:this.renderScene,state:e,descriptors:o,onGestureStart:this.handleGestureStart,onGestureEnd:this.handleGestureEnd,onGestureCancel:this.handleGestureCancel},n))))))))))}}const Vt=b.c.create({container:{flex:1}});function Wt(){return Wt=Object.assign?Object.assign.bind():function(e){for(var t=1;t{var e;return null===(e=g.addListener)||void 0===e?void 0:e.call(g,"tabPress",(e=>{const t=g.isFocused();requestAnimationFrame((()=>{h.index>0&&t&&!e.defaultPrevented&&g.dispatch({...f.ay.popToTop(),target:h.key})}))}))}),[g,h.index,h.key]),d.createElement(y,null,d.createElement(zt,Wt({},a,{state:h,descriptors:p,navigation:g})))})),Yt=d.createContext({options:void 0});Yt.displayName="LinkingContext";const Kt=Yt;function qt(e){let{value:t,children:n}=e;return d.createElement(ae.Provider,{value:t},n)}var Xt=n(4084),Jt=n.n(Xt),Zt=n(9891);function $t(){let e=0,t=[];const n=[],r=()=>{n.forEach((e=>{const t=e.cb;e.cb=()=>t(!0)}))},o={get index(){var e;const n=null===(e=window.history.state)||void 0===e?void 0:e.id;if(n){const e=t.findIndex((e=>e.id===n));return e>-1?e:0}return 0},get:e=>t[e],backIndex(n){let{path:r}=n;for(let o=e-1;o>=0;o--){if(t[o].path===r)return o}return-1},push(n){let{path:o,state:i}=n;r();const a=(0,Zt.S)();t=t.slice(0,e+1),t.push({path:o,state:i,id:a}),e=t.length-1,window.history.pushState({id:a},"",o)},replace(n){var o,i;let{path:a,state:s}=n;r();const l=null!==(o=null===(i=window.history.state)||void 0===i?void 0:i.id)&&void 0!==o?o:(0,Zt.S)();let c=a;!t.length||t.findIndex((e=>e.id===l))<0?(c+=location.hash,t=[{path:c,state:s,id:l}],e=0):(t[e].path===a&&(c+=location.hash),t[e]={path:a,state:s,id:l}),window.history.replaceState({id:l},"",c)},go(o){r();const i=e+o,a=t.length-1;if(o<0&&!t[i]?(o=-e,e=0):o>0&&i>a?(o=a-e,e=a):e=i,0!==o)return new Promise(((r,i)=>{const a=e=>{if(clearTimeout(s),e)return void i(new Error("History was changed during navigation."));const{title:t}=window.document;window.document.title="",window.document.title=t,r()};n.push({ref:a,cb:a});const s=setTimeout((()=>{const e=n.findIndex((e=>e.ref===a));e>-1&&(n[e].cb(),n.splice(e,1))}),100),l=()=>{var r;const o=null===(r=window.history.state)||void 0===r?void 0:r.id,i=t.findIndex((e=>e.id===o));e=Math.max(i,0);const a=n.pop();window.removeEventListener("popstate",l),null===a||void 0===a||a.cb()};window.addEventListener("popstate",l),window.history.go(o)}))},listen(e){const t=()=>{n.length||e()};return window.addEventListener("popstate",t),()=>window.removeEventListener("popstate",t)}};return o}const en=d.createContext(void 0),tn=(e,t)=>{if(void 0===e||void 0===t||e.key!==t.key)return[void 0,void 0];const n=e.history?e.history.length:e.routes.length,r=t.history?t.history.length:t.routes.length,o=e.routes[e.index],i=t.routes[t.index],a=o.state,s=i.state;return n!==r||o.key!==i.key||void 0===a||void 0===s||a.key!==s.key?[e,t]:tn(a,s)},nn=e=>{let t=Promise.resolve();return()=>{t=t.then(e)}};function rn(e){const[t]=d.useState(e);let n=[!1,void 0];t.then((e=>{n=[!0,e]}));const[r,o]=d.useState(n),[i]=r;return d.useEffect((()=>{let e=!1;return i||(async()=>{let n;try{n=await t}finally{e||o([!0,n])}})(),()=>{e=!0}}),[t,i]),r}function on(){return on=Object.assign?Object.assign.bind():function(e){for(var t=1;t{var n;return null!==(n=null===e||void 0===e?void 0:e.title)&&void 0!==n?n:null===t||void 0===t?void 0:t.name})}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};d.useEffect((()=>{if(!t)return;const r=e.current;if(r){const e=n(r.getCurrentOptions(),r.getCurrentRoute());document.title=e}return null===r||void 0===r?void 0:r.addListener("options",(e=>{const t=n(e.data.options,null===r||void 0===r?void 0:r.getCurrentRoute());document.title=t}))}))}(c,i);const{getInitialState:u}=function(e,t){let{independent:n,enabled:r=!0,config:o,getStateFromPath:i=f.sL,getPathFromState:a=f.wB,getActionFromState:s=f.GW}=t;d.useEffect((()=>{}),[r,n]);const[l]=d.useState($t),c=d.useRef(r),u=d.useRef(o),h=d.useRef(i),p=d.useRef(a),g=d.useRef(s);d.useEffect((()=>{c.current=r,u.current=o,h.current=i,p.current=a,g.current=s}));const m=d.useContext(en),y=d.useCallback((()=>{let e;if(c.current){var t;const n=null!==(t=null===m||void 0===m?void 0:m.location)&&void 0!==t?t:"undefined"!==typeof window?window.location:void 0,r=n?n.pathname+n.search:void 0;r&&(e=h.current(r,u.current))}const n={then:t=>Promise.resolve(t?t(e):e),catch:()=>n};return n}),[]),v=d.useRef(void 0),b=d.useRef(void 0),A=d.useRef(void 0);return d.useEffect((()=>(v.current=l.index,l.listen((()=>{var t;const n=e.current;if(!n||!r)return;const{location:o}=window,i=o.pathname+o.search,a=l.index,s=null!==(t=v.current)&&void 0!==t?t:0;v.current=a,A.current=i;const c=l.get(a);if((null===c||void 0===c?void 0:c.path)===i&&null!==c&&void 0!==c&&c.state)return void n.resetRoot(c.state);const d=h.current(i,u.current);if(d){const e=n.getRootState();if(d.routes.some((t=>!(null!==e&&void 0!==e&&e.routeNames.includes(t.name)))))return void console.warn("The navigation state parsed from the URL contains routes not present in the root navigator. This usually means that the linking configuration doesn't match the navigation structure. See https://reactnavigation.org/docs/configuring-links for more details on how to specify a linking configuration.");if(a>s){const e=g.current(d,u.current);if(void 0!==e)try{n.dispatch(e)}catch(Tm){console.warn("An error occurred when trying to handle the link '".concat(i,"': ").concat("object"===typeof Tm&&null!=Tm&&"message"in Tm?Tm.message:Tm))}else n.resetRoot(d)}else n.resetRoot(d)}else n.resetRoot(d)})))),[r,l,e]),d.useEffect((()=>{var t;if(!r)return;const n=(e,t)=>{if(null!==e&&void 0!==e&&e.path){const t=h.current(e.path,u.current);if(t){const n=(0,f.UP)(t);if(n&&n.name===e.name&&Jt()(n.params,e.params))return e.path}}return p.current(t,u.current)};if(e.current){const t=e.current.getRootState();if(t){const e=(0,f.UP)(t),r=n(e,t);void 0===b.current&&(b.current=t),l.replace({path:r,state:t})}}return null===(t=e.current)||void 0===t?void 0:t.addListener("state",nn((async()=>{const t=e.current;if(!t||!r)return;const o=b.current,i=t.getRootState();if(!i)return;const a=A.current,s=(0,f.UP)(i),c=n(s,i);b.current=i,A.current=void 0;const[u,d]=tn(o,i);if(u&&d&&c!==a){const e=(d.history?d.history.length:d.routes.length)-(u.history?u.history.length:u.routes.length);if(e>0)l.push({path:c,state:i});else if(e<0){const t=l.backIndex({path:c}),n=l.index;try{-1!==t&&t{c.current&&REACT_NAVIGATION_DEVTOOLS.set(c.current,{get linking(){var e,t,n,o;return{...r,enabled:l,prefixes:null!==(e=null===r||void 0===r?void 0:r.prefixes)&&void 0!==e?e:[],getStateFromPath:null!==(t=null===r||void 0===r?void 0:r.getStateFromPath)&&void 0!==t?t:f.sL,getPathFromState:null!==(n=null===r||void 0===r?void 0:r.getPathFromState)&&void 0!==n?n:f.wB,getActionFromState:null!==(o=null===r||void 0===r?void 0:r.getActionFromState)&&void 0!==o?o:f.GW}}})}));const[h,p]=rn(u);d.useImperativeHandle(t,(()=>c.current));const g=d.useMemo((()=>({options:r})),[r]),m=null!=s.initialState||!l||h,y=d.useRef(a);return d.useEffect((()=>{y.current=a})),d.useEffect((()=>{var e;m&&(null===(e=y.current)||void 0===e||e.call(y))}),[m]),m?d.createElement(Kt.Provider,{value:g},d.createElement(qt,{value:n},d.createElement(f.eM,on({},s,{initialState:null==s.initialState?p:s.initialState,ref:c})))):o}n.g.REACT_NAVIGATION_DEVTOOLS=new WeakMap;const sn=d.forwardRef(an);var ln=n(7172),cn=n(5904),un=n(1100);const dn=b.c.create({menu:{flexDirection:"row"},menuElement:{flexDirection:"row"},element:{marginRight:"15%"},elementLast:{marginRight:50},textCommon:{alignSelf:"center",paddingLeft:6},text:{color:"#848D9B"},textSelected:{color:"white",fontWeight:"bold"},image:{width:30,height:30,resizeMode:"contain"}});var hn=n(8100);const pn={fr:"Infos",en:"Info"},fn={fr:"Actions",en:"Actions"},gn={fr:"Impact",en:"Impact"},mn={fr:"Programme",en:"Program"};var yn=n(268),vn=n(6720);const bn=b.c.create({horizontal:{flexDirection:"row"},vertical:{flexDirection:"column"},flex1:{flex:1},full_width:{width:"100%"},full_height:{height:"100%"},justify_center:{justifyContent:"center"},justify_right:{justifyContent:"flex-end"},align_item_center:{alignItems:"center"},wrap:{flexWrap:"wrap"},separator_bottom_grey:{borderBottomColor:u.y.GREY1,borderStyle:"solid",borderBottomWidth:1},separator_top_grey:{borderTopColor:u.y.GREY1,borderStyle:"solid",borderTopWidth:1},text_center:{textAlign:"center"}});var An=n(2496);const xn=()=>{const e=(0,f.MJ)(),{replace:t}=(0,f.Yi)(),r=d.useContext(yn.S);if(!r.expanded)return(0,An.jsx)(le.c,{style:{height:64,width:120,resizeMode:"contain",alignContent:"center"},source:n(560)});const o=n=>()=>{r.setTab(n),e.name!==ln.g.ADMIN&&(t(ln.g.ADMIN),vn.O.add(vn.S.ACTIONS,!0))};return"undefined"===typeof r.profile&&(0,An.jsx)(p.c,{})||(0,An.jsxs)(p.c,{style:[bn.horizontal,{minWidth:440,justifyContent:"space-between"}],children:[(0,An.jsx)(p.c,{children:(0,An.jsxs)(cn.c,{onPress:o(0),style:[bn.horizontal,bn.align_item_center,bn.flex1],children:[(0,An.jsx)(le.c,{style:dn.image,source:0===r.tab?n(1308):n(7504)}),(0,An.jsx)(un.c,{style:[dn.textCommon,0===r.tab?dn.textSelected:dn.text],children:(0,hn._)(pn)})]})}),(0,An.jsx)(p.c,{children:(0,An.jsxs)(cn.c,{onPress:o(1),style:[bn.horizontal,bn.align_item_center,bn.flex1],children:[(0,An.jsx)(le.c,{style:dn.image,source:1===r.tab?n(6176):n(1956)}),(0,An.jsx)(un.c,{style:[dn.textCommon,1===r.tab?dn.textSelected:dn.text],children:(0,hn._)(fn)})]})}),(0,An.jsx)(p.c,{children:(0,An.jsxs)(cn.c,{style:[bn.horizontal,bn.align_item_center,bn.flex1],onPress:o(2),children:[(0,An.jsx)(le.c,{style:dn.image,source:2===r.tab?n(1132):n(7892)}),(0,An.jsx)(un.c,{style:[dn.textCommon,2===r.tab?dn.textSelected:dn.text],children:(0,hn._)(gn)})]})}),(0,An.jsx)(p.c,{children:(0,An.jsxs)(cn.c,{style:[bn.horizontal,bn.align_item_center,bn.flex1],onPress:o(3),children:[(0,An.jsx)(le.c,{style:dn.image,source:3===r.tab?n(451):n(3140)}),(0,An.jsx)(un.c,{style:[dn.textCommon,3===r.tab?dn.textSelected:dn.text],children:(0,hn._)(mn)})]})})]})},Sn=()=>{const e=d.useContext(yn.S);return e.expanded?(0,An.jsx)(p.c,{style:{width:"100%",alignItems:"center"},children:(0,An.jsx)(le.c,{style:{height:64,width:120,resizeMode:"contain",alignContent:"center",marginLeft:16},source:n(5544)})}):"undefined"===typeof e.profile&&(0,An.jsx)(p.c,{})||(0,An.jsx)(p.c,{style:{width:"100%",alignItems:"center"},children:(0,An.jsx)(le.c,{style:{height:48,width:90,resizeMode:"contain",alignContent:"center",marginLeft:16},source:n(5544)})})};var wn=n(1484);const Cn=e=>{const t=d.useContext(yn.S),r=0!==e.unreadMessages;return(0,An.jsxs)(wn.Svg,{width:e.size,height:e.size,children:[(0,An.jsx)(wn.Image,{width:e.size,height:e.size,href:n(5040)}),r&&(0,An.jsx)(wn.Circle,{cx:t.expanded?22:18,cy:(t.expanded,7),r:t.expanded?8:7,fill:u.y.RED}),r&&(0,An.jsx)(wn.Text,{x:t.expanded?22:18,y:t.expanded?10:9,fontSize:t.expanded?10:8,fontWeight:"700",fill:u.y.WHITE,textAnchor:"middle",children:e.unreadMessages})]})},_n=e=>{const t=d.useContext(yn.S),r=0!==e.notifications;return(0,An.jsxs)(wn.Svg,{width:e.size,height:e.size,children:[(0,An.jsx)(wn.Image,{width:e.size,height:e.size,href:n(6096)}),r&&(0,An.jsx)(wn.Circle,{cx:t.expanded?22:18,cy:(t.expanded,7),r:t.expanded?8:7,fill:u.y.RED}),r&&(0,An.jsx)(wn.Text,{x:t.expanded?22:18,y:t.expanded?10:9,fontSize:t.expanded?10:8,fontWeight:"700",fill:u.y.WHITE,textAnchor:"middle",children:e.notifications})]})},En=e=>(0,An.jsx)(un.c,{children:e.children,style:"android"===r.default.OS?[{fontFamily:"Roboto"},e.style]:e.style}),Rn=e=>e.source&&0!==e.source.length?(0,An.jsx)(le.c,{source:{uri:e.source},style:[{width:e.size,height:e.size,resizeMode:"cover",backgroundColor:e.bgColor,borderRadius:e.size/2,overflow:"hidden"},e.style]}):(0,An.jsx)(p.c,{style:[{backgroundColor:e.bgColor,borderRadius:100,justifyContent:"center"},"ios"===r.default.OS?{height:e.size,minWidth:e.size,minHeight:e.size,paddingLeft:5,paddingRight:5}:{width:e.size,height:e.size},e.style],children:(0,An.jsx)(En,{style:[{textAlign:"center",fontSize:.4*e.size,color:e.color}],children:"undefined"===typeof e.name?"JD":(Array.isArray(e.name)?e.name:(e.name||"").split(" ")).map((e=>"string"===typeof e?e.charAt(0).toUpperCase():e)).slice(0,2).join("")})});var kn=n(3400);const In={fr:"Retour",en:"Go back"},Tn={fr:"Profil & Param\xe8tres",en:"Profile & Settings"},On={fr:"Profil",en:"Profil"},jn={fr:"Charger une photo de profil",en:"Upload a picture"},Pn={fr:"Charger une image d'\xe9quipe",en:"Upload a picture"},Bn={fr:"Pr\xe9nom",en:"First name"},Ln={fr:"Nom",en:"Name"},Dn={fr:"E-mail",en:"E-mail"},Mn={fr:"Poste",en:"Job title"},Nn={fr:"D\xe9partement",en:"Department"},Un={fr:"Pays",en:"Country"},Fn={fr:"Enregistrer les modifications",en:"Save"},Hn={fr:"Enregistrer",en:"Save"},Gn={fr:"Annuler",en:"Cancel"},zn={fr:"Le format de votre adresse e-mail n'est pas valide",en:"The format of your email address is not valid"},Vn={fr:"Se d\xe9connecter",en:"Log out"},Wn={fr:"Souhaitez-vous vraiment vous d\xe9connecter ?",en:"Are you sure you want to log out ?"},Qn={fr:"Se d\xe9connecter",en:"Confirm"},Yn={fr:"Annuler",en:"Cancel"},Kn={fr:"Supprimer mon compte",en:"Delete my profile"},qn={fr:"Souhaitez-vous vraiment supprimer votre compte ?",en:"Are you sure you want to delete your profile ?"},Xn={fr:"Votre compte, vos acc\xe8s et donn\xe9es seront supprim\xe9s.",en:"Your account, access and data will be deleted."},Jn={fr:"Pour supprimer votre compte, veuillez saisir le code de confirmation envoy\xe9 par e-mail",en:"To delete yout account, please enter the confirmation code sent to your e-mail address"},Zn={fr:"Confirmer",en:"Confirm"},$n={fr:"Annuler",en:"Cancel"},er={fr:"Param\xe8tres personnels",en:"Personal settings"},tr={fr:"Langue",en:"Language"},nr={fr:"Besoin d'aide ?",en:"Need help ?"},rr={fr:"Notifications",en:"Notifications"},or={fr:"E-mails",en:"E-mails"},ir={fr:"Mobile",en:"Mobile"},ar={fr:"Nouveau challenge",en:"New challenge"},sr={fr:"Partage d'une actualit\xe9",en:"Share of a news"},lr={fr:"Rappel challenge en cours",en:"Reminder for current challenge"},cr={fr:"\xc0 la une cette semaine",en:"Highlights of the week"},ur={fr:"Message d'\xe9quipe",en:"Team message"},dr={fr:"Param\xe8tres d'\xe9quipe",en:"Team settings"},hr={fr:"Nom de votre \xe9quipe",en:"Your team name"},pr=b.c.create({h1:{fontSize:26,lineHeight:42,fontWeight:"bold"},h1Expanded:{fontSize:34,lineHeight:42,fontWeight:"bold"},h2:{fontSize:26,lineHeight:32,fontWeight:"bold"},h3:{fontSize:20,lineHeight:28,fontWeight:"bold"},h4:{fontSize:18,lineHeight:26,fontWeight:"bold"},h5:{fontSize:16,lineHeight:24,fontWeight:"bold"},h6:{fontSize:14,lineHeight:20,fontWeight:"bold"},body1:{fontSize:16,lineHeight:24},body2:{fontSize:14,lineHeight:20},caption:{fontSize:11,lineHeight:15}}),fr=b.c.create({white:{color:u.y.WHITE},orange:{color:u.y.ORANGE},yellow:{color:u.y.YELLOW_DARK},green:{color:u.y.GREEN},green_light:{color:u.y.GREEN_LIGHT},purple:{color:u.y.PURPLE},blue_dark:{color:u.y.BLUE_DARK},blue_light_x:{color:u.y.BLUE_LIGHT_X},grey2:{color:u.y.GREY2},grey1:{color:u.y.GREY1},black:{color:u.y.BLACK},red:{color:u.y.RED}}),gr=()=>{let e;e="fr"===hn.O.get()?"cmacgm"===c.Y.name?"https://form.typeform.com/to/Dtra0WRu":"https://form.typeform.com/to/CUFKwODt":"cmacgm"===c.Y.name?"https://form.typeform.com/to/SmIP1mf4":"https://form.typeform.com/to/PElFd2q6","web"===r.default.OS?window.open(e,"_blank"):Promise.resolve(kn.c.openURL(e))},mr=e=>(0,An.jsx)(cn.c,{style:{marginTop:e.noMarginTop?0:40,marginRight:e.marginRight||0,borderColor:"white",borderWidth:1,borderRadius:4,paddingTop:6,paddingBottom:6,paddingLeft:12,paddingRight:12},onPress:()=>{gr()},children:(0,An.jsx)(un.c,{children:(0,hn._)(nr),style:[pr.caption,fr.white]})}),yr=e=>(0,An.jsx)(p.c,{style:[{backgroundColor:e.bgColor,minWidth:e.minWidth,alignSelf:"center"},e.style],children:(0,An.jsx)(p.c,{style:{height:e.height,backgroundColor:e.color,marginLeft:e.margin,marginRight:e.margin}})},"separator"),vr=()=>{var e;const{push:t}=(0,f.Yi)(),n=d.useContext(yn.S),r=(0,f.MJ)();var o;return n.expanded?"undefined"===typeof n.profile&&(0,An.jsx)(p.c,{})||(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center",marginRight:16},children:[(0,An.jsx)(mr,{noMarginTop:!0,marginRight:16}),(0,An.jsx)(yr,{height:24,minWidth:1,color:u.y.WHITE,style:{marginRight:16}}),(0,An.jsx)(cn.c,{style:{marginRight:20},onPress:()=>{t(ln.g.CHAT),vn.O.add(vn.S.CHAT,!0)},children:(0,An.jsx)(Cn,{size:30,unreadMessages:n.messages})}),(0,An.jsx)(cn.c,{style:{marginRight:20},onPress:()=>{n.setTab(-1),t(ln.g.NOTIFICATIONS),vn.O.add(vn.S.NOTIFICATIONS,!0),s.g.recipes.metrics.get({project:"maoboa:app",id:"maoboa:app:v3:notifications/opened"}).add()},children:(0,An.jsx)(_n,{size:30,notifications:n.notifications})}),(0,An.jsx)(cn.c,{onPress:()=>{t(ln.g.SETTINGS),vn.O.add(vn.S.SETTINGS,!0)},children:(0,An.jsx)(Rn,{bgColor:"white",color:u.y.BLUE_DARK,size:30,name:[n.profile.firstname,null===(o=n.profile)||void 0===o?void 0:o.lastname],source:n.picture})})]}):"undefined"===typeof n.profile&&(0,An.jsx)(p.c,{})||(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center",marginRight:16},children:[(0,An.jsx)(cn.c,{style:{marginRight:16},onPress:()=>{t(ln.g.CHAT),vn.O.add(vn.S.CHAT,!0)},children:(0,An.jsx)(Cn,{size:24,unreadMessages:n.messages})}),(0,An.jsx)(cn.c,{style:{marginRight:16},onPress:()=>{r.name!==ln.g.NOTIFICATIONS&&(t(ln.g.NOTIFICATIONS),vn.O.add(vn.S.NOTIFICATIONS,!0),s.g.recipes.metrics.get({project:"maoboa:app",id:"maoboa:app:v3:notifications/opened"}).add())},children:(0,An.jsx)(_n,{size:24,notifications:n.notifications})}),(0,An.jsx)(cn.c,{onPress:()=>{r.name!==ln.g.SETTINGS&&(n.setTab(-1),t(ln.g.SETTINGS),vn.O.add(vn.S.SETTINGS,!0))},children:(0,An.jsx)(Rn,{bgColor:"white",color:u.y.BLUE_DARK,size:24,name:[n.profile.firstname,null===(e=n.profile)||void 0===e?void 0:e.lastname],source:n.picture})})]})},br=e=>{const t=(0,f.Yi)(),n=d.useContext(yn.S),r=r=>{a.cp.setItem("locale",r).then((()=>{hn.O.set(r),e.standalone?e.standalone():(n.setTab(0),t.replace(ln.g.LOADING))}))};return(0,An.jsxs)(p.c,{style:{flexDirection:"row"},children:[(0,An.jsx)(cn.c,{onPress:()=>{"fr"===hn.O.get()&&r("en")},children:(0,An.jsx)(p.c,{style:{marginRight:13},children:(0,An.jsx)(p.c,{style:{padding:3},children:(0,An.jsx)(un.c,{children:"EN",style:{fontSize:12,padding:8,..."en"===hn.O.get()?{backgroundColor:u.y.YELLOW_DARK,color:"black"}:{color:"white"}}})})})}),(0,An.jsx)(cn.c,{onPress:()=>{"en"===hn.O.get()&&r("fr")},children:(0,An.jsx)(p.c,{style:{marginRight:13},children:(0,An.jsx)(p.c,{style:{padding:3},children:(0,An.jsx)(un.c,{children:"FR",style:{fontSize:12,padding:8,..."fr"===hn.O.get()?{backgroundColor:u.y.YELLOW_DARK,color:"black"}:{color:"white"}}})})})})]})};function Ar(){return Ar=Object.assign?Object.assign.bind():function(e){for(var t=1;t{let{style:n={},mode:r,edges:o,...i}=e;const a=j(),s=null!=o?Array.isArray(o)?o.reduce(((e,t)=>e|xr[t]),0):Object.keys(o).reduce(((e,t)=>e|xr[t]),0):15,l=d.useMemo((()=>{const e=8&s?a.top:0,t=4&s?a.right:0,o=2&s?a.bottom:0,i=1&s?a.left:0,l=b.c.flatten(n);if("margin"===r){const{margin:r=0,marginVertical:a=r,marginHorizontal:s=r,marginTop:c=a,marginRight:u=s,marginBottom:d=a,marginLeft:h=s}=l;return[n,{marginTop:c+e,marginRight:u+t,marginBottom:d+o,marginLeft:h+i}]}{const{padding:r=0,paddingVertical:a=r,paddingHorizontal:s=r,paddingTop:c=a,paddingRight:u=s,paddingBottom:d=a,paddingLeft:h=s}=l;return[n,{paddingTop:c+e,paddingRight:u+t,paddingBottom:d+o,paddingLeft:h+i}]}}),[n,a,r,s]);return d.createElement(p.c,Ar({style:l},i,{ref:t}))}));let wr=[];const Cr=e=>e===ln.g.ADMIN||e===ln.g.SETTINGS||e===ln.g.NOTIFICATIONS,_r=(e,t)=>!!t&&Cr(e),Er=(e,t)=>e!==ln.g.SETTINGS&&e!==ln.g.CHAT_MEMBERS&&e!==ln.g.PROGRAM_COMMITMENTS&&e!==ln.g.TEAMS_RANKING&&e!==ln.g.NEW_MESSAGE&&e!==ln.g.FORM&&e!==ln.g.HIGHLIGHTS&&(t||e!==ln.g.CHAT&&e!==ln.g.COMMUNITY_MEMBERS&&e!==ln.g.HIGHLIGHT_DETAILS&&e!==ln.g.NOTIFICATIONS);let Rr={setProfile:()=>{},setPicture:()=>{},addNotification:()=>{}};const kr=()=>"web"===r.default.OS&&window.innerWidth>980,Ir=e=>{const t=d.useReducer((e=>e+1),0)[1];a.cp.getItem("locale").then((e=>{e&&hn.O.get()!==e&&(hn.O.set(e),t())}));const n=Qt(),[o,i]=d.useState("web"===r.default.OS&&vn.O.getCurrentPage()===ln.g.NOTIFICATIONS?-1:1),[s,l]=d.useState(void 0),[c,h]=d.useState(void 0),[f,g]=d.useState(0),[m,y]=d.useState(0);Rr={setProfile:l,setPicture:h,addNotification:()=>g(f+1)};let v=kr();return"web"===r.default.OS&&(window.onresize=()=>{kr()!==v&&(v=!v,t())}),(0,An.jsx)(yn.S.Provider,{value:{tab:o,setTab:e=>{i(e),0===e?vn.O.add(vn.S.INFO,!0):2===e?vn.O.add(vn.S.IMPACT,!0):3===e?vn.O.add(vn.S.PROGRAM,!0):vn.O.add(vn.S.ACTIONS,!0)},profile:s,setProfile:e=>l(Object.assign({},s,e)),picture:c,setPicture:h,notifications:f,setNotifications:g,messages:m,setMessages:y,expanded:v},children:(0,An.jsx)(n.Navigator,{children:Object.keys(e.pages).map((t=>(0,An.jsx)(n.Screen,{name:t,component:e.pages[t],options:{headerShown:Er(t,v),headerStyle:{backgroundColor:u.y.BLUE_DARK,shadowColor:"transparent",elevation:0,borderBottomWidth:0},headerTintColor:"#fff",headerTitleContainerStyle:{flex:1},headerRightContainerStyle:{flexGrow:0,flexBasis:"auto"},headerTitle:()=>(0,An.jsx)(p.c,{style:{width:"100%",alignItems:"center",marginLeft:55},children:_r(t,v)&&(0,An.jsx)(xn,{})}),headerLeft:()=>((e,t)=>t?e!==ln.g.WELCOME:Cr(e))(t,v)?(0,An.jsx)(Sn,{}):(0,An.jsx)(p.c,{}),headerRight:()=>(e=>Cr(e))(t)?(0,An.jsx)(vr,{}):t===ln.g.OFFLINE||t===ln.g.REGISTER||t===ln.g.LOGIN||t===ln.g.PASSWORD_RESET?(0,An.jsx)(br,{}):(0,An.jsx)(p.c,{})}},t)))})})},Tr=e=>(a.cp.getItem("token").then((e=>{null!==e&&s.g.config.setToken(e)})).catch((e=>{console.log("[ERROR]",e)})),(0,An.jsx)(sn,{documentTitle:{enabled:!1},onStateChange:e=>{"undefined"!==typeof e&&wr.push(e.routes[e.routes.length-1].name)},children:(()=>{const t=(0,An.jsx)(Ir,{pages:e});return"web"===r.default.OS?t:(0,An.jsx)(Sr,{style:{flex:1,backgroundColor:u.y.BLUE_DARK},children:t})})()}));var Or=n(9960),jr=n(7300),Pr=n(9020),Br=n(800);var Lr=n(309);function Dr(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,s=[],l=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw o}}return s}}(e,t)||(0,Lr.c)(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var Mr=n(5656);function Nr(e,t){if(null==e)return{};var n,r,o=(0,Mr.c)(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var Ur=["defaultInputValue","defaultMenuIsOpen","defaultValue","inputValue","menuIsOpen","onChange","onInputChange","onMenuClose","onMenuOpen","value"];var Fr=n(5072);var Hr=n(2028);function Gr(e,t){for(var n=0;n0?ro(fo,--ho):0,co--,10===po&&(co=1,lo--),po}function vo(){return po=ho2||So(po)>3?"":" "}function Ro(e,t){for(;--t&&vo()&&!(po<48||po>102||po>57&&po<65||po>70&&po<97););return xo(e,Ao()+(t<6&&32==bo()&&32==vo()))}function ko(e){for(;vo();)switch(po){case e:return ho;case 34:case 39:34!==e&&39!==e&&ko(po);break;case 40:41===e&&ko(e);break;case 92:vo()}return ho}function Io(e,t){for(;vo()&&e+po!==57&&(e+po!==84||47!==bo()););return"/*"+xo(t,ho-1)+"*"+Zr(47===e?e:vo())}function To(e){for(;!So(bo());)vo();return xo(e,ho)}var Oo="-ms-",jo="-moz-",Po="-webkit-",Bo="comm",Lo="rule",Do="decl",Mo="@keyframes";function No(e,t){for(var n="",r=ao(e),o=0;o0&&io(w)-d&&so(p>32?Vo(w+";",r,n,d-1):Vo(to(w," ","")+";",r,n,d-2),l);break;case 59:w+=";";default:if(so(S=Go(w,t,n,c,u,o,s,b,A=[],x=[],d),i),123===v)if(0===u)Ho(w,t,S,S,A,i,d,s,x);else switch(99===h&&110===ro(w,3)?100:h){case 100:case 108:case 109:case 115:Ho(e,S,S,r&&so(Go(e,S,S,0,0,o,s,b,o,A=[],d),x),o,x,d,s,r?A:x);break;default:Ho(w,S,S,S,[""],x,0,s,x)}}c=u=p=0,g=y=1,b=w="",d=a;break;case 58:d=1+io(w),p=f;default:if(g<1)if(123==v)--g;else if(125==v&&0==g++&&125==yo())continue;switch(w+=Zr(v),v*g){case 38:y=u>0?1:(w+="\f",-1);break;case 44:s[c++]=(io(w)-1)*y,y=1;break;case 64:45===bo()&&(w+=_o(vo())),h=bo(),u=d=io(b=w+=To(Ao())),v++;break;case 45:45===f&&2==io(w)&&(g=0)}}return i}function Go(e,t,n,r,o,i,a,s,l,c,u){for(var d=o-1,h=0===o?i:[""],p=ao(h),f=0,g=0,m=0;f0?h[y]+" "+v:to(v,/&\f/g,h[y])))&&(l[m++]=b);return go(e,t,n,0===o?Lo:s,l,c,u)}function zo(e,t,n){return go(e,t,n,Bo,Zr(po),oo(e,2,-2),0)}function Vo(e,t,n,r){return go(e,t,n,Do,oo(e,0,r),oo(e,r+1,-1),r)}var Wo=function(e,t,n){for(var r=0,o=0;r=o,o=bo(),38===r&&12===o&&(t[n]=1),!So(o);)vo();return xo(e,ho)},Qo=function(e,t){return Co(function(e,t){var n=-1,r=44;do{switch(So(r)){case 0:38===r&&12===bo()&&(t[n]=1),e[n]+=Wo(ho-1,t,n);break;case 2:e[n]+=_o(r);break;case 4:if(44===r){e[++n]=58===bo()?"&\f":"",t[n]=e[n].length;break}default:e[n]+=Zr(r)}}while(r=vo());return e}(wo(e),t))},Yo=new WeakMap,Ko=function(e){if("rule"===e.type&&e.parent&&!(e.length<1)){for(var t=e.value,n=e.parent,r=e.column===n.column&&e.line===n.line;"rule"!==n.type;)if(!(n=n.parent))return;if((1!==e.props.length||58===t.charCodeAt(0)||Yo.get(n))&&!r){Yo.set(e,!0);for(var o=[],i=Qo(t,o),a=n.props,s=0,l=0;s6)switch(ro(e,t+1)){case 109:if(45!==ro(e,t+4))break;case 102:return to(e,/(.+:)(.+)-([^]+)/,"$1"+Po+"$2-$3$1"+jo+(108==ro(e,t+3)?"$3":"$2-$3"))+e;case 115:return~no(e,"stretch")?Xo(to(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(115!==ro(e,t+1))break;case 6444:switch(ro(e,io(e)-3-(~no(e,"!important")&&10))){case 107:return to(e,":",":"+Po)+e;case 101:return to(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+Po+(45===ro(e,14)?"inline-":"")+"box$3$1"+Po+"$2$3$1"+Oo+"$2box$3")+e}break;case 5936:switch(ro(e,t+11)){case 114:return Po+e+Oo+to(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return Po+e+Oo+to(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return Po+e+Oo+to(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return Po+e+Oo+e+e}return e}var Jo=[function(e,t,n,r){if(e.length>-1&&!e.return)switch(e.type){case Do:e.return=Xo(e.value,e.length);break;case Mo:return No([mo(e,{value:to(e.value,"@","@"+Po)})],r);case Lo:if(e.length)return function(e,t){return e.map(t).join("")}(e.props,(function(t){switch(function(e,t){return(e=t.exec(e))?e[0]:e}(t,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return No([mo(e,{props:[to(t,/:(read-\w+)/,":-moz-$1")]})],r);case"::placeholder":return No([mo(e,{props:[to(t,/:(plac\w+)/,":"+Po+"input-$1")]}),mo(e,{props:[to(t,/:(plac\w+)/,":-moz-$1")]}),mo(e,{props:[to(t,/:(plac\w+)/,Oo+"input-$1")]})],r)}return""}))}}],Zo=function(e){var t=e.key;if("css"===t){var n=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(n,(function(e){-1!==e.getAttribute("data-emotion").indexOf(" ")&&(document.head.appendChild(e),e.setAttribute("data-s",""))}))}var r=e.stylisPlugins||Jo;var o,i,a={},s=[];o=e.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+t+' "]'),(function(e){for(var t=e.getAttribute("data-emotion").split(" "),n=1;n=4;++r,o-=4)t=1540483477*(65535&(t=255&e.charCodeAt(r)|(255&e.charCodeAt(++r))<<8|(255&e.charCodeAt(++r))<<16|(255&e.charCodeAt(++r))<<24))+(59797*(t>>>16)<<16),n=1540483477*(65535&(t^=t>>>24))+(59797*(t>>>16)<<16)^1540483477*(65535&n)+(59797*(n>>>16)<<16);switch(o){case 3:n^=(255&e.charCodeAt(r+2))<<16;case 2:n^=(255&e.charCodeAt(r+1))<<8;case 1:n=1540483477*(65535&(n^=255&e.charCodeAt(r)))+(59797*(n>>>16)<<16)}return(((n=1540483477*(65535&(n^=n>>>13))+(59797*(n>>>16)<<16))^n>>>15)>>>0).toString(36)}(o)+l;return{name:c,styles:o,next:ci}},hi=!!h.useInsertionEffect&&h.useInsertionEffect,pi=hi||function(e){return e()},fi=(hi||d.useLayoutEffect,{}.hasOwnProperty),gi=d.createContext("undefined"!==typeof HTMLElement?Zo({key:"css"}):null);gi.Provider;var mi=function(e){return(0,d.forwardRef)((function(t,n){var r=(0,d.useContext)(gi);return e(t,r,n)}))};var yi=d.createContext({});var vi="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",bi=function(e){var t=e.cache,n=e.serialized,r=e.isStringTag;return $o(t,n,r),pi((function(){return function(e,t,n){$o(e,t,n);var r=e.key+"-"+t.name;if(void 0===e.inserted[t.name]){var o=t;do{e.insert(t===o?"."+r:"",o,e.sheet,!0),o=o.next}while(void 0!==o)}}(t,n,r)})),null},Ai=mi((function(e,t,n){var r=e.css;"string"===typeof r&&void 0!==t.registered[r]&&(r=t.registered[r]);var o=e[vi],i=[r],a="";"string"===typeof e.className?a=function(e,t,n){var r="";return n.split(" ").forEach((function(n){void 0!==e[n]?t.push(e[n]+";"):r+=n+" "})),r}(t.registered,i,e.className):null!=e.className&&(a=e.className+" ");var s=di(i,void 0,d.useContext(yi));a+=t.key+"-"+s.name;var l={};for(var c in e)fi.call(e,c)&&"css"!==c&&c!==vi&&(l[c]=e[c]);return l.ref=n,l.className=a,d.createElement(d.Fragment,null,d.createElement(bi,{cache:t,serialized:s,isStringTag:"string"===typeof o}),d.createElement(o,l))}));var xi=Ai,Si=(n(784),function(e,t){var n=arguments;if(null==t||!fi.call(t,"css"))return d.createElement.apply(void 0,n);var r=n.length,o=new Array(r);o[0]=xi,o[1]=function(e,t){var n={};for(var r in t)fi.call(t,r)&&(n[r]=t[r]);return n[vi]=e,n}(e,t);for(var i=2;i({x:e,y:e});function Ti(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}function Oi(e){return Bi(e)?(e.nodeName||"").toLowerCase():"#document"}function ji(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function Pi(e){var t;return null==(t=(Bi(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function Bi(e){return e instanceof Node||e instanceof ji(e).Node}function Li(e){return e instanceof Element||e instanceof ji(e).Element}function Di(e){return e instanceof HTMLElement||e instanceof ji(e).HTMLElement}function Mi(e){return"undefined"!==typeof ShadowRoot&&(e instanceof ShadowRoot||e instanceof ji(e).ShadowRoot)}function Ni(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=Hi(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(o)}function Ui(){return!("undefined"===typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function Fi(e){return["html","body","#document"].includes(Oi(e))}function Hi(e){return ji(e).getComputedStyle(e)}function Gi(e){if("html"===Oi(e))return e;const t=e.assignedSlot||e.parentNode||Mi(e)&&e.host||Pi(e);return Mi(t)?t.host:t}function zi(e){const t=Gi(e);return Fi(t)?e.ownerDocument?e.ownerDocument.body:e.body:Di(t)&&Ni(t)?t:zi(t)}function Vi(e,t,n){var r;void 0===t&&(t=[]),void 0===n&&(n=!0);const o=zi(e),i=o===(null==(r=e.ownerDocument)?void 0:r.body),a=ji(o);return i?t.concat(a,a.visualViewport||[],Ni(o)?o:[],a.frameElement&&n?Vi(a.frameElement):[]):t.concat(o,Vi(o,[],n))}function Wi(e){const t=Hi(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=Di(e),i=o?e.offsetWidth:n,a=o?e.offsetHeight:r,s=Ri(n)!==i||Ri(r)!==a;return s&&(n=i,r=a),{width:n,height:r,$:s}}function Qi(e){return Li(e)?e:e.contextElement}function Yi(e){const t=Qi(e);if(!Di(t))return Ii(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:i}=Wi(t);let a=(i?Ri(n.width):n.width)/r,s=(i?Ri(n.height):n.height)/o;return a&&Number.isFinite(a)||(a=1),s&&Number.isFinite(s)||(s=1),{x:a,y:s}}const Ki=Ii(0);function qi(e){const t=ji(e);return Ui()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:Ki}function Xi(e,t,n,r){void 0===t&&(t=!1),void 0===n&&(n=!1);const o=e.getBoundingClientRect(),i=Qi(e);let a=Ii(1);t&&(r?Li(r)&&(a=Yi(r)):a=Yi(e));const s=function(e,t,n){return void 0===t&&(t=!1),!(!n||t&&n!==ji(e))&&t}(i,n,r)?qi(i):Ii(0);let l=(o.left+s.x)/a.x,c=(o.top+s.y)/a.y,u=o.width/a.x,d=o.height/a.y;if(i){const e=ji(i),t=r&&Li(r)?ji(r):r;let n=e.frameElement;for(;n&&r&&t!==e;){const e=Yi(n),t=n.getBoundingClientRect(),r=Hi(n),o=t.left+(n.clientLeft+parseFloat(r.paddingLeft))*e.x,i=t.top+(n.clientTop+parseFloat(r.paddingTop))*e.y;l*=e.x,c*=e.y,u*=e.x,d*=e.y,l+=o,c+=i,n=ji(n).frameElement}}return Ti({width:u,height:d,x:l,y:c})}function Ji(e,t,n,r){void 0===r&&(r={});const{ancestorScroll:o=!0,ancestorResize:i=!0,elementResize:a="function"===typeof ResizeObserver,layoutShift:s="function"===typeof IntersectionObserver,animationFrame:l=!1}=r,c=Qi(e),u=o||i?[...c?Vi(c):[],...Vi(t)]:[];u.forEach((e=>{o&&e.addEventListener("scroll",n,{passive:!0}),i&&e.addEventListener("resize",n)}));const d=c&&s?function(e,t){let n,r=null;const o=Pi(e);function i(){var e;clearTimeout(n),null==(e=r)||e.disconnect(),r=null}return function a(s,l){void 0===s&&(s=!1),void 0===l&&(l=1),i();const{left:c,top:u,width:d,height:h}=e.getBoundingClientRect();if(s||t(),!d||!h)return;const p={rootMargin:-ki(u)+"px "+-ki(o.clientWidth-(c+d))+"px "+-ki(o.clientHeight-(u+h))+"px "+-ki(c)+"px",threshold:Ei(0,_i(1,l))||1};let f=!0;function g(e){const t=e[0].intersectionRatio;if(t!==l){if(!f)return a();t?a(!1,t):n=setTimeout((()=>{a(!1,1e-7)}),100)}f=!1}try{r=new IntersectionObserver(g,{...p,root:o.ownerDocument})}catch(Tm){r=new IntersectionObserver(g,p)}r.observe(e)}(!0),i}(c,n):null;let h,p=-1,f=null;a&&(f=new ResizeObserver((e=>{let[r]=e;r&&r.target===c&&f&&(f.unobserve(t),cancelAnimationFrame(p),p=requestAnimationFrame((()=>{var e;null==(e=f)||e.observe(t)}))),n()})),c&&!l&&f.observe(c),f.observe(t));let g=l?Xi(e):null;return l&&function t(){const r=Xi(e);!g||r.x===g.x&&r.y===g.y&&r.width===g.width&&r.height===g.height||n();g=r,h=requestAnimationFrame(t)}(),n(),()=>{var e;u.forEach((e=>{o&&e.removeEventListener("scroll",n),i&&e.removeEventListener("resize",n)})),null==d||d(),null==(e=f)||e.disconnect(),f=null,l&&cancelAnimationFrame(h)}}const Zi=d.useLayoutEffect;var $i=["className","clearValue","cx","getStyles","getClassNames","getValue","hasValue","isMulti","isRtl","options","selectOption","selectProps","setValue","theme"],ea=function(){};function ta(e,t){return t?"-"===t[0]?e+t:e+"__"+t:e}function na(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),o=2;o-1}function sa(e){return aa(e)?window.pageYOffset:e.scrollTop}function la(e,t){aa(e)?window.scrollTo(0,t):e.scrollTop=t}function ca(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:200,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:ea,o=sa(e),i=t-o,a=0;!function t(){var s,l=i*((s=(s=a+=10)/n-1)*s*s+1)+o;la(e,l),an.bottom?la(e,Math.min(t.offsetTop+t.clientHeight-e.offsetHeight+o,e.scrollHeight)):r.top-o=f)return{placement:"bottom",maxHeight:t};if(C>=f&&!a)return i&&ca(l,_,R),{placement:"bottom",maxHeight:t};if(!a&&C>=r||a&&S>=r)return i&&ca(l,_,R),{placement:"bottom",maxHeight:a?S-b:C-b};if("auto"===o||a){var k=t,I=a?x:w;return I>=r&&(k=Math.min(I-b-s,t)),{placement:"top",maxHeight:k}}if("bottom"===o)return i&&la(l,_),{placement:"bottom",maxHeight:t};break;case"top":if(x>=f)return{placement:"top",maxHeight:t};if(w>=f&&!a)return i&&ca(l,E,R),{placement:"top",maxHeight:t};if(!a&&w>=r||a&&x>=r){var T=t;return(!a&&w>=r||a&&x>=r)&&(T=a?x-A:w-A),i&&ca(l,E,R),{placement:"top",maxHeight:T}}return{placement:"bottom",maxHeight:t};default:throw new Error('Invalid placement provided "'.concat(o,'".'))}return c}var xa,Sa=function(e){return"auto"===e?"bottom":e},wa=(0,d.createContext)(null),Ca=function(e){var t=e.children,n=e.minMenuHeight,r=e.maxMenuHeight,o=e.menuPlacement,i=e.menuPosition,a=e.menuShouldScrollIntoView,s=e.theme,l=((0,d.useContext)(wa)||{}).setPortalPlacement,c=(0,d.useRef)(null),u=Dr((0,d.useState)(r),2),h=u[0],p=u[1],f=Dr((0,d.useState)(null),2),g=f[0],m=f[1],y=s.spacing.controlHeight;return Zi((function(){var e=c.current;if(e){var t="fixed"===i,s=Aa({maxHeight:r,menuEl:e,minHeight:n,placement:o,shouldScroll:a&&!t,isFixedPosition:t,controlHeight:y});p(s.maxHeight),m(s.placement),null===l||void 0===l||l(s.placement)}}),[r,o,i,a,n,l,y]),t({ref:c,placerProps:(0,Br.c)((0,Br.c)({},e),{},{placement:g||Sa(o),maxHeight:h})})},_a=function(e){var t=e.children,n=e.innerRef,r=e.innerProps;return Si("div",(0,Fr.c)({},ia(e,"menu",{menu:!0}),{ref:n},r),t)},Ea=function(e,t){var n=e.theme,r=n.spacing.baseUnit,o=n.colors;return(0,Br.c)({textAlign:"center"},t?{}:{color:o.neutral40,padding:"".concat(2*r,"px ").concat(3*r,"px")})},Ra=Ea,ka=Ea,Ia=["size"],Ta=["innerProps","isRtl","size"];var Oa,ja,Pa={name:"8mmkcg",styles:"display:inline-block;fill:currentColor;line-height:1;stroke:currentColor;stroke-width:0"},Ba=function(e){var t=e.size,n=Nr(e,Ia);return Si("svg",(0,Fr.c)({height:t,width:t,viewBox:"0 0 20 20","aria-hidden":"true",focusable:"false",css:Pa},n))},La=function(e){return Si(Ba,(0,Fr.c)({size:20},e),Si("path",{d:"M14.348 14.849c-0.469 0.469-1.229 0.469-1.697 0l-2.651-3.030-2.651 3.029c-0.469 0.469-1.229 0.469-1.697 0-0.469-0.469-0.469-1.229 0-1.697l2.758-3.15-2.759-3.152c-0.469-0.469-0.469-1.228 0-1.697s1.228-0.469 1.697 0l2.652 3.031 2.651-3.031c0.469-0.469 1.228-0.469 1.697 0s0.469 1.229 0 1.697l-2.758 3.152 2.758 3.15c0.469 0.469 0.469 1.229 0 1.698z"}))},Da=function(e){return Si(Ba,(0,Fr.c)({size:20},e),Si("path",{d:"M4.516 7.548c0.436-0.446 1.043-0.481 1.576 0l3.908 3.747 3.908-3.747c0.533-0.481 1.141-0.446 1.574 0 0.436 0.445 0.408 1.197 0 1.615-0.406 0.418-4.695 4.502-4.695 4.502-0.217 0.223-0.502 0.335-0.787 0.335s-0.57-0.112-0.789-0.335c0 0-4.287-4.084-4.695-4.502s-0.436-1.17 0-1.615z"}))},Ma=function(e,t){var n=e.isFocused,r=e.theme,o=r.spacing.baseUnit,i=r.colors;return(0,Br.c)({label:"indicatorContainer",display:"flex",transition:"color 150ms"},t?{}:{color:n?i.neutral60:i.neutral20,padding:2*o,":hover":{color:n?i.neutral80:i.neutral40}})},Na=Ma,Ua=Ma,Fa=function(){var e=wi.apply(void 0,arguments),t="animation-"+e.name;return{name:t,styles:"@keyframes "+t+"{"+e.styles+"}",anim:1,toString:function(){return"_EMO_"+this.name+"_"+this.styles+"_EMO_"}}}(xa||(Oa=["\n 0%, 80%, 100% { opacity: 0; }\n 40% { opacity: 1; }\n"],ja||(ja=Oa.slice(0)),xa=Object.freeze(Object.defineProperties(Oa,{raw:{value:Object.freeze(ja)}})))),Ha=function(e){var t=e.delay,n=e.offset;return Si("span",{css:wi({animation:"".concat(Fa," 1s ease-in-out ").concat(t,"ms infinite;"),backgroundColor:"currentColor",borderRadius:"1em",display:"inline-block",marginLeft:n?"1em":void 0,height:"1em",verticalAlign:"top",width:"1em"},"","")})},Ga=function(e){var t=e.children,n=e.isDisabled,r=e.isFocused,o=e.innerRef,i=e.innerProps,a=e.menuIsOpen;return Si("div",(0,Fr.c)({ref:o},ia(e,"control",{control:!0,"control--is-disabled":n,"control--is-focused":r,"control--menu-is-open":a}),i,{"aria-disabled":n||void 0}),t)},za=["data"],Va=function(e){var t=e.children,n=e.cx,r=e.getStyles,o=e.getClassNames,i=e.Heading,a=e.headingProps,s=e.innerProps,l=e.label,c=e.theme,u=e.selectProps;return Si("div",(0,Fr.c)({},ia(e,"group",{group:!0}),s),Si(i,(0,Fr.c)({},a,{selectProps:u,theme:c,getStyles:r,getClassNames:o,cx:n}),l),Si("div",null,t))},Wa=["innerRef","isDisabled","isHidden","inputClassName"],Qa={gridArea:"1 / 2",font:"inherit",minWidth:"2px",border:0,margin:0,outline:0,padding:0},Ya={flex:"1 1 auto",display:"inline-grid",gridArea:"1 / 1 / 2 / 3",gridTemplateColumns:"0 min-content","&:after":(0,Br.c)({content:'attr(data-value) " "',visibility:"hidden",whiteSpace:"pre"},Qa)},Ka=function(e){return(0,Br.c)({label:"input",color:"inherit",background:0,opacity:e?0:1,width:"100%"},Qa)},qa=function(e){var t=e.cx,n=e.value,r=oa(e),o=r.innerRef,i=r.isDisabled,a=r.isHidden,s=r.inputClassName,l=Nr(r,Wa);return Si("div",(0,Fr.c)({},ia(e,"input",{"input-container":!0}),{"data-value":n||""}),Si("input",(0,Fr.c)({className:t({input:!0},s),ref:o,style:Ka(a),disabled:i},l)))},Xa=function(e){var t=e.children,n=e.innerProps;return Si("div",n,t)};var Ja=function(e){var t=e.children,n=e.components,r=e.data,o=e.innerProps,i=e.isDisabled,a=e.removeProps,s=e.selectProps,l=n.Container,c=n.Label,u=n.Remove;return Si(l,{data:r,innerProps:(0,Br.c)((0,Br.c)({},ia(e,"multiValue",{"multi-value":!0,"multi-value--is-disabled":i})),o),selectProps:s},Si(c,{data:r,innerProps:(0,Br.c)({},ia(e,"multiValueLabel",{"multi-value__label":!0})),selectProps:s},t),Si(u,{data:r,innerProps:(0,Br.c)((0,Br.c)({},ia(e,"multiValueRemove",{"multi-value__remove":!0})),{},{"aria-label":"Remove ".concat(t||"option")},a),selectProps:s}))},Za={ClearIndicator:function(e){var t=e.children,n=e.innerProps;return Si("div",(0,Fr.c)({},ia(e,"clearIndicator",{indicator:!0,"clear-indicator":!0}),n),t||Si(La,null))},Control:Ga,DropdownIndicator:function(e){var t=e.children,n=e.innerProps;return Si("div",(0,Fr.c)({},ia(e,"dropdownIndicator",{indicator:!0,"dropdown-indicator":!0}),n),t||Si(Da,null))},DownChevron:Da,CrossIcon:La,Group:Va,GroupHeading:function(e){var t=oa(e);t.data;var n=Nr(t,za);return Si("div",(0,Fr.c)({},ia(e,"groupHeading",{"group-heading":!0}),n))},IndicatorsContainer:function(e){var t=e.children,n=e.innerProps;return Si("div",(0,Fr.c)({},ia(e,"indicatorsContainer",{indicators:!0}),n),t)},IndicatorSeparator:function(e){var t=e.innerProps;return Si("span",(0,Fr.c)({},t,ia(e,"indicatorSeparator",{"indicator-separator":!0})))},Input:qa,LoadingIndicator:function(e){var t=e.innerProps,n=e.isRtl,r=e.size,o=void 0===r?4:r,i=Nr(e,Ta);return Si("div",(0,Fr.c)({},ia((0,Br.c)((0,Br.c)({},i),{},{innerProps:t,isRtl:n,size:o}),"loadingIndicator",{indicator:!0,"loading-indicator":!0}),t),Si(Ha,{delay:0,offset:n}),Si(Ha,{delay:160,offset:!0}),Si(Ha,{delay:320,offset:!n}))},Menu:_a,MenuList:function(e){var t=e.children,n=e.innerProps,r=e.innerRef,o=e.isMulti;return Si("div",(0,Fr.c)({},ia(e,"menuList",{"menu-list":!0,"menu-list--is-multi":o}),{ref:r},n),t)},MenuPortal:function(e){var t=e.appendTo,n=e.children,r=e.controlElement,o=e.innerProps,i=e.menuPlacement,a=e.menuPosition,s=(0,d.useRef)(null),l=(0,d.useRef)(null),c=Dr((0,d.useState)(Sa(i)),2),u=c[0],h=c[1],p=(0,d.useMemo)((function(){return{setPortalPlacement:h}}),[]),f=Dr((0,d.useState)(null),2),g=f[0],m=f[1],y=(0,d.useCallback)((function(){if(r){var e=function(e){var t=e.getBoundingClientRect();return{bottom:t.bottom,height:t.height,left:t.left,right:t.right,top:t.top,width:t.width}}(r),t="fixed"===a?0:window.pageYOffset,n=e[u]+t;n===(null===g||void 0===g?void 0:g.offset)&&e.left===(null===g||void 0===g?void 0:g.rect.left)&&e.width===(null===g||void 0===g?void 0:g.rect.width)||m({offset:n,rect:e})}}),[r,a,u,null===g||void 0===g?void 0:g.offset,null===g||void 0===g?void 0:g.rect.left,null===g||void 0===g?void 0:g.rect.width]);Zi((function(){y()}),[y]);var v=(0,d.useCallback)((function(){"function"===typeof l.current&&(l.current(),l.current=null),r&&s.current&&(l.current=Ji(r,s.current,y,{elementResize:"ResizeObserver"in window}))}),[r,y]);Zi((function(){v()}),[v]);var b=(0,d.useCallback)((function(e){s.current=e,v()}),[v]);if(!t&&"fixed"!==a||!g)return null;var A=Si("div",(0,Fr.c)({ref:b},ia((0,Br.c)((0,Br.c)({},e),{},{offset:g.offset,position:a,rect:g.rect}),"menuPortal",{"menu-portal":!0}),o),n);return Si(wa.Provider,{value:p},t?(0,Ci.createPortal)(A,t):A)},LoadingMessage:function(e){var t=e.children,n=void 0===t?"Loading...":t,r=e.innerProps,o=Nr(e,ba);return Si("div",(0,Fr.c)({},ia((0,Br.c)((0,Br.c)({},o),{},{children:n,innerProps:r}),"loadingMessage",{"menu-notice":!0,"menu-notice--loading":!0}),r),n)},NoOptionsMessage:function(e){var t=e.children,n=void 0===t?"No options":t,r=e.innerProps,o=Nr(e,va);return Si("div",(0,Fr.c)({},ia((0,Br.c)((0,Br.c)({},o),{},{children:n,innerProps:r}),"noOptionsMessage",{"menu-notice":!0,"menu-notice--no-options":!0}),r),n)},MultiValue:Ja,MultiValueContainer:Xa,MultiValueLabel:Xa,MultiValueRemove:function(e){var t=e.children,n=e.innerProps;return Si("div",(0,Fr.c)({role:"button"},n),t||Si(La,{size:14}))},Option:function(e){var t=e.children,n=e.isDisabled,r=e.isFocused,o=e.isSelected,i=e.innerRef,a=e.innerProps;return Si("div",(0,Fr.c)({},ia(e,"option",{option:!0,"option--is-disabled":n,"option--is-focused":r,"option--is-selected":o}),{ref:i,"aria-disabled":n},a),t)},Placeholder:function(e){var t=e.children,n=e.innerProps;return Si("div",(0,Fr.c)({},ia(e,"placeholder",{placeholder:!0}),n),t)},SelectContainer:function(e){var t=e.children,n=e.innerProps,r=e.isDisabled,o=e.isRtl;return Si("div",(0,Fr.c)({},ia(e,"container",{"--is-disabled":r,"--is-rtl":o}),n),t)},SingleValue:function(e){var t=e.children,n=e.isDisabled,r=e.innerProps;return Si("div",(0,Fr.c)({},ia(e,"singleValue",{"single-value":!0,"single-value--is-disabled":n}),r),t)},ValueContainer:function(e){var t=e.children,n=e.innerProps,r=e.isMulti,o=e.hasValue;return Si("div",(0,Fr.c)({},ia(e,"valueContainer",{"value-container":!0,"value-container--is-multi":r,"value-container--has-value":o}),n),t)}},$a=n(5232);for(var es={name:"7pg0cj-a11yText",styles:"label:a11yText;z-index:9999;border:0;clip:rect(1px, 1px, 1px, 1px);height:1px;width:1px;position:absolute;overflow:hidden;padding:0;white-space:nowrap"},ts=function(e){return Si("span",(0,Fr.c)({css:es},e))},ns={guidance:function(e){var t=e.isSearchable,n=e.isMulti,r=e.tabSelectsValue,o=e.context,i=e.isInitialFocus;switch(o){case"menu":return"Use Up and Down to choose options, press Enter to select the currently focused option, press Escape to exit the menu".concat(r?", press Tab to select the option and exit the menu":"",".");case"input":return i?"".concat(e["aria-label"]||"Select"," is focused ").concat(t?",type to refine list":"",", press Down to open the menu, ").concat(n?" press left to focus selected values":""):"";case"value":return"Use left and right to toggle between focused values, press Backspace to remove the currently focused value";default:return""}},onChange:function(e){var t=e.action,n=e.label,r=void 0===n?"":n,o=e.labels,i=e.isDisabled;switch(t){case"deselect-option":case"pop-value":case"remove-value":return"option ".concat(r,", deselected.");case"clear":return"All selected options have been cleared.";case"initial-input-focus":return"option".concat(o.length>1?"s":""," ").concat(o.join(","),", selected.");case"select-option":return"option ".concat(r,i?" is disabled. Select another option.":", selected.");default:return""}},onFocus:function(e){var t=e.context,n=e.focused,r=e.options,o=e.label,i=void 0===o?"":o,a=e.selectValue,s=e.isDisabled,l=e.isSelected,c=e.isAppleDevice,u=function(e,t){return e&&e.length?"".concat(e.indexOf(t)+1," of ").concat(e.length):""};if("value"===t&&a)return"value ".concat(i," focused, ").concat(u(a,n),".");if("menu"===t&&c){var d=s?" disabled":"",h="".concat(l?" selected":"").concat(d);return"".concat(i).concat(h,", ").concat(u(r,n),".")}return""},onFilter:function(e){var t=e.inputValue,n=e.resultsMessage;return"".concat(n).concat(t?" for search term "+t:"",".")}},rs=function(e){var t=e.ariaSelection,n=e.focusedOption,r=e.focusedValue,o=e.focusableOptions,i=e.isFocused,a=e.selectValue,s=e.selectProps,l=e.id,c=e.isAppleDevice,u=s.ariaLiveMessages,h=s.getOptionLabel,p=s.inputValue,f=s.isMulti,g=s.isOptionDisabled,m=s.isSearchable,y=s.menuIsOpen,v=s.options,b=s.screenReaderStatus,A=s.tabSelectsValue,x=s.isLoading,S=s["aria-label"],w=s["aria-live"],C=(0,d.useMemo)((function(){return(0,Br.c)((0,Br.c)({},ns),u||{})}),[u]),_=(0,d.useMemo)((function(){var e,n="";if(t&&C.onChange){var r=t.option,o=t.options,i=t.removedValue,s=t.removedValues,l=t.value,c=i||r||(e=l,Array.isArray(e)?null:e),u=c?h(c):"",d=o||s||void 0,p=d?d.map(h):[],f=(0,Br.c)({isDisabled:c&&g(c,a),label:u,labels:p},t);n=C.onChange(f)}return n}),[t,C,g,a,h]),E=(0,d.useMemo)((function(){var e="",t=n||r,i=!!(n&&a&&a.includes(n));if(t&&C.onFocus){var s={focused:t,label:h(t),isDisabled:g(t,a),isSelected:i,options:o,context:t===n?"menu":"value",selectValue:a,isAppleDevice:c};e=C.onFocus(s)}return e}),[n,r,h,g,C,o,a,c]),R=(0,d.useMemo)((function(){var e="";if(y&&v.length&&!x&&C.onFilter){var t=b({count:o.length});e=C.onFilter({inputValue:p,resultsMessage:t})}return e}),[o,p,y,C,v,b,x]),k="initial-input-focus"===(null===t||void 0===t?void 0:t.action),I=(0,d.useMemo)((function(){var e="";if(C.guidance){var t=r?"value":y?"menu":"input";e=C.guidance({"aria-label":S,context:t,isDisabled:n&&g(n,a),isMulti:f,isSearchable:m,tabSelectsValue:A,isInitialFocus:k})}return e}),[S,n,r,f,g,m,y,C,a,A,k]),T=Si(d.Fragment,null,Si("span",{id:"aria-selection"},_),Si("span",{id:"aria-focused"},E),Si("span",{id:"aria-results"},R),Si("span",{id:"aria-guidance"},I));return Si(d.Fragment,null,Si(ts,{id:l},k&&T),Si(ts,{"aria-live":w,"aria-atomic":"false","aria-relevant":"additions text",role:"log"},i&&!k&&T))},os=[{base:"A",letters:"A\u24b6\uff21\xc0\xc1\xc2\u1ea6\u1ea4\u1eaa\u1ea8\xc3\u0100\u0102\u1eb0\u1eae\u1eb4\u1eb2\u0226\u01e0\xc4\u01de\u1ea2\xc5\u01fa\u01cd\u0200\u0202\u1ea0\u1eac\u1eb6\u1e00\u0104\u023a\u2c6f"},{base:"AA",letters:"\ua732"},{base:"AE",letters:"\xc6\u01fc\u01e2"},{base:"AO",letters:"\ua734"},{base:"AU",letters:"\ua736"},{base:"AV",letters:"\ua738\ua73a"},{base:"AY",letters:"\ua73c"},{base:"B",letters:"B\u24b7\uff22\u1e02\u1e04\u1e06\u0243\u0182\u0181"},{base:"C",letters:"C\u24b8\uff23\u0106\u0108\u010a\u010c\xc7\u1e08\u0187\u023b\ua73e"},{base:"D",letters:"D\u24b9\uff24\u1e0a\u010e\u1e0c\u1e10\u1e12\u1e0e\u0110\u018b\u018a\u0189\ua779"},{base:"DZ",letters:"\u01f1\u01c4"},{base:"Dz",letters:"\u01f2\u01c5"},{base:"E",letters:"E\u24ba\uff25\xc8\xc9\xca\u1ec0\u1ebe\u1ec4\u1ec2\u1ebc\u0112\u1e14\u1e16\u0114\u0116\xcb\u1eba\u011a\u0204\u0206\u1eb8\u1ec6\u0228\u1e1c\u0118\u1e18\u1e1a\u0190\u018e"},{base:"F",letters:"F\u24bb\uff26\u1e1e\u0191\ua77b"},{base:"G",letters:"G\u24bc\uff27\u01f4\u011c\u1e20\u011e\u0120\u01e6\u0122\u01e4\u0193\ua7a0\ua77d\ua77e"},{base:"H",letters:"H\u24bd\uff28\u0124\u1e22\u1e26\u021e\u1e24\u1e28\u1e2a\u0126\u2c67\u2c75\ua78d"},{base:"I",letters:"I\u24be\uff29\xcc\xcd\xce\u0128\u012a\u012c\u0130\xcf\u1e2e\u1ec8\u01cf\u0208\u020a\u1eca\u012e\u1e2c\u0197"},{base:"J",letters:"J\u24bf\uff2a\u0134\u0248"},{base:"K",letters:"K\u24c0\uff2b\u1e30\u01e8\u1e32\u0136\u1e34\u0198\u2c69\ua740\ua742\ua744\ua7a2"},{base:"L",letters:"L\u24c1\uff2c\u013f\u0139\u013d\u1e36\u1e38\u013b\u1e3c\u1e3a\u0141\u023d\u2c62\u2c60\ua748\ua746\ua780"},{base:"LJ",letters:"\u01c7"},{base:"Lj",letters:"\u01c8"},{base:"M",letters:"M\u24c2\uff2d\u1e3e\u1e40\u1e42\u2c6e\u019c"},{base:"N",letters:"N\u24c3\uff2e\u01f8\u0143\xd1\u1e44\u0147\u1e46\u0145\u1e4a\u1e48\u0220\u019d\ua790\ua7a4"},{base:"NJ",letters:"\u01ca"},{base:"Nj",letters:"\u01cb"},{base:"O",letters:"O\u24c4\uff2f\xd2\xd3\xd4\u1ed2\u1ed0\u1ed6\u1ed4\xd5\u1e4c\u022c\u1e4e\u014c\u1e50\u1e52\u014e\u022e\u0230\xd6\u022a\u1ece\u0150\u01d1\u020c\u020e\u01a0\u1edc\u1eda\u1ee0\u1ede\u1ee2\u1ecc\u1ed8\u01ea\u01ec\xd8\u01fe\u0186\u019f\ua74a\ua74c"},{base:"OI",letters:"\u01a2"},{base:"OO",letters:"\ua74e"},{base:"OU",letters:"\u0222"},{base:"P",letters:"P\u24c5\uff30\u1e54\u1e56\u01a4\u2c63\ua750\ua752\ua754"},{base:"Q",letters:"Q\u24c6\uff31\ua756\ua758\u024a"},{base:"R",letters:"R\u24c7\uff32\u0154\u1e58\u0158\u0210\u0212\u1e5a\u1e5c\u0156\u1e5e\u024c\u2c64\ua75a\ua7a6\ua782"},{base:"S",letters:"S\u24c8\uff33\u1e9e\u015a\u1e64\u015c\u1e60\u0160\u1e66\u1e62\u1e68\u0218\u015e\u2c7e\ua7a8\ua784"},{base:"T",letters:"T\u24c9\uff34\u1e6a\u0164\u1e6c\u021a\u0162\u1e70\u1e6e\u0166\u01ac\u01ae\u023e\ua786"},{base:"TZ",letters:"\ua728"},{base:"U",letters:"U\u24ca\uff35\xd9\xda\xdb\u0168\u1e78\u016a\u1e7a\u016c\xdc\u01db\u01d7\u01d5\u01d9\u1ee6\u016e\u0170\u01d3\u0214\u0216\u01af\u1eea\u1ee8\u1eee\u1eec\u1ef0\u1ee4\u1e72\u0172\u1e76\u1e74\u0244"},{base:"V",letters:"V\u24cb\uff36\u1e7c\u1e7e\u01b2\ua75e\u0245"},{base:"VY",letters:"\ua760"},{base:"W",letters:"W\u24cc\uff37\u1e80\u1e82\u0174\u1e86\u1e84\u1e88\u2c72"},{base:"X",letters:"X\u24cd\uff38\u1e8a\u1e8c"},{base:"Y",letters:"Y\u24ce\uff39\u1ef2\xdd\u0176\u1ef8\u0232\u1e8e\u0178\u1ef6\u1ef4\u01b3\u024e\u1efe"},{base:"Z",letters:"Z\u24cf\uff3a\u0179\u1e90\u017b\u017d\u1e92\u1e94\u01b5\u0224\u2c7f\u2c6b\ua762"},{base:"a",letters:"a\u24d0\uff41\u1e9a\xe0\xe1\xe2\u1ea7\u1ea5\u1eab\u1ea9\xe3\u0101\u0103\u1eb1\u1eaf\u1eb5\u1eb3\u0227\u01e1\xe4\u01df\u1ea3\xe5\u01fb\u01ce\u0201\u0203\u1ea1\u1ead\u1eb7\u1e01\u0105\u2c65\u0250"},{base:"aa",letters:"\ua733"},{base:"ae",letters:"\xe6\u01fd\u01e3"},{base:"ao",letters:"\ua735"},{base:"au",letters:"\ua737"},{base:"av",letters:"\ua739\ua73b"},{base:"ay",letters:"\ua73d"},{base:"b",letters:"b\u24d1\uff42\u1e03\u1e05\u1e07\u0180\u0183\u0253"},{base:"c",letters:"c\u24d2\uff43\u0107\u0109\u010b\u010d\xe7\u1e09\u0188\u023c\ua73f\u2184"},{base:"d",letters:"d\u24d3\uff44\u1e0b\u010f\u1e0d\u1e11\u1e13\u1e0f\u0111\u018c\u0256\u0257\ua77a"},{base:"dz",letters:"\u01f3\u01c6"},{base:"e",letters:"e\u24d4\uff45\xe8\xe9\xea\u1ec1\u1ebf\u1ec5\u1ec3\u1ebd\u0113\u1e15\u1e17\u0115\u0117\xeb\u1ebb\u011b\u0205\u0207\u1eb9\u1ec7\u0229\u1e1d\u0119\u1e19\u1e1b\u0247\u025b\u01dd"},{base:"f",letters:"f\u24d5\uff46\u1e1f\u0192\ua77c"},{base:"g",letters:"g\u24d6\uff47\u01f5\u011d\u1e21\u011f\u0121\u01e7\u0123\u01e5\u0260\ua7a1\u1d79\ua77f"},{base:"h",letters:"h\u24d7\uff48\u0125\u1e23\u1e27\u021f\u1e25\u1e29\u1e2b\u1e96\u0127\u2c68\u2c76\u0265"},{base:"hv",letters:"\u0195"},{base:"i",letters:"i\u24d8\uff49\xec\xed\xee\u0129\u012b\u012d\xef\u1e2f\u1ec9\u01d0\u0209\u020b\u1ecb\u012f\u1e2d\u0268\u0131"},{base:"j",letters:"j\u24d9\uff4a\u0135\u01f0\u0249"},{base:"k",letters:"k\u24da\uff4b\u1e31\u01e9\u1e33\u0137\u1e35\u0199\u2c6a\ua741\ua743\ua745\ua7a3"},{base:"l",letters:"l\u24db\uff4c\u0140\u013a\u013e\u1e37\u1e39\u013c\u1e3d\u1e3b\u017f\u0142\u019a\u026b\u2c61\ua749\ua781\ua747"},{base:"lj",letters:"\u01c9"},{base:"m",letters:"m\u24dc\uff4d\u1e3f\u1e41\u1e43\u0271\u026f"},{base:"n",letters:"n\u24dd\uff4e\u01f9\u0144\xf1\u1e45\u0148\u1e47\u0146\u1e4b\u1e49\u019e\u0272\u0149\ua791\ua7a5"},{base:"nj",letters:"\u01cc"},{base:"o",letters:"o\u24de\uff4f\xf2\xf3\xf4\u1ed3\u1ed1\u1ed7\u1ed5\xf5\u1e4d\u022d\u1e4f\u014d\u1e51\u1e53\u014f\u022f\u0231\xf6\u022b\u1ecf\u0151\u01d2\u020d\u020f\u01a1\u1edd\u1edb\u1ee1\u1edf\u1ee3\u1ecd\u1ed9\u01eb\u01ed\xf8\u01ff\u0254\ua74b\ua74d\u0275"},{base:"oi",letters:"\u01a3"},{base:"ou",letters:"\u0223"},{base:"oo",letters:"\ua74f"},{base:"p",letters:"p\u24df\uff50\u1e55\u1e57\u01a5\u1d7d\ua751\ua753\ua755"},{base:"q",letters:"q\u24e0\uff51\u024b\ua757\ua759"},{base:"r",letters:"r\u24e1\uff52\u0155\u1e59\u0159\u0211\u0213\u1e5b\u1e5d\u0157\u1e5f\u024d\u027d\ua75b\ua7a7\ua783"},{base:"s",letters:"s\u24e2\uff53\xdf\u015b\u1e65\u015d\u1e61\u0161\u1e67\u1e63\u1e69\u0219\u015f\u023f\ua7a9\ua785\u1e9b"},{base:"t",letters:"t\u24e3\uff54\u1e6b\u1e97\u0165\u1e6d\u021b\u0163\u1e71\u1e6f\u0167\u01ad\u0288\u2c66\ua787"},{base:"tz",letters:"\ua729"},{base:"u",letters:"u\u24e4\uff55\xf9\xfa\xfb\u0169\u1e79\u016b\u1e7b\u016d\xfc\u01dc\u01d8\u01d6\u01da\u1ee7\u016f\u0171\u01d4\u0215\u0217\u01b0\u1eeb\u1ee9\u1eef\u1eed\u1ef1\u1ee5\u1e73\u0173\u1e77\u1e75\u0289"},{base:"v",letters:"v\u24e5\uff56\u1e7d\u1e7f\u028b\ua75f\u028c"},{base:"vy",letters:"\ua761"},{base:"w",letters:"w\u24e6\uff57\u1e81\u1e83\u0175\u1e87\u1e85\u1e98\u1e89\u2c73"},{base:"x",letters:"x\u24e7\uff58\u1e8b\u1e8d"},{base:"y",letters:"y\u24e8\uff59\u1ef3\xfd\u0177\u1ef9\u0233\u1e8f\xff\u1ef7\u1e99\u1ef5\u01b4\u024f\u1eff"},{base:"z",letters:"z\u24e9\uff5a\u017a\u1e91\u017c\u017e\u1e93\u1e95\u01b6\u0225\u0240\u2c6c\ua763"}],is=new RegExp("["+os.map((function(e){return e.letters})).join("")+"]","g"),as={},ss=0;ss1?t-1:0),r=1;r0,g=d-h-u,m=!1;g>t&&a.current&&(r&&r(e),a.current=!1),f&&s.current&&(i&&i(e),s.current=!1),f&&t>g?(n&&!a.current&&n(e),p.scrollTop=d,m=!0,a.current=!0):!f&&-t>u&&(o&&!s.current&&o(e),p.scrollTop=0,m=!0,s.current=!0),m&&ms(e)}}),[n,r,o,i]),h=(0,d.useCallback)((function(e){u(e,e.deltaY)}),[u]),p=(0,d.useCallback)((function(e){l.current=e.changedTouches[0].clientY}),[]),f=(0,d.useCallback)((function(e){var t=l.current-e.changedTouches[0].clientY;u(e,t)}),[u]),g=(0,d.useCallback)((function(e){if(e){var t=!!ga&&{passive:!1};e.addEventListener("wheel",h,t),e.addEventListener("touchstart",p,t),e.addEventListener("touchmove",f,t)}}),[f,p,h]),m=(0,d.useCallback)((function(e){e&&(e.removeEventListener("wheel",h,!1),e.removeEventListener("touchstart",p,!1),e.removeEventListener("touchmove",f,!1))}),[f,p,h]);return(0,d.useEffect)((function(){if(t){var e=c.current;return g(e),function(){m(e)}}}),[t,g,m]),function(e){c.current=e}}({isEnabled:void 0===r||r,onBottomArrive:e.onBottomArrive,onBottomLeave:e.onBottomLeave,onTopArrive:e.onTopArrive,onTopLeave:e.onTopLeave}),i=function(e){var t=e.isEnabled,n=e.accountForScrollbars,r=void 0===n||n,o=(0,d.useRef)({}),i=(0,d.useRef)(null),a=(0,d.useCallback)((function(e){if(ws){var t=document.body,n=t&&t.style;if(r&&ys.forEach((function(e){var t=n&&n[e];o.current[e]=t})),r&&Cs<1){var i=parseInt(o.current.paddingRight,10)||0,a=document.body?document.body.clientWidth:0,s=window.innerWidth-a+i||0;Object.keys(vs).forEach((function(e){var t=vs[e];n&&(n[e]=t)})),n&&(n.paddingRight="".concat(s,"px"))}t&&Ss()&&(t.addEventListener("touchmove",bs,_s),e&&(e.addEventListener("touchstart",xs,_s),e.addEventListener("touchmove",As,_s))),Cs+=1}}),[r]),s=(0,d.useCallback)((function(e){if(ws){var t=document.body,n=t&&t.style;Cs=Math.max(Cs-1,0),r&&Cs<1&&ys.forEach((function(e){var t=o.current[e];n&&(n[e]=t)})),t&&Ss()&&(t.removeEventListener("touchmove",bs,_s),e&&(e.removeEventListener("touchstart",xs,_s),e.removeEventListener("touchmove",As,_s)))}}),[r]);return(0,d.useEffect)((function(){if(t){var e=i.current;return a(e),function(){s(e)}}}),[t,a,s]),function(e){i.current=e}}({isEnabled:n});return Si(d.Fragment,null,n&&Si("div",{onClick:Es,css:Rs}),t((function(e){o(e),i(e)})))}var Is={name:"1a0ro4n-requiredInput",styles:"label:requiredInput;opacity:0;pointer-events:none;position:absolute;bottom:0;left:0;right:0;width:100%"},Ts=function(e){var t=e.name,n=e.onFocus;return Si("input",{required:!0,name:t,tabIndex:-1,"aria-hidden":"true",onFocus:n,css:Is,value:"",onChange:function(){}})};function Os(e){var t;return"undefined"!==typeof window&&null!=window.navigator&&e.test((null===(t=window.navigator.userAgentData)||void 0===t?void 0:t.platform)||window.navigator.platform)}function js(){return Os(/^Mac/i)}function Ps(){return Os(/^iPhone/i)||Os(/^iPad/i)||js()&&navigator.maxTouchPoints>1}var Bs={clearIndicator:Ua,container:function(e){var t=e.isDisabled;return{label:"container",direction:e.isRtl?"rtl":void 0,pointerEvents:t?"none":void 0,position:"relative"}},control:function(e,t){var n=e.isDisabled,r=e.isFocused,o=e.theme,i=o.colors,a=o.borderRadius,s=o.spacing;return(0,Br.c)({label:"control",alignItems:"center",cursor:"default",display:"flex",flexWrap:"wrap",justifyContent:"space-between",minHeight:s.controlHeight,outline:"0 !important",position:"relative",transition:"all 100ms"},t?{}:{backgroundColor:n?i.neutral5:i.neutral0,borderColor:n?i.neutral10:r?i.primary:i.neutral20,borderRadius:a,borderStyle:"solid",borderWidth:1,boxShadow:r?"0 0 0 1px ".concat(i.primary):void 0,"&:hover":{borderColor:r?i.primary:i.neutral30}})},dropdownIndicator:Na,group:function(e,t){var n=e.theme.spacing;return t?{}:{paddingBottom:2*n.baseUnit,paddingTop:2*n.baseUnit}},groupHeading:function(e,t){var n=e.theme,r=n.colors,o=n.spacing;return(0,Br.c)({label:"group",cursor:"default",display:"block"},t?{}:{color:r.neutral40,fontSize:"75%",fontWeight:500,marginBottom:"0.25em",paddingLeft:3*o.baseUnit,paddingRight:3*o.baseUnit,textTransform:"uppercase"})},indicatorsContainer:function(){return{alignItems:"center",alignSelf:"stretch",display:"flex",flexShrink:0}},indicatorSeparator:function(e,t){var n=e.isDisabled,r=e.theme,o=r.spacing.baseUnit,i=r.colors;return(0,Br.c)({label:"indicatorSeparator",alignSelf:"stretch",width:1},t?{}:{backgroundColor:n?i.neutral10:i.neutral20,marginBottom:2*o,marginTop:2*o})},input:function(e,t){var n=e.isDisabled,r=e.value,o=e.theme,i=o.spacing,a=o.colors;return(0,Br.c)((0,Br.c)({visibility:n?"hidden":"visible",transform:r?"translateZ(0)":""},Ya),t?{}:{margin:i.baseUnit/2,paddingBottom:i.baseUnit/2,paddingTop:i.baseUnit/2,color:a.neutral80})},loadingIndicator:function(e,t){var n=e.isFocused,r=e.size,o=e.theme,i=o.colors,a=o.spacing.baseUnit;return(0,Br.c)({label:"loadingIndicator",display:"flex",transition:"color 150ms",alignSelf:"center",fontSize:r,lineHeight:1,marginRight:r,textAlign:"center",verticalAlign:"middle"},t?{}:{color:n?i.neutral60:i.neutral20,padding:2*a})},loadingMessage:ka,menu:function(e,t){var n,r=e.placement,o=e.theme,i=o.borderRadius,a=o.spacing,s=o.colors;return(0,Br.c)((n={label:"menu"},(0,y.c)(n,function(e){return e?{bottom:"top",top:"bottom"}[e]:"bottom"}(r),"100%"),(0,y.c)(n,"position","absolute"),(0,y.c)(n,"width","100%"),(0,y.c)(n,"zIndex",1),n),t?{}:{backgroundColor:s.neutral0,borderRadius:i,boxShadow:"0 0 0 1px hsla(0, 0%, 0%, 0.1), 0 4px 11px hsla(0, 0%, 0%, 0.1)",marginBottom:a.menuGutter,marginTop:a.menuGutter})},menuList:function(e,t){var n=e.maxHeight,r=e.theme.spacing.baseUnit;return(0,Br.c)({maxHeight:n,overflowY:"auto",position:"relative",WebkitOverflowScrolling:"touch"},t?{}:{paddingBottom:r,paddingTop:r})},menuPortal:function(e){var t=e.rect,n=e.offset,r=e.position;return{left:t.left,position:r,top:n,width:t.width,zIndex:1}},multiValue:function(e,t){var n=e.theme,r=n.spacing,o=n.borderRadius,i=n.colors;return(0,Br.c)({label:"multiValue",display:"flex",minWidth:0},t?{}:{backgroundColor:i.neutral10,borderRadius:o/2,margin:r.baseUnit/2})},multiValueLabel:function(e,t){var n=e.theme,r=n.borderRadius,o=n.colors,i=e.cropWithEllipsis;return(0,Br.c)({overflow:"hidden",textOverflow:i||void 0===i?"ellipsis":void 0,whiteSpace:"nowrap"},t?{}:{borderRadius:r/2,color:o.neutral80,fontSize:"85%",padding:3,paddingLeft:6})},multiValueRemove:function(e,t){var n=e.theme,r=n.spacing,o=n.borderRadius,i=n.colors,a=e.isFocused;return(0,Br.c)({alignItems:"center",display:"flex"},t?{}:{borderRadius:o/2,backgroundColor:a?i.dangerLight:void 0,paddingLeft:r.baseUnit,paddingRight:r.baseUnit,":hover":{backgroundColor:i.dangerLight,color:i.danger}})},noOptionsMessage:Ra,option:function(e,t){var n=e.isDisabled,r=e.isFocused,o=e.isSelected,i=e.theme,a=i.spacing,s=i.colors;return(0,Br.c)({label:"option",cursor:"default",display:"block",fontSize:"inherit",width:"100%",userSelect:"none",WebkitTapHighlightColor:"rgba(0, 0, 0, 0)"},t?{}:{backgroundColor:o?s.primary:r?s.primary25:"transparent",color:n?s.neutral20:o?s.neutral0:"inherit",padding:"".concat(2*a.baseUnit,"px ").concat(3*a.baseUnit,"px"),":active":{backgroundColor:n?void 0:o?s.primary:s.primary50}})},placeholder:function(e,t){var n=e.theme,r=n.spacing,o=n.colors;return(0,Br.c)({label:"placeholder",gridArea:"1 / 1 / 2 / 3"},t?{}:{color:o.neutral50,marginLeft:r.baseUnit/2,marginRight:r.baseUnit/2})},singleValue:function(e,t){var n=e.isDisabled,r=e.theme,o=r.spacing,i=r.colors;return(0,Br.c)({label:"singleValue",gridArea:"1 / 1 / 2 / 3",maxWidth:"100%",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},t?{}:{color:n?i.neutral40:i.neutral80,marginLeft:o.baseUnit/2,marginRight:o.baseUnit/2})},valueContainer:function(e,t){var n=e.theme.spacing,r=e.isMulti,o=e.hasValue,i=e.selectProps.controlShouldRenderValue;return(0,Br.c)({alignItems:"center",display:r&&o&&i?"flex":"grid",flex:1,flexWrap:"wrap",WebkitOverflowScrolling:"touch",position:"relative",overflow:"hidden"},t?{}:{padding:"".concat(n.baseUnit/2,"px ").concat(2*n.baseUnit,"px")})}};var Ls,Ds={borderRadius:4,colors:{primary:"#2684FF",primary75:"#4C9AFF",primary50:"#B2D4FF",primary25:"#DEEBFF",danger:"#DE350B",dangerLight:"#FFBDAD",neutral0:"hsl(0, 0%, 100%)",neutral5:"hsl(0, 0%, 95%)",neutral10:"hsl(0, 0%, 90%)",neutral20:"hsl(0, 0%, 80%)",neutral30:"hsl(0, 0%, 70%)",neutral40:"hsl(0, 0%, 60%)",neutral50:"hsl(0, 0%, 50%)",neutral60:"hsl(0, 0%, 40%)",neutral70:"hsl(0, 0%, 30%)",neutral80:"hsl(0, 0%, 20%)",neutral90:"hsl(0, 0%, 10%)"},spacing:{baseUnit:4,controlHeight:38,menuGutter:8}},Ms={"aria-live":"polite",backspaceRemovesValue:!0,blurInputOnSelect:da(),captureMenuScroll:!da(),classNames:{},closeMenuOnSelect:!0,closeMenuOnScroll:!1,components:{},controlShouldRenderValue:!0,escapeClearsValue:!1,filterOption:function(e,t){if(e.data.__isNew__)return!0;var n=(0,Br.c)({ignoreCase:!0,ignoreAccents:!0,stringify:ps,trim:!0,matchFrom:"any"},Ls),r=n.ignoreCase,o=n.ignoreAccents,i=n.stringify,a=n.trim,s=n.matchFrom,l=a?hs(t):t,c=a?hs(i(e)):i(e);return r&&(l=l.toLowerCase(),c=c.toLowerCase()),o&&(l=ds(l),c=us(c)),"start"===s?c.substr(0,l.length)===l:c.indexOf(l)>-1},formatGroupLabel:function(e){return e.label},getOptionLabel:function(e){return e.label},getOptionValue:function(e){return e.value},isDisabled:!1,isLoading:!1,isMulti:!1,isRtl:!1,isSearchable:!0,isOptionDisabled:function(e){return!!e.isDisabled},loadingMessage:function(){return"Loading..."},maxMenuHeight:300,minMenuHeight:140,menuIsOpen:!1,menuPlacement:"bottom",menuPosition:"absolute",menuShouldBlockScroll:!1,menuShouldScrollIntoView:!function(){try{return/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)}catch(Tm){return!1}}(),noOptionsMessage:function(){return"No options"},openMenuOnFocus:!1,openMenuOnClick:!0,options:[],pageSize:5,placeholder:"Select...",screenReaderStatus:function(e){var t=e.count;return"".concat(t," result").concat(1!==t?"s":""," available")},styles:{},tabIndex:0,tabSelectsValue:!0,unstyled:!1};function Ns(e,t,n,r){return{type:"option",data:t,isDisabled:Qs(e,t,n),isSelected:Ys(e,t,n),label:Vs(e,t),value:Ws(e,t),index:r}}function Us(e,t){return e.options.map((function(n,r){if("options"in n){var o=n.options.map((function(n,r){return Ns(e,n,t,r)})).filter((function(t){return Gs(e,t)}));return o.length>0?{type:"group",data:n,options:o,index:r}:void 0}var i=Ns(e,n,t,r);return Gs(e,i)?i:void 0})).filter(ma)}function Fs(e){return e.reduce((function(e,t){return"group"===t.type?e.push.apply(e,qr(t.options.map((function(e){return e.data})))):e.push(t.data),e}),[])}function Hs(e,t){return e.reduce((function(e,n){return"group"===n.type?e.push.apply(e,qr(n.options.map((function(e){return{data:e.data,id:"".concat(t,"-").concat(n.index,"-").concat(e.index)}})))):e.push({data:n.data,id:"".concat(t,"-").concat(n.index)}),e}),[])}function Gs(e,t){var n=e.inputValue,r=void 0===n?"":n,o=t.data,i=t.isSelected,a=t.label,s=t.value;return(!qs(e)||!i)&&Ks(e,{label:a,value:s,data:o},r)}var zs=function(e,t){var n;return(null===(n=e.find((function(e){return e.data===t})))||void 0===n?void 0:n.id)||null},Vs=function(e,t){return e.getOptionLabel(t)},Ws=function(e,t){return e.getOptionValue(t)};function Qs(e,t,n){return"function"===typeof e.isOptionDisabled&&e.isOptionDisabled(t,n)}function Ys(e,t,n){if(n.indexOf(t)>-1)return!0;if("function"===typeof e.isOptionSelected)return e.isOptionSelected(t,n);var r=Ws(e,t);return n.some((function(t){return Ws(e,t)===r}))}function Ks(e,t,n){return!e.filterOption||e.filterOption(t,n)}var qs=function(e){var t=e.hideSelectedOptions,n=e.isMulti;return void 0===t?n:t},Xs=1,Js=function(e){!function(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&zr(e,t)}(i,e);var t,n,r,o=function(e){var t=Wr();return function(){var n,r=Vr(e);if(t){var o=Vr(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Yr(this,n)}}(i);function i(e){var t;if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),(t=o.call(this,e)).state={ariaSelection:null,focusedOption:null,focusedOptionId:null,focusableOptionsWithIds:[],focusedValue:null,inputIsHidden:!1,isFocused:!1,selectValue:[],clearFocusValueOnUpdate:!1,prevWasFocused:!1,inputIsHiddenAfterUpdate:void 0,prevProps:void 0,instancePrefix:""},t.blockOptionHover=!1,t.isComposing=!1,t.commonProps=void 0,t.initialTouchX=0,t.initialTouchY=0,t.openAfterFocus=!1,t.scrollToFocusedOptionOnUpdate=!1,t.userIsDragging=void 0,t.isAppleDevice=js()||Ps(),t.controlRef=null,t.getControlRef=function(e){t.controlRef=e},t.focusedOptionRef=null,t.getFocusedOptionRef=function(e){t.focusedOptionRef=e},t.menuListRef=null,t.getMenuListRef=function(e){t.menuListRef=e},t.inputRef=null,t.getInputRef=function(e){t.inputRef=e},t.focus=t.focusInput,t.blur=t.blurInput,t.onChange=function(e,n){var r=t.props,o=r.onChange,i=r.name;n.name=i,t.ariaOnChange(e,n),o(e,n)},t.setValue=function(e,n,r){var o=t.props,i=o.closeMenuOnSelect,a=o.isMulti,s=o.inputValue;t.onInputChange("",{action:"set-value",prevInputValue:s}),i&&(t.setState({inputIsHiddenAfterUpdate:!a}),t.onMenuClose()),t.setState({clearFocusValueOnUpdate:!0}),t.onChange(e,{action:n,option:r})},t.selectOption=function(e){var n=t.props,r=n.blurInputOnSelect,o=n.isMulti,i=n.name,a=t.state.selectValue,s=o&&t.isOptionSelected(e,a),l=t.isOptionDisabled(e,a);if(s){var c=t.getOptionValue(e);t.setValue(a.filter((function(e){return t.getOptionValue(e)!==c})),"deselect-option",e)}else{if(l)return void t.ariaOnChange(e,{action:"select-option",option:e,name:i});o?t.setValue([].concat(qr(a),[e]),"select-option",e):t.setValue(e,"select-option")}r&&t.blurInput()},t.removeValue=function(e){var n=t.props.isMulti,r=t.state.selectValue,o=t.getOptionValue(e),i=r.filter((function(e){return t.getOptionValue(e)!==o})),a=ya(n,i,i[0]||null);t.onChange(a,{action:"remove-value",removedValue:e}),t.focusInput()},t.clearValue=function(){var e=t.state.selectValue;t.onChange(ya(t.props.isMulti,[],null),{action:"clear",removedValues:e})},t.popValue=function(){var e=t.props.isMulti,n=t.state.selectValue,r=n[n.length-1],o=n.slice(0,n.length-1),i=ya(e,o,o[0]||null);t.onChange(i,{action:"pop-value",removedValue:r})},t.getFocusedOptionId=function(e){return zs(t.state.focusableOptionsWithIds,e)},t.getFocusableOptionsWithIds=function(){return Hs(Us(t.props,t.state.selectValue),t.getElementId("option"))},t.getValue=function(){return t.state.selectValue},t.cx=function(){for(var e=arguments.length,n=new Array(e),r=0;r5||i>5}},t.onTouchEnd=function(e){t.userIsDragging||(t.controlRef&&!t.controlRef.contains(e.target)&&t.menuListRef&&!t.menuListRef.contains(e.target)&&t.blurInput(),t.initialTouchX=0,t.initialTouchY=0)},t.onControlTouchEnd=function(e){t.userIsDragging||t.onControlMouseDown(e)},t.onClearIndicatorTouchEnd=function(e){t.userIsDragging||t.onClearIndicatorMouseDown(e)},t.onDropdownIndicatorTouchEnd=function(e){t.userIsDragging||t.onDropdownIndicatorMouseDown(e)},t.handleInputChange=function(e){var n=t.props.inputValue,r=e.currentTarget.value;t.setState({inputIsHiddenAfterUpdate:!1}),t.onInputChange(r,{action:"input-change",prevInputValue:n}),t.props.menuIsOpen||t.onMenuOpen()},t.onInputFocus=function(e){t.props.onFocus&&t.props.onFocus(e),t.setState({inputIsHiddenAfterUpdate:!1,isFocused:!0}),(t.openAfterFocus||t.props.openMenuOnFocus)&&t.openMenu("first"),t.openAfterFocus=!1},t.onInputBlur=function(e){var n=t.props.inputValue;t.menuListRef&&t.menuListRef.contains(document.activeElement)?t.inputRef.focus():(t.props.onBlur&&t.props.onBlur(e),t.onInputChange("",{action:"input-blur",prevInputValue:n}),t.onMenuClose(),t.setState({focusedValue:null,isFocused:!1}))},t.onOptionHover=function(e){if(!t.blockOptionHover&&t.state.focusedOption!==e){var n=t.getFocusableOptions().indexOf(e);t.setState({focusedOption:e,focusedOptionId:n>-1?t.getFocusedOptionId(e):null})}},t.shouldHideSelectedOptions=function(){return qs(t.props)},t.onValueInputFocus=function(e){e.preventDefault(),e.stopPropagation(),t.focus()},t.onKeyDown=function(e){var n=t.props,r=n.isMulti,o=n.backspaceRemovesValue,i=n.escapeClearsValue,a=n.inputValue,s=n.isClearable,l=n.isDisabled,c=n.menuIsOpen,u=n.onKeyDown,d=n.tabSelectsValue,h=n.openMenuOnFocus,p=t.state,f=p.focusedOption,g=p.focusedValue,m=p.selectValue;if(!l&&("function"!==typeof u||(u(e),!e.defaultPrevented))){switch(t.blockOptionHover=!0,e.key){case"ArrowLeft":if(!r||a)return;t.focusValue("previous");break;case"ArrowRight":if(!r||a)return;t.focusValue("next");break;case"Delete":case"Backspace":if(a)return;if(g)t.removeValue(g);else{if(!o)return;r?t.popValue():s&&t.clearValue()}break;case"Tab":if(t.isComposing)return;if(e.shiftKey||!c||!d||!f||h&&t.isOptionSelected(f,m))return;t.selectOption(f);break;case"Enter":if(229===e.keyCode)break;if(c){if(!f)return;if(t.isComposing)return;t.selectOption(f);break}return;case"Escape":c?(t.setState({inputIsHiddenAfterUpdate:!1}),t.onInputChange("",{action:"menu-close",prevInputValue:a}),t.onMenuClose()):s&&i&&t.clearValue();break;case" ":if(a)return;if(!c){t.openMenu("first");break}if(!f)return;t.selectOption(f);break;case"ArrowUp":c?t.focusOption("up"):t.openMenu("last");break;case"ArrowDown":c?t.focusOption("down"):t.openMenu("first");break;case"PageUp":if(!c)return;t.focusOption("pageup");break;case"PageDown":if(!c)return;t.focusOption("pagedown");break;case"Home":if(!c)return;t.focusOption("first");break;case"End":if(!c)return;t.focusOption("last");break;default:return}e.preventDefault()}},t.state.instancePrefix="react-select-"+(t.props.instanceId||++Xs),t.state.selectValue=ra(e.value),e.menuIsOpen&&t.state.selectValue.length){var n=t.getFocusableOptionsWithIds(),r=t.buildFocusableOptions(),a=r.indexOf(t.state.selectValue[0]);t.state.focusableOptionsWithIds=n,t.state.focusedOption=r[a],t.state.focusedOptionId=zs(n,r[a])}return t}return t=i,n=[{key:"componentDidMount",value:function(){this.startListeningComposition(),this.startListeningToTouch(),this.props.closeMenuOnScroll&&document&&document.addEventListener&&document.addEventListener("scroll",this.onScroll,!0),this.props.autoFocus&&this.focusInput(),this.props.menuIsOpen&&this.state.focusedOption&&this.menuListRef&&this.focusedOptionRef&&ua(this.menuListRef,this.focusedOptionRef)}},{key:"componentDidUpdate",value:function(e){var t=this.props,n=t.isDisabled,r=t.menuIsOpen,o=this.state.isFocused;(o&&!n&&e.isDisabled||o&&r&&!e.menuIsOpen)&&this.focusInput(),o&&n&&!e.isDisabled?this.setState({isFocused:!1},this.onMenuClose):o||n||!e.isDisabled||this.inputRef!==document.activeElement||this.setState({isFocused:!0}),this.menuListRef&&this.focusedOptionRef&&this.scrollToFocusedOptionOnUpdate&&(ua(this.menuListRef,this.focusedOptionRef),this.scrollToFocusedOptionOnUpdate=!1)}},{key:"componentWillUnmount",value:function(){this.stopListeningComposition(),this.stopListeningToTouch(),document.removeEventListener("scroll",this.onScroll,!0)}},{key:"onMenuOpen",value:function(){this.props.onMenuOpen()}},{key:"onMenuClose",value:function(){this.onInputChange("",{action:"menu-close",prevInputValue:this.props.inputValue}),this.props.onMenuClose()}},{key:"onInputChange",value:function(e,t){this.props.onInputChange(e,t)}},{key:"focusInput",value:function(){this.inputRef&&this.inputRef.focus()}},{key:"blurInput",value:function(){this.inputRef&&this.inputRef.blur()}},{key:"openMenu",value:function(e){var t=this,n=this.state,r=n.selectValue,o=n.isFocused,i=this.buildFocusableOptions(),a="first"===e?0:i.length-1;if(!this.props.isMulti){var s=i.indexOf(r[0]);s>-1&&(a=s)}this.scrollToFocusedOptionOnUpdate=!(o&&this.menuListRef),this.setState({inputIsHiddenAfterUpdate:!1,focusedValue:null,focusedOption:i[a],focusedOptionId:this.getFocusedOptionId(i[a])},(function(){return t.onMenuOpen()}))}},{key:"focusValue",value:function(e){var t=this.state,n=t.selectValue,r=t.focusedValue;if(this.props.isMulti){this.setState({focusedOption:null});var o=n.indexOf(r);r||(o=-1);var i=n.length-1,a=-1;if(n.length){switch(e){case"previous":a=0===o?0:-1===o?i:o-1;break;case"next":o>-1&&o0&&void 0!==arguments[0]?arguments[0]:"first",t=this.props.pageSize,n=this.state.focusedOption,r=this.getFocusableOptions();if(r.length){var o=0,i=r.indexOf(n);n||(i=-1),"up"===e?o=i>0?i-1:r.length-1:"down"===e?o=(i+1)%r.length:"pageup"===e?(o=i-t)<0&&(o=0):"pagedown"===e?(o=i+t)>r.length-1&&(o=r.length-1):"last"===e&&(o=r.length-1),this.scrollToFocusedOptionOnUpdate=!0,this.setState({focusedOption:r[o],focusedValue:null,focusedOptionId:this.getFocusedOptionId(r[o])})}}},{key:"getTheme",value:function(){return this.props.theme?"function"===typeof this.props.theme?this.props.theme(Ds):(0,Br.c)((0,Br.c)({},Ds),this.props.theme):Ds}},{key:"getCommonProps",value:function(){var e=this.clearValue,t=this.cx,n=this.getStyles,r=this.getClassNames,o=this.getValue,i=this.selectOption,a=this.setValue,s=this.props,l=s.isMulti,c=s.isRtl,u=s.options;return{clearValue:e,cx:t,getStyles:n,getClassNames:r,getValue:o,hasValue:this.hasValue(),isMulti:l,isRtl:c,options:u,selectOption:i,selectProps:s,setValue:a,theme:this.getTheme()}}},{key:"hasValue",value:function(){return this.state.selectValue.length>0}},{key:"hasOptions",value:function(){return!!this.getFocusableOptions().length}},{key:"isClearable",value:function(){var e=this.props,t=e.isClearable,n=e.isMulti;return void 0===t?n:t}},{key:"isOptionDisabled",value:function(e,t){return Qs(this.props,e,t)}},{key:"isOptionSelected",value:function(e,t){return Ys(this.props,e,t)}},{key:"filterOption",value:function(e,t){return Ks(this.props,e,t)}},{key:"formatOptionLabel",value:function(e,t){if("function"===typeof this.props.formatOptionLabel){var n=this.props.inputValue,r=this.state.selectValue;return this.props.formatOptionLabel(e,{context:t,inputValue:n,selectValue:r})}return this.getOptionLabel(e)}},{key:"formatGroupLabel",value:function(e){return this.props.formatGroupLabel(e)}},{key:"startListeningComposition",value:function(){document&&document.addEventListener&&(document.addEventListener("compositionstart",this.onCompositionStart,!1),document.addEventListener("compositionend",this.onCompositionEnd,!1))}},{key:"stopListeningComposition",value:function(){document&&document.removeEventListener&&(document.removeEventListener("compositionstart",this.onCompositionStart),document.removeEventListener("compositionend",this.onCompositionEnd))}},{key:"startListeningToTouch",value:function(){document&&document.addEventListener&&(document.addEventListener("touchstart",this.onTouchStart,!1),document.addEventListener("touchmove",this.onTouchMove,!1),document.addEventListener("touchend",this.onTouchEnd,!1))}},{key:"stopListeningToTouch",value:function(){document&&document.removeEventListener&&(document.removeEventListener("touchstart",this.onTouchStart),document.removeEventListener("touchmove",this.onTouchMove),document.removeEventListener("touchend",this.onTouchEnd))}},{key:"renderInput",value:function(){var e=this.props,t=e.isDisabled,n=e.isSearchable,r=e.inputId,o=e.inputValue,i=e.tabIndex,a=e.form,s=e.menuIsOpen,l=e.required,c=this.getComponents().Input,u=this.state,h=u.inputIsHidden,p=u.ariaSelection,f=this.commonProps,g=r||this.getElementId("input"),m=(0,Br.c)((0,Br.c)((0,Br.c)({"aria-autocomplete":"list","aria-expanded":s,"aria-haspopup":!0,"aria-errormessage":this.props["aria-errormessage"],"aria-invalid":this.props["aria-invalid"],"aria-label":this.props["aria-label"],"aria-labelledby":this.props["aria-labelledby"],"aria-required":l,role:"combobox","aria-activedescendant":this.isAppleDevice?void 0:this.state.focusedOptionId||""},s&&{"aria-controls":this.getElementId("listbox")}),!n&&{"aria-readonly":!0}),this.hasValue()?"initial-input-focus"===(null===p||void 0===p?void 0:p.action)&&{"aria-describedby":this.getElementId("live-region")}:{"aria-describedby":this.getElementId("placeholder")});return n?d.createElement(c,(0,Fr.c)({},f,{autoCapitalize:"none",autoComplete:"off",autoCorrect:"off",id:g,innerRef:this.getInputRef,isDisabled:t,isHidden:h,onBlur:this.onInputBlur,onChange:this.handleInputChange,onFocus:this.onInputFocus,spellCheck:"false",tabIndex:i,form:a,type:"text",value:o},m)):d.createElement(gs,(0,Fr.c)({id:g,innerRef:this.getInputRef,onBlur:this.onInputBlur,onChange:ea,onFocus:this.onInputFocus,disabled:t,tabIndex:i,inputMode:"none",form:a,value:""},m))}},{key:"renderPlaceholderOrValue",value:function(){var e=this,t=this.getComponents(),n=t.MultiValue,r=t.MultiValueContainer,o=t.MultiValueLabel,i=t.MultiValueRemove,a=t.SingleValue,s=t.Placeholder,l=this.commonProps,c=this.props,u=c.controlShouldRenderValue,h=c.isDisabled,p=c.isMulti,f=c.inputValue,g=c.placeholder,m=this.state,y=m.selectValue,v=m.focusedValue,b=m.isFocused;if(!this.hasValue()||!u)return f?null:d.createElement(s,(0,Fr.c)({},l,{key:"placeholder",isDisabled:h,isFocused:b,innerProps:{id:this.getElementId("placeholder")}}),g);if(p)return y.map((function(t,a){var s=t===v,c="".concat(e.getOptionLabel(t),"-").concat(e.getOptionValue(t));return d.createElement(n,(0,Fr.c)({},l,{components:{Container:r,Label:o,Remove:i},isFocused:s,isDisabled:h,key:c,index:a,removeProps:{onClick:function(){return e.removeValue(t)},onTouchEnd:function(){return e.removeValue(t)},onMouseDown:function(e){e.preventDefault()}},data:t}),e.formatOptionLabel(t,"value"))}));if(f)return null;var A=y[0];return d.createElement(a,(0,Fr.c)({},l,{data:A,isDisabled:h}),this.formatOptionLabel(A,"value"))}},{key:"renderClearIndicator",value:function(){var e=this.getComponents().ClearIndicator,t=this.commonProps,n=this.props,r=n.isDisabled,o=n.isLoading,i=this.state.isFocused;if(!this.isClearable()||!e||r||!this.hasValue()||o)return null;var a={onMouseDown:this.onClearIndicatorMouseDown,onTouchEnd:this.onClearIndicatorTouchEnd,"aria-hidden":"true"};return d.createElement(e,(0,Fr.c)({},t,{innerProps:a,isFocused:i}))}},{key:"renderLoadingIndicator",value:function(){var e=this.getComponents().LoadingIndicator,t=this.commonProps,n=this.props,r=n.isDisabled,o=n.isLoading,i=this.state.isFocused;return e&&o?d.createElement(e,(0,Fr.c)({},t,{innerProps:{"aria-hidden":"true"},isDisabled:r,isFocused:i})):null}},{key:"renderIndicatorSeparator",value:function(){var e=this.getComponents(),t=e.DropdownIndicator,n=e.IndicatorSeparator;if(!t||!n)return null;var r=this.commonProps,o=this.props.isDisabled,i=this.state.isFocused;return d.createElement(n,(0,Fr.c)({},r,{isDisabled:o,isFocused:i}))}},{key:"renderDropdownIndicator",value:function(){var e=this.getComponents().DropdownIndicator;if(!e)return null;var t=this.commonProps,n=this.props.isDisabled,r=this.state.isFocused,o={onMouseDown:this.onDropdownIndicatorMouseDown,onTouchEnd:this.onDropdownIndicatorTouchEnd,"aria-hidden":"true"};return d.createElement(e,(0,Fr.c)({},t,{innerProps:o,isDisabled:n,isFocused:r}))}},{key:"renderMenu",value:function(){var e=this,t=this.getComponents(),n=t.Group,r=t.GroupHeading,o=t.Menu,i=t.MenuList,a=t.MenuPortal,s=t.LoadingMessage,l=t.NoOptionsMessage,c=t.Option,u=this.commonProps,h=this.state.focusedOption,p=this.props,f=p.captureMenuScroll,g=p.inputValue,m=p.isLoading,y=p.loadingMessage,v=p.minMenuHeight,b=p.maxMenuHeight,A=p.menuIsOpen,x=p.menuPlacement,S=p.menuPosition,w=p.menuPortalTarget,C=p.menuShouldBlockScroll,_=p.menuShouldScrollIntoView,E=p.noOptionsMessage,R=p.onMenuScrollToTop,k=p.onMenuScrollToBottom;if(!A)return null;var I,T=function(t,n){var r=t.type,o=t.data,i=t.isDisabled,a=t.isSelected,s=t.label,l=t.value,p=h===o,f=i?void 0:function(){return e.onOptionHover(o)},g=i?void 0:function(){return e.selectOption(o)},m="".concat(e.getElementId("option"),"-").concat(n),y={id:m,onClick:g,onMouseMove:f,onMouseOver:f,tabIndex:-1,role:"option","aria-selected":e.isAppleDevice?void 0:a};return d.createElement(c,(0,Fr.c)({},u,{innerProps:y,data:o,isDisabled:i,isSelected:a,key:m,label:s,type:r,value:l,isFocused:p,innerRef:p?e.getFocusedOptionRef:void 0}),e.formatOptionLabel(t.data,"menu"))};if(this.hasOptions())I=this.getCategorizedOptions().map((function(t){if("group"===t.type){var o=t.data,i=t.options,a=t.index,s="".concat(e.getElementId("group"),"-").concat(a),l="".concat(s,"-heading");return d.createElement(n,(0,Fr.c)({},u,{key:s,data:o,options:i,Heading:r,headingProps:{id:l,data:t.data},label:e.formatGroupLabel(t.data)}),t.options.map((function(e){return T(e,"".concat(a,"-").concat(e.index))})))}if("option"===t.type)return T(t,"".concat(t.index))}));else if(m){var O=y({inputValue:g});if(null===O)return null;I=d.createElement(s,u,O)}else{var j=E({inputValue:g});if(null===j)return null;I=d.createElement(l,u,j)}var P={minMenuHeight:v,maxMenuHeight:b,menuPlacement:x,menuPosition:S,menuShouldScrollIntoView:_},B=d.createElement(Ca,(0,Fr.c)({},u,P),(function(t){var n=t.ref,r=t.placerProps,a=r.placement,s=r.maxHeight;return d.createElement(o,(0,Fr.c)({},u,P,{innerRef:n,innerProps:{onMouseDown:e.onMenuMouseDown,onMouseMove:e.onMenuMouseMove},isLoading:m,placement:a}),d.createElement(ks,{captureEnabled:f,onTopArrive:R,onBottomArrive:k,lockEnabled:C},(function(t){return d.createElement(i,(0,Fr.c)({},u,{innerRef:function(n){e.getMenuListRef(n),t(n)},innerProps:{role:"listbox","aria-multiselectable":u.isMulti,id:e.getElementId("listbox")},isLoading:m,maxHeight:s,focusedOption:h}),I)})))}));return w||"fixed"===S?d.createElement(a,(0,Fr.c)({},u,{appendTo:w,controlElement:this.controlRef,menuPlacement:x,menuPosition:S}),B):B}},{key:"renderFormField",value:function(){var e=this,t=this.props,n=t.delimiter,r=t.isDisabled,o=t.isMulti,i=t.name,a=t.required,s=this.state.selectValue;if(a&&!this.hasValue()&&!r)return d.createElement(Ts,{name:i,onFocus:this.onValueInputFocus});if(i&&!r){if(o){if(n){var l=s.map((function(t){return e.getOptionValue(t)})).join(n);return d.createElement("input",{name:i,type:"hidden",value:l})}var c=s.length>0?s.map((function(t,n){return d.createElement("input",{key:"i-".concat(n),name:i,type:"hidden",value:e.getOptionValue(t)})})):d.createElement("input",{name:i,type:"hidden",value:""});return d.createElement("div",null,c)}var u=s[0]?this.getOptionValue(s[0]):"";return d.createElement("input",{name:i,type:"hidden",value:u})}}},{key:"renderLiveRegion",value:function(){var e=this.commonProps,t=this.state,n=t.ariaSelection,r=t.focusedOption,o=t.focusedValue,i=t.isFocused,a=t.selectValue,s=this.getFocusableOptions();return d.createElement(rs,(0,Fr.c)({},e,{id:this.getElementId("live-region"),ariaSelection:n,focusedOption:r,focusedValue:o,isFocused:i,selectValue:a,focusableOptions:s,isAppleDevice:this.isAppleDevice}))}},{key:"render",value:function(){var e=this.getComponents(),t=e.Control,n=e.IndicatorsContainer,r=e.SelectContainer,o=e.ValueContainer,i=this.props,a=i.className,s=i.id,l=i.isDisabled,c=i.menuIsOpen,u=this.state.isFocused,h=this.commonProps=this.getCommonProps();return d.createElement(r,(0,Fr.c)({},h,{className:a,innerProps:{id:s,onKeyDown:this.onKeyDown},isDisabled:l,isFocused:u}),this.renderLiveRegion(),d.createElement(t,(0,Fr.c)({},h,{innerRef:this.getControlRef,innerProps:{onMouseDown:this.onControlMouseDown,onTouchEnd:this.onControlTouchEnd},isDisabled:l,isFocused:u,menuIsOpen:c}),d.createElement(o,(0,Fr.c)({},h,{isDisabled:l}),this.renderPlaceholderOrValue(),this.renderInput()),d.createElement(n,(0,Fr.c)({},h,{isDisabled:l}),this.renderClearIndicator(),this.renderLoadingIndicator(),this.renderIndicatorSeparator(),this.renderDropdownIndicator())),this.renderMenu(),this.renderFormField())}}],r=[{key:"getDerivedStateFromProps",value:function(e,t){var n=t.prevProps,r=t.clearFocusValueOnUpdate,o=t.inputIsHiddenAfterUpdate,i=t.ariaSelection,a=t.isFocused,s=t.prevWasFocused,l=t.instancePrefix,c=e.options,u=e.value,d=e.menuIsOpen,h=e.inputValue,p=e.isMulti,f=ra(u),g={};if(n&&(u!==n.value||c!==n.options||d!==n.menuIsOpen||h!==n.inputValue)){var m=d?function(e,t){return Fs(Us(e,t))}(e,f):[],y=d?Hs(Us(e,f),"".concat(l,"-option")):[],v=r?function(e,t){var n=e.focusedValue,r=e.selectValue.indexOf(n);if(r>-1){if(t.indexOf(n)>-1)return n;if(r-1?n:t[0]}(t,m);g={selectValue:f,focusedOption:b,focusedOptionId:zs(y,b),focusableOptionsWithIds:y,focusedValue:v,clearFocusValueOnUpdate:!1}}var A=null!=o&&e!==n?{inputIsHidden:o,inputIsHiddenAfterUpdate:void 0}:{},x=i,S=a&&s;return a&&!S&&(x={value:ya(p,f,f[0]||null),options:f,action:"initial-input-focus"},S=!s),"initial-input-focus"===(null===i||void 0===i?void 0:i.action)&&(x=null),(0,Br.c)((0,Br.c)((0,Br.c)({},g),A),{},{prevProps:e,ariaSelection:x,prevWasFocused:S})}}],n&&Gr(t.prototype,n),r&&Gr(t,r),Object.defineProperty(t,"prototype",{writable:!1}),i}(d.Component);Js.defaultProps=Ms;var Zs=(0,d.forwardRef)((function(e,t){var n=function(e){var t=e.defaultInputValue,n=void 0===t?"":t,r=e.defaultMenuIsOpen,o=void 0!==r&&r,i=e.defaultValue,a=void 0===i?null:i,s=e.inputValue,l=e.menuIsOpen,c=e.onChange,u=e.onInputChange,h=e.onMenuClose,p=e.onMenuOpen,f=e.value,g=Nr(e,Ur),m=Dr((0,d.useState)(void 0!==s?s:n),2),y=m[0],v=m[1],b=Dr((0,d.useState)(void 0!==l?l:o),2),A=b[0],x=b[1],S=Dr((0,d.useState)(void 0!==f?f:a),2),w=S[0],C=S[1],_=(0,d.useCallback)((function(e,t){"function"===typeof c&&c(e,t),C(e)}),[c]),E=(0,d.useCallback)((function(e,t){var n;"function"===typeof u&&(n=u(e,t)),v(void 0!==n?n:e)}),[u]),R=(0,d.useCallback)((function(){"function"===typeof p&&p(),x(!0)}),[p]),k=(0,d.useCallback)((function(){"function"===typeof h&&h(),x(!1)}),[h]),I=void 0!==s?s:y,T=void 0!==l?l:A,O=void 0!==f?f:w;return(0,Br.c)((0,Br.c)({},g),{},{inputValue:I,menuIsOpen:T,onChange:_,onInputChange:E,onMenuClose:k,onMenuOpen:R,value:O})}(e);return d.createElement(Js,(0,Fr.c)({ref:t},n))})),$s=Zs;const el=e=>(0,An.jsx)($s,{value:e.value?{value:e.value,label:(0,hn._)(e.values[e.value])}:{value:"",label:(0,hn._)(e.label)},onChange:t=>e.onChange(null===t||void 0===t?void 0:t.value),menuPortalTarget:document.body,placeholder:(0,hn._)(e.label),styles:{container:e=>({...e,width:"100%",marginTop:10,marginBottom:10}),menuPortal:e=>({...e,zIndex:9999})},options:Object.keys(e.values).map((t=>({value:t,label:(0,hn._)(e.values[t])}))).sort(((e,t)=>e.label.localeCompare(t.label)))}),tl=b.c.create({out_top_xs:{marginTop:4},out_top_s:{marginTop:8},out_top_m:{marginTop:16},out_top_l:{marginTop:32},out_top_xl:{marginTop:40},out_bottom_xs:{marginBottom:4},out_bottom_s:{marginBottom:8},out_bottom_m:{marginBottom:16},out_bottom_l:{marginBottom:32},out_bottom_xl:{marginBottom:40},in_bottom_xs:{paddingBottom:4},in_bottom_s:{paddingBottom:8},in_bottom_m:{paddingBottom:16},in_bottom_l:{paddingBottom:32},in_bottom_xl:{paddingBottom:40},out_right_xs:{marginRight:4},out_right_s:{marginRight:8},out_right_m:{marginRight:16},out_right_l:{marginRight:32},out_right_xl:{marginRight:40},out_left_xs:{marginLeft:4},out_left_s:{marginLeft:8},out_left_m:{marginLeft:16},out_left_l:{marginLeft:32}}),nl={fr:"Cr\xe9er un compte",en:"Create en account"},rl={fr:"Code d'invitation",en:"Invitation code"},ol={fr:"Pr\xe9nom",en:"First name"},il={fr:"Nom",en:"Name"},al={fr:"Pays",en:"Country"},sl={fr:"E-mail professionnel",en:"Professional e-mail address"},ll={fr:"Mot de passe",en:"Password"},cl={fr:"En continuant, vous acceptez les CGU de m\xe3o boa",en:"By continuing, you agree to the terms of use of m\xe3o boa"},ul={fr:"Vous avez d\xe9j\xe0 un compte ?",en:"You already have an account?"},dl={fr:"Se connecter",en:"Login"},hl={fr:"Veuillez indiquer un code d'invitation",en:"Please enter an invitation code"},pl={fr:"Veuillez indiquer votre pr\xe9nom",en:"Please enter your firstname"},fl={fr:"Veuillez indiquer votre nom",en:"Please enter your lastname"},gl={fr:"Saisissez une adresse e-mail professionnelle valide",en:"Enter a valid professional email address"},ml={fr:"Veuillez indiquer votre pays",en:"Please enter your country"},yl=e=>({fr:"Doit comporter au minimum ".concat(e," caract\xe8res, dont 1 minuscule, 1 majuscule, 1 chiffre et 1 caract\xe8re sp\xe9cial"),en:"Must contain at least ".concat(e," characters, including 1 lowercase, 1 uppercase, 1 number and 1 special character")}),vl=e=>({fr:"La cr\xe9ation de votre compte n'a pas pu \xeatre valid\xe9e car le syst\xe8me a d\xe9tect\xe9 que vous \xe9tiez un robot, veuillez r\xe9essayer en ".concat(e?"rafra\xeechissant la page":"relan\xe7ant l'application",", ou en contactant le support si le probl\xe8me persiste :"),en:"Your account could not be validated because the system detected that you were a robot, please try again by ".concat(e?"refreshing the page":"restarting the application",", or contact support if the problem persists:")}),bl=e=>{const t=d.useContext(yn.S),[r,o]=d.useState(!1),[i,a]=d.useState(e.fields.reduce(((e,t,n)=>(e[n]="",e)),{})),s=(e,t)=>{const n={};return 0===e&&(n.borderTopRightRadius=10,n.borderTopLeftRadius=10),e===t-1&&(n.borderBottomRightRadius=10,n.borderBottomLeftRadius=10),n},l=t=>n=>{const r=e.fields[t];if(r.onChange(n),e.setReady){let s;if("email"===(null===r||void 0===r?void 0:r.type))(o=n)&&/^(([^<>()[\]\.,;:\s@\"]+(\.[^<>()[\]\.,;:\s@\"]+)*)|(\".+\"))@(([^<>()[\]\.,;:\s@\"]+\.)+[^<>()[\]\.,;:\s@\"]{2,})$/i.test(o.trim().toLowerCase())||(s=(0,hn._)(gl));else if(r.password){const e="cmacgm"===c.Y.name?15:8;("undefined"===typeof n||n.length{if("undefined"===typeof t)return(0,An.jsx)(p.c,{},a);let c;return c="choices"===t.type?(0,An.jsx)(el,{value:t.value,onChange:l(a),values:t.values||{},label:{fr:"Choisir votre pays",en:"Choose your country"}}):(0,An.jsx)(kt.c,{placeholder:t.name,secureTextEntry:t.password&&!r,autoComplete:t.password?"password":t.type,keyboardType:"email"===t.type?"email-address":"default",onChangeText:l(a),placeholderTextColor:u.y.GREY2,style:[{height:50},e.inputStyle,{flex:1},pr.body1,fr.black]}),[(0,An.jsxs)(p.c,{style:[s(a+(e.before?1:0),e.fields.length+(e.before?1:0)),{flexDirection:"row",backgroundColor:"white",width:"100%",alignItems:"center"}],children:[c,t.password&&(0,An.jsx)(cn.c,{onPress:()=>o(!r),style:{marginLeft:10,marginRight:10},children:(0,An.jsx)(le.c,{source:n(r?7964:9396),style:{width:24,height:24}})})]},"field-".concat(a)),(0,An.jsx)(yr,{color:u.y.GREY1,bgColor:u.y.GREY1,minWidth:"100%",height:1,margin:16,style:[e.inputStyle]},"separator-".concat(a)),(0,An.jsx)(p.c,{children:!!i[a]&&(0,An.jsx)(En,{children:i[a],style:[pr.body2,fr.red,tl.out_top_xs,tl.out_bottom_s]})},"error-".concat(a))]}))]})},Al=b.c.create({touchable:{borderRadius:20,shadowRadius:2},text:{textAlign:"center",marginTop:8,marginBottom:8}}),xl=e=>(0,An.jsxs)(cn.c,{onPress:e.onPress,disabled:e.disabled,style:["web"===r.default.OS?{shadowColor:"none"}:{},Al.touchable,"undefined"!==typeof e.color?{}:{borderWidth:1,borderColor:"#fff"},{backgroundColor:e.color,justifyContent:"center",flexDirection:"row",alignItems:"center"},e.style],children:["undefined"!==typeof e.sideLeft&&e.sideLeft,"undefined"!==typeof e.children?(0,An.jsx)(En,{style:[Al.text,"undefined"!==typeof e.textColor?{color:e.textColor}:{color:"white"},{fontSize:e.fontSize||17,fontWeight:e.fontWeight}],children:e.children}):(0,An.jsx)(le.c,{style:{height:30,width:30,resizeMode:"contain",alignSelf:"center"},source:"white"===e.color?n(3048):n(340)}),"undefined"!==typeof e.side&&e.side]}),Sl={fr:"Pr\xeat.e \xe0 vous engager dans l'impact environnemental et social de votre organisation ?",en:"Ready to get involved in the social & environmental impact of your organization?"},wl={fr:"Informez vous sur l'impact, contribuez aux initiatives RSE de votre organisation et mesurez votre contribution.",en:"Get informed on environnmental and social issues, contribute to CSR initiatives within your organization and measure your impact."},Cl={fr:"S'inscrire avec votre e-mail",en:"Register with your email"},_l={fr:"Se connecter avec votre e-mail",en:"Login with your email"},El=(e,t)=>"company"===e?{fr:"Aucune organisation ne correspond au format de l'adresse e-mail de votre compte ".concat(t,"."),en:"No organization matches the format of your account's email address ".concat(t,".")}:{fr:"Une erreur inconnue est survenue lors de la connexion avec ".concat(t,", veuillez r\xe9essayer ou contacter le support si le probl\xe8me persiste."),en:"An unknown error occured while connecting with ".concat(t,", please try again or contact support if the problem persists.")},Rl={AD:{en:"Andorra",fr:"Andorre"},AE:{en:"United Arab Emirates",fr:"\xc9mirats Arabes Unis"},AF:{en:"Afghanistan",fr:"Afghanistan"},AG:{en:"Antigua and Barbuda",fr:"Antigua-et-Barbuda"},AI:{en:"Anguilla",fr:"Anguilla"},AL:{en:"Albania",fr:"Albanie"},AM:{en:"Armenia",fr:"Arm\xe9nie"},AN:{en:"Netherlands Antilles",fr:"Antilles N\xe9erlandaises"},AO:{en:"Angola",fr:"Angola"},AQ:{en:"Antarctica",fr:"Antarctique"},AR:{en:"Argentina",fr:"Argentine"},AS:{en:"American Samoa",fr:"Samoa Am\xe9ricaines"},AT:{en:"Austria",fr:"Autriche"},AU:{en:"Australia",fr:"Australie"},AW:{en:"Aruba",fr:"Aruba"},AZ:{en:"Azerbaijan",fr:"Azerba\xefdjan"},BA:{en:"Bosnia and Herzegovina",fr:"Bosnie-Herz\xe9govine"},BB:{en:"Barbados",fr:"Barbade"},BD:{en:"Bangladesh",fr:"Bangladesh"},BE:{en:"Belgium",fr:"Belgique"},BF:{en:"Burkina Faso",fr:"Burkina Faso"},BG:{en:"Bulgaria",fr:"Bulgarie"},BH:{en:"Bahrain",fr:"Bahre\xefn"},BI:{en:"Burundi",fr:"Burundi"},BJ:{en:"Benin",fr:"B\xe9nin"},BM:{en:"Bermuda",fr:"Bermudes"},BN:{en:"Brunei Darussalam",fr:"Brun\xe9i Darussalam"},BO:{en:"Bolivia",fr:"Bolivie"},BR:{en:"Brazil",fr:"Br\xe9sil"},BS:{en:"Bahamas",fr:"Bahamas"},BT:{en:"Bhutan",fr:"Bhoutan"},BW:{en:"Botswana",fr:"Botswana"},BY:{en:"Belarus",fr:"B\xe9larus"},BZ:{en:"Belize",fr:"Belize"},CA:{en:"Canada",fr:"Canada"},CC:{en:"Cocos (Keeling) Islands",fr:"\xceles Cocos (Keeling)"},CD:{en:"Democratic Republic of the Congo (Kinshasa)",fr:"Congo, La R\xe9publique D\xe9mocratique du"},CF:{en:"Central African Republic",fr:"Centrafricaine, R\xe9publique"},CG:{en:"Congo, Republic of (Brazzaville)",fr:"R\xe9publique du Congo"},CH:{en:"Switzerland",fr:"Suisse"},CI:{en:"Ivory Coast",fr:"C\xf4te D'ivoire"},CK:{en:"Cook Islands",fr:"\xceles Cook"},CL:{en:"Chile",fr:"Chili"},CM:{en:"Cameroon",fr:"Cameroun"},CN:{en:"China",fr:"Chine"},CO:{en:"Colombia",fr:"Colombie"},CR:{en:"Costa Rica",fr:"Costa Rica"},CU:{en:"Cuba",fr:"Cuba"},CV:{en:"Cape Verde",fr:"Cap-Vert"},CX:{en:"Christmas Island",fr:"\xcele Christmas"},CY:{en:"Cyprus",fr:"Chypre"},CZ:{en:"Czech Republic",fr:"R\xe9publique Tch\xe8que"},DE:{en:"Germany",fr:"Allemagne"},DJ:{en:"Djibouti",fr:"Djibouti"},DK:{en:"Denmark",fr:"Danemark"},DM:{en:"Dominica",fr:"Dominique"},DO:{en:"Dominican Republic",fr:"Dominicaine, R\xe9publique"},DZ:{en:"Algeria",fr:"Alg\xe9rie"},EC:{en:"Ecuador",fr:"\xc9quateur"},EE:{en:"Estonia",fr:"Estonie"},EG:{en:"Egypt",fr:"\xc9gypte"},EH:{en:"Western Sahara",fr:"Sahara Occidental"},ER:{en:"Eritrea",fr:"\xc9rythr\xe9e"},ES:{en:"Spain",fr:"Espagne"},ET:{en:"Ethiopia",fr:"\xc9thiopie"},FI:{en:"Finland",fr:"Finlande"},FJ:{en:"Fiji",fr:"Fidji"},FK:{en:"Falkland Islands",fr:"Falkland, \xceles (Malvinas)"},FM:{en:"Micronesia, Federal States of",fr:"\xc9tats F\xe9d\xe9r\xe9s de Micron\xe9sie"},FO:{en:"Faroe Islands",fr:"\xceles F\xe9ro\xe9"},FR:{en:"France",fr:"France"},GA:{en:"Gabon",fr:"Gabon"},GB:{en:"United Kingdom",fr:"Royaume-Uni"},GD:{en:"Grenada",fr:"Grenade"},GE:{en:"Georgia",fr:"G\xe9orgie"},GF:{en:"French Guiana",fr:"Guyane Fran\xe7aise"},GH:{en:"Ghana",fr:"Ghana"},GI:{en:"Gibraltar",fr:"Gibraltar"},GL:{en:"Greenland",fr:"Groenland"},GM:{en:"The Gambia",fr:"Gambie"},GN:{en:"Guinea",fr:"Guin\xe9e"},GP:{en:"Guadeloupe",fr:"Guadeloupe"},GQ:{en:"Equatorial Guinea",fr:"Guin\xe9e \xc9quatoriale"},GR:{en:"Greece",fr:"Gr\xe8ce"},GT:{en:"Guatemala",fr:"Guatemala"},GU:{en:"Guam",fr:"Guam"},GW:{en:"Guinea-Bissau",fr:"Guin\xe9e-Bissau"},GY:{en:"Guyana",fr:"Guyana"},HK:{en:"Hong Kong",fr:"Hong-Kong"},HN:{en:"Honduras",fr:"Honduras"},HR:{en:"Croatia",fr:"Croatie"},HT:{en:"Haiti",fr:"Ha\xefti"},HU:{en:"Hungary",fr:"Hongrie"},ID:{en:"Indonesia",fr:"Indon\xe9sie"},IE:{en:"Ireland",fr:"Irlande"},IL:{en:"Israel",fr:"Isra\xebl"},IN:{en:"India",fr:"Inde"},IQ:{en:"Iraq",fr:"Iraq"},IR:{en:"Iran (Islamic Republic of)",fr:"R\xe9publique Islamique d' Iran"},IS:{en:"Iceland",fr:"Islande"},IT:{en:"Italy",fr:"Italie"},JM:{en:"Jamaica",fr:"Jama\xefque"},JO:{en:"Jordan",fr:"Jordanie"},JP:{en:"Japan",fr:"Japon"},KE:{en:"Kenya",fr:"Kenya"},KG:{en:"Kyrgyzstan",fr:"Kirghizistan"},KH:{en:"Cambodia",fr:"Cambodge"},KI:{en:"Kiribati",fr:"Kiribati"},KM:{en:"Comoros",fr:"Comores"},KN:{en:"Saint Kitts and Nevis",fr:"Saint-Kitts-et-Nevis"},KR:{en:"Korea, Republic of (South Korea)",fr:"Cor\xe9e, R\xe9publique de (Cor\xe9e du Sud)"},KW:{en:"Kuwait",fr:"Kowe\xeft"},KY:{en:"Cayman Islands",fr:"\xceles Ca\xefmans"},KZ:{en:"Kazakhstan",fr:"Kazakstan"},LA:{en:"Lao, People's Democratic Republic",fr:"Lao, R\xe9publique D\xe9mocratique Populaire"},LB:{en:"Lebanon",fr:"Liban"},LC:{en:"Saint Lucia",fr:"Sainte-Lucie"},LI:{en:"Liechtenstein",fr:"Liechtenstein"},LK:{en:"Sri Lanka",fr:"Sri Lanka"},LR:{en:"Liberia",fr:"Lib\xe9ria"},LS:{en:"Lesotho",fr:"Lesotho"},LT:{en:"Lithuania",fr:"Lituanie"},LU:{en:"Luxembourg",fr:"Luxembourg"},LV:{en:"Latvia",fr:"Lettonie"},LY:{en:"Libya",fr:"Libye"},MA:{en:"Morocco",fr:"Maroc"},MC:{en:"Monaco",fr:"Monaco"},MD:{en:"Moldova, Republic of",fr:"Moldova, R\xe9publique de"},ME:{en:"Montenegro",fr:"Mont\xe9n\xe9gro"},MG:{en:"Madagascar",fr:"Madagascar"},MH:{en:"Marshall Islands",fr:"\xceles Marshall"},MK:{en:"North Macedonia",fr:"Mac\xe9doine du Nord"},ML:{en:"Mali",fr:"Mali"},MM:{en:"Myanmar, Burma",fr:"Myanmar, Birmanie"},MN:{en:"Mongolia",fr:"Mongolie"},MO:{en:"Macau",fr:"Macao"},MP:{en:"Northern Mariana Islands",fr:"\xceles Mariannes du Nord"},MQ:{en:"Martinique",fr:"Martinique"},MR:{en:"Mauritania",fr:"Mauritanie"},MS:{en:"Montserrat",fr:"Montserrat"},MT:{en:"Malta",fr:"Malte"},MU:{en:"Mauritius",fr:"\xcele Maurice"},MV:{en:"Maldives",fr:"Maldives"},MW:{en:"Malawi",fr:"Malawi"},MX:{en:"Mexico",fr:"Mexique"},MY:{en:"Malaysia",fr:"Malaisie"},MZ:{en:"Mozambique",fr:"Mozambique"},NA:{en:"Namibia",fr:"Namibie"},NC:{en:"New Caledonia",fr:"Nouvelle-Cal\xe9donie"},NE:{en:"Niger",fr:"Niger"},NG:{en:"Nigeria",fr:"Nig\xe9ria"},NI:{en:"Nicaragua",fr:"Nicaragua"},NL:{en:"Netherlands",fr:"Pays-Bas"},NO:{en:"Norway",fr:"Norv\xe8ge"},NP:{en:"Nepal",fr:"N\xe9pal"},NR:{en:"Nauru",fr:"Nauru"},NU:{en:"Niue",fr:"Niou\xe9"},NZ:{en:"New Zealand",fr:"Nouvelle-Z\xe9lande"},OM:{en:"Oman",fr:"Oman"},PA:{en:"Panama",fr:"Panama"},PE:{en:"Peru",fr:"P\xe9rou"},PF:{en:"French Polynesia",fr:"Polyn\xe9sie Fran\xe7aise"},PG:{en:"Papua New Guinea",fr:"Papouasie-Nouvelle-Guin\xe9e"},PH:{en:"Philippines",fr:"Philippines"},PK:{en:"Pakistan",fr:"Pakistan"},PL:{en:"Poland",fr:"Pologne"},PN:{en:"Pitcairn Island",fr:"Pitcairn"},PR:{en:"Puerto Rico",fr:"Porto Rico"},PS:{en:"Palestinian territories",fr:"Autorit\xe9 Nationale Palestinienne"},PT:{en:"Portugal",fr:"Portugal"},PW:{en:"Palau",fr:"Palaos"},PY:{en:"Paraguay",fr:"Paraguay"},QA:{en:"Qatar",fr:"Qatar"},RE:{en:"Reunion Island",fr:"Ile de la R\xe9union"},RO:{en:"Romania",fr:"Roumanie"},RS:{en:"Serbia",fr:"Serbie"},RU:{en:"Russian Federation",fr:"Russie (F\xe9d\xe9ration)"},RW:{en:"Rwanda",fr:"Rwanda"},SA:{en:"Saudi Arabia",fr:"Arabie Saoudite"},SB:{en:"Solomon Islands",fr:"Salomon, \xceles"},SC:{en:"Seychelles",fr:"Seychelles"},SD:{en:"Sudan",fr:"Soudan"},SE:{en:"Sweden",fr:"Su\xe8de"},SG:{en:"Singapore",fr:"Singapour"},SI:{en:"Slovenia",fr:"Slov\xe9nie"},SK:{en:"Slovakia (Slovak Republic)",fr:"Slovaquie"},SL:{en:"Sierra Leone",fr:"Sierra Leone"},SM:{en:"San Marino",fr:"Saint-Marin"},SN:{en:"Senegal",fr:"S\xe9n\xe9gal"},SO:{en:"Somalia",fr:"Somalie"},SR:{en:"Suriname",fr:"Suriname"},SS:{en:"South Sudan",fr:"Soudan du Sud"},ST:{en:"Sao Tome and Principe",fr:"Sao Tom\xe9-et-Principe"},SV:{en:"El Salvador",fr:"El Salvador"},SY:{en:"Syria, Syrian Arab Republic",fr:"Syrienne, R\xe9publique Arabe"},SZ:{en:"Swaziland (Eswatini)",fr:"Swaziland"},TB:{en:"Tibet",fr:"Tibet"},TC:{en:"Turks and Caicos Islands",fr:"Turks et Ca\xefques, \xceles"},TD:{en:"Chad",fr:"Tchad"},TF:{en:"French Southern Territories",fr:"Terres Australes Fran\xe7aises"},TG:{en:"Togo",fr:"Togo"},TH:{en:"Thailand",fr:"Tha\xeflande"},TJ:{en:"Tajikistan",fr:"Tadjikistan"},TK:{en:"Tokelau",fr:"Tokelau"},TL:{en:"Timor-Leste (East Timor)",fr:"Timor-Leste (Timor Oriental)"},TM:{en:"Turkmenistan",fr:"Turkm\xe9nistan"},TN:{en:"Tunisia",fr:"Tunisie"},TO:{en:"Tonga",fr:"Tonga"},TR:{en:"Turkey",fr:"Turquie"},TT:{en:"Trinidad and Tobago",fr:"Trinit\xe9-et-Tobago"},TV:{en:"Tuvalu",fr:"Tuvalu"},TW:{en:"Taiwan (Republic of China)",fr:"Ta\xefwan, Province de Chine"},TZ:{en:"Tanzania; officially the United Republic of Tanzania",fr:"Tanzanie, R\xe9publique-Unie de"},UA:{en:"Ukraine",fr:"Ukraine"},UG:{en:"Uganda",fr:"Ouganda"},US:{en:"United States",fr:"\xc9tats-Unis"},UY:{en:"Uruguay",fr:"Uruguay"},UZ:{en:"Uzbekistan",fr:"Ouzb\xe9kistan"},VC:{en:"Saint Vincent and the Grenadines",fr:"Saint-Vincent-et-les Grenadines"},VE:{en:"Venezuela",fr:"Venezuela"},VG:{en:"Virgin Islands (British)",fr:"\xceles Vierges Britanniques"},VI:{en:"Virgin Islands (U.S.)",fr:"\xceles Vierges des \xc9tats-Unis"},VN:{en:"Vietnam",fr:"Vi\xeat Nam"},VU:{en:"Vanuatu",fr:"Vanuatu"},WF:{en:"Wallis and Futuna Islands",fr:"Wallis et Futuna"},WS:{en:"Samoa",fr:"Samoa"},XK:{en:"Kosovo Flag",fr:"Kosovo"},YE:{en:"Yemen",fr:"Y\xe9men"},YT:{en:"Mayotte",fr:"Mayotte"},ZA:{en:"South Africa",fr:"Afrique du Sud"},ZM:{en:"Zambia",fr:"Zambie"},ZW:{en:"Zimbabwe",fr:"Zimbabwe"}},kl="recaptcha-script",Il=e=>window.grecaptcha.execute("6LeGjawdAAAAAOAx-RaSPm1N50owd6a3H9WuziAM",{action:e}),Tl=()=>{if("web"!==r.default.OS)return;window.___grecaptcha_cfg=void 0;const e=document.querySelector("#".concat(kl));e&&e.remove();const t=document.querySelector(".grecaptcha-badge");t&&t.remove()},Ol=e=>(d.useEffect((()=>{(async(e,t)=>{if(document.querySelector("#".concat(kl)))t(await Il(e));else{window.onCAPTCHALoad=async()=>{t(await Il(e))};const n=document.createElement("script");n.id=kl,n.src="https://www.recaptcha.net/recaptcha/api.js?render=6LeGjawdAAAAAOAx-RaSPm1N50owd6a3H9WuziAM&onload=onCAPTCHALoad",n.async=!0,n.defer=!0,document.head.appendChild(n)}})(e.action,e.onChange)}),[e.action]),(0,An.jsx)(p.c,{})),jl=()=>(0,An.jsxs)(cn.c,{style:{flexDirection:"row",alignItems:"center"},onPress:()=>{(()=>{let e;e="fr"===hn.O.get()?"cmacgm"===c.Y.name?"https://form.typeform.com/to/Dtra0WRu":"https://form.typeform.com/to/CUFKwODt":"cmacgm"===c.Y.name?"https://form.typeform.com/to/SmIP1mf4":"https://form.typeform.com/to/PElFd2q6","web"===r.default.OS?window.open(e,"_blank"):Promise.resolve(kn.c.openURL(e))})()},children:[(0,An.jsx)(le.c,{style:{height:24,width:24,marginRight:8},source:n(260)}),(0,An.jsx)(un.c,{children:(0,hn._)(nr),style:[pr.h6,fr.black]})]}),Pl=e=>{const t=d.useContext(yn.S);return(0,An.jsxs)(p.c,{children:[(0,An.jsx)(p.c,{style:[bn.horizontal,{backgroundColor:e.bgColor,justifyContent:"center",flexWrap:"wrap"}],children:(0,An.jsx)(un.c,{style:[t.expanded?pr.h1Expanded:pr.h1,fr.white,bn.text_center,tl.out_top_l,tl.out_bottom_l],children:e.title})}),(0,An.jsx)(p.c,{style:{backgroundColor:u.y.BLUE_DARK,height:24},children:(0,An.jsx)(p.c,{style:{backgroundColor:u.y.WHITE,borderTopLeftRadius:24,borderTopRightRadius:24,height:"100%"}})})]})},Bl=e=>(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center"},children:[(0,An.jsx)(le.c,{style:{height:24,width:24,marginRight:8},source:e.picture||n(8024)}),(0,An.jsx)(En,{style:[fr.black,pr.h6],children:(0,hn._)(e.text)})]}),Ll=b.c.create({container:{alignItems:"center",width:"100%"},space:{width:"85%"},h1:{fontSize:24,color:"white",fontFamily:"ios"===r.default.OS?"Brown":"Brown-Bold"},h2:{fontSize:16,color:"white"},marginBottom:{marginBottom:30},marginBottomSmall:{marginBottom:10},marginTopSmall:{marginTop:10},marginTopMedium:{marginTop:20}});var Dl=n(7511);const Ml={fr:"Se connecter",en:"Log in"},Nl={fr:"Connexion en cours...",en:"Connection in progress..."},Ul={fr:"Adresse e-mail",en:"E-mail address"},Fl={fr:"Mot de passe",en:"Password"},Hl={fr:"Se connecter",en:"Login"},Gl={fr:"J'ai oubli\xe9 mon mot de passe",en:"I forgot my password"},zl={fr:"Vous n'avez pas encore de compte ?",en:"You don't have an account yet?"},Vl={fr:"Cr\xe9er un compte",en:"Create an account"},Wl={fr:"Connexion au serveur impossible",en:"Connection to the server is not possible"},Ql=b.c.create({container:{backgroundColor:u.y.BLUE_DARK,alignItems:"center",width:"100%"}});var Yl=n(4152);const Kl=e=>(e<10?"0":"")+e.toFixed(0),ql=(e,t,n)=>{const r=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=Math.floor(e/3600),r=Math.floor(n/24),o=Math.floor((e-3600*n)/60),i=e-3600*n-60*o;return n-=24*r,{days:t?Kl(r):r,hours:t?Kl(n):n,minutes:t?Kl(o):o,seconds:t?Kl(i):i}}(t,!1);let o="";return 0!=r.days&&(o+=r.days+" "+("fr"===e?"j":"d")),0!=r.hours&&(o.length>0&&(o+=" "),o+=r.hours+" h"),0!=r.minutes&&(o.length>0&&(o+=" "),o+=r.minutes+" m"),n||0!=r.days||0==r.seconds||(o.length>0&&(o+=" "),o+=r.seconds+" s"),o},Xl=(e,t)=>{const n=new Date(e),r=new Date(t),o={day:Kl(n.getDate()),month:Kl(n.getMonth()+1),year:n.getFullYear()},i={day:Kl(r.getDate()),month:Kl(r.getMonth()+1),year:r.getFullYear()};return{fr:"du ".concat(o.day,"/").concat(o.month,"/").concat(o.year," au ").concat(i.day,"/").concat(i.month,"/").concat(i.year),en:"from ".concat(o.month,"/").concat(o.day,"/").concat(o.year," to ").concat(i.month,"/").concat(i.day,"/").concat(i.year)}},Jl=function(e){let t,n=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],r=new Date("number"===typeof e?e:Number(e));return isNaN(r.getTime())&&(console.log("Warning convertDateToString: date is NaN <{"+e+"; type "+typeof e+"}> "),r=new Date),"fr"===hn.O.get()?(t="".concat(Kl(r.getDate()),"/").concat(Kl(r.getMonth()+1),"/").concat(r.getFullYear()),n&&(t+=" \xe0 ".concat(Kl(r.getHours()),":").concat(Kl(r.getMinutes())))):(t="".concat(Kl(r.getMonth()+1),"/").concat(Kl(r.getDate()),"/").concat(r.getFullYear()),n&&(t+=" at ".concat(Kl(r.getHours()),":").concat(Kl(r.getMinutes())))),t},Zl=e=>(0,An.jsx)(Yl.CountdownCircleTimer,{initialRemainingTime:(e.date.getTime()-(new Date).getTime())/1e3,duration:e.duration,isPlaying:!0,onComplete:e.onComplete,trailColor:e.outsideColor||u.y.BLUE_DARK,size:e.size,colors:e.insideColor||"#ffffff",children:t=>{let{remainingTime:n}=t;return(0,An.jsx)(X.default.Text,{style:{fontSize:e.textSize||19,color:e.textColor||"white",fontWeight:"bold"},children:ql(hn.O.get(),n)})}}),$l=e=>(0,An.jsx)(un.c,{children:e.children,style:e.style}),ec={fr:"Votre s\xe9lection nous a bien \xe9t\xe9 envoy\xe9e, merci !",en:"Thank you, we have received your choices!"},tc={fr:"Rendez-vous dans quelques heures pour d\xe9couvrir le projet que vous allez soutenir avec votre communaut\xe9",en:"See you in a few hours to discover your community and the charity you will support"},nc={fr:"Nous vous associons \xe0 la communaut\xe9 en coh\xe9rence avec vos choix",en:"We associate you with the community according to your choices"},rc=b.c.create({container:{backgroundColor:u.y.BLUE_DARK,alignItems:"center"},spacing:{paddingLeft:40,paddingRight:40},buttons:{width:"100%",marginTop:32},button:{marginTop:32}});var oc=n(8776);const ic=e=>(0,An.jsx)(p.c,{onStartShouldSetResponder:e.onStartShouldSetResponder,style:{width:e.width},children:(0,An.jsxs)(p.c,{style:[{borderRadius:20,padding:e.margin||5,backgroundColor:e.bgColor,elevation:3,alignItems:"center"},e.style],children:[e.title&&(0,An.jsx)(En,{children:e.title,style:[{color:e.titleColor,fontWeight:"bold",marginTop:10,fontSize:15},e.textStyle]}),(0,An.jsx)(p.c,{children:e.children,style:{width:"100%",height:e.height}})]})});var ac=n(3768);const sc=e=>{const t=d.useContext(yn.S),[r,o]=d.useState(!1);e.handler((e=>o(e)));let i={backgroundColor:"white",maxWidth:600,borderRadius:20,padding:15,width:e.width};return(0,An.jsx)(ac.c,{children:!r||(0,An.jsx)(p.c,{style:{height:"100%",alignItems:"center",justifyContent:"center",backgroundColor:"rgba(0, 0, 0, 0.5)"},children:(0,An.jsxs)(p.c,{style:[i,e.style],children:[e.title&&(0,An.jsx)(En,{style:[{width:"100%",textAlign:"center",alignSelf:"center",color:u.y.BLUE_DARK,fontWeight:"bold",marginTop:24},e.textStyle],children:e.title})||(0,An.jsx)(p.c,{style:{width:"100%",height:15}}),(0,An.jsx)(cn.c,{style:{position:"absolute",right:10,top:10},onPress:()=>{o(!1),e.onClose&&e.onClose()},children:(0,An.jsx)(p.c,{style:{padding:t.expanded?4:8},children:(0,An.jsx)(le.c,{style:{width:t.expanded?24:20,height:t.expanded?24:20},source:n(1227)})})}),e.children]})})})},lc=b.c.create({modalContainer:{display:"flex",alignItems:"center",flexDirection:"column"},h1:{textAlign:"center",color:u.y.BLACK,fontSize:24,marginBottom:20},h2:{textAlign:"center",color:u.y.BLACK,fontSize:20},resultZone:{borderColor:u.y.GREY1,borderWidth:1,borderRadius:16,width:"90%",padding:24},marginTopSmall:{marginTop:15},marginBottomMedium:{marginBottom:20},separatorMarge:{marginTop:24,marginBottom:24},multipleDispositionDisplayValidate:{width:"100%",flexDirection:"row",justifyContent:"space-around",marginTop:16},multipleDispositionDisplayShared:{width:"100%",flexDirection:"column",justifyContent:"space-around"},fullWidthButton:{width:"70%",minWidth:150,maxWidth:400},defaultButton:{width:"40%",minWidth:100},commonButton:{alignSelf:"center",marginTop:16,paddingLeft:12,paddingRight:12,marginRight:8},blackButton:{borderStyle:"solid",borderWidth:1,borderColor:u.y.GREY2}}),cc=e=>{const t=e.content.buttonLeft.text,n=e.content.buttonLeft.textColor?e.content.buttonLeft.textColor:u.y.BLACK,r=e.content.buttonLeft.backgroundColor?e.content.buttonLeft.backgroundColor:u.y.WHITE,o=e.content.buttonRight.text,i=e.content.buttonRight.textColor?e.content.buttonRight.textColor:u.y.WHITE,a=e.content.buttonRight.backgroundColor?e.content.buttonRight.backgroundColor:u.y.WHITE;return(0,An.jsx)(sc,{width:"90%",handler:e.hide,children:(0,An.jsxs)(p.c,{style:lc.modalContainer,children:[(0,An.jsx)(En,{style:[tl.out_top_m,pr.h3,fr.black,bn.text_center],children:(0,hn._)(e.content.message)}),(0,An.jsxs)(p.c,{style:lc.multipleDispositionDisplayValidate,children:[(0,An.jsx)(xl,{onPress:()=>{e.closeModal()},children:(0,hn._)(t),color:r,textColor:n,fontWeight:"bold",fontSize:14,style:[lc.blackButton,tl.out_bottom_m,lc.commonButton,lc.defaultButton]}),(0,An.jsx)(xl,{onPress:e.onPress,fontWeight:"bold",fontSize:14,children:(0,hn._)(o),color:a,textColor:i,style:[lc.commonButton,lc.defaultButton,tl.out_bottom_m]})]})]})})},uc={input:{fr:"R\xe9diger une publication",en:"Write a post"},commentInput:{fr:"Commenter un post...",en:"Comment a post..."},commentButton:{fr:"Publier",en:"Share"},likesInteraction:{fr:"R\xe9actions",en:"Interactions"},likedBy:{fr:"Aim\xe9 par",en:"Liked by"},send:{fr:"Publier",en:"Share"},deleteConfirmPost:{fr:"Souhaitez-vous supprimer ce post ?",en:"Do you want to delete this post?"},notif:{fr:"D\xe9sactiver notification",en:"Disable notification"},notifDetail:{fr:"Les utilisateurs de votre organisation seront notifi\xe9s",en:"Users of your organization will be notified"},notNotif:{fr:"Activer notification",en:"Activate notification"},deletePost:{fr:"Supprimer le post",en:"Delete the post"},reportContent:{fr:"Signaler le contenu",en:"Report content"},reportContentConfirm:{fr:"Souhaitez-vous signaler ce contenu ?",en:"Are you sure you want to report this content ?"},confirmReportBtn:{fr:"Signaler",en:"Report"},cancelReportBtn:{fr:"Annuler",en:"Cancel"},deleteCom:{fr:"Supprimer le commentaire",en:"Delete the comment"},deleteConfirmCom:{fr:"Souhaitez-vous supprimer ce commentaire ?",en:"Do you want to delete this comment?"},deleteConfirmYes:{fr:"Supprimer",en:"Delete"},deleteConfirmNo:{fr:"Annuler",en:"Cancel"},notifyCompany:{fr:"Notifier l'organisation",en:"Notify the organization"},dontNotifyCompany:{fr:"Ne pas notifier l'organisation",en:"Don't notify the organization"},pin:{fr:"\xc9pingler",en:"Pin"},dontPin:{fr:"Ne pas \xe9pingler",en:"Do not pin"},unpin:{fr:"Ne plus \xe9pingler",en:"Remove pin"},posts:{fr:"Toutes les publications",en:"All posts"},pinned:{fr:"Publication \xe9pingl\xe9e",en:"Pinned post"},alertPin:{fr:"Le post actuellement \xe9pingl\xe9 sera remplac\xe9",en:"Current pinned post will be replaced"}};let dc=()=>{},hc=e=>{dc=e},pc=()=>dc();const fc=b.c.create({container:{paddingLeft:8,paddingRight:8},containerExpanded:{paddingLeft:0,paddingRight:0,height:"1vh",backgroundColor:u.y.WHITE},colorBlueDark:{backgroundColor:u.y.BLUE_DARK},footerContainer:{width:"100%",flexDirection:"row",backgroundColor:u.y.BLUE_DARK,paddingTop:10,paddingBottom:10,justifyContent:"center"},content:{alignSelf:"center"},contentExpanded:{width:"80%",alignSelf:"center"},footerElement:{width:"24%",alignItems:"center"},image:{width:30,height:30,resizeMode:"contain"},textSelected:{color:"white",fontWeight:"bold"},text:{color:"grey",fontWeight:"normal"}});var gc=n(4832),mc=n.n(gc);mc().setAppElement("#root");const yc=e=>{var t,o;const i=d.useContext(yn.S);return(0,An.jsxs)(mc(),{isOpen:e.isVisible,shouldCloseOnOverlayClick:!1,style:{content:{backgroundColor:e.color,borderRadius:24,maxWidth:null===e.maxWidth?void 0:null!==(t=e.maxWidth)&&void 0!==t?t:800,margin:"auto",inset:i.expanded||"web"!==r.default.OS?30:14}},contentLabel:"Modal",children:[(0,An.jsx)(p.c,{style:{position:"absolute",top:0,left:0,right:0},children:e.top}),(0,An.jsx)(cn.c,{style:{position:"absolute",right:15,top:15,zIndex:2},onPress:()=>{e.hide()},children:(0,An.jsx)(le.c,{style:{width:24,height:24,padding:4},source:n(1227)})}),(0,An.jsx)(p.c,{style:[{paddingTop:null!==(o=e.paddingTop)&&void 0!==o?o:24,height:"undefined"!==typeof e.bottom?"90%":"100%"},i.expanded||"web"!==r.default.OS?[tl.out_left_m,tl.out_right_m]:{marginLeft:2,marginRight:2}],children:e.content}),(0,An.jsx)(p.c,{style:{position:"absolute",bottom:0,left:0,right:0},children:e.bottom})]})};var vc=n(5340);const bc={fr:"Votre fichier n'est pas une image",en:"Your file is not an image"},Ac=e=>{var t=document.createElement("input");t.type="file",t.onchange=t=>{const n=t.target.files[0];if("image"!==n.type.split("/")[0])alert((0,hn._)(bc));else{const t=new FileReader;t.readAsDataURL(n),t.onload=t=>{e(t.target.result.split(",")[1],n.type.split("/")[1])}}},t.click()},xc=e=>{var t,r;const o=d.useContext(yn.S),i="undefined"!==typeof o.profile?[null===(t=o.profile)||void 0===t?void 0:t.firstname,null===(r=o.profile)||void 0===r?void 0:r.lastname]:[];return(0,An.jsxs)(p.c,{style:{flex:1},children:[(0,An.jsxs)(p.c,{style:[{alignItems:"flex-start",flexDirection:"row"},tl.out_top_m],children:[(0,An.jsx)(Rn,{bgColor:u.y.BLUE_LIGHT,color:"black",size:48,name:i,source:o.picture,style:{minHeight:48,borderRadius:50,marginRight:8,marginLeft:8}}),(0,An.jsxs)(p.c,{style:o.expanded?{height:"100%",justifyContent:"center"}:{paddingTop:o.profile.can_submit_on_company?0:10},children:[(0,An.jsx)(En,{children:i.join(" "),style:[pr.h5,fr.black,{marginBottom:4}]}),o.profile.can_submit_on_company&&(0,An.jsxs)(p.c,{style:o.expanded?{flexDirection:"row"}:{flexDirection:"column"},children:[(0,An.jsx)(xl,{children:(0,hn._)(e.notifyCompany?uc.notifyCompany:uc.dontNotifyCompany),onPress:()=>e.setNotifyCompany(!e.notifyCompany),fontSize:14,fontWeight:"bold",textColor:u.y.BLACK,sideLeft:(0,An.jsx)(le.c,{source:e.notifyCompany?n(8088):n(832),style:{width:16,height:16,marginRight:8}}),style:{borderRadius:24,borderColor:u.y.BLACK,paddingLeft:12,paddingRight:12,marginRight:8}}),(0,An.jsx)(xl,{children:(0,hn._)(e.pin?uc.pin:uc.dontPin),onPress:()=>e.setPin(!e.pin),fontSize:14,fontWeight:"bold",textColor:u.y.BLACK,sideLeft:(0,An.jsx)(le.c,{source:e.pin?n(508):n(244),style:{width:16,height:16,marginRight:8}}),style:[{borderRadius:24,borderColor:u.y.BLACK,paddingLeft:12,paddingRight:12,alignSelf:"flex-start"},o.expanded?{}:{marginTop:8}]})]}),e.pin&&e.hasPins()&&(0,An.jsx)(En,{children:(0,hn._)(uc.alertPin),style:[pr.caption,fr.grey2,tl.out_top_s]})]})]}),(0,An.jsxs)(p.c,{style:[{flex:1},tl.out_top_m],children:["undefined"!==typeof e.upload&&(0,An.jsx)(le.c,{source:{uri:"data:image/".concat(e.upload.type,";base64,").concat(e.upload.picture)},style:{height:80,width:"100%",resizeMode:"contain"}}),(0,An.jsx)(kt.c,{maxLength:2e3,placeholder:(0,hn._)(uc.input),multiline:!0,value:e.message,placeholderTextColor:u.y.GREY2,onChangeText:t=>{e.setMessage(t)},style:[{flex:1,textAlignVertical:"top"},fr.black,pr.body1]}),"undefined"!==typeof e.setUpload&&(0,An.jsxs)(p.c,{style:[{flexDirection:"row",justifyContent:"space-between"},tl.out_top_s],children:[(0,An.jsx)(vc.c,{accessibilityRole:"link",style:{alignSelf:"flex-start"},onPress:()=>{"undefined"!==typeof e.upload?e.setUpload(void 0):Ac(((t,n)=>{e.setUpload({picture:t,type:n})}))},children:(0,An.jsx)(le.c,{style:{width:24,height:24,resizeMode:"contain",marginBottom:"undefined"===typeof e.upload?3:0,marginRight:15,alignSelf:"center"},source:"undefined"===typeof e.upload?n(5428):n(5892)})}),(0,An.jsx)(xl,{children:(0,hn._)(uc.send),color:e.locked?u.y.GREY1:u.y.YELLOW_DARK,textColor:u.y.WHITE,fontSize:16,fontWeight:"700",disabled:0===e.message.length&&"undefined"===typeof e.upload||e.locked,onPress:()=>{if(!e.locked){var t;e.setLocked(!0);const n={text:e.message};o.profile&&null!==(t=o.profile)&&void 0!==t&&t.can_submit_on_company&&(n.notify=e.notifyCompany,n.pin=e.pin),"undefined"!==typeof e.upload&&(n.picture=e.upload.picture,n.pictureFormat=e.upload.type),s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:feed/add"}).execute(n).then((()=>{e.setUpload(void 0),e.setMessage(""),e.setLocked(!1),"undefined"!==typeof e.update&&e.update()}))}},style:{paddingLeft:16,paddingRight:16,marginBottom:5,marginTop:5}})]})]})]})},Sc=e=>{var t,n;const{push:o}=(0,f.Yi)(),[i,a]=d.useState(!1),[s,l]=d.useState(void 0),[c,h]=d.useState(""),[g,m]=d.useState(!1),[y,v]=d.useState(!1),[b,A]=d.useState(!1),x=d.useContext(yn.S),S="undefined"!==typeof x.profile?[null===(t=x.profile)||void 0===t?void 0:t.firstname,null===(n=x.profile)||void 0===n?void 0:n.lastname]:[];return(0,An.jsxs)(p.c,{style:[{width:"100%",marginLeft:"auto",marginRight:"auto",marginTop:16},x.expanded?{maxWidth:650}:{paddingLeft:16,paddingRight:16}],children:[(0,An.jsxs)(cn.c,{style:{backgroundColor:"#6F7A8A",borderRadius:61,height:64,flexDirection:"row",alignItems:"center"},onPress:()=>{"web"===r.default.OS?a(!0):o(ln.g.NEW_MESSAGE,{hasPins:e.hasPins()})},children:[(0,An.jsx)(Rn,{bgColor:u.y.BLUE_LIGHT,color:"black",size:48,name:S,source:x.picture,style:{minHeight:48,borderRadius:50,marginRight:8,marginLeft:8}}),(0,An.jsx)(En,{children:(0,hn._)(uc.input),style:[pr.body1,fr.white]})]}),"web"===r.default.OS&&(0,An.jsx)(yc,{isVisible:i,hide:()=>a(!1),color:"white",margin:30,content:(0,An.jsxs)(p.c,{style:{flex:1},children:[(0,An.jsx)(En,{style:[pr.h2,fr.black,tl.out_bottom_m],children:(0,hn._)(uc.input)}),(0,An.jsx)(xc,{message:c,setMessage:h,upload:s,setUpload:l,notifyCompany:g,setNotifyCompany:m,pin:y,setPin:v,locked:b,setLocked:A,hasPins:e.hasPins,update:()=>{a(!1),e.update(),v(!1),m(!1)}})]})})]})},wc=e=>{const[t,n]=(0,d.useState)(!1);e.setClose&&e.setClose((()=>n(!1)));const o="string"===typeof e.mainText?e.mainText:(0,hn._)(e.mainText);return(0,An.jsxs)(p.c,{style:{zIndex:1,...e.viewStyle},children:[(0,An.jsx)(cn.c,{style:{alignSelf:e.align,marginBottom:e.marginBottom,marginTop:e.marginTop},onPress:()=>{n(!t)},children:(0,An.jsx)(En,{style:{fontWeight:"bold",fontSize:18},children:o})}),t&&(0,An.jsx)(p.c,{style:{display:"flex",alignItems:e.align},children:(0,An.jsx)(p.c,{style:{position:"absolute"},ref:t=>{t&&e.outsideClick&&e.outsideClick((e=>{"web"!==r.default.OS||t.contains(e)||n(!1)}))},children:(0,An.jsx)(p.c,{style:{display:"flex",flexDirection:"column",justifyContent:"space-between",backgroundColor:e.color,borderRadius:e.borderRadius,borderWidth:e.borderWidth,borderColor:e.borderColor},children:e.content})})})]})},Cc=b.c.create({containerDropdown:{flexDirection:"column",alignItems:"center",paddingLeft:10,paddingBottom:10,paddingTop:10,paddingRight:10,borderRadius:4}});var _c=n(2403);function Ec(){return Ec=Object.assign?Object.assign.bind():function(e){for(var t=1;t{if(!this.state.linkifyIt.pretest(e.props.children)||!this.state.linkifyIt.test(e.props.children))return e;let t=[],n=0;const r={...e.props,ref:void 0,key:void 0};try{var o;return null===(o=this.state.linkifyIt.match(e.props.children))||void 0===o||o.forEach((o=>{var i,a;let{index:s,lastIndex:l,text:c,url:u}=o,h=e.props.children.substring(n,s);h&&t.push(h),n=l,this.props.linkText&&(c="function"===typeof this.props.linkText?this.props.linkText(u):this.props.linkText);const p={};"web"!==Ic&&(p.onLongPress=this.props.onLongPress?()=>{var e,t;return null===(e=(t=this.props).onLongPress)||void 0===e?void 0:e.call(t,u,c)}:void 0),p.onPress=this.props.onPress?()=>{var e,t;return null===(e=(t=this.props).onPress)||void 0===e?void 0:e.call(t,u,c)}:void 0,t.push(d.createElement(un.c,Ec({},r,p,{key:u+s,style:[e.props.style,this.props.linkStyle]},null===(i=(a=this.props).injectViewProps)||void 0===i?void 0:i.call(a,u)),c))})),t.push(e.props.children.substring(n,e.props.children.length)),d.cloneElement(e,r,t)}catch(i){return e}})),Rc(this,"parse",(e=>{let{props:{children:t}={children:void 0}}=e||{};if(!t)return e;const n={...e.props,ref:void 0,key:void 0};return d.cloneElement(e,n,d.Children.map(t,(t=>{let{type:{displayName:r}={displayName:void 0}}=t||{};return"string"===typeof t&&this.state.linkifyIt.pretest(t)?this.linkify(d.createElement(un.c,Ec({},n,{style:e.props.style}),t)):"Text"!==r||this.isTextNested(t)?this.parse(t):this.linkify(t)})))})),this.state={linkifyIt:e.linkify||kc}}render(){const{onPress:e,linkDefault:t,onLongPress:n,linkStyle:r,linkify:o,linkText:i,...a}=this.props;return d.createElement(p.c,Ec({},a,{style:this.props.style}),this.props.onPress||this.props.onLongPress||this.props.linkStyle?this.parse(this).props.children:this.props.children)}isTextNested(e){if(!d.isValidElement(e))throw new Error("Invalid component");let{type:{displayName:t}={}}=e;if("Text"!==t)throw new Error("Not a Text component");return"string"!==typeof e.props.children}}Rc(Tc,"defaultProps",{linkify:kc,injectViewProps:e=>({})});const Oc=class extends d.Component{constructor(e){super(e),this.handleLink=this.handleLink.bind(this)}handleLink(e){const t=_c.parse(e);t.protocol=t.protocol.toLowerCase();const n=_c.format(t);kn.c.canOpenURL(n).then((e=>e&&kn.c.openURL(n)))}render(){const e=this.handleLink||this.props.onPress;return this.props.linkDefault?d.createElement(Tc,Ec({},this.props,{onPress:e})):d.createElement(Tc,this.props)}},jc=e=>({fr:e+" points",en:e+" points"}),Pc=e=>{const t=d.useContext(yn.S);let n=e.users?(Array.isArray(e.users)?[...e.users]:Object.keys(e.users).map((t=>{const n=e.users[t];let r=n.name;return r||(r=[n.firstname,n.lastname]),{name:r,picture:n.picture}}))).sort((e=>e.picture)):[];return n.some((e=>e.points))&&(n=n.sort(((e,t)=>e.points&&t.points?t.points-e.points:e.points?-1:t.points?1:0))),(0,An.jsxs)(p.c,{children:[!!e.title&&(0,An.jsx)(En,{children:e.title,style:e.titleStyle}),!!e.description&&(0,An.jsx)(En,{children:e.description,style:e.textStyle}),(0,An.jsx)(p.c,{style:{flexDirection:"row",flexWrap:"wrap",alignItems:"center",marginTop:e.description?16:0},children:n.map(((n,r)=>(0,An.jsxs)(p.c,{style:{flexDirection:t.expanded?"row":"column",alignItems:t.expanded?"center":"flex-start",width:t.expanded&&"undefined"===typeof n.points?"50%":"100%",marginBottom:16},children:[(0,An.jsxs)(p.c,{style:{flexDirection:"row",flex:t.expanded?1:0},children:[(0,An.jsx)(Rn,{size:e.size,name:n.name,source:n.picture,bgColor:e.bgColor,color:e.color,style:{marginRight:8}}),(0,An.jsxs)(p.c,{style:[bn.flex1],children:[(0,An.jsx)(En,{style:[pr.h5,fr.black],children:n.name}),(0,An.jsx)(En,{style:[pr.body1,fr.grey2],children:n.email})]})]}),"undefined"!==typeof n.points&&(0,An.jsx)(p.c,{style:{marginLeft:t.expanded?0:e.size+8},children:(0,An.jsx)(En,{style:[pr.h6,fr.black],children:(0,hn._)(jc(n.points))})})]},r)))})]})},Bc=e=>{var t,n,o,i;const a=d.useContext(yn.S),[s,l]=d.useState(!1),c=(0,f.Yi)();return 0===(null===(t=e.likes)||void 0===t?void 0:t.length)?(0,An.jsx)(p.c,{}):(0,An.jsxs)(p.c,{style:[tl.out_left_s],children:[(0,An.jsx)(cn.c,{onPress:()=>{"web"===r.default.OS?l(!0):c.navigate(ln.g.FEED_LIKES,{likes:e.likes})},children:(0,An.jsx)(p.c,{style:[bn.horizontal],children:null===(n=e.likes)||void 0===n||null===(o=n.sort((e=>{var t;return e.picture&&e.email===(null===a||void 0===a||null===(t=a.profile)||void 0===t?void 0:t.email)?-1:1})))||void 0===o||null===(i=o.slice(0,3))||void 0===i?void 0:i.map(((t,n)=>(0,An.jsx)(Rn,{bgColor:u.y.BLUE_LIGHT,color:"black",name:t.name,source:t.picture,size:24,style:[{borderWidth:2,borderColor:u.y.WHITE,zIndex:e.likes.length-n},n>0&&{marginLeft:-10}]},n)))})}),"web"===r.default.OS&&(0,An.jsx)(yc,{isVisible:s,hide:()=>l(!1),color:"white",margin:30,content:(0,An.jsx)(Pc,{users:e.likes,bgColor:u.y.BLUE_LIGHT_X,color:u.y.BLUE_DARK,size:50,title:(0,hn._)(uc.likesInteraction),description:(0,hn._)(uc.likedBy),titleStyle:[pr.h2,fr.black,tl.out_bottom_m],textStyle:[pr.body1,fr.black]})})]})},Lc=e=>{const t=d.useContext(yn.S),[n,o]=d.useState(),[i,a]=d.useState("");return(0,An.jsxs)(p.c,{style:[t.expanded||"web"!==r.default.OS?{}:{flexWrap:"wrap"},{flexDirection:"row",alignItems:"flex-start",marginBottom:10}],children:[(0,An.jsx)(Rn,{bgColor:u.y.BLUE_LIGHT,color:"black",name:e.name,source:e.picture,size:30,style:{marginTop:t.expanded?2:0}}),(0,An.jsx)(p.c,{style:[t.expanded||"web"!==r.default.OS?{}:{minWidth:250},{flex:1,width:"50%",marginLeft:10,marginRight:5,justifyContent:"center",flexDirection:"column",borderColor:u.y.WHITE,borderWidth:1}],children:(0,An.jsx)(kt.c,{maxLength:2e3,placeholder:(0,hn._)(uc.commentInput),multiline:!0,value:e.id!==n?"":i,onChangeText:t=>{e.id!==n&&o(e.id),a(t)},style:[t.expanded&&"web"===r.default.OS?pr.body1:pr.body2,fr.black,{textAlignVertical:"top",paddingTop:t.expanded?4:0,paddingLeft:4,height:t.expanded?50:void 0}]})}),(0,An.jsx)(xl,{children:(0,hn._)(uc.commentButton),disabled:e.locked,fontSize:14,fontWeight:"700",color:e.locked?u.y.GREY1:u.y.BLUE_DARK,style:{paddingLeft:16,paddingRight:16},onPress:()=>{var t;!e.locked&&i&&(null===(t=e.setLocked)||void 0===t||t.call(e,!0),s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:feed/comment"}).execute({[e.type]:e.id,text:i}).then((()=>{var t;e.updateFeed&&e.updateFeed(),a(""),null===(t=e.setLocked)||void 0===t||t.call(e,!1)})))}})]})},Dc=e=>{var t,o;const i=d.useContext(yn.S),[a,l]=d.useState([]);let c;const h="undefined"!==typeof i.profile?[null===(t=i.profile)||void 0===t?void 0:t.firstname,null===(o=i.profile)||void 0===o?void 0:o.lastname]:[];return(0,An.jsxs)(p.c,{children:[(0,An.jsxs)(p.c,{style:{flexDirection:"row"},children:[(0,An.jsx)(Rn,{bgColor:u.y.BLUE_LIGHT,color:"black",name:e.data.author.name,source:e.data.author.picture,size:40}),(0,An.jsxs)(p.c,{style:{marginLeft:10,justifyContent:"center"},children:[(0,An.jsx)(En,{children:e.data.author.name,style:[i.expanded||"web"!==r.default.OS?pr.h4:pr.h5,fr.black]}),(0,An.jsx)(En,{style:[pr.caption,fr.grey2],children:Jl(e.data.date)})]})]}),(0,An.jsxs)(p.c,{style:{marginBottom:8},children:[(0,An.jsx)(Oc,{linkStyle:{color:u.y.BLUE_DARK},onPress:e=>{"web"===r.default.OS?window.open(e,"_blank"):kn.c.openURL(e)},children:(0,An.jsx)(En,{style:[pr.body1,fr.black,tl.out_top_m,{marginBottom:5}],children:e.data.text})}),e.data.picture&&"string"===typeof e.data.picture&&(0,An.jsx)(le.c,{style:{width:"100%",height:400,resizeMode:"contain",marginTop:20},source:{uri:e.data.picture}})]}),(0,An.jsxs)(p.c,{style:[bn.horizontal],children:[(0,An.jsx)(cn.c,{style:{marginBottom:15},onPress:()=>{const t=e.data.likes||[],n=t.findIndex((e=>{var t;return e.id===(null===(t=i.profile)||void 0===t?void 0:t.id)}));var r,o,a,l;-1===n?t.push({id:null===(r=i.profile)||void 0===r?void 0:r.id,name:(null===(o=i.profile)||void 0===o?void 0:o.firstname)+" "+(null===(a=i.profile)||void 0===a?void 0:a.lastname),picture:i.picture,email:null===(l=i.profile)||void 0===l?void 0:l.email}):t.splice(n,1);e.updateFeed&&e.updateFeed({likes:t}),s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:feed/likes"}).execute({id:e.data.id})},children:(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center"},children:[(0,An.jsx)(le.c,{style:{width:20,height:20,resizeMode:"contain"},source:e.data.likes&&-1!==e.data.likes.findIndex((e=>{var t;return e.id===(null===(t=i.profile)||void 0===t?void 0:t.id)}))?n(6228):n(6212)}),(0,An.jsx)(En,{style:[pr.body2,fr.black,tl.out_left_xs],children:e.data.likes?e.data.likes.length:0})]})}),(0,An.jsx)(Bc,{likes:e.data.likes})]}),(0,An.jsx)(yr,{color:u.y.GREY1,bgColor:"white",minWidth:"100%",height:1,style:{marginTop:5,marginBottom:15}}),("undefined"!==typeof e.updateFeed&&e.data.comments.length&&-1===a.indexOf(e.data.id)?[e.data.comments[0]]:e.data.comments).map((t=>{var o,a,s;return(0,An.jsxs)(p.c,{style:{flexDirection:"row",marginBottom:16},children:[(0,An.jsx)(p.c,{style:{marginTop:i.expanded?12:6},children:(0,An.jsx)(Rn,{bgColor:u.y.BLUE_LIGHT,color:u.y.BLACK,name:t.author.name,source:t.author.picture,size:30})}),(0,An.jsxs)(p.c,{style:{marginLeft:10,width:"90%",backgroundColor:"#F5F5F5",padding:i.expanded?16:8,borderRadius:12},children:[(0,An.jsxs)(p.c,{style:{flexDirection:"row"},children:[(0,An.jsx)(p.c,{style:{flex:1},children:(0,An.jsx)(En,{children:t.author.name,style:[pr.h5,fr.black]})}),"web"!==r.default.OS&&t.author.id===(null===(o=i.profile)||void 0===o?void 0:o.id)&&!e.locked&&(0,An.jsxs)(p.c,{style:{marginTop:-6},children:[(0,An.jsx)(cn.c,{style:{alignSelf:"flex-end"},onPress:()=>{var n;null===(n=e.setFeedItemId)||void 0===n||n.call(e,t.id),c(!0)},children:(0,An.jsx)(En,{style:[pr.h5,fr.black],children:"..."})}),(0,An.jsx)(sc,{width:"80%",handler:e=>{c=e},children:(0,An.jsxs)(cn.c,{style:{flexDirection:"row",alignSelf:"center",alignItems:"center"},onPress:()=>{var n,r,o;null===(n=e.setIsPost)||void 0===n||n.call(e,!1),null===(r=e.setFeedItemId)||void 0===r||r.call(e,t.id),c(!1),null===(o=e.setValidationDeletePostModalOpen)||void 0===o||o.call(e,!0)},children:[(0,An.jsx)(le.c,{style:{width:24,height:24,marginRight:6,resizeMode:"cover"},source:n(8288)}),(0,An.jsxs)(En,{style:[pr.h6,fr.black],children:[" ",(0,hn._)(uc.deleteCom)]})]})})]})]}),(0,An.jsx)(Oc,{linkStyle:{color:u.y.BLUE_DARK},onPress:e=>{"web"===r.default.OS?window.open(e,"_blank"):kn.c.openURL(e)},children:(0,An.jsx)(En,{style:[pr.body1,fr.black,{marginTop:4}],children:t.text})}),"web"===r.default.OS&&t.author.id===(null===(a=i.profile)||void 0===a?void 0:a.id)&&!e.locked&&(0,An.jsx)(wc,{mainText:"...",align:"flex-end",marginTop:-5,color:u.y.WHITE,viewStyle:{position:"absolute",right:15,top:12},borderRadius:8,borderWidth:1,borderColor:u.y.GREY2,outsideClick:e.dropdownOutsideClick,content:(0,An.jsx)(p.c,{style:[Cc.containerDropdown,{width:"max-content"}],children:(0,An.jsxs)(cn.c,{style:{flexDirection:"row",alignItems:"center",marginTop:t.author.id===(null===(s=i.profile)||void 0===s?void 0:s.id)?5:0},onPress:()=>{var n,r,o;null===(n=e.setIsPost)||void 0===n||n.call(e,!1),null===(r=e.setFeedItemId)||void 0===r||r.call(e,t.id),null===(o=e.setValidationDeletePostModalOpen)||void 0===o||o.call(e,!0)},children:[(0,An.jsx)(le.c,{style:{width:24,height:24,marginRight:6,resizeMode:"cover"},source:n(8288)}),(0,An.jsxs)(En,{style:[pr.h6,fr.black],children:[" ",(0,hn._)(uc.deleteCom)]})]})})})]})]},t.id)})),"undefined"!==typeof e.updateFeed&&e.data.comments.length>1&&(0,An.jsx)(cn.c,{onPress:()=>{const t=a.indexOf(e.data.id);-1===t?l([e.data.id,...a]):(a.splice(t,1),l([...a]))},children:(0,An.jsx)(le.c,{style:{width:18,height:18,resizeMode:"contain",alignSelf:"center",marginTop:8,marginBottom:8},source:-1!==a.indexOf(e.data.id)?n(6576):n(2404)})}),(0,An.jsx)(Lc,{locked:e.locked,setLocked:e.setLocked,updateFeed:()=>{var t;e.updateFeed?e.updateFeed():null===(t=e.forceUpdate)||void 0===t||t.call(e)},name:h,picture:i.picture,id:e.data.id,type:e.data.type})]})},Mc=e=>{var t;const o=d.useContext(yn.S);let i;return"undefined"===typeof e.feed?(0,An.jsx)(p.c,{}):(0,An.jsx)(p.c,{children:null===(t=e.feed)||void 0===t?void 0:t.map(((t,a)=>{var l;return(0,An.jsxs)(p.c,{children:["web"!==r.default.OS&&!e.locked&&(0,An.jsx)(p.c,{style:{marginTop:-10},children:(0,An.jsx)(cn.c,{style:{alignSelf:"flex-end"},onPress:()=>{e.setFeedItemId(t.id),e.setFeedItemsOwner(t.author.id),e.setSelectedItem({id:t.id,type:t.type,pinned:t.pinned}),e.setMobileOverlayOpen(!0)},children:(0,An.jsx)(En,{style:[pr.h5,fr.black],children:"..."})})}),"web"===r.default.OS&&!e.locked&&(0,An.jsx)(wc,{mainText:"...",align:"flex-end",marginBottom:-12,color:u.y.WHITE,borderRadius:8,borderWidth:1,borderColor:u.y.GREY2,outsideClick:e.dropdownOutsideClick,setClose:e=>i=e,content:(0,An.jsxs)(p.c,{style:[Cc.containerDropdown],children:[t.author.id===(null===(l=o.profile)||void 0===l?void 0:l.id)&&(0,An.jsxs)(cn.c,{style:{flexDirection:"row",alignItems:"center"},onPress:()=>{e.setFeedItemId(t.id),e.setIsPost(!0),e.setValidationDeletePostModalOpen(!0)},children:[(0,An.jsx)(le.c,{style:{width:24,height:24,marginRight:6,resizeMode:"cover"},source:n(8288)}),(0,An.jsx)(En,{style:[pr.h6,fr.black],children:(0,hn._)(uc.deletePost)})]})||(0,An.jsxs)(cn.c,{style:{flexDirection:"row",alignItems:"center"},onPress:()=>{e.setSelectedItem({id:t.id,type:t.type,pinned:t.pinned}),e.setSignalContent(!0)},children:[(0,An.jsx)(le.c,{style:{width:20,height:20,marginRight:6,resizeMode:"cover"},source:n(1220)}),(0,An.jsx)(En,{style:[pr.h6,fr.black],children:(0,hn._)(uc.reportContent)})]}),"news"!==t.type&&o.profile.can_submit_on_company&&(0,An.jsxs)(cn.c,{style:{flexDirection:"row",marginTop:10},onPress:()=>{s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:feed/"+(t.pinned?"unpin":"pin")}).execute({id:t.id}).then((()=>{i&&i(),e.updateFeed(e.limit)}))},children:[(0,An.jsx)(le.c,{style:{width:20,height:20,marginRight:6,resizeMode:"cover"},source:t.pinned?n(244):n(508)}),(0,An.jsx)(En,{style:[pr.h6,fr.black],children:(0,hn._)(t.pinned?uc.unpin:uc.pin)})]})]})}),(0,An.jsxs)(p.c,{children:[(0,An.jsx)(Dc,{data:t,locked:e.locked,setLocked:e.setLocked,dropdownOutsideClick:e.dropdownOutsideClick,setFeedItemId:e.setFeedItemId,setIsPost:e.setIsPost,setValidationDeletePostModalOpen:e.setValidationDeletePostModalOpen,updateFeed:t=>{e.updateFeed(e.limit,t?{key:e.feedKey,index:a,data:t}:void 0)}}),(0,An.jsx)(yr,{color:u.y.GREY1,bgColor:"white",minWidth:"100%",height:1,style:{marginTop:5,marginBottom:15}})]})]},t.id)}))})},Nc=e=>{var t,o;const[i,a]=d.useState(void 0),[l,c]=d.useState(15),[h,f]=d.useState(""),[g,m]=d.useState(),[y,v]=d.useState({}),[b,A]=d.useState(!1),[x,S]=d.useState(!1);let w,C,_;const E=d.useContext(yn.S);let R=!0,k=(e,t)=>{if(t){if(R&&i){const e={...i};Object.keys(t.data).forEach((n=>{e[t.key][t.index][n]=t.data[n]})),a(e)}}else s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:feed/list/v2"}).execute({limit:e}).then((e=>{R&&a(e)}))};const[I,T]=d.useState(!1),O=d.useCallback((()=>{T(!0),k(l),setTimeout((()=>{T(!1)}),500)}),[]);return d.useEffect((()=>(k(l),hc((()=>{k(l)})),0!==E.tab&&E.setTab(0),()=>{R=!1})),[]),(0,An.jsxs)(Or.c,{behavior:"ios"===r.default.OS?"padding":"height",keyboardVerticalOffset:"ios"===r.default.OS?80:30,style:[{flex:1,alignItems:"center",backgroundColor:u.y.BLUE_DARK}],children:[(0,An.jsx)(Sc,{update:()=>k(l),hasPins:()=>{var e;return 0!==(null===i||void 0===i||null===(e=i.pinned)||void 0===e?void 0:e.length)}}),(0,An.jsx)(jr.c,{style:[{width:"100%",backgroundColor:u.y.BLUE_DARK},tl.out_top_m],contentContainerStyle:E.expanded?{flexGrow:1,flexShrink:1,flexBasis:1,justifyContent:"flex-start",paddingLeft:15}:{width:"100%",paddingLeft:16,paddingRight:16,paddingBottom:20},showsVerticalScrollIndicator:"web"===r.default.OS,refreshControl:(0,An.jsx)(oc.c,{refreshing:I,onRefresh:O}),children:(0,An.jsxs)(p.c,{style:[E.expanded?fc.contentExpanded:"web"===r.default.OS?{}:fc.content,E.expanded?{maxWidth:650,paddingBottom:20}:{}],children:["web"!==r.default.OS&&(0,An.jsx)(sc,{width:"80%",handler:e=>_=e,children:(0,An.jsxs)(p.c,{style:{alignItems:"center"},children:[(0,An.jsxs)(cn.c,{style:{flexDirection:"row",alignSelf:"center",alignItems:"center"},onPress:()=>{var e;_(!1),g===(null===(e=E.profile)||void 0===e?void 0:e.id)?(A(!0),w(!0)):C(!0)},children:[g===(null===(t=E.profile)||void 0===t?void 0:t.id)&&(0,An.jsx)(le.c,{style:{width:24,height:24,marginRight:6,resizeMode:"cover"},source:n(8288)})||(0,An.jsx)(le.c,{style:{width:20,height:20,marginRight:6,resizeMode:"cover"},source:n(1220)}),(0,An.jsx)(En,{style:[pr.h6,fr.black],children:(0,hn._)(g===(null===(o=E.profile)||void 0===o?void 0:o.id)?uc.deletePost:uc.reportContent)})]}),"news"!==y.type&&E.profile.can_submit_on_company&&(0,An.jsxs)(cn.c,{style:{flexDirection:"row",marginTop:20},onPress:()=>{s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:feed/"+(y.pinned?"unpin":"pin")}).execute({id:y.id}).then((()=>{_(!1),k(l)}))},children:[(0,An.jsx)(le.c,{style:{width:20,height:20,marginRight:3,resizeMode:"cover"},source:y.pinned?n(244):n(508)}),(0,An.jsx)(En,{style:[pr.h6,fr.black],children:(0,hn._)(y.pinned?uc.unpin:uc.pin)})]})]})}),(0,An.jsx)(cc,{onPress:()=>{x||(S(!0),w(!1),s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:feed/delete"}).execute({id:h}).then((()=>{S(!1),k(l)})))},closeModal:()=>{f(""),w(!1)},hide:e=>{w=e},content:{message:b?uc.deleteConfirmPost:uc.deleteConfirmCom,buttonRight:{text:uc.deleteConfirmYes,backgroundColor:u.y.YELLOW_DARK,textColor:u.y.BLACK},buttonLeft:{text:uc.deleteConfirmNo}}}),(0,An.jsx)(cc,{onPress:()=>{x||(C(!1),s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:feed/report"}).execute(y))},closeModal:()=>{C(!1)},hide:e=>{C=e},content:{message:uc.reportContentConfirm,buttonRight:{text:uc.confirmReportBtn,backgroundColor:u.y.YELLOW_DARK,textColor:u.y.BLACK},buttonLeft:{text:uc.cancelReportBtn}}}),(null===i||void 0===i?void 0:i.pinned)&&0!==i.pinned.length&&(0,An.jsxs)(p.c,{children:[(0,An.jsx)(En,{children:(0,hn._)(uc.pinned),style:[pr.h6,fr.white,tl.out_bottom_m,tl.out_top_m,{paddingLeft:8}]}),(0,An.jsx)(ic,{bgColor:u.y.WHITE,style:[{borderRadius:10,paddingTop:16,width:"100%"},E.expanded?{paddingLeft:24,paddingRight:24}:{paddingLeft:16,paddingRight:16}],titleColor:u.y.BLUE_DARK,children:(0,An.jsx)(Mc,{feed:null===i||void 0===i?void 0:i.pinned,feedKey:"pinned",limit:l,locked:x,setLocked:S,dropdownOutsideClick:e.dropdownOutsideClick,setFeedItemId:f,setFeedItemsOwner:m,setSelectedItem:v,setIsPost:A,updateFeed:k,setValidationDeletePostModalOpen:e=>w(e),setSignalContent:e=>C(e),setMobileOverlayOpen:e=>_(e)})}),(0,An.jsx)(un.c,{children:(0,hn._)(uc.posts),style:[pr.h6,fr.white,tl.out_bottom_m,tl.out_top_m,{paddingLeft:8}]})]}),(null===i||void 0===i?void 0:i.main)&&0!==i.main.length&&(0,An.jsxs)(ic,{bgColor:u.y.WHITE,style:[{borderRadius:10,paddingTop:16,width:"100%"},E.expanded?{paddingLeft:24,paddingRight:24}:{paddingLeft:16,paddingRight:16}],titleColor:u.y.BLUE_DARK,children:[(0,An.jsx)(Mc,{feed:i.main,feedKey:"main",limit:l,locked:x,setLocked:S,dropdownOutsideClick:e.dropdownOutsideClick,setFeedItemId:f,setFeedItemsOwner:m,setSelectedItem:v,setIsPost:A,updateFeed:k,setValidationDeletePostModalOpen:e=>w(e),setSignalContent:e=>C(e),setMobileOverlayOpen:e=>_(e)}),(0,An.jsx)(cn.c,{onPress:()=>{const e=l+15;c(e),k(e)},children:(0,An.jsx)(le.c,{style:{width:20,height:20,resizeMode:"contain",alignSelf:"center",marginTop:8,marginBottom:8},source:n(2404)})})]})]})})]})},Uc={fr:"Vue utilisateur",en:"User view"},Fc={fr:"Vue admin",en:"Admin view"},Hc={fr:"Mon organisation",en:"My organization"},Gc=e=>({fr:"".concat(e," ").concat(1===e?"action r\xe9alis\xe9e":"actions r\xe9alis\xe9es"),en:"".concat(e," ").concat(1===e?"action realized":"actions realized")}),zc={fr:"sur les 17 Objectifs de D\xe9veloppement Durable de l\u2019ONU",en:"towards the 17 Sustainable Development Goals of the UN"},Vc=e=>({fr:"".concat(e," action").concat(1===e?"":"s"),en:"".concat(e," action").concat(1===e?"":"s")}),Wc={fr:"D\xe9couvrir les ODDs",en:"Discover the SDGs"},Qc=function(e){return{fr:"\xe9vit\xe9s par "+e+" collaborateurs engag\xe9s",en:"avoided by "+e+" committed colleagues"}},Yc=e=>({fr:e>100?"Compl\xe9t\xe9":"".concat(e,"% accompli"),en:e>100?"Completed":"".concat(e,"% completed")}),Kc=function(e,t){return t?{fr:"points collect\xe9s sur un objectif de "+e+" points",en:"points collected over a goal of "+e+" points"}:{fr:"collect\xe9s sur une enveloppe de "+e+" \u20ac",en:"collected over a total budget available of "+e+" \u20ac"}},qc=e=>({fr:"Campagne cl\xf4tur\xe9e le "+Jl(e,!1),en:"Campaign closed on "+Jl(e,!1)}),Xc={fr:"Mon \xe9quipe",en:"My team"},Jc=e=>({fr:e+" points collect\xe9s",en:e+" points collected"}),Zc=e=>({fr:e+"% des points de l'organisation",en:e+"% of the organization's points"}),$c={fr:"Classement des \xe9quipes",en:"Team ranking"},eu={fr:"D\xe9couvrir le classement",en:"Team ranking"},tu={fr:"Votre \xe9quipe",en:"Your team"},nu=function(e){return{fr:e+" membre".concat(1!==e?"s":""),en:e+" member".concat(1!==e?"s":"")}},ru={fr:"dans mon \xe9quipe",en:"in my team"},ou={fr:"Ma communaut\xe9",en:"My community"},iu=(e,t)=>({fr:e+" "+(t?"points":"\u20ac")+" collect\xe9s",en:e+" "+(t?"points":"\u20ac")+" collected"}),au=function(e){return{fr:e+" points r\xe9colt\xe9s par les collaborateurs qui soutiennent l'association",en:e+" points collected by colleagues who support the same charity"}},su=function(e){return{fr:e+" membres",en:e+" members"}},lu={fr:"soutiennent avec moi",en:"support with me"},cu={fr:"Voir le d\xe9tail",en:"See details"},uu={fr:"Ma contribution",en:"My contribution"},du={fr:"Niveau",en:"Level"},hu=function(e){return{fr:"Encore "+e.points+" points avant de passer au niveau "+e.lvlName,en:e.points+" points left until moving to "+e.lvlName}},pu=function(e){return{fr:"\xe9vit\xe9s gr\xe2ce \xe0 mes actions, soit l'\xe9quivalent de "+e+" km de voiture !",en:"avoided thanks to my actions, equivalent to a "+e+" km car ride"}},fu=function(e){return{fr:e+" points",en:e+" points"}},gu=function(e,t){return{fr:e.ratio+"% des points de l'organisation"+(t?"":" \xb7 "+e.earned+"\u20ac pour mon association"),en:e.ratio+"% of the points earned by the organization"+(t?"":" \xb7 "+e.earned+"\u20ac for my charity")}},mu=e=>"undefined"===typeof e||null===e?"0":("number"===typeof e&&(e=Math.floor(e).toString()),e.replace(/\B(?=(\d{3})+(?!\d))/g," ")),yu=e=>"undefined"===typeof e||null===e||0===e?"0 g":e>=1e6?"".concat(mu((e/1e6).toFixed(2))," t"):e>=1e3?"".concat(mu((e/1e3).toFixed(2))," kg"):"".concat(mu(e.toFixed(2))," g"),vu={mainTitle:e=>({fr:"Impact"+e,en:"Impact"+e}),updateDescription:e=>({fr:"Cumul\xe9 depuis le "+Jl(e),en:"\xe0 traduire "+Jl(e)}),global:{fr:"Aper\xe7u global",en:"Global overview"},globalCommitment:{fr:"Taux d'engagement",en:"Commitment rate"},globalCommitmentBeginning:{fr:"depuis le d\xe9but",en:"from the beginning"},globalCommitmentLastWeek:{fr:"la semaine derni\xe8re",en:"last week"},globalUsers:{fr:"Utilisateurs",en:"Users"},globalUsersDescription:(e,t)=>({fr:e+"% d'adoption sur "+mu(t)+" collaborateurs invit\xe9s",en:e+"% registration rate out of "+mu(t)+" expected collaborators"}),export:{fr:"Exporter la liste",en:"Export list"},globalActionsDone:{fr:"Actions r\xe9alis\xe9es",en:"Actions completed"},globalActionsChallenges:e=>({fr:e+"% de challenges",en:e+"% challenges"}),globalActionsRoutines:e=>({fr:e+"% de routines",en:e+"% daily routines"}),globalCO2:{fr:"\xc9qu. CO2 \xe9vit\xe9",en:"CO2 equ. avoided"},globalCO2Description:e=>({fr:"Soit l'\xe9quivalent de ".concat(e," trajet").concat(e>1?"s":""," aller-retour de Marseille \xe0 Paris"),en:"This is equivalent to ".concat(e," round trip").concat(e>1?"s":""," from Marseille to Paris")}),globalEarned:{fr:"Dons collect\xe9s",en:"Collected funds"},globalEarnedDescription:function(e,t){let n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return{fr:e+"% accompli sur une enveloppe de "+mu(t)+(n?" points":" \u20ac"),en:e+"% collected on a "+mu(t)+(n?" points":" \u20ac")+" envelope"}},activity:{fr:"Activit\xe9",en:"Activity"},activityChart:{fr:"\xc9volution de l'engagement des utilisateurs",en:"Evolution of user engagement rate"},activityUsers:{fr:"Utilisateurs actifs",en:"Active user"},activityUsersBeginning:{fr:"depuis le d\xe9but",en:"from the beginning"},activityUsersLastWeek:{fr:"la semaine derni\xe8re",en:"last week"},activityPoints:{fr:"Points collect\xe9s",en:"Collected points"},activityPointsDescription:{fr:"depuis le d\xe9but",en:"from the beginning"},activityParticipation:{fr:"Participation",en:"Participation rate"},activityParticipationDescription:{fr:"au dernier challenge",en:"at the last challenge"},activityChallengesTitle:(e,t)=>({fr:(()=>{let n="Taux de participation au";return 1!==t&&(n+="x"),n+=" challenge"+(1!==t?"s":"")+" ",n+=e?"en cours":"pass\xe9"+(1!==t?"s":""),n})(),en:(()=>{let n="Participation rate in ";return n+=e?"current challenge"+(1!==t?"s":""):"past challenge"+(1!==t?"s":""),n})()}),activityChallengeIndividual:{fr:"individuel",en:"individual"},activityChallengeCollective:{fr:"collectif",en:"collective"},activityChallengeTimeLeft:e=>({fr:0===e?"moins de 1 jour restant":"".concat(e," jour").concat(1!==e?"s":""," restant").concat(1!==e?"s":""),en:0===e?"less than 1 day left":"".concat(e," day").concat(1!==e?"s":""," left")}),activityChallengeEndDate:e=>({fr:"fini le ".concat(e),en:"ends on ".concat(e)}),activitySeeMore:{fr:"Afficher tous",en:"View all"},activitySeeLess:{fr:"Afficher moins",en:"View less"},rankingTitle:{fr:"Classements",en:"Leaderboard"},rankingAmbassadors:{fr:"Top 3 ambassadeurs",en:"Top 3 ambassadors"},rankingAmbassadorsPoints:e=>({fr:e+" points",en:e+" points"}),rankingChallenges:{fr:"Top 3 challenges",en:"Top 3 challenges"},rankingChallengesParticipation:e=>({fr:e+"% de participation",en:e+"% of participation"}),rankingRoutines:{fr:"Top 3 routines",en:"Top 3 routines"},rankingRoutinesAccomplished:e=>({fr:"R\xe9alis\xe9e "+e+" fois",en:"Accomplished ".concat(e," time").concat(e>1?"s":"")}),rankingCommunities:{fr:"Classement des communaut\xe9s",en:"Community Ranking"},communityRankingEarned:(e,t)=>({fr:"".concat(e," ").concat(t?"points":"\u20ac"," collect\xe9").concat(e>1?"s":""),en:"".concat(e," ").concat(t?"points":"\u20ac"," collected")}),communityRankingMembers:e=>({fr:"".concat(e," membre").concat(e>1?"s":""),en:"".concat(e," member").concat(e>1?"s":"")})},bu=e=>{let{picture:t,date:n,showUpdateText:r}=e;return(0,An.jsxs)(p.c,{children:[(0,An.jsx)(le.c,{source:{uri:t},style:{width:125,height:125,resizeMode:"contain",alignSelf:"center"}}),r&&(0,An.jsx)(un.c,{style:[pr.body2,tl.out_top_m,tl.out_bottom_l],children:(0,hn._)(vu.updateDescription(n))})]})},Au=b.c.create({blueInsert:{backgroundColor:u.y.BLUE_LIGHT_X,borderRadius:20,padding:16,marginBottom:24},whiteInsert:{backgroundColor:u.y.WHITE,paddingLeft:16,paddingRight:16,maxWidth:330},borderRight:{borderRightColor:u.y.GREY_LIGHT,borderRightWidth:1,maxHeight:110},horizontal:{flexDirection:"row"},vertical:{flexDirection:"column"},flex1:{flex:1},fullWidth:{width:"100%"},spaceBetween:{justifyContent:"space-between"},blueLightSquare:{height:15,width:15,backgroundColor:u.y.BLUE_LIGHT,marginRight:8,borderRadius:4},blueDarkSquare:{height:15,width:15,backgroundColor:u.y.BLUE_DARK,marginRight:8,borderRadius:4}}),xu=100,Su=20,wu=e=>{let{data:t}=e;const n={};for(const o of t){const e=new Date(o.date),t=(0,hn._)(Cu(e.getMonth()))+" "+e.getFullYear().toString().slice(2);"undefined"===typeof n[t]&&(n[t]=0),n[t]+=o.value}const r=Object.keys(n);return(0,An.jsx)(jr.c,{style:{paddingBottom:10},horizontal:!0,children:(0,An.jsxs)(wn.Svg,{height:150,width:50*r.length,children:[r.reduce(((e,t,o)=>{const i=50*o+20;if(e.push((0,An.jsx)(wn.Line,{x1:i,y1:"0",x2:i,y2:140,stroke:u.y.GREY_LIGHT,strokeWidth:"2"},o+"-column")),0!==o){let a=n[t];a>100&&(a=100);let s=n[r[o-1]];s>100&&(s=100);const l={x:i,y:xu-a+Su},c={x:l.x-50,y:xu-s+Su};e.push((0,An.jsx)(wn.Path,{d:"M ".concat(c.x," ").concat(c.y," L ").concat(l.x," ").concat(l.y," L ").concat(l.x," ").concat(140," L ").concat(c.x," ").concat(140," Z"),fill:u.y.BLUE_LIGHT_X},o+"-path"))}return e}),[]),r.reduce(((e,t,o)=>{let i=n[t];i>100&&(i=100);const a=50*o+20,s=[...e,(0,An.jsx)(wn.Text,{x:a,y:150,fontSize:"10",fill:u.y.GREY2,textAnchor:"middle",children:t},o+"-text"),(0,An.jsx)(wn.Circle,{cx:a,cy:xu-i+Su,r:"4",fill:u.y.BLUE_DARK},o+"-point"),(0,An.jsx)(wn.Text,{x:a,y:xu-i+Su-(i>50?10:20),fontSize:"10",fill:u.y.BLUE_DARK,textAnchor:"middle",children:mu(n[t])},o+"-value")];if(0!==o){let e=n[r[o-1]];e>100&&(e=100),s.push((0,An.jsx)(wn.Line,{x1:a-50,y1:xu-e+Su,x2:a,y2:xu-i+Su,stroke:u.y.BLUE_DARK,strokeWidth:"2"},o+"-line"))}return s}),[])]})})};function Cu(e){return 0===e?{fr:"Jan",en:"Jan"}:1===e?{fr:"F\xe9v",en:"Feb"}:2===e?{fr:"Mar",en:"Mar"}:3===e?{fr:"Avr",en:"Apr"}:4===e?{fr:"Mai",en:"May"}:5===e?{fr:"Jui",en:"Jun"}:6===e?{fr:"Jui",en:"Jul"}:7===e?{fr:"Ao\xfb",en:"Aug"}:8===e?{fr:"Sep",en:"Sep"}:9===e?{fr:"Oct",en:"Oct"}:10===e?{fr:"Nov",en:"Nov"}:11===e?{fr:"D\xe9c",en:"Dec"}:{fr:"",en:""}}const _u=e=>{const t=d.useContext(yn.S),[r,o]=d.useState(!1);if(0===e.challenges.length)return(0,An.jsx)(p.c,{});let i=e.challenges;return r||(i=i.slice(0,3)),(0,An.jsxs)(p.c,{children:[(0,An.jsx)(En,{style:[pr.h6,fr.blue_dark,tl.out_bottom_m,tl.out_top_s],children:(0,hn._)(vu.activityChallengesTitle(e.current,e.challenges.length))}),(0,An.jsx)(yr,{color:u.y.GREY1,minWidth:"100%",height:1,style:{marginBottom:16}}),i.map(((r,o)=>{let a,s;if(a=e.current?r.collective?n(8640):n(1228):r.collective?n(7416):n(3100),e.current){const e=Math.ceil((r.date-Date.now())/864e5);s=(0,hn._)(vu.activityChallengeTimeLeft(e))}else{const e=(e=>{const t=new Date("number"===typeof e?e:Number(e));let n=t.getDate()+" ";if("fr"===hn.O.get())switch(t.getMonth()){case 0:n+="janvier";break;case 1:n+="f\xe9vrier";break;case 2:n+="mars";break;case 3:n+="avril";break;case 4:n+="mai";break;case 5:n+="juin";break;case 6:n+="juillet";break;case 7:n+="ao\xfbt";break;case 8:n+="septembre";break;case 9:n+="octobre";break;case 10:n+="novembre";break;case 11:n+="d\xe9cembre"}else switch(t.getMonth()){case 0:n+="January";break;case 1:n+="February";break;case 2:n+="March";break;case 3:n+="April";break;case 4:n+="May";break;case 5:n+="June";break;case 6:n+="July";break;case 7:n+="August";break;case 8:n+="September";break;case 9:n+="October";break;case 10:n+="November";break;case 11:n+="December"}return n+" "+t.getFullYear()})(r.date);s=(0,hn._)(vu.activityChallengeEndDate(e))}return(0,An.jsxs)(p.c,{style:{marginBottom:16},children:[(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center",justifyContent:"space-between",paddingBottom:16},children:[(0,An.jsxs)(p.c,{style:[t.expanded?{flexDirection:"row"}:{maxWidth:"80%",flexDirection:"column"}],children:[(0,An.jsx)(En,{style:[pr.h4,{marginRight:24,maxWidth:450},e.current?fr.blue_dark:fr.grey2],children:(0,hn._)(r.name)}),(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center"},children:[(0,An.jsx)(le.c,{style:{height:16,width:16,marginRight:8},source:a}),(0,An.jsx)(En,{style:[pr.h6,e.current?fr.blue_dark:fr.grey2],children:r.collective?(0,hn._)(vu.activityChallengeCollective):(0,hn._)(vu.activityChallengeIndividual)}),(0,An.jsx)(En,{style:[{marginLeft:4,marginRight:4},pr.caption,fr.grey2],children:"\u2022"}),(0,An.jsx)(En,{style:[pr.body2,fr.grey2],children:s})]})]}),(0,An.jsx)(En,{style:[pr.h4,e.current?fr.blue_dark:fr.grey2],children:r.value+" %"})]}),(e.challenges.length>3||o!==i.length-1)&&(0,An.jsx)(yr,{color:u.y.GREY1,minWidth:"100%",height:1})]},o)})),e.challenges.length>3&&(0,An.jsx)(xl,{textColor:u.y.BLUE_DARK,onPress:()=>o(!r),style:[{borderRadius:24,borderWidth:1,borderColor:u.y.GREY1,paddingLeft:12,paddingRight:12,marginBottom:24},t.expanded?{alignSelf:"flex-start"}:{}],fontSize:16,side:(0,An.jsx)(le.c,{style:{height:16,width:16,marginLeft:6},source:n(r?1752:4692)}),fontWeight:"700",color:u.y.WHITE,children:(0,hn._)(r?vu.activitySeeLess:vu.activitySeeMore)})]})},Eu=e=>{let{data:t}=e;const n=d.useContext(yn.S);return(0,An.jsxs)(p.c,{children:[(0,An.jsx)(un.c,{style:[pr.h2,tl.out_bottom_m,tl.out_top_l],children:(0,hn._)(vu.activity)}),(0,An.jsxs)(p.c,{style:{borderColor:u.y.GREY_LIGHT,borderWidth:1,borderRadius:20,marginBottom:32},children:[(0,An.jsx)(un.c,{style:[{paddingLeft:16,marginBottom:16,marginTop:16},pr.h5,fr.blue_dark],children:(0,hn._)(vu.activityChart)}),(0,An.jsx)(p.c,{style:[{paddingLeft:16,paddingRight:16}],children:(0,An.jsx)(wu,{data:t.activity.months})}),(0,An.jsxs)(p.c,{style:[n.expanded?{flexDirection:"row"}:{flexDirection:"column"}],children:[(0,An.jsxs)(p.c,{style:[Au.whiteInsert,bn.full_width,n.expanded?{borderRightColor:u.y.GREY_LIGHT,borderRightWidth:1,maxHeight:110,marginTop:16,marginBottom:16}:{paddingTop:16,paddingBottom:16}],children:[(0,An.jsx)(un.c,{style:[pr.h5,fr.blue_dark],children:(0,hn._)(vu.activityUsers)}),(0,An.jsxs)(p.c,{style:[Au.horizontal],children:[(0,An.jsxs)(p.c,{style:{marginRight:24},children:[(0,An.jsx)(un.c,{style:[pr.h2,fr.blue_dark,tl.out_top_m],children:t.activity.users.beginning}),(0,An.jsx)(un.c,{style:[pr.caption,fr.grey2],children:(0,hn._)(vu.activityUsersBeginning)})]}),(0,An.jsxs)(p.c,{children:[(0,An.jsx)(un.c,{style:[pr.h2,fr.blue_dark,tl.out_top_m],children:t.activity.users.lastWeek}),(0,An.jsx)(un.c,{style:[pr.caption,fr.grey2],children:(0,hn._)(vu.activityUsersLastWeek)})]})]})]}),n.expanded&&(0,An.jsx)(p.c,{style:[bn.horizontal],children:(0,An.jsxs)(p.c,{style:[Au.whiteInsert,bn.full_width,tl.out_top_m,tl.out_bottom_m],children:[(0,An.jsx)(un.c,{style:[pr.h5,fr.blue_dark],children:(0,hn._)(vu.activityPoints)}),(0,An.jsxs)(p.c,{children:[(0,An.jsx)(un.c,{style:[pr.h2,fr.blue_dark,tl.out_top_m],children:t.activity.points.beginning}),(0,An.jsx)(un.c,{style:[pr.caption,fr.grey2],children:(0,hn._)(vu.activityPointsDescription)})]})]})}),!n.expanded&&(0,An.jsxs)(p.c,{style:[bn.horizontal,tl.out_top_m,tl.out_bottom_m],children:[(0,An.jsxs)(p.c,{style:[Au.whiteInsert,{width:"50%"}],children:[(0,An.jsx)(un.c,{style:[pr.h5,fr.blue_dark],children:(0,hn._)(vu.activityPoints)}),(0,An.jsxs)(p.c,{children:[(0,An.jsx)(un.c,{style:[pr.h2,fr.blue_dark,tl.out_top_m],children:t.activity.users.beginning}),(0,An.jsx)(un.c,{style:[pr.caption,fr.grey2],children:(0,hn._)(vu.activityPointsDescription)})]})]}),(0,An.jsxs)(p.c,{style:[Au.whiteInsert,{width:"50%"}],children:[(0,An.jsx)(un.c,{style:[pr.h5,fr.blue_dark],children:(0,hn._)(vu.activityParticipation)}),(0,An.jsxs)(p.c,{children:[(0,An.jsxs)(un.c,{style:[pr.h2,fr.blue_dark,tl.out_top_m],children:[t.activity.participation.lastChallenge,"%"]}),(0,An.jsx)(un.c,{style:[pr.caption,fr.grey2],children:(0,hn._)(vu.activityParticipationDescription)})]})]})]})]}),(0,An.jsxs)(p.c,{style:[{paddingLeft:16,paddingRight:16}],children:[(0,An.jsx)(_u,{current:!0,challenges:t.history.current}),(0,An.jsx)(_u,{current:!1,challenges:t.history.past})]})]})]})},Ru=b.c.create({points:{backgroundColor:u.y.BLUE_DARK},bonus:{backgroundColor:u.y.YELLOW_DARK},objective:{backgroundColor:u.y.GREEN},objectiveText:{position:"absolute",fontSize:12,color:u.y.GREEN,right:0,fontWeight:"bold",flex:1},text:{fontSize:30,fontWeight:"bold",textAlign:"center",color:u.y.BLUE_DARK,marginTop:8}}),ku={fr:"Objectif :",en:"Objective:"},Iu=e=>{const t=d.useContext(yn.S),n=e.width-("undefined"!==typeof e.objectiveWidth?e.objectiveWidth:0),r=e.objective+("undefined"!==typeof e.shift?e.shift:0),o=0===r?0:n/r;return(0,An.jsxs)(p.c,{children:[(0,An.jsxs)(p.c,{style:{height:e.height,flexDirection:"row",width:e.width,backgroundColor:e.backgroundColor||"white",borderRadius:e.borderRadius,alignSelf:"center"},children:[(0,An.jsx)(p.c,{style:[Ru.points,{width:o*e.points,maxWidth:e.width,height:e.height,borderRadius:e.borderRadius}]}),(0,An.jsx)(p.c,{style:[Ru.bonus,{width:o*e.bonus,height:e.height}]}),"undefined"!==typeof e.objectiveWidth&&(0,An.jsx)(En,{style:[Ru.objectiveText,{top:-e.height}],children:(t.expanded?"".concat((0,hn._)(ku)," "):"")+mu(e.objective)}),"undefined"!==typeof e.objectiveWidth&&(0,An.jsx)(p.c,{style:[Ru.objective,{marginLeft:o*(e.objective-e.points-e.bonus),width:e.objectiveWidth,height:e.height}]})]}),"undefined"!==typeof e.text&&(0,An.jsx)(En,{style:Ru.text,children:e.text})]})},Tu=e=>{var t,o,i,a,l,c,h,f,g,m,y,v,b;let{data:A}=e;const x=d.useContext(yn.S),S=!(null!==(t=x.profile)&&void 0!==t&&null!==(o=t.company)&&void 0!==o&&o.noCommunities)||!(null!==(i=x.profile)&&void 0!==i&&null!==(a=i.company)&&void 0!==a&&a.limitedBudgetCap)||A.global.earned.expectedCount>=A.global.earned.total,w=S?null===(l=A.global.earned)||void 0===l?void 0:l.total:null===(c=A.global.earned)||void 0===c?void 0:c.expectedCount,C=S?null===(h=A.global.earned)||void 0===h?void 0:h.expectedProportion:100,_=!(null===(f=x.profile)||void 0===f||null===(g=f.company)||void 0===g||!g.noCommunities),E=!(null===(m=x.profile)||void 0===m||null===(y=m.company)||void 0===y||!y.forcePoints);return(0,An.jsxs)(p.c,{children:[(0,An.jsx)(un.c,{style:[pr.h2,tl.out_bottom_m,tl.out_top_l],children:(0,hn._)(vu.global)}),(0,An.jsxs)(p.c,{style:[Au.horizontal,{flexWrap:"wrap",justifyContent:"space-between"}],children:[(0,An.jsxs)(p.c,{style:[Au.blueInsert,x.expanded?{}:{flexDirection:"column",width:"100%",justifyContent:"flex-start"}],children:[(0,An.jsx)(un.c,{style:[pr.h5,fr.blue_dark],children:(0,hn._)(vu.globalCommitment)}),(0,An.jsxs)(p.c,{style:x.expanded?{}:{flexDirection:"row",width:"100%",marginTop:24,justifyContent:"center"},children:[(0,An.jsxs)(p.c,{style:[Au.vertical,Au.flex1,x.expanded?{marginTop:16}:{borderRightColor:u.y.GREY1,borderRightWidth:1,marginRight:16}],children:[(0,An.jsxs)(un.c,{style:[pr.h2,fr.blue_dark],children:[A.global.commitment.beginning,"%"]}),(0,An.jsx)(un.c,{style:[pr.caption,fr.grey2],children:(0,hn._)(vu.globalCommitmentBeginning)})]}),(0,An.jsxs)(p.c,{style:[Au.vertical,Au.flex1,x.expanded?{marginTop:16}:{}],children:[(0,An.jsxs)(un.c,{style:[pr.h2,fr.blue_dark],children:[A.global.commitment.lastWeek,"%"]}),(0,An.jsx)(un.c,{style:[pr.caption,fr.grey2],children:(0,hn._)(vu.globalCommitmentLastWeek)})]})]})]}),(0,An.jsxs)(p.c,{style:[Au.blueInsert,x.expanded?{minWidth:180,maxWidth:180,width:"100%"}:{maxWidth:"47%",minWidth:"47%",marginRight:8},x.expanded||"web"!==r.default.OS?{}:{maxWidth:"48%",minWidth:"48%",marginRight:4}],children:[(0,An.jsx)(un.c,{style:[pr.h5,fr.blue_dark],children:(0,hn._)(vu.globalUsers)}),(0,An.jsx)(un.c,{style:[x.expanded||"web"!==r.default.OS?pr.h2:pr.h3,fr.blue_dark,tl.out_top_m,tl.out_bottom_m],children:A.global.users.total}),(0,An.jsxs)(cn.c,{style:{flexDirection:"row",alignItems:"center",marginBottom:16},onPress:()=>{const e=s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:admin/exportUsers"}).url();"web"===r.default.OS?window.open(e,"_blank"):Promise.resolve(kn.c.openURL(e))},children:[(0,An.jsx)(le.c,{source:n(7748),style:{width:24,height:24}}),(0,An.jsx)(un.c,{children:(0,hn._)(vu.export),style:{marginLeft:10}})]}),(0,An.jsx)(Iu,{width:130,height:10,objective:A.global.users.expectedCount,points:A.global.users.total,shift:0,bonus:0,backgroundColor:u.y.GREY1,borderRadius:10}),(0,An.jsx)(un.c,{style:[pr.caption,fr.grey2,tl.out_top_m],children:(0,hn._)(vu.globalUsersDescription(A.global.users.expectedProportion,A.global.users.expectedCount))})]}),(0,An.jsxs)(p.c,{style:[Au.blueInsert,x.expanded?{minWidth:180,maxWidth:180,width:"100%"}:{maxWidth:"47%",minWidth:"47%",marginLeft:8},x.expanded||"web"!==r.default.OS?{}:{maxWidth:"48%",minWidth:"48%",marginLeft:4}],children:[(0,An.jsx)(un.c,{style:[pr.h5,fr.blue_dark],children:(0,hn._)(vu.globalActionsDone)}),(0,An.jsx)(un.c,{style:[x.expanded||"web"!==r.default.OS?pr.h2:pr.h3,fr.blue_dark,tl.out_top_m],children:A.global.actions.total}),!(null===(v=x.profile)||void 0===v||null===(b=v.company)||void 0===b||!b.pointsExport)&&(0,An.jsxs)(cn.c,{style:{flexDirection:"row",alignItems:"center",marginTop:16},onPress:()=>{const e=s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:admin/exportPoints"}).url();"web"===r.default.OS?window.open(e,"_blank"):Promise.resolve(kn.c.openURL(e))},children:[(0,An.jsx)(le.c,{source:n(7748),style:{width:24,height:24}}),(0,An.jsx)(un.c,{children:(0,hn._)(vu.export),style:{marginLeft:10}})]}),(0,An.jsxs)(p.c,{style:[Au.horizontal,tl.out_top_m],children:[(0,An.jsx)(p.c,{style:Au.blueLightSquare}),(0,An.jsx)(un.c,{style:[pr.caption,fr.grey2],children:(0,hn._)(vu.globalActionsChallenges(A.global.actions.challenges))})]}),(0,An.jsxs)(p.c,{style:[Au.horizontal,tl.out_top_s],children:[(0,An.jsx)(p.c,{style:Au.blueDarkSquare}),(0,An.jsx)(un.c,{style:[pr.caption,fr.grey2],children:(0,hn._)(vu.globalActionsRoutines(A.global.actions.routines))})]})]}),(0,An.jsxs)(p.c,{style:[Au.blueInsert,x.expanded?{minWidth:180,maxWidth:180,width:"100%"}:{maxWidth:"47%",minWidth:"47%",marginRight:8},x.expanded||"web"!==r.default.OS?{}:{maxWidth:"48%",minWidth:"48%",marginRight:4}],children:[(0,An.jsx)(un.c,{style:[pr.h5,fr.blue_dark],children:(0,hn._)(vu.globalCO2)}),(0,An.jsx)(un.c,{style:[x.expanded||"web"!==r.default.OS?pr.h2:pr.h3,fr.blue_dark,tl.out_top_m,tl.out_bottom_s],children:yu(A.global.co2.total)}),(0,An.jsx)(le.c,{style:{width:16,height:16},source:n(5680)}),(0,An.jsx)(un.c,{style:[pr.caption,fr.grey2,tl.out_top_xs],children:(0,hn._)(vu.globalCO2Description(A.global.co2.car))})]}),"undefined"!==typeof A.global.earned&&(0,An.jsxs)(p.c,{style:[Au.blueInsert,x.expanded?{minWidth:180,maxWidth:180,width:"100%"}:{maxWidth:"47%",minWidth:"47%",marginLeft:8},x.expanded||"web"!==r.default.OS?{}:{maxWidth:"48%",minWidth:"48%",marginLeft:4}],children:[(0,An.jsx)(un.c,{style:[pr.h5,fr.blue_dark],children:(0,hn._)(vu.globalEarned)}),(0,An.jsxs)(un.c,{style:[x.expanded||"web"!==r.default.OS?pr.h2:pr.h3,fr.blue_dark,tl.out_top_m,tl.out_bottom_m],children:[Math.round(w)," ",_||E?"points":"\u20ac"]}),(0,An.jsx)(Iu,{width:130,height:10,objective:A.global.earned.expectedCount,points:w,shift:0,bonus:0,backgroundColor:u.y.GREY1,borderRadius:10}),(0,An.jsx)(un.c,{style:[pr.caption,fr.grey2,tl.out_top_m],children:(0,hn._)(vu.globalEarnedDescription(C,A.global.earned.expectedCount,_||E))})]})]})]})},Ou=e=>{let{data:t}=e;const n=d.useContext(yn.S);return(0,An.jsxs)(p.c,{style:[n.expanded?{width:"32%"}:{width:"100%"},{borderColor:u.y.GREY_LIGHT,borderWidth:1,borderRadius:20,paddingTop:16,paddingLeft:16,paddingRight:16,backgroundColor:u.y.WHITE,paddingBottom:16,marginBottom:16}],children:[(0,An.jsx)(un.c,{style:[pr.h3],children:(0,hn._)(vu.rankingAmbassadors)}),t.ranking.ambassadors.map(((e,r)=>(0,An.jsx)(p.c,{children:(0,An.jsxs)(p.c,{style:[bn.horizontal,{borderBottomColor:u.y.GREY_LIGHT,borderBottomWidth:r===t.ranking.ambassadors.length-1?0:1,paddingBottom:r===t.ranking.ambassadors.length-1?0:16,paddingTop:16}],children:[(0,An.jsx)(Rn,{source:e.picture,name:e.name,size:40,bgColor:"white",color:u.y.BLUE_DARK,style:[{marginRight:12},n.expanded?{}:{height:35,width:35,marginTop:4}]}),(0,An.jsxs)(p.c,{children:[(0,An.jsx)(un.c,{style:[pr.body1,fr.blue_dark],children:e.name}),(0,An.jsx)(un.c,{style:[pr.body2,fr.grey2],children:(0,hn._)(vu.rankingAmbassadorsPoints(e.points))})]})]})},r)))]})},ju=e=>({1:{fr:"ODD 1 : Pas de pauvret\xe9",en:"SDG 1 : No poverty"},2:{fr:"ODD 2 : Faim z\xe9ro",en:"SDG 2 : Zero hunger"},3:{fr:"ODD 3 : Bonne sant\xe9 et bien-\xeatre",en:"SDG 3 : Good health and well-being"},4:{fr:"ODD 4 : \xc9ducation de qualit\xe9",en:"SDG 4 : Quality education"},5:{fr:"ODD 5 : \xc9galit\xe9 entre les sexes",en:"SDG 5 : Gender equality"},6:{fr:"ODD 6 : Eau propre et assainissement",en:"SDG 6 : Clean water and sanitation"},7:{fr:"ODD 7 : \xc9nergie propre et d'un co\xfbt abordable",en:"SDG 7 : Affordable and clean energy"},8:{fr:"ODD 8 : Travail d\xe9cent et croissance \xe9conomique",en:"SDG 8 : Decent work and economic growth"},9:{fr:"ODD 9 : Industrie, innovation et infrastructure",en:"SDG 9 : Industry, innovation and infrastructure"},10:{fr:"ODD 10 : In\xe9galit\xe9s r\xe9duites",en:"SDG 10 : Reduced inequalities"},11:{fr:"ODD 11 : Villes et communaut\xe9s durables",en:"SDG 11 : Sustainable cities and communities"},12:{fr:"ODD 12 : Consommation et production responsables",en:"SDG 12 : Responsible consumption and production"},13:{fr:"ODD 13 : Lutte contre les changements climatiques",en:"SDG 13 : Climate action"},14:{fr:"ODD 14 : Vie aquatique",en:"SDG 14 : Life below water"},15:{fr:"ODD 15 : Vie terrestre",en:"SDG 15 : Life on land"},16:{fr:"ODD 16 : Paix, justice et institutions efficaces",en:"SDG 16 : Peace, justice and strong institutions"},17:{fr:"ODD 17 : Partenariats pour la r\xe9alisation des objectifs",en:"SDG 17 : Partnerships for the goals"}}[e]),Pu=e=>({1:"#E5243B",2:"#DDA83A",3:"#4C9F38",4:"#C5192D",5:"#FF3A21",6:"#26BDE2",7:"#FCC30B",8:"#A21942",9:"#FD6925",10:"#DD1367",11:"#FD9D24",12:"#BF8B2E",13:"#3F7E44",14:"#0A97D9",15:"#56C02B",16:"#00689D",17:"#19486A"}[e]),Bu=e=>{const t=d.useContext(yn.S);return(0,An.jsx)(p.c,{style:[{backgroundColor:Pu(e.number),borderRadius:4,paddingTop:4,paddingBottom:4,paddingLeft:8,paddingRight:8},t.expanded?{width:"fit-content"}:{alignSelf:"flex-start"}],children:(0,An.jsx)(un.c,{style:[fr.white,pr.caption],children:(0,hn._)(ju(e.number))})})},Lu=e=>{let{data:t}=e;const n=d.useContext(yn.S);return(0,An.jsxs)(p.c,{style:[{borderColor:u.y.GREY_LIGHT,borderWidth:1,borderRadius:20,padding:16,marginBottom:16,backgroundColor:"white"},n.expanded?{width:"32%"}:{width:"100%"}],children:[(0,An.jsx)(un.c,{style:[pr.h3,tl.out_bottom_s],children:(0,hn._)(vu.rankingChallenges)}),t.ranking.challenges.map(((e,n)=>(0,An.jsx)(p.c,{children:(0,An.jsx)(p.c,{style:{borderBottomColor:u.y.GREY_LIGHT,borderBottomWidth:n===t.ranking.challenges.length-1?0:1,paddingBottom:n===t.ranking.challenges.length-1?0:16},children:(0,An.jsxs)(p.c,{children:[(0,An.jsx)(un.c,{style:[pr.body1,fr.blue_dark,tl.out_top_s],children:(0,hn._)(e.name)}),(0,An.jsx)(Bu,{number:e.odd}),(0,An.jsx)(un.c,{style:[pr.body2,fr.grey2],children:(0,hn._)(vu.rankingChallengesParticipation(e.proportion))})]})})},n)))]})},Du=e=>{let{data:t}=e;const n=d.useContext(yn.S);return(0,An.jsxs)(p.c,{style:[{borderColor:u.y.GREY_LIGHT,borderWidth:1,borderRadius:20,padding:16,backgroundColor:u.y.WHITE,marginBottom:16},n.expanded?{width:"32%"}:{width:"100%"}],children:[(0,An.jsx)(un.c,{style:[pr.h3,tl.out_bottom_s],children:(0,hn._)(vu.rankingRoutines)}),t.ranking.routines.map(((e,n)=>(0,An.jsx)(p.c,{children:(0,An.jsx)(p.c,{style:2===n?{}:{borderBottomColor:u.y.GREY_LIGHT,borderBottomWidth:n===t.ranking.routines.length-1?0:1,paddingBottom:n===t.ranking.routines.length-1?0:16},children:(0,An.jsxs)(p.c,{children:[(0,An.jsx)(un.c,{style:[pr.body1,fr.blue_dark,tl.out_top_s],children:(0,hn._)(e.name)}),(0,An.jsx)(Bu,{number:e.odd}),(0,An.jsx)(un.c,{style:[pr.body2,fr.grey2],children:(0,hn._)(vu.rankingRoutinesAccomplished(e.total))})]})})},n)))]})},Mu=e=>{var t,r;let{data:o}=e;const[i,a]=d.useState(!1),s=d.useContext(yn.S),l=!(null===(t=s.profile)||void 0===t||null===(r=t.company)||void 0===r||!r.forcePoints);if(!o.ranking.communities)return(0,An.jsx)(p.c,{});const c=[],h=i?o.ranking.communities.length:3;for(let n=0;n(0,An.jsx)(p.c,{style:[s.expanded?{flexDirection:"row",flexWrap:"wrap",marginBottom:16}:{flexDirection:"column",flex:1}],children:e.map(((e,n)=>{const r=3*t+n;let i={paddingBottom:16,paddingTop:16};return r!==h-1&&(i.borderBottomColor=u.y.GREY_LIGHT,i.borderBottomWidth=1),s.expanded&&(i={borderRightColor:2!==n&&r!==o.ranking.communities.length-1?u.y.GREY_LIGHT:u.y.WHITE,borderRightWidth:1}),(0,An.jsxs)(p.c,{style:[{maxWidth:s.expanded?"33.33%":void 0,flex:1,flexDirection:"row"},i],children:[(0,An.jsx)(un.c,{style:[pr.h3,fr.blue_dark,{marginRight:12,marginLeft:12,alignSelf:"center"}],children:r+1}),(0,An.jsxs)(p.c,{style:[{maxWidth:"90%"},s.expanded?{justifyContent:"space-around"}:{}],children:[(0,An.jsx)(un.c,{style:[pr.body1,fr.black,tl.out_top_xs,tl.out_bottom_xs],children:(0,hn._)(e.project.name)}),(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center",marginTop:8,marginBottom:8},children:[(0,An.jsx)(Rn,{bgColor:u.y.BLUE_LIGHT,color:u.y.BLUE_DARK,size:30,source:e.organization.picture,style:[tl.out_right_s]}),(0,An.jsx)(un.c,{style:[pr.h6,fr.black],children:(0,hn._)(e.organization.name)})]}),(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center"},children:[(0,An.jsx)(un.c,{style:[pr.body2,fr.grey2],children:(0,hn._)(vu.communityRankingEarned(e.earned,l))}),(0,An.jsx)(un.c,{style:[tl.out_left_xs,tl.out_right_xs,pr.body2,fr.grey2],children:"\u2022"}),(0,An.jsx)(un.c,{style:[pr.body2,fr.grey2],children:(0,hn._)(vu.communityRankingMembers(e.members))})]})]})]},r)}))},t)))}),o.ranking.communities.length>3&&(0,An.jsx)(xl,{textColor:u.y.BLUE_DARK,onPress:()=>a(!i),style:[{borderRadius:24,borderWidth:1,borderColor:u.y.GREY1,paddingLeft:12,paddingRight:12,marginTop:16},s.expanded?{alignSelf:"flex-start"}:{}],fontSize:16,side:(0,An.jsx)(le.c,{style:{height:16,width:16,marginLeft:6},source:n(i?1752:4692)}),fontWeight:"700",color:u.y.WHITE,children:(0,hn._)(i?vu.activitySeeLess:vu.activitySeeMore)})]})},Nu=e=>{var t;let{data:n}=e;const r=d.useContext(yn.S);return(0,An.jsxs)(p.c,{children:[(0,An.jsx)(un.c,{style:[pr.h2,tl.out_bottom_m,tl.out_top_m],children:(0,hn._)(vu.rankingTitle)}),(0,An.jsxs)(p.c,{style:[r.expanded?{justifyContent:"space-between",alignItems:"flex-start",flexDirection:"row"}:{flexDirection:"column"}],children:[(0,An.jsx)(Ou,{data:n}),(0,An.jsx)(Lu,{data:n}),(0,An.jsx)(Du,{data:n})]}),(null===(t=n.ranking.communities)||void 0===t?void 0:t.length)>0&&(0,An.jsx)(Mu,{data:n})]})},Uu=e=>{var t,n;const r=d.useContext(yn.S),[o,i]=d.useState(void 0);return d.useEffect((()=>{let e=!0;return s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:dashboard"}).execute().then((t=>{e&&i(t)})),()=>{e=!1}}),[]),"undefined"===typeof o?(0,An.jsx)(p.c,{}):(0,An.jsxs)(p.c,{style:bn.align_item_center,children:[(0,An.jsx)(bu,{picture:null===(t=o.company)||void 0===t?void 0:t.picture,startDate:null===(n=o.company)||void 0===n?void 0:n.startDate,date:Date.now(),showUpdateText:e.showUpdateText}),(0,An.jsxs)(p.c,{style:[bn.horizontal,bn.align_item_center,{justifyContent:"center",borderColor:u.y.GREY1,borderWidth:1,borderRadius:60},r.expanded?{width:"fit-content",paddingLeft:8,paddingRight:8,paddingTop:4,paddingBottom:4}:{width:"100%",paddingLeft:6,paddingRight:6}],children:[(0,An.jsx)(xl,{onPress:e.goToUser,children:(0,hn._)(Uc),textColor:u.y.BLUE_DARK,fontWeight:"600",style:[{shadowOpacity:0},r.expanded?{width:180,padding:8,height:41,marginRight:8}:{flex:1,padding:6}]}),(0,An.jsx)(p.c,{style:[{backgroundColor:u.y.BLUE_DARK,borderRadius:49,borderWidth:1,borderColor:u.y.BLUE_DARK,padding:8},r.expanded?{width:180}:{flex:1}],children:(0,An.jsx)(un.c,{style:[pr.h5,fr.white,{textAlign:"center"}],children:(0,hn._)(Fc)})})]}),(0,An.jsxs)(p.c,{style:[{width:"100%"},{maxWidth:1050}],children:[(0,An.jsx)(Tu,{data:o}),(0,An.jsx)(Eu,{data:o}),(0,An.jsx)(Nu,{data:o})]})]})},Fu=b.c.create({border:{borderWidth:1,borderRadius:16,borderColor:u.y.GREY1,padding:24}}),Hu=b.c.create({LoadBarMain:{borderRadius:13,marginTop:5},LoadBarChild:{height:10,borderRadius:10}}),Gu=e=>{let t=u.y.PURPLE,n=u.y.GREY1,r="";return r=e.ratio<0?"0%":e.ratio>1?"100%":100*e.ratio+"%",void 0!==e.color&&(t=e.color),void 0!==e.backgroundColor&&(n=e.backgroundColor),(0,An.jsx)(p.c,{style:[Hu.LoadBarMain,{backgroundColor:n}],children:(0,An.jsx)(p.c,{style:[Hu.LoadBarChild,{backgroundColor:t,width:r}]})})};var zu=Math.PI,Vu=2*zu,Wu=1e-6,Qu=Vu-Wu;function Yu(){this._x0=this._y0=this._x1=this._y1=null,this._=""}function Ku(){return new Yu}Yu.prototype=Ku.prototype={constructor:Yu,moveTo:function(e,t){this._+="M"+(this._x0=this._x1=+e)+","+(this._y0=this._y1=+t)},closePath:function(){null!==this._x1&&(this._x1=this._x0,this._y1=this._y0,this._+="Z")},lineTo:function(e,t){this._+="L"+(this._x1=+e)+","+(this._y1=+t)},quadraticCurveTo:function(e,t,n,r){this._+="Q"+ +e+","+ +t+","+(this._x1=+n)+","+(this._y1=+r)},bezierCurveTo:function(e,t,n,r,o,i){this._+="C"+ +e+","+ +t+","+ +n+","+ +r+","+(this._x1=+o)+","+(this._y1=+i)},arcTo:function(e,t,n,r,o){e=+e,t=+t,n=+n,r=+r,o=+o;var i=this._x1,a=this._y1,s=n-e,l=r-t,c=i-e,u=a-t,d=c*c+u*u;if(o<0)throw new Error("negative radius: "+o);if(null===this._x1)this._+="M"+(this._x1=e)+","+(this._y1=t);else if(d>Wu)if(Math.abs(u*s-l*c)>Wu&&o){var h=n-i,p=r-a,f=s*s+l*l,g=h*h+p*p,m=Math.sqrt(f),y=Math.sqrt(d),v=o*Math.tan((zu-Math.acos((f+d-g)/(2*m*y)))/2),b=v/y,A=v/m;Math.abs(b-1)>Wu&&(this._+="L"+(e+b*c)+","+(t+b*u)),this._+="A"+o+","+o+",0,0,"+ +(u*h>c*p)+","+(this._x1=e+A*s)+","+(this._y1=t+A*l)}else this._+="L"+(this._x1=e)+","+(this._y1=t);else;},arc:function(e,t,n,r,o,i){e=+e,t=+t,i=!!i;var a=(n=+n)*Math.cos(r),s=n*Math.sin(r),l=e+a,c=t+s,u=1^i,d=i?r-o:o-r;if(n<0)throw new Error("negative radius: "+n);null===this._x1?this._+="M"+l+","+c:(Math.abs(this._x1-l)>Wu||Math.abs(this._y1-c)>Wu)&&(this._+="L"+l+","+c),n&&(d<0&&(d=d%Vu+Vu),d>Qu?this._+="A"+n+","+n+",0,1,"+u+","+(e-a)+","+(t-s)+"A"+n+","+n+",0,1,"+u+","+(this._x1=l)+","+(this._y1=c):d>Wu&&(this._+="A"+n+","+n+",0,"+ +(d>=zu)+","+u+","+(this._x1=e+n*Math.cos(o))+","+(this._y1=t+n*Math.sin(o))))},rect:function(e,t,n,r){this._+="M"+(this._x0=this._x1=+e)+","+(this._y0=this._y1=+t)+"h"+ +n+"v"+ +r+"h"+-n+"Z"},toString:function(){return this._}};const qu=Ku;function Xu(e){return function(){return e}}function Ju(e){this._context=e}function Zu(e){return new Ju(e)}function $u(e){return e[0]}function ed(e){return e[1]}function td(){var e=$u,t=ed,n=Xu(!0),r=null,o=Zu,i=null;function a(a){var s,l,c,u=a.length,d=!1;for(null==r&&(i=o(c=qu())),s=0;s<=u;++s)!(s=u;--d)s.point(m[d],y[d]);s.lineEnd(),s.areaEnd()}g&&(m[c]=+e(h,c,l),y[c]=+n(h,c,l),s.point(t?+t(h,c,l):m[c],r?+r(h,c,l):y[c]))}if(p)return s=null,p+""||null}function c(){return td().defined(o).curve(a).context(i)}return l.x=function(n){return arguments.length?(e="function"===typeof n?n:Xu(+n),t=null,l):e},l.x0=function(t){return arguments.length?(e="function"===typeof t?t:Xu(+t),l):e},l.x1=function(e){return arguments.length?(t=null==e?null:"function"===typeof e?e:Xu(+e),l):t},l.y=function(e){return arguments.length?(n="function"===typeof e?e:Xu(+e),r=null,l):n},l.y0=function(e){return arguments.length?(n="function"===typeof e?e:Xu(+e),l):n},l.y1=function(e){return arguments.length?(r=null==e?null:"function"===typeof e?e:Xu(+e),l):r},l.lineX0=l.lineY0=function(){return c().x(e).y(n)},l.lineY1=function(){return c().x(e).y(r)},l.lineX1=function(){return c().x(t).y(n)},l.defined=function(e){return arguments.length?(o="function"===typeof e?e:Xu(!!e),l):o},l.curve=function(e){return arguments.length?(a=e,null!=i&&(s=a(i)),l):a},l.context=function(e){return arguments.length?(null==e?i=s=null:s=a(i=e),l):i},l}Ju.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t)}}};var rd=n(9840),od=n.n(rd);function id(e,t){return et?1:e>=t?0:NaN}var ad=function(e){var t;return 1===e.length&&(t=e,e=function(e,n){return id(t(e),n)}),{left:function(t,n,r,o){for(null==r&&(r=0),null==o&&(o=t.length);r>>1;e(t[i],n)<0?r=i+1:o=i}return r},right:function(t,n,r,o){for(null==r&&(r=0),null==o&&(o=t.length);r>>1;e(t[i],n)>0?o=i:r=i+1}return r}}}(id),sd=ad.right;ad.left;const ld=sd;function cd(e,t){var n,r,o,i=e.length,a=-1;if(null==t){for(;++a=n)for(r=o=n;++an&&(r=n),o=n)for(r=o=n;++an&&(r=n),o0)return[e];if((r=t0)for(e=Math.ceil(e/a),t=Math.floor(t/a),i=new Array(o=Math.ceil(t-e+1));++s=0?(i>=dd?10:i>=hd?5:i>=pd?2:1)*Math.pow(10,o):-Math.pow(10,-o)/(i>=dd?10:i>=hd?5:i>=pd?2:1)}function md(e){for(var t,n,r,o=e.length,i=-1,a=0;++i=0;)for(t=(r=e[o]).length;--t>=0;)n[--a]=r[t];return n}var yd="$";function vd(){}function bd(e,t){var n=new vd;if(e instanceof vd)e.each((function(e,t){n.set(t,e)}));else if(Array.isArray(e)){var r,o=-1,i=e.length;if(null==t)for(;++o=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function Fd(e){if(!(t=Ud.exec(e)))throw new Error("invalid format: "+e);var t;return new Hd({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}function Hd(e){this.fill=void 0===e.fill?" ":e.fill+"",this.align=void 0===e.align?">":e.align+"",this.sign=void 0===e.sign?"-":e.sign+"",this.symbol=void 0===e.symbol?"":e.symbol+"",this.zero=!!e.zero,this.width=void 0===e.width?void 0:+e.width,this.comma=!!e.comma,this.precision=void 0===e.precision?void 0:+e.precision,this.trim=!!e.trim,this.type=void 0===e.type?"":e.type+""}function Gd(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]}function zd(e){return(e=Gd(Math.abs(e)))?e[1]:NaN}function Vd(e,t){var n=Gd(e,t);if(!n)return e+"";var r=n[0],o=n[1];return o<0?"0."+new Array(-o).join("0")+r:r.length>o+1?r.slice(0,o+1)+"."+r.slice(o+1):r+new Array(o-r.length+2).join("0")}Fd.prototype=Hd.prototype,Hd.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};const Wd={"%":function(e,t){return(100*e).toFixed(t)},b:function(e){return Math.round(e).toString(2)},c:function(e){return e+""},d:function(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)},e:function(e,t){return e.toExponential(t)},f:function(e,t){return e.toFixed(t)},g:function(e,t){return e.toPrecision(t)},o:function(e){return Math.round(e).toString(8)},p:function(e,t){return Vd(100*e,t)},r:Vd,s:function(e,t){var n=Gd(e,t);if(!n)return e+"";var r=n[0],o=n[1],i=o-(Nd=3*Math.max(-8,Math.min(8,Math.floor(o/3))))+1,a=r.length;return i===a?r:i>a?r+new Array(i-a+1).join("0"):i>0?r.slice(0,i)+"."+r.slice(i):"0."+new Array(1-i).join("0")+Gd(e,Math.max(0,t+i-1))[0]},X:function(e){return Math.round(e).toString(16).toUpperCase()},x:function(e){return Math.round(e).toString(16)}};function Qd(e){return e}var Yd,Kd,qd,Xd=Array.prototype.map,Jd=["y","z","a","f","p","n","\xb5","m","","k","M","G","T","P","E","Z","Y"];function Zd(e){var t,n,r=void 0===e.grouping||void 0===e.thousands?Qd:(t=Xd.call(e.grouping,Number),n=e.thousands+"",function(e,r){for(var o=e.length,i=[],a=0,s=t[0],l=0;o>0&&s>0&&(l+s+1>r&&(s=Math.max(1,r-l)),i.push(e.substring(o-=s,o+s)),!((l+=s+1)>r));)s=t[a=(a+1)%t.length];return i.reverse().join(n)}),o=void 0===e.currency?"":e.currency[0]+"",i=void 0===e.currency?"":e.currency[1]+"",a=void 0===e.decimal?".":e.decimal+"",s=void 0===e.numerals?Qd:function(e){return function(t){return t.replace(/[0-9]/g,(function(t){return e[+t]}))}}(Xd.call(e.numerals,String)),l=void 0===e.percent?"%":e.percent+"",c=void 0===e.minus?"-":e.minus+"",u=void 0===e.nan?"NaN":e.nan+"";function d(e){var t=(e=Fd(e)).fill,n=e.align,d=e.sign,h=e.symbol,p=e.zero,f=e.width,g=e.comma,m=e.precision,y=e.trim,v=e.type;"n"===v?(g=!0,v="g"):Wd[v]||(void 0===m&&(m=12),y=!0,v="g"),(p||"0"===t&&"="===n)&&(p=!0,t="0",n="=");var b="$"===h?o:"#"===h&&/[boxX]/.test(v)?"0"+v.toLowerCase():"",A="$"===h?i:/[%p]/.test(v)?l:"",x=Wd[v],S=/[defgprs%]/.test(v);function w(e){var o,i,l,h=b,w=A;if("c"===v)w=x(e)+w,e="";else{var C=(e=+e)<0||1/e<0;if(e=isNaN(e)?u:x(Math.abs(e),m),y&&(e=function(e){e:for(var t,n=e.length,r=1,o=-1;r0&&(o=0)}return o>0?e.slice(0,o)+e.slice(t+1):e}(e)),C&&0===+e&&"+"!==d&&(C=!1),h=(C?"("===d?d:c:"-"===d||"("===d?"":d)+h,w=("s"===v?Jd[8+Nd/3]:"")+w+(C&&"("===d?")":""),S)for(o=-1,i=e.length;++o(l=e.charCodeAt(o))||l>57){w=(46===l?a+e.slice(o+1):e.slice(o))+w,e=e.slice(0,o);break}}g&&!p&&(e=r(e,1/0));var _=h.length+e.length+w.length,E=_>1)+h+e+w+E.slice(_);break;default:e=E+h+e+w}return s(e)}return m=void 0===m?6:/[gprs]/.test(v)?Math.max(1,Math.min(21,m)):Math.max(0,Math.min(20,m)),w.toString=function(){return e+""},w}return{format:d,formatPrefix:function(e,t){var n=d(((e=Fd(e)).type="f",e)),r=3*Math.max(-8,Math.min(8,Math.floor(zd(t)/3))),o=Math.pow(10,-r),i=Jd[8+r/3];return function(e){return n(o*e)+i}}}}function $d(e,t,n){var r,o=e[0],i=e[e.length-1],a=function(e,t,n){var r=Math.abs(t-e)/Math.max(0,n),o=Math.pow(10,Math.floor(Math.log(r)/Math.LN10)),i=r/o;return i>=dd?o*=10:i>=hd?o*=5:i>=pd&&(o*=2),t2?Md:Dd,r=o=null,u}function u(t){return(r||(r=n(i,a,l?function(e){return function(t,n){var r=e(t=+t,n=+n);return function(e){return e<=t?0:e>=n?1:r(e)}}}(e):e,s)))(+t)}return u.invert=function(e){return(o||(o=n(a,i,Ld,l?function(e){return function(t,n){var r=e(t=+t,n=+n);return function(e){return e<=0?t:e>=1?n:r(e)}}}(t):t)))(+e)},u.domain=function(e){return arguments.length?(i=_d.call(e,Pd),c()):i.slice()},u.range=function(e){return arguments.length?(a=Ed.call(e),c()):a.slice()},u.rangeRound=function(e){return a=Ed.call(e),s=jd.c,c()},u.clamp=function(e){return arguments.length?(l=!!e,c()):l},u.interpolate=function(e){return arguments.length?(s=e,c()):s},c()}(Ld,Td.c);return e.copy=function(){return t=e,eh().domain(t.domain()).range(t.range()).interpolate(t.interpolate()).clamp(t.clamp());var t},function(e){var t=e.domain;return e.ticks=function(e){var n=t();return fd(n[0],n[n.length-1],null==e?10:e)},e.tickFormat=function(e,n){return $d(t(),e,n)},e.nice=function(n){null==n&&(n=10);var r,o=t(),i=0,a=o.length-1,s=o[i],l=o[a];return l0?r=gd(s=Math.floor(s/r)*r,l=Math.ceil(l/r)*r,n):r<0&&(r=gd(s=Math.ceil(s*r)/r,l=Math.floor(l*r)/r,n)),r>0?(o[i]=Math.floor(s/r)*r,o[a]=Math.ceil(l/r)*r,t(o)):r<0&&(o[i]=Math.ceil(s*r)/r,o[a]=Math.floor(l*r)/r,t(o)),e},e}(e)}Yd=Zd({decimal:".",thousands:",",grouping:[3],currency:["$",""],minus:"-"}),Kd=Yd.format,qd=Yd.formatPrefix;function th(e){return e.match(/.{6}/g).map((function(e){return"#"+e}))}th("1f77b4ff7f0e2ca02cd627289467bd8c564be377c27f7f7fbcbd2217becf"),th("393b795254a36b6ecf9c9ede6379398ca252b5cf6bcedb9c8c6d31bd9e39e7ba52e7cb94843c39ad494ad6616be7969c7b4173a55194ce6dbdde9ed6"),th("3182bd6baed69ecae1c6dbefe6550dfd8d3cfdae6bfdd0a231a35474c476a1d99bc7e9c0756bb19e9ac8bcbddcdadaeb636363969696bdbdbdd9d9d9"),th("1f77b4aec7e8ff7f0effbb782ca02c98df8ad62728ff98969467bdc5b0d58c564bc49c94e377c2f7b6d27f7f7fc7c7c7bcbd22dbdb8d17becf9edae5");var nh=n(8816),rh=n(3548);(0,rh.o)((0,nh.c)(300,.5,0),(0,nh.c)(-240,.5,1));(0,rh.o)((0,nh.c)(-100,.75,.35),(0,nh.c)(80,1.5,.8)),(0,rh.o)((0,nh.c)(260,.75,.35),(0,nh.c)(80,1.5,.8)),(0,nh.c)();function oh(e){var t=e.length;return function(n){return e[Math.max(0,Math.min(t-1,Math.floor(n*t)))]}}oh(th("44015444025645045745055946075a46085c460a5d460b5e470d60470e6147106347116447136548146748166848176948186a481a6c481b6d481c6e481d6f481f70482071482173482374482475482576482677482878482979472a7a472c7a472d7b472e7c472f7d46307e46327e46337f463480453581453781453882443983443a83443b84433d84433e85423f854240864241864142874144874045884046883f47883f48893e49893e4a893e4c8a3d4d8a3d4e8a3c4f8a3c508b3b518b3b528b3a538b3a548c39558c39568c38588c38598c375a8c375b8d365c8d365d8d355e8d355f8d34608d34618d33628d33638d32648e32658e31668e31678e31688e30698e306a8e2f6b8e2f6c8e2e6d8e2e6e8e2e6f8e2d708e2d718e2c718e2c728e2c738e2b748e2b758e2a768e2a778e2a788e29798e297a8e297b8e287c8e287d8e277e8e277f8e27808e26818e26828e26828e25838e25848e25858e24868e24878e23888e23898e238a8d228b8d228c8d228d8d218e8d218f8d21908d21918c20928c20928c20938c1f948c1f958b1f968b1f978b1f988b1f998a1f9a8a1e9b8a1e9c891e9d891f9e891f9f881fa0881fa1881fa1871fa28720a38620a48621a58521a68522a78522a88423a98324aa8325ab8225ac8226ad8127ad8128ae8029af7f2ab07f2cb17e2db27d2eb37c2fb47c31b57b32b67a34b67935b77937b87838b9773aba763bbb753dbc743fbc7340bd7242be7144bf7046c06f48c16e4ac16d4cc26c4ec36b50c46a52c56954c56856c66758c7655ac8645cc8635ec96260ca6063cb5f65cb5e67cc5c69cd5b6ccd5a6ece5870cf5773d05675d05477d1537ad1517cd2507fd34e81d34d84d44b86d54989d5488bd6468ed64590d74393d74195d84098d83e9bd93c9dd93ba0da39a2da37a5db36a8db34aadc32addc30b0dd2fb2dd2db5de2bb8de29bade28bddf26c0df25c2df23c5e021c8e020cae11fcde11dd0e11cd2e21bd5e21ad8e219dae319dde318dfe318e2e418e5e419e7e419eae51aece51befe51cf1e51df4e61ef6e620f8e621fbe723fde725"));oh(th("00000401000501010601010802010902020b02020d03030f03031204041405041606051806051a07061c08071e0907200a08220b09240c09260d0a290e0b2b100b2d110c2f120d31130d34140e36150e38160f3b180f3d19103f1a10421c10441d11471e114920114b21114e22115024125325125527125829115a2a115c2c115f2d11612f116331116533106734106936106b38106c390f6e3b0f703d0f713f0f72400f74420f75440f764510774710784910784a10794c117a4e117b4f127b51127c52137c54137d56147d57157e59157e5a167e5c167f5d177f5f187f601880621980641a80651a80671b80681c816a1c816b1d816d1d816e1e81701f81721f817320817521817621817822817922827b23827c23827e24828025828125818326818426818627818827818928818b29818c29818e2a81902a81912b81932b80942c80962c80982d80992d809b2e7f9c2e7f9e2f7fa02f7fa1307ea3307ea5317ea6317da8327daa337dab337cad347cae347bb0357bb2357bb3367ab5367ab73779b83779ba3878bc3978bd3977bf3a77c03a76c23b75c43c75c53c74c73d73c83e73ca3e72cc3f71cd4071cf4070d0416fd2426fd3436ed5446dd6456cd8456cd9466bdb476adc4869de4968df4a68e04c67e24d66e34e65e44f64e55064e75263e85362e95462ea5661eb5760ec5860ed5a5fee5b5eef5d5ef05f5ef1605df2625df2645cf3655cf4675cf4695cf56b5cf66c5cf66e5cf7705cf7725cf8745cf8765cf9785df9795df97b5dfa7d5efa7f5efa815ffb835ffb8560fb8761fc8961fc8a62fc8c63fc8e64fc9065fd9266fd9467fd9668fd9869fd9a6afd9b6bfe9d6cfe9f6dfea16efea36ffea571fea772fea973feaa74feac76feae77feb078feb27afeb47bfeb67cfeb77efeb97ffebb81febd82febf84fec185fec287fec488fec68afec88cfeca8dfecc8ffecd90fecf92fed194fed395fed597fed799fed89afdda9cfddc9efddea0fde0a1fde2a3fde3a5fde5a7fde7a9fde9aafdebacfcecaefceeb0fcf0b2fcf2b4fcf4b6fcf6b8fcf7b9fcf9bbfcfbbdfcfdbf")),oh(th("00000401000501010601010802010a02020c02020e03021004031204031405041706041907051b08051d09061f0a07220b07240c08260d08290e092b10092d110a30120a32140b34150b37160b39180c3c190c3e1b0c411c0c431e0c451f0c48210c4a230c4c240c4f260c51280b53290b552b0b572d0b592f0a5b310a5c320a5e340a5f3609613809623909633b09643d09653e0966400a67420a68440a68450a69470b6a490b6a4a0c6b4c0c6b4d0d6c4f0d6c510e6c520e6d540f6d550f6d57106e59106e5a116e5c126e5d126e5f136e61136e62146e64156e65156e67166e69166e6a176e6c186e6d186e6f196e71196e721a6e741a6e751b6e771c6d781c6d7a1d6d7c1d6d7d1e6d7f1e6c801f6c82206c84206b85216b87216b88226a8a226a8c23698d23698f24699025689225689326679526679727669827669a28659b29649d29649f2a63a02a63a22b62a32c61a52c60a62d60a82e5fa92e5eab2f5ead305dae305cb0315bb1325ab3325ab43359b63458b73557b93556ba3655bc3754bd3853bf3952c03a51c13a50c33b4fc43c4ec63d4dc73e4cc83f4bca404acb4149cc4248ce4347cf4446d04545d24644d34743d44842d54a41d74b3fd84c3ed94d3dda4e3cdb503bdd513ade5238df5337e05536e15635e25734e35933e45a31e55c30e65d2fe75e2ee8602de9612bea632aeb6429eb6628ec6726ed6925ee6a24ef6c23ef6e21f06f20f1711ff1731df2741cf3761bf37819f47918f57b17f57d15f67e14f68013f78212f78410f8850ff8870ef8890cf98b0bf98c0af98e09fa9008fa9207fa9407fb9606fb9706fb9906fb9b06fb9d07fc9f07fca108fca309fca50afca60cfca80dfcaa0ffcac11fcae12fcb014fcb216fcb418fbb61afbb81dfbba1ffbbc21fbbe23fac026fac228fac42afac62df9c72ff9c932f9cb35f8cd37f8cf3af7d13df7d340f6d543f6d746f5d949f5db4cf4dd4ff4df53f4e156f3e35af3e55df2e661f2e865f2ea69f1ec6df1ed71f1ef75f1f179f2f27df2f482f3f586f3f68af4f88ef5f992f6fa96f8fb9af9fc9dfafda1fcffa4")),oh(th("0d088710078813078916078a19068c1b068d1d068e20068f2206902406912605912805922a05932c05942e05952f059631059733059735049837049938049a3a049a3c049b3e049c3f049c41049d43039e44039e46039f48039f4903a04b03a14c02a14e02a25002a25102a35302a35502a45601a45801a45901a55b01a55c01a65e01a66001a66100a76300a76400a76600a76700a86900a86a00a86c00a86e00a86f00a87100a87201a87401a87501a87701a87801a87a02a87b02a87d03a87e03a88004a88104a78305a78405a78606a68707a68808a68a09a58b0aa58d0ba58e0ca48f0da4910ea3920fa39410a29511a19613a19814a099159f9a169f9c179e9d189d9e199da01a9ca11b9ba21d9aa31e9aa51f99a62098a72197a82296aa2395ab2494ac2694ad2793ae2892b02991b12a90b22b8fb32c8eb42e8db52f8cb6308bb7318ab83289ba3388bb3488bc3587bd3786be3885bf3984c03a83c13b82c23c81c33d80c43e7fc5407ec6417dc7427cc8437bc9447aca457acb4679cc4778cc4977cd4a76ce4b75cf4c74d04d73d14e72d24f71d35171d45270d5536fd5546ed6556dd7566cd8576bd9586ada5a6ada5b69db5c68dc5d67dd5e66de5f65de6164df6263e06363e16462e26561e26660e3685fe4695ee56a5de56b5de66c5ce76e5be76f5ae87059e97158e97257ea7457eb7556eb7655ec7754ed7953ed7a52ee7b51ef7c51ef7e50f07f4ff0804ef1814df1834cf2844bf3854bf3874af48849f48948f58b47f58c46f68d45f68f44f79044f79143f79342f89441f89540f9973ff9983ef99a3efa9b3dfa9c3cfa9e3bfb9f3afba139fba238fca338fca537fca636fca835fca934fdab33fdac33fdae32fdaf31fdb130fdb22ffdb42ffdb52efeb72dfeb82cfeba2cfebb2bfebd2afebe2afec029fdc229fdc328fdc527fdc627fdc827fdca26fdcb26fccd25fcce25fcd025fcd225fbd324fbd524fbd724fad824fada24f9dc24f9dd25f8df25f8e125f7e225f7e425f6e626f6e826f5e926f5eb27f4ed27f3ee27f3f027f2f227f1f426f1f525f0f724f0f921"));var ih=n(3124);function ah(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function sh(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function lh(){return lh=Object.assign||function(e){for(var t=1;t{e||(this._clearInteraction(),this.handle=gt.c.createInteractionHandle(),e=t);const n=(t-e)/this.props.animationDuration;if(n>1)return this.component.setNativeProps({d:this.newD}),void this._clearInteraction();const r=this.interpolator(n);this.component.setNativeProps({d:r}),this.setState(this.state,(()=>{this._animate(e)}))}))}_clearInteraction(){this.handle&&(gt.c.clearInteractionHandle(this.handle),this.handle=null)}render(){return d.createElement(wn.Path,lh({ref:e=>this.component=e},this.props,{d:this.props.animate?this.state.d:this.props.d}))}}ch.propTypes=function(e){for(var t=1;tnull};const uh=ch;function dh(){return dh=Object.assign||function(e){for(var t=1;t({y:n({item:e,index:r}),x:t({item:e,index:r})}))),C=w.map((e=>e.y)),_=w.map((e=>e.x)),E=cd([...C,m,g]),R=cd([..._]),{yMin:k=E[0],yMax:I=E[1],xMin:T=R[0],xMax:O=R[1]}=this.props,j=r().domain([k,I]).range([S-u,c]).clamp(v),P=o().domain([T,O]).range([h,x-f]).clamp(y),B=this.createPaths({data:w,x:P,y:j}),L=j.ticks(l),D=function(e){for(var t=1;tthis._onLayout(e)},S>0&&x>0&&d.createElement(wn.default,{style:{height:S,width:x}},d.Children.map(A,(e=>e&&e.props.belowChart?d.cloneElement(e,D):null)),d.createElement(uh,dh({fill:"none"},b,{d:B.path,animate:a,animationDuration:s})),d.Children.map(A,(e=>e&&!e.props.belowChart?d.cloneElement(e,D):null)))))}}fh.propTypes={data:od().oneOfType([od().arrayOf(od().object),od().arrayOf(od().number),od().arrayOf(od().array)]).isRequired,svg:od().object,style:od().any,animate:od().bool,animationDuration:od().number,curve:od().func,contentInset:od().shape({top:od().number,left:od().number,right:od().number,bottom:od().number}),numberOfTicks:od().number,gridMin:od().number,gridMax:od().number,yMin:od().any,yMax:od().any,xMin:od().any,xMax:od().any,clampX:od().bool,clampY:od().bool,xScale:od().func,yScale:od().func,xAccessor:od().func,yAccessor:od().func},fh.defaultProps={svg:{},width:100,height:100,curve:Zu,contentInset:{},numberOfTicks:10,xScale:eh,yScale:eh,xAccessor:e=>{let{index:t}=e;return t},yAccessor:e=>{let{item:t}=e;return t}};const gh=fh;function mh(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function yh(e){for(var t=1;tn(e.x))).y0(r(i)).y1((e=>r(e.y))).defined((e=>"number"===typeof e.y)).curve(o)(t);return{path:a,area:a,line:td().x((e=>n(e.x))).y((e=>r(e.y))).defined((e=>"number"===typeof e.y)).curve(o)(t)}}}bh.propTypes=yh({},gh.propTypes,{start:od().number}),bh.defaultProps=yh({},gh.defaultProps,{start:0});function Ah(e){for(var t=e.length,n=new Array(t);--t>=0;)n[t]=t;return n}function xh(e,t){if((o=e.length)>1)for(var n,r,o,i=1,a=e[t[0]],s=a.length;i2&&void 0!==arguments[2]?arguments[2]:Ah,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:xh;return md(md(Ch().keys(t).order(n).offset(r)(e)))}_onLayout(e){const{nativeEvent:{layout:{height:t,width:n}}}=e;this.setState({height:t,width:n})}render(){const{data:e,keys:t,colors:n,animate:r,animationDuration:o,style:i,curve:a,numberOfTicks:s,contentInset:{top:l=0,bottom:c=0,left:u=0,right:h=0},gridMin:f,gridMax:g,children:m,offset:y,order:v,svgs:b,xAccessor:A,xScale:x,clampY:S,clampX:w}=this.props,{height:C,width:_}=this.state;if(0===e.length)return d.createElement(p.c,{style:i});const E=Ch().keys(t).order(v).offset(y)(e),R=md(md(E)),k=e.map(((e,t)=>A({item:e,index:t}))),I=cd([...R,f,g]),T=cd(k),{yMin:O=I[0],yMax:j=I[1],xMin:P=T[0],xMax:B=T[1]}=this.props,L=eh().domain([O,j]).range([C-c,l]).clamp(S),D=x().domain([P,B]).range([u,_-h]).clamp(w),M=L.ticks(s),N=E.map(((r,o)=>{const i=nd().x(((e,t)=>D(A({item:e.data,index:t})))).y0((e=>L(e[0]))).y1((e=>L(e[1]))).curve(a)(e.map(((e,t)=>r[t])));return{path:i,key:t[o],color:n[o]}})),U={x:D,y:L,width:_,height:C,ticks:M,areas:N};return d.createElement(p.c,{style:i},d.createElement(p.c,{style:{flex:1},onLayout:e=>this._onLayout(e)},C>0&&_>0&&d.createElement(wn.Svg,{style:{height:C,width:_}},d.Children.map(m,(e=>e&&e.props.belowChart?d.cloneElement(e,U):null)),N.map(((e,t)=>d.createElement(uh,_h({key:e.key,fill:e.color},b[t],{animate:r,animationDuration:o,d:e.path})))),d.Children.map(m,(e=>e&&!e.props.belowChart?d.cloneElement(e,U):null)))))}}Eh.propTypes={data:od().arrayOf(od().object).isRequired,keys:od().arrayOf(od().string).isRequired,colors:od().arrayOf(od().string).isRequired,svgs:od().arrayOf(od().object),offset:od().func,order:od().func,style:od().any,animate:od().bool,animationDuration:od().number,contentInset:od().shape({top:od().number,left:od().number,right:od().number,bottom:od().number}),numberOfTicks:od().number,showGrid:od().bool,xScale:od().func,xAccessor:od().func,yMin:od().any,yMax:od().any,xMin:od().any,xMax:od().any,clampX:od().bool,clampY:od().bool},Eh.defaultProps={curve:Zu,offset:xh,order:Ah,svgs:[],strokeWidth:2,contentInset:{},numberOfTicks:10,showGrid:!0,xScale:eh,xAccessor:e=>{let{index:t}=e;return t}};function Rh(){return Rh=Object.assign||function(e){for(var t=1;to({item:e})));return n?r.map(((n,r)=>({bar:n,path:nd().y(((e,n)=>0===n?t(r):t(r)+t.bandwidth())).x0(e(0)).x1((t=>e(t))).defined((e=>"number"===typeof e))([i[r],i[r]])}))):r.map(((n,r)=>({bar:n,path:nd().y0(t(0)).y1((e=>t(e))).x(((t,n)=>0===n?e(r):e(r)+e.bandwidth())).defined((e=>"number"===typeof e))([i[r],i[r]])})))}calcExtent(){const{data:e,gridMin:t,gridMax:n,yAccessor:r}=this.props,o=cd([...e.map((e=>r({item:e}))),n,t]),{yMin:i=o[0],yMax:a=o[1]}=this.props;return[i,a]}calcIndexes(){const{data:e}=this.props;return e.map(((e,t)=>t))}render(){const{data:e,animate:t,animationDuration:n,style:r,numberOfTicks:o,svg:i,horizontal:a,children:s}=this.props,{height:l,width:c}=this.state;if(0===e.length)return d.createElement(p.c,{style:r});const u=this.calcExtent(),h=this.calcIndexes(),f=fd(u[0],u[1],o),g=a?u:h,m=a?h:u,y=this.calcXScale(g),v=this.calcYScale(m),b=a?v.bandwidth():y.bandwidth(),A=this.calcAreas(y,v).filter((e=>null!==e.bar&&void 0!==e.bar&&null!==e.path)),x={x:y,y:v,width:c,height:l,bandwidth:b,ticks:f,data:e};return d.createElement(p.c,{style:r},d.createElement(p.c,{style:{flex:1},onLayout:e=>this._onLayout(e)},l>0&&c>0&&d.createElement(wn.default,{style:{height:l,width:c}},d.Children.map(s,(e=>{if(e&&e.props.belowChart)return d.cloneElement(e,x)})),A.map(((e,r)=>{const{bar:{svg:o={}},path:a}=e;return d.createElement(uh,Rh({key:r},i,o,{d:a,animate:t,animationDuration:n}))})),d.Children.map(s,(e=>{if(e&&!e.props.belowChart)return d.cloneElement(e,x)})))))}}kh.propTypes={data:od().arrayOf(od().oneOfType([od().number,od().object])).isRequired,style:od().any,spacingInner:od().number,spacingOuter:od().number,animate:od().bool,animationDuration:od().number,contentInset:od().shape({top:od().number,left:od().number,right:od().number,bottom:od().number}),numberOfTicks:od().number,gridMin:od().number,gridMax:od().number,svg:od().object,yMin:od().any,yMax:od().any,clamp:od().bool},kh.defaultProps={spacingInner:.05,spacingOuter:.05,contentInset:{},numberOfTicks:10,svg:{},yAccessor:e=>{let{item:t}=e;return t}};const Ih=kh;function Th(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Oh(e){for(var t=1;t{const{svg:t={}}=e;return Oh({},e,{data:e.data.map((e=>"number"===typeof e?{value:e,svg:t}:Oh({},e,{svg:Oh({},t,{},e.svg),value:o({item:e})})))})})),a=[];if(n){const n=t.bandwidth()/r.length;i.forEach(((r,o)=>{r.data.forEach(((r,i)=>{a.push({bar:r,path:nd().y(((e,r)=>0===r?t(i)+n*o:t(i)+n+n*o)).x0(e(0)).x1((t=>e(t))).defined((e=>"number"===typeof e))([r.value,r.value])})}))}))}else{const n=e.bandwidth()/r.length;i.forEach(((r,o)=>{r.data.forEach(((r,i)=>{a.push({bar:r,path:nd().x(((t,r)=>0===r?e(i)+n*o:e(i)+n+n*o)).y0(t(0)).y1((e=>t(e))).defined((e=>"number"===typeof e))([r.value,r.value])})}))}))}return a}calcExtent(){const{data:e,yAccessor:t,gridMin:n,gridMax:r}=this.props,o=cd([...md(e.map((e=>e.data.map((e=>t({item:e})))))),r,n]),{yMin:i=o[0],yMax:a=o[1]}=this.props;return[i,a]}calcIndexes(){const{data:e}=this.props;return e[0].data.map(((e,t)=>t))}}Ph.propTypes=Oh({},Ih.propTypes,{data:od().arrayOf(od().shape({data:od().array.isRequired,svg:od().object})).isRequired});function Bh(){return Bh=Object.assign||function(e){for(var t=1;t2&&void 0!==arguments[2]?arguments[2]:Ah,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:xh;return md(md(Ch().keys(t).order(n).offset(r)(e)))}_onLayout(e){const{nativeEvent:{layout:{height:t,width:n}}}=e;this.setState({height:t,width:n})}calcXScale(e){const{data:t}=this.props,{horizontal:n,contentInset:{left:r=0,right:o=0},spacingInner:i,spacingOuter:a}=this.props,{width:s}=this.state;return n?eh().domain(e).range([r,s-o]):Id().domain(t.map(((e,t)=>t))).range([r,s-o]).paddingInner([i]).paddingOuter([a])}calcYScale(e){const{data:t}=this.props,{horizontal:n,contentInset:{top:r=0,bottom:o=0},spacingInner:i,spacingOuter:a}=this.props,{height:s}=this.state;return n?Id().domain(t.map(((e,t)=>t))).range([r,s-o]).paddingInner([i]).paddingOuter([a]):eh().domain(e).range([s-o,r])}calcAreas(e,t,n){const{horizontal:r,colors:o,keys:i}=this.props;return md(r?n.map(((n,r)=>n.map(((n,a)=>({path:nd().x0((t=>e(t[0]))).x1((t=>e(t[1]))).y(((e,n)=>0===n?t(a):t(a)+t.bandwidth())).defined((e=>!isNaN(e[0])&&!isNaN(e[1])))([n,n]),color:o[r],key:i[r]}))))):n.map(((n,r)=>n.map(((n,a)=>({path:nd().y0((e=>t(e[0]))).y1((e=>t(e[1]))).x(((t,n)=>0===n?e(a):e(a)+e.bandwidth())).defined((e=>!isNaN(e[0])&&!isNaN(e[1])))([n,n]),color:o[r],key:i[r]}))))))}calcExtent(e){const{gridMax:t,gridMin:n}=this.props;return cd([...e,n,t])}calcIndexes(e){return e.map(((e,t)=>t))}getSeries(){const{data:e,keys:t,offset:n,order:r,valueAccessor:o}=this.props;return Ch().keys(t).value(((e,t)=>o({item:e,key:t}))).order(r).offset(n)(e)}render(){const{data:e,animate:t,animationDuration:n,style:r,numberOfTicks:o,children:i,horizontal:a}=this.props,{height:s,width:l}=this.state;if(0===e.length)return d.createElement(p.c,{style:r});const c=this.getSeries(),u=md(md(c)),h=this.calcIndexes(u),f=this.calcExtent(u),g=fd(f[0],f[1],o),m=a?f:h,y=a?h:f,v=this.calcXScale(m),b=this.calcYScale(y),A=a?b.bandwidth():v.bandwidth(),x=this.calcAreas(v,b,c),S={x:v,y:b,width:l,height:s,ticks:g,data:e,bandwidth:A};return d.createElement(p.c,{style:r},d.createElement(p.c,{style:{flex:1},onLayout:e=>this._onLayout(e)},s>0&&l>0&&d.createElement(wn.default,{style:{height:s,width:l}},d.Children.map(i,(e=>e&&e.props.belowChart?d.cloneElement(e,S):null)),x.map(((r,o)=>{const i=o%e.length,a="".concat(i,"-").concat(r.key),{svg:s}=e[i][r.key];return d.createElement(uh,Bh({key:a,fill:r.color},s,{d:r.path,animate:t,animationDuration:n}))})),d.Children.map(i,(e=>e&&!e.props.belowChart?d.cloneElement(e,S):null)))))}}Lh.propTypes={data:od().arrayOf(od().object),keys:od().arrayOf(od().string).isRequired,colors:od().arrayOf(od().string).isRequired,offset:od().func,order:od().func,style:od().any,spacingInner:od().number,spacingOuter:od().number,animate:od().bool,animationDuration:od().number,contentInset:od().shape({top:od().number,left:od().number,right:od().number,bottom:od().number}),gridMin:od().number,gridMax:od().number,valueAccessor:od().func},Lh.defaultProps={spacingInner:.05,spacingOuter:.05,offset:xh,order:Ah,width:100,height:100,showZeroAxis:!0,contentInset:{},numberOfTicks:10,showGrid:!0,valueAccessor:e=>{let{item:t,key:n}=e;return t[n]}};function Dh(){return Dh=Object.assign||function(e){for(var t=1;t{const s=[];if(s.push({marker:"M",values:[e,t]}),i){const n=[e+o,t],r=[e,t+o];s.push({marker:"L",values:n}),s.push({marker:"C",values:[...n,e,t,...r]}),s.push({marker:"L",values:r})}else s.push({marker:"L",values:[e,t]});if(a){const t=[e,r-o],i=[e+o,r];s.push({marker:"L",values:t}),s.push({marker:"C",values:[...t,e,r,...i]}),s.push({marker:"L",values:i});const a=[n-o,r],l=[n,r-o];s.push({marker:"L",values:a}),s.push({marker:"C",values:[...a,n,r,...l]}),s.push({marker:"L",values:l})}else s.push({marker:"L",values:[e,r]}),s.push({marker:"L",values:[n,r]});if(i){const e=[n,t+o],r=[n-o,t];s.push({marker:"L",values:e}),s.push({marker:"C",values:[...e,n,t,...r]}),s.push({marker:"L",values:r})}else s.push({marker:"L",values:[n,t]});return s.push({marker:"Z",values:[]}),s})),Mh(this,"commandsToSvgPath",(e=>e.map((e=>"".concat(e.marker," ").concat(e.values.join(",")))).join(" ").trim()))}_onLayout(e){const{nativeEvent:{layout:{height:t,width:n}}}=e;this.setState({height:t,width:n})}calcXScale(e){const{horizontal:t,contentInset:{left:n=0,right:r=0},spacingInner:o,spacingOuter:i}=this.props,{width:a}=this.state;return t?eh().domain(e).range([n,a-r]):Id().domain(e).range([n,a-r]).paddingInner([o]).paddingOuter([i])}calcYScale(e){const{horizontal:t,contentInset:{top:n=0,bottom:r=0},spacingInner:o,spacingOuter:i}=this.props,{height:a}=this.state;return t?Id().domain(e).range([n,a-r]).paddingInner([o]).paddingOuter([i]):eh().domain(e).range([a-r,n])}calcAreas(e,t,n){const{horizontal:r,colors:o,keys:i,data:a,borderRadius:s,innerBarSpace:l}=this.props;let c,u;return r?(u=t.bandwidth()/a.length,c=n.map(((r,a)=>r.map(((r,s)=>r.map(((r,c)=>{const d=n.length>1?l/2:0;return{path:nd().x0((t=>e(t[0]))).x1((t=>e(t[1]))).y(((e,n)=>(0===n?t(c)+u*a+d:t(c)+u+u*a)-d)).defined((e=>!isNaN(e[0])&&!isNaN(e[1])))([r,r]),color:o[a][s],key:i[a][s]}}))))))):(u=e.bandwidth()/a.length,c=n.map(((r,a)=>r.map(((c,d)=>c.map(((c,h)=>{const p=n.length>1?l/2:0,f=e(h)+u*a+p,g=e(h)+u+u*a-p,m=t(c[1]),y=t(c[0]),v=y-m,b=2*s>v?v/2:s,A=d===r.length-1,x=0===d,S=this.coordinatesToPathCommands(f,m,g,y,b,A,x);return{path:this.commandsToSvgPath(S),color:o[a][d],key:i[a][d]}}))))))),md(c)}calcExtent(e){const{gridMax:t,gridMin:n}=this.props;return cd([...md(e),n,t])}calcIndexes(){const{data:e}=this.props;return e[0].data.map(((e,t)=>t))}getSeries(){const{data:e,keys:t,offset:n,order:r,valueAccessor:o}=this.props;return e.map(((e,i)=>Ch().keys(t[i]).value(((e,t)=>o({item:e,key:t}))).order(r).offset(n)(e.data)))}render(){const{data:e,animate:t,animationDuration:n,style:r,numberOfTicks:o,children:i,horizontal:a}=this.props,{height:s,width:l}=this.state;if(0===e.length)return d.createElement(p.c,{style:r});const c=this.getSeries(),u=md(md(c)),h=this.calcIndexes(u),f=this.calcExtent(u),g=fd(f[0],f[1],o),m=a?f:h,y=a?h:f,v=this.calcXScale(m),b=this.calcYScale(y),A=a?b.bandwidth():v.bandwidth(),x=this.calcAreas(v,b,c),S={x:v,y:b,width:l,height:s,ticks:g,data:e,bandwidth:A};return d.createElement(p.c,{style:r},d.createElement(p.c,{style:{flex:1},onLayout:e=>this._onLayout(e)},s>0&&l>0&&d.createElement(wn.default,{style:{height:s,width:l}},d.Children.map(i,(e=>e&&e.props.belowChart?d.cloneElement(e,S):null)),x.map(((r,o)=>{const i=o%e.length;return r.map(((r,o)=>{const a=o%e[i].data.length,s="".concat(i,"-").concat(a,"-").concat(r.key),{svg:l}=e[i].data[a][r.key];return d.createElement(uh,Dh({key:s,fill:r.color},l,{d:r.path,animate:t,animationDuration:n}))}))})),d.Children.map(i,(e=>e&&!e.props.belowChart?d.cloneElement(e,S):null)))))}}Nh.propTypes={data:od().arrayOf(od().object),keys:od().arrayOf(od().arrayOf(od().string)).isRequired,colors:od().arrayOf(od().arrayOf(od().string)).isRequired,offset:od().func,order:od().func,style:od().any,spacingInner:od().number,spacingOuter:od().number,animate:od().bool,animationDuration:od().number,contentInset:od().shape({top:od().number,left:od().number,right:od().number,bottom:od().number}),gridMin:od().number,gridMax:od().number,valueAccessor:od().func,borderRadius:od().number,innerBarSpace:od().number},Nh.defaultProps={spacingInner:.05,spacingOuter:.05,offset:xh,order:Ah,width:100,height:100,showZeroAxis:!0,contentInset:{},numberOfTicks:10,showGrid:!0,valueAccessor:e=>{let{item:t,key:n}=e;return t[n]},borderRadius:0,innerBarSpace:0};function Uh(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Fh(e){for(var t=1;tn(e.x))).y((e=>r(e.y))).defined((e=>"number"===typeof e.y)).curve(o)(t);return{path:i,line:i}}}Gh.propTypes=Fh({},gh.propTypes),Gh.defaultProps=Fh({},gh.defaultProps);function zh(){return zh=Object.assign||function(e){for(var t=1;te.data.map(((e,r)=>({y:n({item:e,index:r}),x:t({item:e,index:r})}))))),C=md(w).map((e=>e.y)),_=md(w).map((e=>e.x)),E=cd([...C,m,g]),R=cd([..._]),{yMin:k=E[0],yMax:I=E[1],xMin:T=R[0],xMax:O=R[1]}=this.props,j=r().domain([k,I]).range([S-u,c]).clamp(v),P=o().domain([T,O]).range([h,x-f]).clamp(y),B=this.createPaths({data:w,x:P,y:j}),L=j.ticks(l),D=Wh({x:P,y:j,data:e,ticks:L,width:x,height:S},B);return d.createElement(p.c,{style:i},d.createElement(p.c,{style:{flex:1},onLayout:e=>this._onLayout(e)},S>0&&x>0&&d.createElement(wn.default,{style:{height:S,width:x}},d.Children.map(A,(e=>e&&e.props.belowChart?d.cloneElement(e,D):null)),B.path.map(((t,n)=>{const{svg:r}=e[n],o=t+"-"+n;return d.createElement(uh,zh({key:o,fill:"none"},b,r,{d:t,animate:a,animationDuration:s}))})),d.Children.map(A,(e=>e&&!e.props.belowChart?d.cloneElement(e,D):null)))))}}Yh.propTypes=Wh({},gh.propTypes,{data:od().arrayOf(od().shape({data:od().oneOfType([od().arrayOf(od().object),od().arrayOf(od().number),od().arrayOf(od().array)]),svg:od().object})).isRequired}),Yh.defaultProps=Wh({},gh.defaultProps);const Kh=Yh;function qh(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Xh(e){for(var t=1;ttd().x((e=>n(e.x))).y((e=>r(e.y))).defined((e=>"number"===typeof e.y)).curve(o)(e)));return{path:i,lines:i}}}Zh.propTypes=Xh({},Kh.propTypes),Zh.defaultProps=Xh({},Kh.defaultProps);var $h=Math.abs,ep=Math.atan2,tp=Math.cos,np=Math.max,rp=Math.min,op=Math.sin,ip=Math.sqrt,ap=1e-12,sp=Math.PI,lp=sp/2,cp=2*sp;function up(e){return e>=1?lp:e<=-1?-lp:Math.asin(e)}function dp(e){return e.innerRadius}function hp(e){return e.outerRadius}function pp(e){return e.startAngle}function fp(e){return e.endAngle}function gp(e){return e&&e.padAngle}function mp(e,t,n,r,o,i,a){var s=e-n,l=t-r,c=(a?i:-i)/ip(s*s+l*l),u=c*l,d=-c*s,h=e+u,p=t+d,f=n+u,g=r+d,m=(h+f)/2,y=(p+g)/2,v=f-h,b=g-p,A=v*v+b*b,x=o-i,S=h*g-f*p,w=(b<0?-1:1)*ip(np(0,x*x*A-S*S)),C=(S*b-v*w)/A,_=(-S*v-b*w)/A,E=(S*b+v*w)/A,R=(-S*v+b*w)/A,k=C-m,I=_-y,T=E-m,O=R-y;return k*k+I*I>T*T+O*O&&(C=E,_=R),{cx:C,cy:_,x01:-u,y01:-d,x11:C*(o/x-1),y11:_*(o/x-1)}}function yp(){var e=dp,t=hp,n=Xu(0),r=null,o=pp,i=fp,a=gp,s=null;function l(){var l,c,u,d=+e.apply(this,arguments),h=+t.apply(this,arguments),p=o.apply(this,arguments)-lp,f=i.apply(this,arguments)-lp,g=$h(f-p),m=f>p;if(s||(s=l=qu()),hap)if(g>cp-ap)s.moveTo(h*tp(p),h*op(p)),s.arc(0,0,h,p,f,!m),d>ap&&(s.moveTo(d*tp(f),d*op(f)),s.arc(0,0,d,f,p,m));else{var y,v,b=p,A=f,x=p,S=f,w=g,C=g,_=a.apply(this,arguments)/2,E=_>ap&&(r?+r.apply(this,arguments):ip(d*d+h*h)),R=rp($h(h-d)/2,+n.apply(this,arguments)),k=R,I=R;if(E>ap){var T=up(E/d*op(_)),O=up(E/h*op(_));(w-=2*T)>ap?(x+=T*=m?1:-1,S-=T):(w=0,x=S=(p+f)/2),(C-=2*O)>ap?(b+=O*=m?1:-1,A-=O):(C=0,b=A=(p+f)/2)}var j=h*tp(b),P=h*op(b),B=d*tp(S),L=d*op(S);if(R>ap){var D,M=h*tp(A),N=h*op(A),U=d*tp(x),F=d*op(x);if(g1?0:u<-1?sp:Math.acos(u))/2),Q=ip(D[0]*D[0]+D[1]*D[1]);k=rp(R,(d-Q)/(W-1)),I=rp(R,(h-Q)/(W+1))}}C>ap?I>ap?(y=mp(U,F,j,P,h,I,m),v=mp(M,N,B,L,h,I,m),s.moveTo(y.cx+y.x01,y.cy+y.y01),Iap&&w>ap?k>ap?(y=mp(B,L,M,N,d,-k,m),v=mp(j,P,U,F,d,-k,m),s.lineTo(y.cx+y.x01,y.cy+y.y01),ke?1:t>=e?0:NaN}function bp(e){return e}function Ap(){var e=bp,t=vp,n=null,r=Xu(0),o=Xu(cp),i=Xu(0);function a(a){var s,l,c,u,d,h=a.length,p=0,f=new Array(h),g=new Array(h),m=+r.apply(this,arguments),y=Math.min(cp,Math.max(-cp,o.apply(this,arguments)-m)),v=Math.min(Math.abs(y)/h,i.apply(this,arguments)),b=v*(y<0?-1:1);for(s=0;s0&&(p+=d);for(null!=t?f.sort((function(e,n){return t(g[e],g[n])})):null!=n&&f.sort((function(e,t){return n(a[e],a[t])})),s=0,c=p?(y-h*b)/p:0;s0?d*c:0)+b,g[l]={data:a[l],index:s,value:d,startAngle:m,endAngle:u,padAngle:v};return g}return a.value=function(t){return arguments.length?(e="function"===typeof t?t:Xu(+t),a):e},a.sortValues=function(e){return arguments.length?(t=e,n=null,a):t},a.sort=function(e){return arguments.length?(n=e,t=null,a):n},a.startAngle=function(e){return arguments.length?(r="function"===typeof e?e:Xu(+e),a):r},a.endAngle=function(e){return arguments.length?(o="function"===typeof e?e:Xu(+e),a):o},a.padAngle=function(e){return arguments.length?(i="function"===typeof e?e:Xu(+e),a):i},a}function xp(){return xp=Object.assign||function(e){for(var t=1;th({item:e}))))<0&&console.error("don't pass negative numbers to pie-chart, it makes no sense!");const A=this._calculateRadius(o,b,b),x=this._calculateRadius(n,b,0),S=this._calculateRadius(i,b,A);o>0&&x>=o&&console.warn("innerRadius is equal to or greater than outerRadius");const w=e.map((e=>{const t=yp().outerRadius(A).innerRadius(x).padAngle(a);return e.arc&&Object.entries(e.arc).forEach((e=>{let[n,r]=e;"function"===typeof t[n]&&("string"===typeof r?t[n](r.split("%")[0]/100*A):t[n](r))})),t})),C=e.map(((e,t)=>i?yp().outerRadius(S).innerRadius(S).padAngle(a):w[t])),_=Ap().value((e=>h({item:e}))).sort(u).startAngle(g).endAngle(m)(e),E=_.map(((e,t)=>function(e){for(var t=1;tthis._onLayout(e)},y>0&&v>0&&d.createElement(wn.default,{pointerEvents:"android"===r.default.OS&&"box-none",style:{height:y,width:v}},d.createElement(wn.G,{x:v/2,y:y/2},d.Children.map(f,(e=>e&&e.props.belowChart?d.cloneElement(e,R):null)),_.map(((t,n)=>{const{key:r,onPress:o,svg:i}=e[n];return d.createElement(wn.Path,xp({key:r,onPress:o},i,{d:w[n](t),animate:s,animationDuration:l}))})),d.Children.map(f,(e=>e&&!e.props.belowChart?d.cloneElement(e,R):null))))))}}Cp.propTypes={data:od().arrayOf(od().shape({svg:od().object,key:od().any.isRequired,value:od().number,arc:od().object})).isRequired,innerRadius:od().oneOfType([od().number,od().string]),outerRadius:od().oneOfType([od().number,od().string]),labelRadius:od().oneOfType([od().number,od().string]),padAngle:od().number,animate:od().bool,animationDuration:od().number,style:od().any,sort:od().func,valueAccessor:od().func},Cp.defaultProps={width:100,height:100,padAngle:.05,startAngle:0,endAngle:2*Math.PI,valueAccessor:e=>{let{item:t}=e;return t.value},innerRadius:"50%",sort:(e,t)=>t.value-e.value};const _p=Cp;function Ep(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Rp(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class kp extends d.PureComponent{constructor(){super(...arguments),Rp(this,"state",{height:0,width:0})}_onLayout(e){const{nativeEvent:{layout:{height:t,width:n}}}=e;this.setState({height:t,width:n})}render(){const{style:e,progressColor:t,backgroundColor:n,strokeWidth:r,startAngle:o,endAngle:i,animate:a,animateDuration:s,children:l,cornerRadius:c}=this.props;let{progress:u}=this.props;const{height:h,width:f}=this.state,g=Math.min(f,h);isFinite(u)&&!isNaN(u)||(u=0);const m=[{key:"rest",value:1-u,color:n},{key:"progress",value:u,color:t}],y=Ap().value((e=>e.value)).sort((e=>"rest"===e.key?1:-1)).startAngle(o).endAngle(i)(m).map(((e,t)=>function(e){for(var t=1;tthis._onLayout(e)},h>0&&f>0&&d.createElement(wn.default,{style:{height:h,width:f}},d.createElement(wn.G,{x:f/2,y:h/2},d.Children.map(l,(e=>e&&e.props.belowChart?d.cloneElement(e,v):null)),y.map(((e,t)=>d.createElement(uh,{key:t,fill:e.color,d:e.path,animate:a,animationDuration:s}))),d.Children.map(l,(e=>e&&!e.props.belowChart?d.cloneElement(e,v):null)))))}}kp.propTypes={progress:od().number.isRequired,style:od().any,progressColor:od().any,backgroundColor:od().any,strokeWidth:od().number,startAngle:od().number,endAngle:od().number,animate:od().bool,cornerRadius:od().number,animateDuration:od().number},kp.defaultProps={progressColor:"black",backgroundColor:"#ECECEC",strokeWidth:5,startAngle:0,endAngle:2*Math.PI,cornerRadius:45};function Ip(){return Ip=Object.assign||function(e){for(var t=1;ts(e)+s.bandwidth()/2):s}render(){const{style:e,scale:t,data:n,xAccessor:r,formatLabel:o,numberOfTicks:i,svg:a,children:s,min:l,max:c}=this.props,{height:u,width:h}=this.state;if(0===n.length)return d.createElement(p.c,{style:e});const f=n.map(((e,t)=>r({item:e,index:t}))),g=cd(f),m=t===Id?f:[l||g[0],c||g[1]],y=this._getX(m),v=i?y.ticks(i):f,b={x:y,ticks:v,width:h,height:u,formatLabel:o};return d.createElement(p.c,{style:e},d.createElement(p.c,{style:{flexGrow:1},onLayout:e=>this._onLayout(e)},d.createElement(un.c,{style:{opacity:0,fontSize:a.fontSize,fontFamily:a.fontFamily,fontWeight:a.fontWeight}},o(v[0],0)),u>0&&h>0&&d.createElement(wn.default,{style:{position:"absolute",top:0,left:0,height:u,width:h}},d.createElement(wn.G,null,d.Children.map(s,(e=>d.cloneElement(e,b))),h>0&&v.map(((e,t)=>{const{svg:r={}}=n[t]||{};return d.createElement(wn.Text,Ip({textAnchor:"middle",originX:y(e),alignmentBaseline:"hanging"},a,r,{key:t,x:y(e)}),o(e,t))}))))))}}Tp.propTypes={data:od().arrayOf(od().oneOfType([od().number,od().object])).isRequired,spacingInner:od().number,spacingOuter:od().number,formatLabel:od().func,contentInset:od().shape({left:od().number,right:od().number}),scale:od().func,numberOfTicks:od().number,xAccessor:od().func,svg:od().object,min:od().any,max:od().any},Tp.defaultProps={spacingInner:.05,spacingOuter:.05,contentInset:{},svg:{},xAccessor:e=>{let{index:t}=e;return t},scale:eh,formatLabel:e=>e};function Op(){return Op=Object.assign||function(e){for(var t=1;ts(e)+s.bandwidth()/2):s}render(){const{style:e,data:t,scale:n,yAccessor:r,numberOfTicks:o,formatLabel:i,svg:a,children:s}=this.props,{height:l,width:c}=this.state;if(0===t.length)return d.createElement(p.c,{style:e});const u=t.map(((e,t)=>r({item:e,index:t}))),h=cd(u),{min:f=h[0],max:g=h[1]}=this.props,m=n===Id?u:[f,g],y=this.getY(m),v=n===Id?u:y.ticks(o),b=v.map(((e,t)=>i(e,t))).reduce(((e,t)=>e.toString().length>t.toString().length?e:t),0),A={y:y,ticks:v,width:c,height:l,formatLabel:i};return d.createElement(p.c,{style:[e]},d.createElement(p.c,{style:{flexGrow:1},onLayout:e=>this._onLayout(e)},d.createElement(un.c,{style:{opacity:0,fontSize:a.fontSize,fontFamily:a.fontFamily,fontWeight:a.fontWeight}},b),l>0&&c>0&&d.createElement(wn.Svg,{style:{position:"absolute",top:0,left:0,height:l,width:c}},d.createElement(wn.G,null,d.Children.map(s,(e=>d.cloneElement(e,A))),l>0&&v.map(((e,t)=>d.createElement(wn.Text,Op({originY:y(e),textAnchor:"middle",x:"50%",alignmentBaseline:"middle"},a,{key:y(e),y:y(e)}),i(e,t,v.length))))))))}}jp.propTypes={data:od().oneOfType([od().arrayOf(od().object),od().arrayOf(od().number)]).isRequired,svg:od().object,style:od().any,numberOfTicks:od().number,formatLabel:od().func,contentInset:od().shape({top:od().number,bottom:od().number}),min:od().number,max:od().number,yAccessor:od().func,scale:od().func,spacingInner:od().number,spacingOuter:od().number},jp.defaultProps={numberOfTicks:10,spacingInner:.05,spacingOuter:.05,contentInset:{},svg:{},scale:eh,formatLabel:e=>e&&e.toString(),yAccessor:e=>{let{item:t}=e;return t}};function Pp(){return Pp=Object.assign||function(e){for(var t=1;t=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}class Lp extends d.Component{render(){const e=this.props,{y:t,value:n}=e,r=Bp(e,["y","value"]);return d.createElement(wn.Line,Pp({x1:"0%",x2:"100%",y1:t(n),y2:t(n)},r))}}Lp.defaultProps={stroke:"black"};const Dp=e=>{let{x:t,y:n,value:r,index:o,radius:i,color:a}=e;return isNaN(r)?d.createElement(wn.Circle,null):d.createElement(wn.Circle,{cx:t(o),cy:n(r),r:i,stroke:a,fill:"white"})};Dp.propTypes={x:od().func.isRequired,y:od().func.isRequired,value:od().number,radius:od().number,index:od().number,color:od().string},Dp.defaultProps={radius:4,color:"black"};const Mp=e=>{let{x:t,y:n,value:r,index:o,height:i,text:a,stroke:s,pointStroke:l}=e;return d.createElement(wn.G,null,d.createElement(wn.Line,{x1:t(o),y1:i,x2:t(o),y2:20,stroke:s}),d.createElement(wn.Circle,{cx:t(o),cy:n(r),r:4,stroke:l,strokeWidth:2,fill:"white"}),d.createElement(wn.G,{x:t(o)<40?40:t(o),y:10},d.createElement(wn.Rect,{x:-40,y:1,width:80,height:20,fill:"rgba(0, 0, 0, 0.2)",rx:2,ry:2}),d.createElement(wn.Rect,{x:-40,y:0,width:80,height:20,fill:"white",rx:2,ry:2}),d.createElement(wn.Text,{fontSize:"12",textAnchor:"middle"},a)))};Mp.propTypes={x:od().func.isRequired,y:od().func.isRequired,value:od().number,index:od().number,height:od().number,stroke:od().string,pointStroke:od().string,text:od().string};function Np(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function Up(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Fp(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Hp(){return Hp=Object.assign||function(e){for(var t=1;t{let{ticks:t=[],y:n,svg:r}=e;return d.createElement(wn.G,null,t.map((e=>d.createElement(wn.Line,Hp({key:e,x1:"0%",x2:"100%",y1:n(e),y2:n(e),strokeWidth:1,stroke:"rgba(0,0,0,0.2)"},r)))))},zp=e=>{let{ticks:t=[],x:n,svg:r}=e;return d.createElement(wn.G,null,t.map(((e,t)=>d.createElement(wn.Line,Hp({key:t,y1:"0%",y2:"100%",x1:n(e),x2:n(e),strokeWidth:1,stroke:"rgba(0,0,0,0.2)"},r)))))},Vp=e=>d.createElement(wn.G,null,d.createElement(Gp,e),d.createElement(zp,e));zp.propTypes={x:od().func,dataPoints:od().array,svg:od().object},Gp.propTypes={y:od().func,ticks:od().array},Vp.propTypes=function(e){for(var t=1;t{let{direction:t}=e,n=Np(e,["direction"]);return t===Wp.VERTICAL?d.createElement(zp,n):t===Wp.HORIZONTAL?d.createElement(Gp,n):t===Wp.BOTH?d.createElement(Vp,n):null};Qp.Direction=Wp,Qp.propTypes={direction:od().oneOf(Object.values(Wp)),belowChart:od().bool,svg:od().object},Qp.defaultProps={direction:Wp.HORIZONTAL,belowChart:!0};const Yp={1:()=>n(7100),2:()=>n(7344),3:()=>n(3160),4:()=>n(7624),5:()=>n(6284),6:()=>n(1736),7:()=>n(9696),8:()=>n(3524),9:()=>n(4684),10:()=>n(9817),11:()=>n(6796),12:()=>n(3868),13:()=>n(3416),14:()=>n(9304),15:()=>n(6612),16:()=>n(2825),17:()=>n(4016)},Kp={1:"#E5243B",2:"#DDA83A",3:"#4C9F38",4:"#C5192D",5:"#FF3A21",6:"#26BDE2",7:"#FCC30B",8:"#A21942",9:"#FD6925",10:"#DD1367",11:"#FD9D24",12:"#BF8B2E",13:"#3F7E44",14:"#0A97D9",15:"#56C02B",16:"#00689D",17:"#19486A"},qp=e=>{const t=t=>{e.setCurrent(e.current===t?null:t)},n=e.data.map(((n,r)=>({value:n,svg:{fill:e.current===r+1||null===e.current?Kp[r+1]:u.y.GREY_LIGHT,onPress:()=>t(r+1),onClick:()=>t(r+1)},key:"pie-".concat(r)})));return(0,An.jsxs)(p.c,{style:{flex:1,justifyContent:"center"},children:[(0,An.jsx)(_p,{style:[{height:250},tl.out_bottom_s,tl.out_bottom_m],data:n,innerRadius:"75%",padAngle:null===e.current?0:.01}),null!==e.current&&(0,An.jsx)(un.c,{style:[{position:"absolute",alignSelf:"center",color:Kp[e.current]},pr.h3],children:(0,hn._)(Vc(e.data[e.current-1]))})]})};function Xp(e){const t=d.useContext(yn.S),[n,o]=d.useState(null);return(0,An.jsx)(p.c,{children:(0,An.jsxs)(p.c,{style:[{flex:1,flexDirection:t.expanded?"row":"column"},t.expanded?{}:tl.out_top_xs],children:[(0,An.jsx)(qp,{current:n,setCurrent:o,data:e.data}),(0,An.jsxs)(p.c,{style:[{flex:1,width:"100%",marginTop:42},tl.in_bottom_m,t.expanded?{}:[tl.out_top_m,bn.justify_center]],children:[(0,An.jsx)(p.c,{style:{maxWidth:430,flexDirection:"row",flexWrap:"wrap",justifyContent:t.expanded?"flex-start":"center"},children:Object.keys(Yp).map(((e,r)=>{const i=n===r+1,a=(t.expanded?52:48)*(i?2:1)+(i?10:0);return(0,An.jsx)(vc.c,{style:{alignSelf:"center"},onPress:()=>o(i?null:r+1),children:(0,An.jsx)(p.c,{style:{margin:5},children:(0,An.jsx)(le.c,{source:Yp[e](),style:{width:a,height:a}})})},r)}))}),(0,An.jsx)(xl,{fontSize:16,color:u.y.WHITE,textColor:u.y.BLACK,fontWeight:"bold",style:{borderColor:u.y.BLACK,borderRadius:40,borderWidth:1,paddingLeft:16,paddingRight:16,alignSelf:t.expanded?"flex-start":"center",marginTop:16},children:(0,hn._)(Wc),onPress:()=>{let e;e="fr"===hn.O.get()?"https://www.un.org/sustainabledevelopment/fr/objectifs-de-developpement-durable/":"https://www.un.org/sustainabledevelopment/","web"===r.default.OS?window.open(e,"_blank"):Promise.resolve(kn.c.openURL(e))}})]})]})})}const Jp=e=>{const t=Array.isArray(e.users)?e.users.filter((e=>!e.deleted)):Object.keys(e.users).reduce(((t,n)=>{const r=e.users[n];if(!r.deleted){let e=r.name;e||(e=[r.firstname,r.lastname]),t.push({name:e,picture:r.picture})}return t}),[]);return(0,An.jsxs)(p.c,{style:{flexDirection:"row",flexWrap:"wrap"},children:[t.slice(0,e.max).map(((t,n)=>(0,An.jsx)(Rn,{size:e.size,name:t.name,source:t.picture,bgColor:e.bgColor,color:e.color,style:{marginRight:8}},n))),t.length>e.max&&(e.dots&&(0,An.jsx)(En,{style:[fr.white],children:"..."})||(0,An.jsx)(p.c,{style:[{backgroundColor:e.bgColorPlus,borderRadius:50,justifyContent:"center",marginRight:e.marginRight,borderColor:e.borderColorPlus,borderWidth:e.borderWidthPlus},"ios"===r.default.OS?{minWidth:e.widthChip||35,height:e.heightChip||35}:{width:e.widthChip||35,height:e.heightChip||35}],children:(0,An.jsx)(En,{style:[{textAlign:"center",fontSize:11,fontWeight:"700",color:u.y.BLUE_DARK}],children:"+"+(t.length-e.max)})}))]})},Zp={fr:"Veuillez trier par ordre de pr\xe9f\xe9rence les projets que vous aimeriez soutenir",en:"Please sort the projects you would like to support"},$p={fr:"Nous vous associerons \xe0 un projet respectant vos choix.",en:"We will integrate you in the communnity that respects your choices."},ef={fr:"Choix n\xb0",en:"Choice n\xb0"},tf={fr:"Mission",en:"Mission"},nf={fr:"Projet",en:"Project"},rf={fr:"Localisation",en:"Location"},of={fr:"Objectifs de D\xe9veloppement Durable de l'ONU",en:"UN Sustainable Development Goals"},af={fr:"Voir le d\xe9tail",en:"See details"},sf={fr:"Valider",en:"Validate"},lf=b.c.create({direction:{flexDirection:"row"},arrowBack:{width:24,height:24},marginTop:{marginTop:16},marginBottom:{marginBottom:16},h3:{fontWeight:"600",color:u.y.BLACK,fontSize:28,marginBottom:16},h4:{fontWeight:"700",color:u.y.BLACK,fontSize:26,marginBottom:8},body1:{color:u.y.BLACK,fontSize:17,marginBottom:20},textBlue:{color:u.y.BLUE_DARK,fontWeight:"bold",fontSize:18},tag:{color:u.y.BLACK,fontSize:11,backgroundColor:u.y.GREY_LIGHT_X,borderRadius:4,borderWidth:1,borderColor:u.y.GREY_LIGHT_X,marginTop:16,marginBottom:16,paddingLeft:10,paddingRight:10,paddingTop:4,paddingBottom:4},imageOrganization:{marginRight:8}}),cf=e=>{const t=d.useContext(yn.S);return(0,An.jsxs)(p.c,{style:[t.expanded?{}:{marginRight:16,marginLeft:16},{alignSelf:"center"}],children:[e.goBack&&(0,An.jsx)(cn.c,{onPress:e.goBack,children:(0,An.jsx)(le.c,{style:[lf.arrowBack,lf.marginBottom,lf.marginTop],source:n(6364)})}),(0,An.jsx)(un.c,{style:[pr.h2,fr.black,tl.out_bottom_xs],children:(0,hn._)(e.data.name)}),(0,An.jsx)(p.c,{style:{alignSelf:"flex-start"},children:(0,An.jsx)(un.c,{style:lf.tag,children:(0,hn._)(e.data.tag)})}),(0,An.jsx)(p.c,{style:[lf.direction,lf.marginBottom,{alignItems:"center"}],children:(0,An.jsxs)(cn.c,{style:{flexDirection:"row",alignItems:"center"},onPress:()=>{const t=e.data.url;t&&("web"===r.default.OS?window.open(t,"_blank"):kn.c.openURL(t))},children:[(0,An.jsx)(Rn,{bgColor:"white",color:"black",size:40,source:e.data.organization.picture,name:e.data.organization.name,style:lf.imageOrganization}),(0,An.jsx)(un.c,{style:[pr.h4,fr.blue_dark,tl.out_bottom_xs],children:(0,hn._)(e.data.organization.name)})]})}),(0,An.jsx)(un.c,{style:[pr.h3,fr.black,tl.out_bottom_xs],children:(0,hn._)(tf)}),(0,An.jsx)(un.c,{style:[pr.body1,fr.black,tl.out_bottom_m],children:(0,hn._)(e.data.mission)}),(0,An.jsx)(un.c,{style:[pr.h3,fr.black,tl.out_bottom_xs],children:(0,hn._)(nf)}),(0,An.jsx)(un.c,{style:[pr.body1,fr.black,tl.out_bottom_m],children:(0,hn._)(e.data.description)}),(0,An.jsx)(un.c,{style:[pr.h3,fr.black,tl.out_bottom_xs],children:(0,hn._)(rf)}),(0,An.jsx)(un.c,{style:[pr.body1,fr.black,tl.out_bottom_m],children:(0,hn._)(e.data.location)}),(0,An.jsx)(un.c,{style:[pr.h3,fr.black,tl.out_bottom_xs],children:(0,hn._)(of)}),(0,An.jsx)(p.c,{style:{flexDirection:"row",marginBottom:16},children:(0,An.jsx)(p.c,{style:{flexDirection:"row",marginTop:10,flexWrap:"wrap",width:"100%"},children:e.data.odd.reduce(((e,n,r)=>("undefined"!==typeof Yp[n]&&e.push((0,An.jsx)(le.c,{style:{width:t.expanded?66:60,height:t.expanded?66:60,margin:5},source:Yp[n]()},r)),e)),[])},"images")})]})},uf=e=>{var t,r,o,i,a,s,l;const c=d.useContext(yn.S),[h,f]=d.useState(),g=(null===(t=e.community)||void 0===t?void 0:t.earned)||0;let m=g*e.pointValue;if(m>0){const t=e.data.reduce(((t,n)=>t+n.community.earned*(1-n.progression/100+1)*e.pointValue),0);m/=e.budget*e.pointValue-t,m=Math.round(100*m)}const y=[...null!==(r=e.community)&&void 0!==r&&r.project?[{progression:m,community:{earned:g||0,name:(0,hn._)(null===(o=e.community)||void 0===o||null===(i=o.organization)||void 0===i?void 0:i.name),picture:null===(a=e.community)||void 0===a||null===(s=a.organization)||void 0===s?void 0:s.picture,project:{...e.community.project,organization:e.community.organization},users:(null===(l=e.community)||void 0===l?void 0:l.users)||[]}}]:[],...e.data],v="undefined"!==typeof h;return(0,An.jsxs)(p.c,{children:[y.map(((e,t)=>{var r,o;return(0,An.jsxs)(p.c,{style:[tl.out_top_m],children:[(0,An.jsxs)(p.c,{style:[bn.horizontal,c.expanded?{alignItems:"center"}:{alignItems:"flex-start"}],children:[(0,An.jsx)(p.c,{style:[c.expanded?{flexDirection:"row"}:{flexDirection:"column"}],children:(0,An.jsx)(En,{style:[pr.h4,0!==t?{color:u.y.GREY2}:{color:u.y.BLUE_DARK},tl.out_right_s,c.expanded?{}:{maxWidth:240}],children:(0,hn._)(e.community.project.name)})}),(0,An.jsxs)(p.c,{style:[bn.horizontal,bn.flex1,bn.align_item_center,bn.justify_right,c.expanded?{}:{marginTop:2}],children:[(0,An.jsx)(le.c,{style:{height:19,width:19,marginRight:3,alignContent:"center"},source:n(0!==t?8127:2988)}),(0,An.jsx)(En,{style:[pr.h5,fr.blue_dark,0!==t?{color:u.y.GREEN}:{color:u.y.BLUE_DARK}],children:e.progression+" %"})]})]}),(0,An.jsxs)(p.c,{style:[bn.horizontal,bn.align_item_center,tl.out_top_s],children:[(0,An.jsx)(Rn,{style:[{borderColor:u.y.GREY_LIGHT,borderWidth:1},tl.out_right_s],size:32,bgColor:u.y.GREY_LIGHT,color:u.y.BLUE_DARK,name:e.community.name,source:e.community.picture}),(0,An.jsx)(En,{style:[pr.h5,0!==t?{color:u.y.GREY2}:{color:u.y.BLUE_DARK}],children:e.community.name}),(0,An.jsx)(En,{style:[pr.body2,fr.blue_dark,tl.out_left_s,0!==t?{color:u.y.GREY2}:{color:u.y.BLACK},{flex:1,textAlign:"right"}],children:mu(e.community.earned)+" \u20ac"})]}),(0,An.jsxs)(p.c,{style:[tl.out_top_s,c.expanded?{flexDirection:"row",alignItems:"center"}:{alignItems:"flex-start"}],children:[0===t&&(0!==(null===(r=e.community)||void 0===r||null===(o=r.users)||void 0===o?void 0:o.length)?(0,An.jsxs)(p.c,{style:[bn.horizontal,bn.align_item_center,tl.out_top_s,bn.flex1],children:[(0,An.jsx)(Jp,{users:e.community.users,max:3,bgColor:u.y.BLUE_LIGHT_X,color:u.y.BLUE_DARK,bgColorPlus:u.y.BLUE_LIGHT_X,size:24,widthChip:24,heightChip:24}),(0,An.jsx)(En,{style:[tl.out_left_s,pr.body2,fr.black],children:(0,hn._)(lu)})]}):(0,An.jsx)(p.c,{style:[bn.flex1]})),!!e.endDate&&(0,An.jsx)(En,{children:(0,hn._)(qc(e.endDate)),style:[pr.body2,fr.grey2,bn.flex1]}),(0,An.jsx)(xl,{fontWeight:"bold",fontSize:13,children:(0,hn._)(cu),textColor:0!==t?u.y.GREY2:u.y.BLUE_DARK,onPress:()=>{f(e.community.project)},style:[{borderWidth:1,borderRadius:24,borderColor:0!==t?u.y.GREY2:u.y.BLUE_DARK,paddingLeft:8,paddingRight:8},c.expanded?{}:{marginTop:14}]})]}),y.length-1!==t&&(0,An.jsx)(yr,{color:u.y.GREY_LIGHT,height:1,minWidth:"100%",style:[tl.out_top_m]})]},t)})),v&&(0,An.jsx)(yc,{isVisible:!0,color:"white",margin:c.expanded?20:16,hide:()=>f(void 0),content:(0,An.jsx)(jr.c,{contentContainerStyle:{alignSelf:"flex-start"},children:(0,An.jsx)(cf,{data:h})})})]})},df=e=>{var t,n,o,i,a,s;const l=d.useContext(yn.S),c=e.company,h=!e.community,f=!(null===(t=l.profile)||void 0===t||null===(n=t.company)||void 0===n||!n.forcePoints),g=h||null===(o=l.profile)||void 0===o||null===(i=o.company)||void 0===i||!i.limitedBudgetCap||c.budget>c.earned?null===c||void 0===c?void 0:c.earned:c.budget;return(0,An.jsxs)(p.c,{children:[(0,An.jsx)(En,{style:[pr.h2,tl.out_bottom_m],children:(0,hn._)(Hc)}),(0,An.jsxs)(p.c,{style:Fu.border,children:[(0,An.jsxs)(p.c,{style:[tl.out_bottom_m],children:[(0,An.jsx)(le.c,{source:{uri:null===c||void 0===c?void 0:c.picture},style:{width:80,minHeight:80,resizeMode:"contain"}}),(0,An.jsx)(En,{style:[pr.h2,fr.purple,tl.out_bottom_xs],children:(0,hn._)(Gc(null===(a=e.company)||void 0===a||null===(s=a.odds)||void 0===s?void 0:s.reduce(((e,t)=>e+t),0)))}),(0,An.jsx)(En,{style:[pr.body2,fr.grey2],children:(0,hn._)(zc)})]}),(0,An.jsx)(Xp,{data:e.company.odds}),(0,An.jsx)(yr,{style:{marginTop:l.expanded?"5%":15},color:u.y.GREY_LIGHT,height:1,minWidth:"100%"}),(0,An.jsx)(En,{style:[l.expanded||"web"!==r.default.OS?pr.h2:pr.h3,fr.purple,tl.out_top_m,tl.out_bottom_xs],children:yu(c.co2)+" eq. CO2"}),(0,An.jsx)(En,{style:[pr.body2,fr.grey2],children:(0,hn._)(Qc(mu(c.users)))}),(0,An.jsx)(yr,{style:{marginTop:l.expanded?"5%":15},color:u.y.GREY_LIGHT,height:1,minWidth:"100%"}),(0,An.jsxs)(p.c,{style:[bn.horizontal,tl.out_top_m],children:[(0,An.jsx)(En,{style:[bn.flex1,l.expanded||"web"!==r.default.OS?pr.h2:pr.h3,fr.purple],children:mu(g)+(h||f?" points":" \u20ac")}),(0,An.jsx)(p.c,{children:(0,An.jsx)(En,{style:[pr.h6,fr.purple,tl.out_top_xs],children:(0,hn._)(Yc(Math.round(100*c.progress)))})})]}),(0,An.jsx)(Gu,{ratio:c.progress,backgroundColor:u.y.PURPLE_LIGHT}),(0,An.jsx)(En,{style:[pr.body2,fr.grey2,tl.out_top_s,tl.out_bottom_s],children:(0,hn._)(Kc(mu(c.budget),h||f))}),!!e.company.campaigns&&(0,An.jsx)(uf,{data:e.company.campaigns,community:e.community,pointValue:null===c||void 0===c?void 0:c.pointValue,budget:c.budget})]})]})},hf=e=>{var t,r,o,i,a;const s=d.useContext(yn.S);return(0,An.jsx)(p.c,{style:[s.expanded?{marginLeft:"auto",maxWidth:"48%",flex:1}:{marginTop:10}],children:(0,An.jsxs)(p.c,{children:[(0,An.jsx)(En,{style:[pr.h2,tl.out_bottom_m,s.expanded?{}:tl.out_top_m],children:(0,hn._)(uu)}),(0,An.jsxs)(p.c,{children:[(0,An.jsxs)(p.c,{style:[{backgroundColor:u.y.GREEN_LIGHT,borderTopLeftRadius:16,borderTopRightRadius:16,padding:s.expanded?24:16}],children:[(0,An.jsxs)(p.c,{style:{flexDirection:"row"},children:[(0,An.jsx)(Rn,{bgColor:"white",color:u.y.BLUE_DARK,size:s.expanded?50:40,name:[s.profile.firstname,null===(t=s.profile)||void 0===t?void 0:t.lastname],source:s.picture,style:{marginRight:20}}),(0,An.jsxs)(p.c,{children:[(0,An.jsxs)(p.c,{style:{flexDirection:"row"},children:[(0,An.jsx)(le.c,{style:{width:24,height:24,resizeMode:"contain",marginRight:5},source:n(1324)}),(0,An.jsx)(En,{style:[fr.green,pr.h6],children:(0,hn._)(du)})]}),(0,An.jsx)(En,{style:[fr.green,pr.h4],children:(0,hn._)(e.user.level)})]})]}),(0,An.jsx)(p.c,{children:e.user.remaining.lvlName&&(0,An.jsx)(En,{style:[pr.body2,fr.green,tl.out_top_s],children:(0,hn._)(hu({points:mu(e.user.remaining.points),lvlName:(0,hn._)(e.user.remaining.lvlName)}))})})]}),(0,An.jsxs)(p.c,{style:{borderWidth:2,borderBottomLeftRadius:16,borderBottomRightRadius:16,borderColor:u.y.GREEN_LIGHT,padding:s.expanded?24:16},children:[(0,An.jsxs)(p.c,{children:[(0,An.jsx)(En,{style:[fr.green,pr.h3],children:yu(e.user.co2)+" eq. CO2"}),(0,An.jsx)(En,{style:[pr.body2,fr.grey2,tl.out_top_xs],children:(0,hn._)(pu(mu(Math.round(100*(e.user.co2/193+Number.EPSILON))/100)))})]}),(0,An.jsx)(yr,{style:{marginTop:s.expanded?24:16},color:u.y.GREY_LIGHT,height:1,minWidth:"100%"}),(0,An.jsxs)(p.c,{style:[{marginTop:s.expanded?24:16}],children:[(0,An.jsx)(En,{style:[fr.green,pr.h3],children:(0,hn._)(fu(mu(e.user.points)))}),"undefined"!==typeof e.user.companyRatio&&(0,An.jsx)(En,{style:[pr.body2,fr.grey2,tl.out_top_xs],children:(0,hn._)(gu({ratio:Math.round(e.user.companyRatio),earned:mu(e.user.earned)},(null===s||void 0===s||null===(r=s.profile)||void 0===r||null===(o=r.company)||void 0===o?void 0:o.noCommunities)||(null===(i=s.profile)||void 0===i||null===(a=i.company)||void 0===a?void 0:a.forcePoints)))})]})]})]})]})})},pf=b.c.create({arrowClick:{height:10,width:10,resizeMode:"contain",alignSelf:"center"},alignCenter:{alignItems:"center"},collectiveChallengeCard:{display:"flex",flexDirection:"column",justifyContent:"space-between"},cardMainTitle:{display:"flex",flexDirection:"row",justifyContent:"flex-start",alignItems:"center"},cardMainTitleImage:{width:24,height:24},marginBottomBig:{marginBottom:30},marginLeft:{marginLeft:10},blueLightBackground:{backgroundColor:u.y.BLUE_LIGHT_X},fullWidth:{width:"100%"}}),ff=e=>{let t=[],o=e.current;if(!e.limit||e.teams.length<3)t=e.teams;else if(0===e.current)t=e.teams.slice(0,3);else if(e.current===e.teams.length-1){const n=e.teams.length-3;t=e.teams.slice(n),o-=n}else{const n=e.current-1;t=e.teams.slice(n,e.current+2),o-=n}const[i,a]=d.useState();return(0,An.jsxs)(p.c,{children:[!e.hideText&&(0,An.jsx)(En,{style:[e.limit?pr.h4:pr.h2,e.limit?fr.blue_dark:fr.black,tl.in_bottom_m],children:(0,hn._)($c)}),t.map(((s,l)=>(0,An.jsxs)(p.c,{children:[(0,An.jsx)(cn.c,{onPress:"undefined"===typeof e.members?void 0:()=>{i===l?a():a(l)},style:"web"!==r.default.OS?{}:{cursor:"undefined"===typeof e.members?"default":"pointer"},children:(0,An.jsxs)(p.c,{style:[{flexDirection:"row",alignItems:"center"},tl.out_bottom_m],children:[(0,An.jsx)(En,{style:[pr.h4,fr.blue_dark,{marginRight:10}],children:s.ranking}),(0,An.jsx)(Rn,{size:32,bgColor:u.y.BLUE_LIGHT_X,color:u.y.BLUE_DARK,name:s.name,source:s.picture,style:[tl.out_right_s]}),(0,An.jsxs)(p.c,{style:{flex:1},children:[(0,An.jsx)(En,{style:[pr.body2,fr.blue_dark,{flex:1,maxWidth:"95%"},l===o&&{fontWeight:"bold"}],children:s.name}),l===o&&(0,An.jsx)(p.c,{style:{backgroundColor:u.y.GREY_LIGHT,borderRadius:4,paddingLeft:8,paddingRight:8,paddingTop:4,paddingBottom:4,alignSelf:"flex-start"},children:(0,An.jsx)(En,{style:{color:u.y.BLUE_DARK,fontSize:11},children:(0,hn._)(tu)})})]}),(0,An.jsx)(En,{style:[pr.caption,fr.blue_dark],children:s.points}),"undefined"!==typeof e.members&&(0,An.jsx)(le.c,{source:n(i===l?4040:9216),style:[pf.arrowClick,{marginLeft:8}]})]})}),i===l&&(0,An.jsx)(Pc,{users:e.members[l],size:40,color:u.y.BLUE_DARK,bgColor:u.y.BLUE_LIGHT_X,userTeam:!0}),l!==t.length-1&&(0,An.jsx)(yr,{color:u.y.GREY_LIGHT,height:1,minWidth:"100%",style:[tl.out_bottom_m,i===l&&{marginTop:26}]})]},l)))]})},gf=e=>{const[t,n]=d.useState(!1),o=(0,f.Yi)();return(0,An.jsxs)(p.c,{style:{padding:24},children:[(0,An.jsx)(ff,{teams:e.teams,current:e.current,limit:!e.listOnly,hideText:e.listOnly,members:e.listOnly?e.members:void 0}),!e.listOnly&&(0,An.jsx)(xl,{children:(0,hn._)(eu),textColor:u.y.BLACK,fontWeight:"700",fontSize:16,style:{borderColor:u.y.GREY1,alignSelf:"flex-start",paddingLeft:24,paddingRight:24},onPress:()=>{"web"===r.default.OS?n(!0):o.navigate(ln.g.TEAMS_RANKING,{teams:e.teams,current:e.current,members:e.members})}}),"web"===r.default.OS&&(0,An.jsx)(yc,{isVisible:t,hide:()=>n(!1),color:u.y.WHITE,content:(0,An.jsx)(p.c,{style:{paddingTop:24},children:(0,An.jsx)(ff,{teams:e.teams,current:e.current,members:e.members})}),paddingTop:0})]})},mf=e=>{const t=d.useContext(yn.S),{push:r}=(0,f.Yi)();return(0,An.jsx)(xl,{color:u.y.WHITE,style:[t.expanded?{minWidth:260,alignSelf:"flex-end"}:{maxWidth:260},{borderColor:u.y.GREY1,borderRadius:25,borderWidth:1}],textColor:u.y.BLACK,fontSize:16,fontWeight:"bold",side:!!e.unreadMessages&&(0,An.jsx)(p.c,{style:{backgroundColor:u.y.RED,borderRadius:24,borderWidth:1,borderColor:u.y.RED,borderStyle:"solid",alignItems:"center",marginLeft:8},children:(0,An.jsx)(un.c,{style:[pr.h6,fr.white,{minHeight:24,minWidth:24,padding:2,textAlign:"center"}],children:e.unreadMessages})}),sideLeft:(0,An.jsx)(le.c,{style:{height:24,width:24,marginRight:8},source:n(1988)}),children:e.text,onPress:()=>{r(ln.g.CHAT),vn.O.add(vn.S.CHAT,!0)}})},yf={action:{fr:"Voir notre d\xe9marche RSE",en:"See our CSR approach"},seeMoreAction:{fr:"En savoir plus",en:"Find out more"},highlightsTitle:{fr:"Temps forts",en:"Highlights"},highlightsInProgress:{fr:"En cours",en:"Ongoing"},highlightsPassed:{fr:"Termin\xe9",en:"Completed"},highlightsInComing:{fr:"\xc0 venir",en:"Coming"},highlightsSeeMore:{fr:"Voir tous les temps forts",en:"See all the highlights"},intoAction:{fr:"Entrez en action",en:"Get into action"},individualChallenge:{fr:"Challenge individuel",en:"Individual challenge"},moreDetail:{fr:"Voir plus",en:"See more"},tagAwerness:{fr:"Se sensibiliser",en:"Raise awareness"},tagTest:{fr:"Lancer une discussion",en:"Launch a discussion"},tagEmbody:{fr:"Incarner le changement",en:"Embody change"},tagTransform:{fr:"Transformer",en:"Transform"},challengeParticipate:{fr:"Participer",en:"Join in"},challengeParticipants:e=>({fr:"".concat(e," collaborateur").concat(1!==e?"s":""," participe").concat(1!==e?"nt":""," au challenge"),en:"".concat(e," collaborator").concat(1!==e?"s":""," ").concat(1===e?"is":"are"," participating in the challenge")}),challengeParticipantsInProgress:(e,t)=>({fr:"".concat(t?1!==e?"ont ":"a ":"","particip").concat(t?"\xe9":1!==e?"ent":"e"," au challenge avec vous"),en:"".concat(t?"have participated":(1===e?"is":"are")+" participating"," in the challenge with you")}),challengeParticipantsAlone:e=>({fr:"Vous ".concat(e?"avez \xe9t\xe9":"\xeates"," le ").concat(e?"seul":"premier"," \xe0 participer au challenge"),en:"You ".concat(e?"were":"are"," the ").concat(e?"only one":"first"," to participate in the challenge")}),challengeOneParticipating:{fr:"Vous \xeates le premier \xe0 participer au challenge",en:"You are the first to participate"},challengeParticipantHistory:{fr:"l'ont r\xe9alis\xe9",en:"achieved it"},participantsTitle:{fr:"Participants",en:"Participants"},yourFavoriteRoutines:{fr:"Vos routines favorites",en:"Your favorite routines"},noFavoritesRoutines:{fr:"Vous n\u2019avez pas encore d\xe9fini de routines favorites. Explorez les routines et d\xe9finissez vos objectifs hebdomadaires.",en:"You haven't set any favorite routines yet. Explore the routines and set your weekly goals."},allRoutines:{fr:"Toutes les routines",en:"All the routines"},participantsDetails:{fr:"Participez pour d\xe9couvrir la liste",en:"Participate to discover the list"},nextIndividualChallenge:e=>({fr:"Prochain challenge individuel dans ".concat(ql("fr",e,!0),"."),en:"Next individual challenge in ".concat(ql("en",e,!0),".")}),nextCollectiveChallenge:e=>({fr:"Prochain challenge collectif dans ".concat(ql("fr",e,!0),". Pensez \xe0 utiliser le chat pour d\xe9couvrir les membres de votre \xe9quipe."),en:"Next Collective challenge in ".concat(ql("en",e,!0),". Consider using chat to find out about your team members.")}),noNextIndividualChallenge:{fr:"Vous n'avez aucun challenge \xe0 r\xe9aliser aujourd'hui. C'est le moment de d\xe9connecter !",en:"No individual challenge to do today. It's time to disconnect!"},noNextCollectiveChallenge:{fr:"Aucun challenge collectif en cours. Pensez \xe0 utiliser le chat pour \xe9changer avec les membres de votre \xe9quipe.",en:"No collective challenge in progress. Consider using chat to exchange with your team members."},noRoutineYetDone:{fr:"Vous n\u2019avez pas encore r\xe9alis\xe9 de routines quotidiennes aujourd\u2019hui",en:"You have not yet completed any daily routines today"},routinesDoneToday:(e,t,n)=>({fr:"Vos routines aujourd'hui : ".concat(e," action").concat(1===e?"":"s"," \xb7 ").concat(t," points").concat(n?" \xb7 ".concat(n," g \xe9q. CO2"):""),en:"Your routines today: ".concat(e," action").concat(1===e?"":"s"," \xb7 ").concat(t," points").concat(n?" \xb7 ".concat(n," g eq. CO2"):"")}),moreRoutines:e=>({fr:"".concat(e," de plus..."),en:"".concat(e," more...")}),soon:{fr:"quelques temps",en:"a while"},collectiveChallenge:{fr:"Challenge collectif",en:"Collective challenge"},myChallenge:{fr:"Mon challenge",en:"My challenge"},ourChallenge:{fr:"Notre challenge",en:"Our challenge"},myObjective:{fr:"Mon objectif",en:"My objective"},ourObjective:{fr:"Notre objectif",en:"Our objective"},inProgress:{fr:"Vous participez",en:"You participate"},collectiveChallengeGroup:{fr:"Mon \xe9quipe",en:"My team"},yourCollectiveChallengeGroup:{fr:"Votre \xe9quipe",en:"Your team"},members:e=>({fr:"".concat(e," membres"),en:"".concat(e," members")}),collectiveChallengeGroupDetail:{fr:"Ce challenge est \xe0 r\xe9aliser en \xe9quipe",en:"This challenge is to be carried out in teams"},dailyRoutine:{fr:"Routines quotidiennes",en:"Daily routines"},validate:{fr:"Valider",en:"Validate"},dailyRoutineConfirm:{fr:"Avez-vous r\xe9alis\xe9 cette routine aujourd'hui ?",en:"Have you completed this routine today?"},individualChallengeConfirm:{fr:"Avez-vous accompli ce challenge individuel ?",en:"Have you completed this individual challenge?"},collectiveChallengeConfirm:{fr:"Avez-vous accompli ce challenge collectif ?",en:"Have you completed this collective challenge?"},dailyRoutineDoneToday:{fr:"Routine r\xe9alis\xe9e aujourd'hui",en:"Routine completed today"},routinesAction:{fr:"Valider des routines",en:"Complete routines"},routinesChallenge:{fr:"Explorez les routines et d\xe9finissez vos actions quotidiennes favorites",en:"Explore routines and set your favorite daily actions"},stakesTitle:{fr:"Enjeux",en:"Stakes"},oddTitle:{fr:"Objectif de D\xe9veloppement Durable",en:"Sustainable Development Goals"},context:{fr:"Contexte",en:"Context"},co2Avoid:{fr:"\xe9quivalent CO2 \xe9vit\xe9s",en:"CO2 equivalent avoided"},pointEarned:e=>({fr:"pour ma communaut\xe9"+(e?"":" et mon association"),en:"for my community"+(e?"":" and my charity")}),addToFavorites:{fr:"Ajouter \xe0 vos favoris",en:"Add to favorites"},removeFromFavorites:{fr:"Supprimer des favoris",en:"Remove from favorites"},allFavoritesDone:{fr:"Tout valider",en:"Validate all"},allFavoritesDoneSucceed:{fr:"\ud83d\udc4f Bravo, vous avez r\xe9alis\xe9 toutes vos routines favorites aujourd\u2019hui",en:"Well done, you have completed all your favorite routines today"},pointsCollective:{fr:"vous devez \xeatre 50% de l'\xe9quipe \xe0 avoir r\xe9alis\xe9 ce challenge collectif pour comptabiliser vos points",en:"you must be 50% of the team to have completed this collective challenge to count your points"},timeLeft:{fr:"Temps restant",en:"Time left"},remainingTime:{fr:"pour r\xe9aliser ce challenge",en:"to complete this challenge"},yes:{fr:"Oui",en:"Yes"},no:{fr:"Non",en:"No"},goBack:{fr:"Quitter",en:"Go back"},noThanks:{fr:"Non merci",en:"No thank you"},congrats:{fr:"F\xe9licitations !",en:"Congratulations! "},shared:{fr:"Partager sur le fil d'actualit\xe9",en:"Share on the news feed"},letsGo:{fr:"C'est parti !",en:"Let's go!"},copyEmail:{fr:"Copier les adresses e-mails",en:"Copy email addresses"},impactResult:(e,t)=>{let n="";return e&&(n+=e+"g \xe9q. CO2 \u2022 "),n+=t+" pt"+(1!==t?"s":""),{fr:n,en:n}},hour:e=>({fr:Math.round(e)+" heures",en:Math.round(e)+" hours"}),points:e=>({fr:e+" points",en:e+" points"}),gram:e=>({fr:e+" grammes",en:e+" grams"}),routinesDo:e=>({fr:e+"/2 routines r\xe9alis\xe9e"+(1!==e?"s":"")+" aujourd'hui",en:e+"/2 routines completed"}),challengeResult:(e,t,n)=>{const r=(e?e+"g \xe9q. CO2 \u2022 ":"")+t+" pts \u2022 ";return{fr:r+ql("fr",n,!0),en:r+ql("en",n,!0)}},startDate:(e,t,n)=>{if(!n)return Xl(e,t);const r=Math.floor((t-Date.now())/1e3/3600);if(r<0)return Xl(e,t);const o=Math.floor(r/24),i=o%30,a=Math.floor(o/30)%12,s={fr:"",en:""};return 0!==a&&(s.fr="".concat(a," mois"),s.en="".concat(a," month").concat(1!==a?"s":"")),0!==i?(s.fr&&(s.fr+=" et "),s.fr+="".concat(i," jour").concat(1!==i?"s":""," restants"),s.en&&(s.en+=" and "),s.en+="".concat(i," day").concat(1!==i?"s":""," left")):0===a?r?(s.fr="moins d'une heure restante",s.en="less than one hour left"):(s.fr="".concat(r," heure").concat(1!==r?"s":""," restante").concat(1!==r?"s":""),s.en="".concat(r," hour").concat(1!==r?"s":""," left")):(s.fr+=" restant".concat(1!==a?"s":""),s.en+=" left"),s},projectAccomplished:e=>({fr:e>100?"Compl\xe9t\xe9":"".concat(e,"% accompli"),en:e>100?"Completed":"".concat(e,"% completed")}),historyTitle:{fr:"Historique de vos actions",en:"Your actions history"},historyChallengeCollective:{fr:"Collectif",en:"Collective"},historyChallengeIndividual:{fr:"Individuel",en:"Individual"},historyPoints:{fr:"points",en:"points"},historyTimes:e=>({fr:e+" fois",en:e+" time"+(e>1?"s":"")}),historyRoutinesCompleted:e=>({fr:"".concat(e," routine").concat(e>1?"s":""," r\xe9alis\xe9e").concat(e>1?"s":""),en:"".concat(e," routine").concat(e>1?"s":""," completed")}),historyChallengesCompleted:e=>({fr:"".concat(e," challenge").concat(e>1?"s":""," r\xe9alis\xe9").concat(e>1?"s":""),en:"".concat(e," challenge").concat(e>1?"s":""," completed")}),goToChat:{fr:"Ouvrir le chat d'\xe9quipe",en:"Open the team chat"},participate:e=>({fr:1===e?"participe":"participent",en:1===e?"participates":"participate"})},vf=e=>{const t=d.useContext(yn.S),o=(0,f.Yi)(),[i,a]=d.useState(!1);return(0,An.jsxs)(p.c,{style:{padding:24},children:[(0,An.jsx)(cn.c,{onPress:()=>{"web"===r.default.OS?a(!0):(console.log(e.users),o.navigate(ln.g.CHAT_MEMBERS,{users:e.users,standalone:!0}))},children:(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center"},children:[(0,An.jsxs)(p.c,{style:{flex:1},children:[(0,An.jsx)(En,{style:[pr.h4,fr.blue_dark],children:(0,hn._)(nu(e.users.filter((e=>!e.deleted)).length))}),(0,An.jsx)(En,{style:[pr.body2,fr.grey2,tl.out_bottom_m],children:(0,hn._)(ru)}),(0,An.jsx)(Jp,{users:e.users,max:5,bgColor:u.y.BLUE_LIGHT_X,color:u.y.BLUE_DARK,bgColorPlus:u.y.BLUE_LIGHT_X,size:35})]}),(0,An.jsx)(le.c,{style:{height:24,width:24},source:n(9820)})]})}),(0,An.jsx)(p.c,{style:[{marginTop:24},t.expanded?{alignSelf:"flex-start"}:{}],children:(0,An.jsx)(mf,{text:(0,hn._)(yf.goToChat),unreadMessages:e.unreadMessages})}),"web"===r.default.OS&&(0,An.jsx)(yc,{isVisible:i,hide:()=>a(!1),color:"white",margin:30,content:(0,An.jsx)(Pc,{title:(0,hn._)(Xc),titleStyle:[pr.h2,fr.black,tl.out_bottom_m],users:e.users,size:40,color:u.y.BLUE_DARK,bgColor:u.y.BLUE_LIGHT_X,userTeam:!0})})]})},bf=e=>{var t,n,r,o,i,a,s,l,c;const h=d.useContext(yn.S);return(0,An.jsxs)(p.c,{style:[h.expanded?{marginRight:"auto",maxWidth:"48%",flex:1}:{marginTop:8}],children:[(0,An.jsx)(En,{style:[pr.h2,tl.out_bottom_m,h.expanded?{}:tl.out_top_m],children:(0,hn._)(Xc)}),(0,An.jsxs)(p.c,{style:{borderRadius:16,borderColor:u.y.PURPLE_LIGHT,borderWidth:1},children:[(0,An.jsxs)(p.c,{style:{backgroundColor:u.y.PURPLE_LIGHT,borderTopLeftRadius:16,borderTopRightRadius:16,padding:h.expanded?24:16},children:[(0,An.jsxs)(p.c,{style:[{flexDirection:"row",alignItems:"center"}],children:[(0,An.jsx)(Rn,{style:[tl.out_right_m],size:h.expanded?50:40,bgColor:"white",color:u.y.BLUE_DARK,name:null===(t=e.teams)||void 0===t||null===(n=t[e.current])||void 0===n?void 0:n.name,source:null===(r=e.teams)||void 0===r||null===(o=r[e.current])||void 0===o?void 0:o.picture}),(0,An.jsx)(En,{style:[pr.h4,fr.blue_dark,{maxWidth:h.expanded?"95%":250}],children:(0,hn._)(null===(i=e.teams)||void 0===i||null===(a=i[e.current])||void 0===a?void 0:a.name)})]}),(0,An.jsx)(En,{style:[pr.h3,fr.blue_dark,tl.out_top_s],children:(0,hn._)(Jc(null===(s=e.teams)||void 0===s||null===(l=s[e.current])||void 0===l?void 0:l.points))}),(0,An.jsx)(En,{style:[pr.body2,fr.grey2],children:(0,hn._)(Zc(e.ratio))})]}),(0,An.jsxs)(p.c,{children:[(0,An.jsx)(gf,{teams:e.teams,current:e.current,members:e.members}),(0,An.jsx)(yr,{height:1,color:u.y.GREY_LIGHT,minWidth:"100%",style:{paddingLeft:24,paddingRight:24}}),(0,An.jsx)(vf,{users:null===(c=e.members)||void 0===c?void 0:c[e.current],unreadMessages:e.unreadMessages})]})]})]})},Af={fr:"Membres de ma communaut\xe9",en:"My community members"},xf={fr:"Voici les membres de votre communaut\xe9 qui soutiennent le m\xeame projet que vous",en:"Here are the members of your community who support the same project as you"},Sf=b.c.create({BackgroundBlueLight:{backgroundColor:u.y.BLUE_LIGHT_X},InLineContent:{flex:1,flexDirection:"row"},TextBlueDark:{color:u.y.BLUE_DARK}}),wf=e=>{var t,o;const i=d.useContext(yn.S),a=!(null===(t=i.profile)||void 0===t||null===(o=t.company)||void 0===o||!o.forcePoints),{push:s}=(0,f.Yi)(),[l,c]=d.useState(!1),[h,g]=d.useState(!1),m={...e.community.project,organization:e.community.organization};return(0,An.jsxs)(p.c,{style:[i.expanded?{flex:1}:{marginTop:8}],children:[(0,An.jsxs)(p.c,{children:[(0,An.jsx)(En,{style:[pr.h2,tl.out_bottom_m,i.expanded?{}:tl.out_top_m],children:(0,hn._)(ou)}),(0,An.jsxs)(p.c,{children:[(0,An.jsxs)(p.c,{style:[Sf.BackgroundBlueLight,{borderTopLeftRadius:16,borderTopRightRadius:16,padding:i.expanded?24:16}],children:[(0,An.jsx)(En,{style:[pr.h3,fr.blue_dark,tl.out_bottom_s],children:(0,hn._)(e.community.project.name)}),(0,An.jsx)(p.c,{style:[{backgroundColor:u.y.WHITE,paddingBottom:4,paddingTop:2,paddingLeft:6,paddingRight:6,alignSelf:"flex-start"},tl.out_bottom_s],children:(0,An.jsx)(En,{style:[pr.caption,fr.blue_dark],children:(0,hn._)(e.community.project.tag)})}),(0,An.jsxs)(p.c,{style:[Sf.InLineContent,i.expanded?{marginTop:4,marginBottom:4}:{marginTop:8,marginBottom:8}],children:[(0,An.jsx)(p.c,{style:{borderColor:u.y.BLUE_LIGHT,borderWidth:1,borderRadius:50,marginRight:10},children:(0,An.jsx)(Rn,{size:i.expanded?50:40,bgColor:"white",color:u.y.BLUE_DARK,name:e.community.organization.name,source:e.community.organization.picture})}),(0,An.jsx)(En,{style:[i.expanded?{alignSelf:"center",marginLeft:5,fontSize:20,fontWeight:"bold"}:{alignSelf:"center",marginLeft:5},pr.h4,fr.blue_dark],children:e.community.organization.name})]}),(0,An.jsx)(xl,{children:(0,hn._)(cu),textColor:u.y.BLUE_DARK,fontWeight:"700",fontSize:14,style:{borderColor:u.y.BLUE_DARK,maxWidth:130,marginTop:8,marginBottom:2},onPress:()=>{"web"===r.default.OS?g(!0):s(ln.g.PROJECT_INFO,{project:{data:m}})}})]}),(0,An.jsxs)(p.c,{style:{borderWidth:2,borderBottomLeftRadius:16,borderBottomRightRadius:16,borderColor:u.y.BLUE_LIGHT_X,padding:i.expanded?24:16},children:[(0,An.jsxs)(p.c,{children:[(0,An.jsx)(En,{style:[fr.blue_dark,pr.h4],children:(0,hn._)(iu(mu(e.community.earned),a))}),(0,An.jsx)(En,{style:[pr.body2,fr.grey2,tl.out_top_xs],children:(0,hn._)(au(mu(e.community.points)))})]}),(0,An.jsx)(yr,{style:{marginTop:i.expanded?24:16},color:u.y.GREY_LIGHT_X,height:1,minWidth:"100%"}),(0,An.jsx)(cn.c,{style:{flex:1},onPress:()=>{"web"===r.default.OS?c(!0):s(ln.g.COMMUNITY_MEMBERS,{users:e.community.users})},children:(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center"},children:[(0,An.jsxs)(p.c,{style:{flex:1},children:[(0,An.jsxs)(p.c,{style:[{marginTop:i.expanded?24:16}],children:[(0,An.jsx)(En,{style:[Sf.TextBlueDark,pr.h4],children:(0,hn._)(su(mu(e.community.users.length)))}),(0,An.jsx)(En,{style:[pr.body2,fr.grey2,tl.out_top_xs,tl.out_bottom_m],children:(0,hn._)(lu)})]}),(0,An.jsx)(Jp,{users:e.community.users,bgColor:u.y.BLUE_LIGHT_X,color:u.y.BLUE_DARK,bgColorPlus:u.y.BLUE_LIGHT_X,max:5,size:35})]}),(0,An.jsx)(le.c,{style:{height:24,width:24},source:n(9820)})]})})]})]})]}),"web"===r.default.OS&&(0,An.jsx)(yc,{isVisible:l,hide:()=>c(!1),color:u.y.WHITE,content:(0,An.jsx)(Pc,{users:e.community.users,bgColor:u.y.BLUE_LIGHT_X,color:u.y.BLUE_DARK,size:50,title:(0,hn._)(Af),description:(0,hn._)(xf),titleStyle:[pr.h2,fr.black,tl.out_bottom_m],textStyle:[pr.body1,fr.black]})}),"web"===r.default.OS&&(0,An.jsx)(yc,{isVisible:h,hide:()=>g(!1),color:u.y.WHITE,content:(0,An.jsx)(cf,{data:m})})]})},Cf=e=>{var t,n,r,o,i,a,l,c;const h=d.useContext(yn.S),f=!(null===(t=h.profile)||void 0===t||null===(n=t.company)||void 0===n||!n.forcePoints),[g,m]=d.useState(void 0);return d.useEffect((()=>{let e=!0;return s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:impact"}).execute().then((t=>{e&&m(t)})),()=>{e=!1}}),[]),"undefined"===typeof g?(0,An.jsx)(p.c,{}):(0,An.jsxs)(p.c,{style:g.community&&h.expanded?{alignSelf:"center"}:{},children:[(0,An.jsx)(bu,{picture:null===(r=g.company)||void 0===r?void 0:r.picture,startDate:null===(o=g.company)||void 0===o?void 0:o.startDate,date:Date.now(),showUpdateText:e.showUpdateText}),"undefined"===typeof e.goToAdmin&&(0,An.jsx)(p.c,{})||(0,An.jsx)(p.c,{style:[bn.align_item_center],children:(0,An.jsxs)(p.c,{style:[bn.horizontal,bn.align_item_center,{justifyContent:"center",borderColor:u.y.GREY1,borderWidth:1,borderRadius:60},h.expanded?{width:"fit-content",paddingLeft:8,paddingRight:8,paddingTop:4,paddingBottom:4}:{width:"100%",paddingLeft:6,paddingRight:6}],children:[(0,An.jsx)(p.c,{style:[{backgroundColor:u.y.BLUE_DARK,borderRadius:49,borderWidth:1,borderColor:u.y.BLUE_DARK,padding:8},h.expanded?{width:180,marginRight:8}:{flex:1}],children:(0,An.jsx)(un.c,{style:[pr.h5,fr.white,{textAlign:"center"}],children:(0,hn._)(Uc)})}),(0,An.jsx)(xl,{onPress:e.goToAdmin,children:(0,hn._)(Fc),textColor:u.y.BLUE_DARK,fontWeight:"600",style:[{shadowOpacity:0},h.expanded?{width:180,padding:8,height:41}:{flex:1,padding:6}]})]})}),(0,An.jsx)(p.c,{style:{width:"100%",maxWidth:1050,marginTop:24,marginLeft:"auto",marginRight:"auto"},children:(0,An.jsx)(df,{company:g.company,community:g.community})}),(0,An.jsxs)(p.c,{style:[{maxWidth:1050,marginLeft:"auto",marginRight:"auto",width:"100%"},h.expanded?{marginTop:36,marginBottom:24,flex:1,flexDirection:"row"}:{}],children:[(0,An.jsx)(bf,{teams:(null===(i=g.teams)||void 0===i?void 0:i.all)||[],current:null===(a=g.teams)||void 0===a?void 0:a.current,ratio:null===(l=g.teams)||void 0===l?void 0:l.ratio,members:null===(c=g.teams)||void 0===c?void 0:c.members,unreadMessages:g.unreadMessages}),(0,An.jsx)(hf,{user:g.user})]}),g.community&&!g.company.campaigns&&!f&&(0,An.jsx)(p.c,{style:[h.expanded?{maxWidth:"48%",marginRight:"auto"}:{},{marginBottom:24}],children:(0,An.jsx)(wf,{community:g.community})})]})},_f=()=>{var e;const t=d.useContext(yn.S),[n,r]=d.useState(0),[o,i]=d.useState(!1),[a,l]=d.useState(!(null===t||void 0===t||null===(e=t.profile)||void 0===e||!e.can_submit_on_company));return d.useEffect((()=>{s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:users/isAdmin"}).execute().then((e=>{l(e.admin),i(!0)}))}),[]),o?a?(0,An.jsx)(p.c,{style:[tl.out_top_l],children:0===n&&(0,An.jsx)(Cf,{goToAdmin:()=>r(1),showUpdateText:!1})||(0,An.jsx)(Uu,{goToUser:()=>r(0),showUpdateText:!0})}):(0,An.jsx)(Cf,{showUpdateText:!1}):(0,An.jsx)(p.c,{})},Ef=e=>{const t=d.useContext(yn.S);return(0,An.jsx)(p.c,{style:[pf.alignCenter,t.expanded?{marginTop:24}:{marginTop:16}],children:(0,An.jsxs)(p.c,{style:[pf.blueLightBackground,pf.fullWidth,{borderRadius:10},t.expanded?{height:"100%",padding:24,justifyContent:"space-around"}:{padding:16}],children:[(0,An.jsx)(un.c,{style:[pr.h3,fr.blue_dark],children:(0,hn._)(e.partnerLink.title)}),(()=>{if(e.partnerLink.description)return(0,An.jsx)(un.c,{style:[pr.body1,fr.blue_dark,tl.out_top_m],children:(0,hn._)(e.partnerLink.description)})})(),(0,An.jsx)(p.c,{style:pf.alignCenter,children:(0,An.jsx)(xl,{style:[t.expanded?{minWidth:200,maxWidth:320,alignSelf:"center",marginTop:10}:{minWidth:150,maxWidth:300,marginTop:16},"web"===r.default.OS?{shadowColor:"none"}:{},{paddingLeft:12,paddingRight:12}],fontSize:16,fontWeight:"700",color:u.y.WHITE,textColor:u.y.BLUE_DARK,onPress:()=>(0,l.kB)((0,hn._)(e.partnerLink.url).trim()),side:(0,An.jsx)(le.c,{source:n(4648),style:{width:14,height:14,marginLeft:7}}),children:(0,hn._)(e.partnerLink.button)})})]})})},Rf=e=>{const t=d.useContext(yn.S),n=e.participants.filter((e=>!e.deleted)),o=1===n.length&&n[0].id===t.profile.id,i=n.filter((e=>e.id!==t.profile.id));return(0,An.jsx)(p.c,{style:[bn.horizontal,t.expanded||"web"!==r.default.OS?{}:{flexWrap:"wrap",maxWidth:"100%"}],children:(e.challengeInProgress||e.challengeEnded)&&(0,An.jsxs)(p.c,{style:[bn.horizontal,bn.align_item_center,t.expanded||"web"!==r.default.OS?{}:{flexWrap:"wrap",maxWidth:"100%"}],children:[!o&&(0,An.jsx)(Jp,{users:i.map((e=>({name:e.name,picture:e.picture}))),size:24,color:u.y.BLACK,bgColor:u.y.PURPLE_LIGHT,bgColorPlus:u.y.WHITE,max:4,widthChip:24,heightChip:24,marginRight:8,borderColorPlus:u.y.GREY1,borderWidthPlus:1}),(0,An.jsx)(En,{style:[t.expanded||"web"!==r.default.OS?{}:{marginTop:2},e.textStyle||pr.body2,e.colorText?{color:e.colorText}:fr.white],children:(0,hn._)(o?yf.challengeParticipantsAlone(e.challengeEnded):yf.challengeParticipantsInProgress(i.length,e.challengeEnded))})]})||(0,An.jsx)(En,{style:[e.textStyle||pr.body2,e.colorText?{color:e.colorText}:fr.white],children:(0,hn._)(yf.challengeParticipants(i.length))+(e.introText||"")})})},kf=e=>{let{history:t,setCurrentChallenge:r}=e;const o=d.useContext(yn.S);return(0,An.jsxs)(p.c,{style:[bn.separator_top_grey,tl.out_top_l],children:[(0,An.jsx)(un.c,{style:[pr.h2,tl.out_top_l],children:(0,hn._)(yf.historyTitle)}),(0,An.jsxs)(p.c,{style:o.expanded?{flexDirection:"row",justifyContent:"space-between"}:{},children:[(0,An.jsx)(p.c,{style:[o.expanded?{width:"48%"}:{},tl.out_top_l],children:null!==t&&void 0!==t&&t.challenges?(0,An.jsxs)(p.c,{style:bn.separator_bottom_grey,children:[(0,An.jsx)(un.c,{style:[pr.h3,tl.out_bottom_m],children:(0,hn._)(yf.historyChallengesCompleted(t.challenges.length))}),t.challenges.map(((e,t)=>(0,An.jsxs)(cn.c,{style:[bn.separator_top_grey,tl.out_bottom_m],onPress:()=>r(e.id),children:[(0,An.jsxs)(p.c,{style:[bn.horizontal,bn.full_width,tl.out_top_m],children:[e.collective?(0,An.jsxs)(p.c,{style:[bn.flex1,bn.horizontal],children:[(0,An.jsx)(le.c,{source:n(3046),style:{width:16,height:16,marginRight:8}}),(0,An.jsx)(un.c,{style:[pr.h6,fr.purple,tl.out_bottom_xs],children:(0,hn._)(yf.historyChallengeCollective)})]}):(0,An.jsxs)(p.c,{style:[bn.flex1,bn.horizontal],children:[(0,An.jsx)(le.c,{source:n(8176),style:{width:16,height:16,marginRight:8}}),(0,An.jsx)(un.c,{style:[pr.h6,fr.green,tl.out_bottom_xs],children:(0,hn._)(yf.historyChallengeIndividual)})]}),(0,An.jsx)(un.c,{style:[pr.body2,fr.grey2],children:Jl(e.date)})]}),(0,An.jsx)(un.c,{style:[pr.h4,bn.flex1,e.collective?fr.purple:fr.green],children:(0,hn._)(e.name)}),(0,An.jsxs)(p.c,{style:[bn.horizontal,tl.out_bottom_s,{alignItems:"flex-end"}],children:[e.odds.map(((e,t)=>(0,An.jsx)(p.c,{style:[bn.flex1],children:(0,An.jsx)(un.c,{style:[pr.body2,fr.grey2,bn.flex1],children:(0,hn._)(ju(Number(e)))})},t))),(0,An.jsxs)(un.c,{style:[pr.h4,fr.grey2],children:[e.points," ",(0,hn._)(yf.historyPoints)]})]}),(0,An.jsx)(Rf,{participants:e.users,challengeEnded:!0,colorText:u.y.GREY2})]},t)))]}):(0,An.jsx)(p.c,{})}),(0,An.jsx)(p.c,{style:[o.expanded?{width:"48%"}:{},tl.out_top_l],children:null!==t&&void 0!==t&&t.routines?(0,An.jsxs)(p.c,{style:bn.separator_bottom_grey,children:[(0,An.jsx)(un.c,{style:[pr.h3,tl.out_bottom_m],children:(0,hn._)(yf.historyRoutinesCompleted(t.routines.reduce(((e,t)=>e+t.count),0)))}),t.routines.map(((e,t)=>{var n;return(0,An.jsxs)(p.c,{style:[bn.separator_top_grey,tl.out_bottom_m],children:[(0,An.jsxs)(p.c,{style:[bn.horizontal,bn.full_width,tl.out_top_m],children:[(0,An.jsx)(un.c,{style:[pr.h4,fr.orange,bn.flex1],children:(0,hn._)(e.name)}),(0,An.jsx)(un.c,{style:[pr.body2,fr.grey2],children:(0,hn._)(yf.historyTimes(e.count))})]}),(0,An.jsxs)(p.c,{style:[bn.horizontal,{alignItems:"flex-end"}],children:[null===e||void 0===e||null===(n=e.odd)||void 0===n?void 0:n.map(((e,t)=>(0,An.jsx)(p.c,{style:[bn.flex1],children:(0,An.jsx)(un.c,{style:[pr.body2,fr.grey2,bn.flex1],children:(0,hn._)(ju(Number(e)))})},t))),(0,An.jsxs)(un.c,{style:[pr.h4,fr.grey2],children:[e.points," ",(0,hn._)(yf.historyPoints)]})]})]},t)}))]}):(0,An.jsx)(p.c,{})})]})]})},If=e=>{const t=d.useContext(yn.S);if(2===e.data.status)return(0,An.jsx)(p.c,{});const o=e.data.users.filter((e=>!e.deleted));return(0,An.jsxs)(cn.c,{style:{marginBottom:t.expanded?24:16,borderRadius:16},onPress:()=>e.setCurrentChallenge(e.index),children:[!!e.data.cover&&(0,An.jsx)(le.c,{source:{uri:e.data.cover},resizeMode:"cover",style:{position:"absolute",width:"100%",height:"100%",borderRadius:16,borderWidth:1,borderColor:"white"}}),(0,An.jsx)(p.c,{style:{backgroundColor:"black",opacity:.5,position:"absolute",width:"100%",height:"100%",borderRadius:16,borderWidth:1,borderColor:"white"}}),(0,An.jsxs)(p.c,{style:{padding:24},children:[(0,An.jsxs)(p.c,{style:[bn.horizontal,bn.align_item_center],children:[(0,An.jsxs)(p.c,{style:[bn.horizontal,bn.flex1],children:[!!e.data.kind&&(0,An.jsx)(le.c,{style:{height:16,width:16,marginRight:6},source:(()=>{switch(e.data.kind){case Vf.awareness:return n(3796);case Vf.test:return n(1896);case Vf.embody:return n(4312);case Vf.transform:return n(7604)}})()}),(0,An.jsx)(En,{style:[pr.caption,fr.white],children:(()=>{switch(e.data.kind){case Vf.awareness:return(0,hn._)(yf.tagAwerness);case Vf.test:return(0,hn._)(yf.tagTest);case Vf.embody:return(0,hn._)(yf.tagEmbody);case Vf.transform:return(0,hn._)(yf.tagTransform)}})()})]}),(0,An.jsx)(le.c,{style:{height:24,width:24},source:e.data.isCollective?n(2064):n(9372)})]}),(0,An.jsx)(En,{style:[pr.h3,fr.white,tl.out_bottom_m,tl.out_top_m,t.expanded?{textAlign:"center",marginBottom:24}:{marginBottom:16},{maxWidth:500,alignSelf:"center",width:"100%"}],children:(0,hn._)(e.data.name)}),(0,An.jsxs)(p.c,{style:[bn.horizontal,bn.flex1,t.expanded||"web"!==r.default.OS?{}:{flexWrap:"wrap"}],children:[(0,An.jsxs)(p.c,{style:[bn.horizontal,{flex:1},t.expanded||"web"!==r.default.OS?{}:{minWidth:150,marginBottom:6}],children:[(0,An.jsx)(le.c,{style:{height:24,width:24},source:n(456)}),(0,An.jsx)(En,{style:[fr.white,pr.h5,tl.out_left_xs],children:ql(hn.O.get(),(e.data.end_date-Date.now())/1e3,!0)})]}),(0,An.jsxs)(p.c,{style:[bn.horizontal,t.expanded||"web"!==r.default.OS?{}:{marginBottom:6},{alignItems:"center"}],children:[(0,An.jsx)(Jp,{users:o.map((e=>({name:e.name,picture:e.picture}))),size:24,color:u.y.BLACK,bgColor:u.y.PURPLE_LIGHT,bgColorPlus:u.y.WHITE,max:2,widthChip:24,heightChip:24,marginRight:8,borderColorPlus:u.y.GREY1,borderWidthPlus:1}),0!==o.length&&(0,An.jsx)(un.c,{children:(0,hn._)(yf.participate(o.length)),style:{color:u.y.WHITE}})]})]})]})]})},Tf=e=>{const t=d.useContext(yn.S),o=d.useRef(null),i=t=>{var n;e.setCurrentSection(1,t),null===(n=o.current)||void 0===n||n.scrollTo({y:0,x:0,animated:!1})};return(0,An.jsxs)(p.c,{style:[{width:"100%",alignSelf:"center"},t.expanded?{maxWidth:1050}:{},pf.marginBottomBig],children:[(0,An.jsx)(En,{style:[pr.h2,fr.black,{marginTop:24,marginBottom:24}],children:(0,hn._)(yf.intoAction)}),(0,An.jsxs)(p.c,{children:[e.data.challenges.current.map(((t,n)=>(0,An.jsx)(If,{index:n,data:t,setCurrentChallenge:i,team:e.data.challenges.team,reload:e.reload,unreadMessages:e.data.messages.unread,ignoreMargin:!0},n))),(0,An.jsxs)(p.c,{style:[pf.collectiveChallengeCard,{backgroundColor:u.y.YELLOW_DARK,borderRadius:10},t.expanded?{padding:24,justifyContent:"space-around"}:{padding:16}],children:[(0,An.jsxs)(p.c,{style:[pf.cardMainTitle],children:[(0,An.jsx)(le.c,{style:pf.cardMainTitleImage,source:n(4844)}),(0,An.jsx)(En,{style:[pr.h3,fr.black,pf.marginLeft],children:(0,hn._)(yf.dailyRoutine)})]}),0===e.data.routines.done.length&&(0,An.jsx)(En,{style:[tl.out_top_m,pr.h4,fr.black],children:(0,hn._)(yf.noRoutineYetDone)}),0===e.data.routines.done.length&&(0,An.jsx)(En,{style:[tl.out_top_m,pr.body1,fr.black],children:(0,hn._)(yf.routinesChallenge)}),0!==e.data.routines.done.length&&(0,An.jsx)(En,{style:[pr.h4,fr.black,tl.out_top_m],children:(0,hn._)(yf.routinesDoneToday(e.data.routines.done.length,e.data.routines.done.reduce(((t,n)=>{var r;return t+((null===(r=e.data.routines.data[n])||void 0===r?void 0:r.points)||0)}),0),e.data.routines.done.reduce(((t,n)=>{var r;return t+((null===(r=e.data.routines.data[n])||void 0===r?void 0:r.co2)||0)}),0)))}),(0,An.jsxs)(p.c,{style:[{flexDirection:"column",alignItems:"baseline"},tl.out_top_m],children:[e.data.routines.done.slice(0,3).filter((t=>e.data.routines.data[t])).map(((t,r)=>(0,An.jsxs)(p.c,{style:{width:"100%",alignSelf:"center",flexDirection:"row"},children:[(0,An.jsx)(le.c,{style:{height:16,width:16,alignContent:"center",alignSelf:"center",marginRight:4},source:n(6404)}),(0,An.jsx)(En,{style:[fr.black,pr.body2,{textAlign:"center"}],children:(0,hn._)(e.data.routines.data[t].name)})]},r))),e.data.routines.done.length>3&&(0,An.jsx)(En,{style:[tl.out_top_s,pr.body2,fr.black],children:(0,hn._)(yf.moreRoutines(e.data.routines.done.length-3))})]}),(0,An.jsx)(p.c,{style:pf.alignCenter,children:(0,An.jsx)(xl,{color:u.y.WHITE,textColor:u.y.BLACK,fontSize:16,fontWeight:"700",sideLeft:(0,An.jsx)(le.c,{source:n(1056),style:{height:24,width:24,marginRight:8}}),style:[{minWidth:130,maxWidth:320,alignSelf:t.expanded?"flex-end":"flex-start"},"web"===r.default.OS?{shadowColor:"none"}:{},{paddingLeft:10,paddingRight:10},t.expanded?{marginTop:-16}:{marginTop:16}],onPress:()=>{var t;null===(t=o.current)||void 0===t||t.scrollTo({y:0,x:0,animated:!1}),e.setCurrentSection(2)},children:(0,hn._)(yf.routinesAction)})})]}),(t=>{if(null!==(t=e.data.company)&&void 0!==t&&t.partnerLink)return(0,An.jsx)(Ef,{partnerLink:e.data.company.partnerLink})})()]}),(0,An.jsx)(kf,{history:e.data.history,setCurrentChallenge:i})]})},Of=b.c.create({mainContainer:{width:"100%",alignSelf:"center",maxWidth:1250},backgroundRed:{backgroundColor:u.y.ORANGE,borderRadius:16},h1:{fontSize:24,fontWeight:"600",textAlign:"center",color:u.y.WHITE},h2:{fontSize:22,fontWeight:"600",textAlign:"left",color:u.y.ORANGE},h3:{fontSize:20,textAlign:"left",color:u.y.BLACK},h4:{fontSize:18,fontWeight:"700",color:u.y.BLACK},h4Red:{fontSize:18,fontWeight:"700",textAlign:"left",color:u.y.ORANGE},text:{fontSize:16,fontWeight:"400",textAlign:"left",color:u.y.BLACK},subTitle:{fontSize:18,fontWeight:"300",textAlign:"center",color:u.y.WHITE,maxWidth:300},routines:{fontSize:18,fontWeight:"700",textAlign:"center",color:u.y.WHITE},fullSize:{flex:1},marginTopBig:{marginTop:25},marginTopMedium:{marginTop:10},marginTopSmall:{marginTop:5},marginBottomBig:{marginBottom:20},marginRightLeft:{marginRight:8,marginLeft:8},emojiSize:{fontSize:35}}),jf={fr:"Enjeu :",en:"Issue:"};function Pf(e){const t=d.useContext(yn.S);return(0,An.jsxs)(p.c,{children:[(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center"},children:[e.done&&(0,An.jsx)(le.c,{style:{height:24,width:24,alignContent:"center",marginRight:16,marginTop:8},source:n(6404)})||(0,An.jsx)(cn.c,{onPress:()=>{e.setCurrentRoutineId(e.routineId,!0),e.openValidationModalOpen()},children:(0,An.jsx)(le.c,{style:{height:24,width:24,alignContent:"center",marginRight:16,marginTop:8},source:n(6628)})}),(0,An.jsx)(cn.c,{style:{flex:1},onPress:()=>{e.setCurrentRoutineId(e.currentRoutineId!==e.routineId?e.routineId:-1)},children:(0,An.jsxs)(p.c,{style:[tl.out_top_m,{flexDirection:"row",alignItems:"center",borderBottomColor:u.y.GREY1,borderBottomWidth:1,paddingBottom:6}],children:[(0,An.jsx)(En,{style:[pr.h3,Of.fullSize,fr.black],children:(0,hn._)(e.data.name)}),(0,An.jsxs)(p.c,{style:{flexDirection:"row"},children:[e.favorites&&(0,An.jsx)(le.c,{style:{height:24,width:24,marginRight:8},source:n(5580)}),(0,An.jsx)(le.c,{style:{height:24,width:24,alignContent:"center"},source:e.currentRoutineId===e.routineId?n(6496):n(3724)})]})]})})]}),e.currentRoutineId===e.routineId&&(0,An.jsxs)(p.c,{children:[(0,An.jsx)(En,{style:[pr.body1,fr.black,tl.out_top_m],children:(0,hn._)(e.data.description)}),(0,An.jsx)(En,{style:[pr.h5,fr.black,tl.out_top_m],children:(0,hn._)(jf)}),(0,An.jsx)(En,{style:[pr.body1,fr.black,tl.out_top_s],children:(0,hn._)(e.data.context)}),(0,An.jsx)(p.c,{style:{flexDirection:"row",alignItems:"center",marginTop:8},children:(0,An.jsx)(En,{style:[pr.h4,fr.black],children:(0,hn._)(yf.impactResult(e.data.co2,e.data.points))})}),(0,An.jsxs)(p.c,{style:[{flexDirection:t.expanded?"row":"column",alignItems:"center"},tl.out_top_m,tl.out_bottom_l],children:[e.done?(0,An.jsxs)(p.c,{style:[{flexDirection:"row",alignItems:"center"},tl.out_top_m,tl.out_bottom_m],children:[(0,An.jsx)(le.c,{style:{height:24,width:24,alignContent:"center",marginRight:8},source:n(1056)}),(0,An.jsx)(En,{style:[pr.h4,fr.black,tl.out_right_l],children:(0,hn._)(yf.dailyRoutineDoneToday)})]}):(0,An.jsx)(xl,{onPress:()=>e.openValidationModalOpen(),children:(0,hn._)(yf.validate),color:u.y.YELLOW_DARK,textColor:u.y.BLACK,fontWeight:"700",style:{alignSelf:"center",paddingLeft:16,paddingRight:16,marginRight:16,marginBottom:t.expanded?0:16},sideLeft:(0,An.jsx)(le.c,{source:n(1056),style:{height:24,width:24,marginRight:8}})}),(0,An.jsx)(xl,{onPress:()=>e.setFavorite(e.routineId),children:(0,hn._)(e.favorites?yf.removeFromFavorites:yf.addToFavorites),color:u.y.WHITE,textColor:u.y.BLACK,fontWeight:"700",style:{borderColor:u.y.BLACK,borderRadius:25,borderWidth:1,paddingLeft:16,paddingRight:16}})]})]})]})}const Bf=e=>{const t=d.useContext(yn.S),n=e.getReward();return(0,An.jsx)(sc,{width:"90%",onClose:e.onClose,handler:e.hide,children:(0,An.jsxs)(p.c,{style:lc.modalContainer,children:[(0,An.jsx)($l,{style:[tl.out_bottom_m,{fontSize:48}],children:"\ud83d\udc4f"}),(0,An.jsx)(En,{style:[bn.text_center,fr.black,pr.h2,tl.out_bottom_m],children:(0,hn._)(yf.congrats)}),(0,An.jsxs)(p.c,{style:lc.resultZone,children:[n.co2?(0,An.jsxs)(p.c,{children:[(0,An.jsx)(En,{style:[t.expanded?pr.h1Expanded:pr.h1,{color:e.themeColor}],children:(0,hn._)(yf.gram(n.co2))}),(0,An.jsx)(En,{style:[fr.grey2],children:(0,hn._)(yf.co2Avoid)})]}):null,n.co2?(0,An.jsx)(yr,{style:lc.separatorMarge,color:u.y.GREY1,height:1,minWidth:"100%"}):null,(0,An.jsxs)(p.c,{children:[(0,An.jsx)(En,{style:[t.expanded?pr.h1Expanded:pr.h1,{color:e.themeColor}],children:(0,hn._)(yf.points(e.collective&&!e.challengeDone?0:n.points))}),(0,An.jsx)(En,{style:[fr.grey2],children:(0,hn._)(e.collective&&!e.challengeDone?yf.pointsCollective:yf.pointEarned(e.noCommunity))})]})]}),(0,An.jsxs)(p.c,{style:[lc.multipleDispositionDisplayShared,tl.out_top_s],children:[(0,An.jsx)(xl,{onPress:()=>{e.share()},children:(0,hn._)(yf.shared),color:e.themeColor,textColor:u.y.WHITE,fontWeight:"bold",style:[lc.commonButton,lc.fullWidthButton]}),(0,An.jsx)(xl,{onPress:()=>{e.closeModal()},children:(0,hn._)(yf.noThanks),color:u.y.WHITE,textColor:u.y.BLACK,fontWeight:"bold",style:{alignSelf:"center",marginTop:15,marginBottom:20,paddingLeft:12,paddingRight:12}})]})]})})};let Lf=!1;const Df=e=>{const t=d.useContext(yn.S),[r,o]=d.useState(-1);let i,a;const l=e.data.routines.favorites.length>0&&e.data.routines.favorites.reduce(((t,n)=>t&&e.data.routines.done.includes(n)),!0);return(0,An.jsxs)(jr.c,{style:[bn.full_width,tl.out_top_m,{maxWidth:1050,marginRight:"auto",marginLeft:"auto"}],children:[(0,An.jsx)(p.c,{style:{width:"100%"},children:(0,An.jsxs)(p.c,{style:{width:"100%",paddingTop:24,paddingBottom:24,paddingLeft:t.expanded?24:16,paddingRight:t.expanded?24:16,backgroundColor:u.y.YELLOW_DARK,borderRadius:16},children:[(0,An.jsx)(cn.c,{onPress:()=>{e.setCurrentSection(0)},children:(0,An.jsx)(le.c,{style:{height:24,width:24,alignContent:"center"},source:n(6364)})}),(0,An.jsx)(le.c,{style:{height:24,width:24,alignSelf:"center"},source:n(4844)}),(0,An.jsxs)(En,{style:[pr.h2,fr.black,tl.out_bottom_m,tl.out_top_xs,bn.text_center],children:[" ",(0,hn._)(yf.dailyRoutine)]}),(0,An.jsxs)(p.c,{style:{alignSelf:"center"},children:[0===e.data.routines.done.length&&(0,An.jsx)(En,{style:[tl.out_top_m,pr.body1,pr.h4,fr.black,{textAlign:"center"}],children:(0,hn._)(yf.noRoutineYetDone)}),0!==e.data.routines.done.length&&(0,An.jsx)(En,{style:[pr.h4,fr.black,tl.in_bottom_m],children:(0,hn._)(yf.routinesDoneToday(e.data.routines.done.length,e.data.routines.done.reduce(((t,n)=>{var r;return t+((null===(r=e.data.routines.data[n])||void 0===r?void 0:r.points)||0)}),0),e.data.routines.done.reduce(((t,n)=>{var r;return t+((null===(r=e.data.routines.data[n])||void 0===r?void 0:r.co2)||0)}),0)))})]}),e.data.routines.done.reduce(((t,r,o)=>{if(!e.data.routines.data[r])return t;const i=e.data.routines.favorites.includes(r),a=(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center",maxWidth:560,alignSelf:"center",width:"100%"},children:[(0,An.jsxs)(p.c,{style:{flexDirection:"row",flex:1,alignItems:"center"},children:[(0,An.jsx)(le.c,{style:{height:16,width:16,marginRight:8},source:n(6404)}),(0,An.jsx)(En,{style:[fr.black,pr.body2],children:(0,hn._)(e.data.routines.data[r].name)})]}),i&&(0,An.jsx)(le.c,{style:{height:24,width:24,marginRight:8},source:n(5580)})]},o);return i?t.unshift(a):t.push(a),t}),[])]})}),(0,An.jsxs)(p.c,{style:[tl.out_bottom_l],children:[(0,An.jsx)(En,{style:[pr.h3,fr.black,tl.out_top_l,tl.out_bottom_s],children:(0,hn._)(yf.yourFavoriteRoutines)}),0===e.data.routines.favorites.length&&(0,An.jsx)(En,{style:[pr.body1,fr.black,tl.out_top_s],children:(0,hn._)(yf.noFavoritesRoutines)}),e.data.routines.favorites.map(((t,n)=>e.data.routines.data[t]?(0,An.jsx)(Pf,{done:e.data.routines.done.includes(t),favorites:!0,routineId:t,data:e.data.routines.data[t],currentRoutineId:r,setCurrentRoutineId:(e,t)=>{o(e),t&&(Lf=!0)},openValidationModalOpen:()=>i(!0),setFavorite:e.setFavorite},"favorite-routine-"+n):(0,An.jsx)(p.c,{},"favorite-routine-"+n)))]}),l&&(0,An.jsx)(En,{children:(0,hn._)(yf.allFavoritesDoneSucceed),style:[tl.out_bottom_l,fr.black,pr.body1,bn.text_center]})||0!==e.data.routines.favorites.length&&(0,An.jsx)(xl,{children:(0,hn._)(yf.allFavoritesDone),color:u.y.YELLOW_DARK,textColor:u.y.BLACK,fontWeight:"700",style:{alignSelf:"center",paddingLeft:16,paddingRight:16,marginRight:16},sideLeft:(0,An.jsx)(le.c,{source:n(1056),style:{height:24,width:24,marginRight:8}}),onPress:()=>{s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:routine/done-favorites"}).execute().then((()=>{e.forceUpdate()}))}}),(0,An.jsxs)(p.c,{style:[tl.out_top_m],children:[(0,An.jsx)(En,{style:[pr.h3,fr.black,tl.out_top_m],children:(0,hn._)(yf.allRoutines)}),Object.values(Object.keys(e.data.routines.data).reduce(((t,n)=>{const r=parseInt(n),o=e.data.routines.data[r].category;return"undefined"===typeof t[o]&&(t[o]={name:e.data.routines.categories[o],data:[]}),e.data.routines.favorites.includes(r)||t[o].data.push(r),t}),{})).filter((e=>e.data.length>0)).map(((t,n)=>(0,An.jsxs)(p.c,{children:[(0,An.jsx)(En,{style:[pr.h2,fr.black,tl.out_top_l],children:(0,hn._)(t.name)}),t.data.map(((t,a)=>(0,An.jsx)(Pf,{done:e.data.routines.done.includes(t),favorites:!1,routineId:t,data:e.data.routines.data[t],currentRoutineId:r,setCurrentRoutineId:(e,t)=>{o(e),t&&(Lf=!0)},openValidationModalOpen:()=>i(!0),setFavorite:e.setFavorite},"category-"+n+"-routine-"+a)))]},"category-"+n)))]}),(0,An.jsx)(cc,{content:{message:yf.dailyRoutineConfirm,buttonRight:{text:yf.yes,backgroundColor:u.y.YELLOW_DARK},buttonLeft:{text:yf.no}},onPress:()=>{e.addRoutine(r),s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:routine/done"}).execute({id:r}),i(!1),a(!0)},closeModal:()=>{i(!1),Lf&&(o(-1),Lf=!1)},hide:e=>{i=e}}),(0,An.jsx)(Bf,{themeColor:u.y.YELLOW_DARK,getReward:()=>{const t=e.data.routines.data[r];return{co2:(null===t||void 0===t?void 0:t.co2)||0,points:(null===t||void 0===t?void 0:t.points)||0}},share:()=>{a(!1),t.setTab(0),Lf=!1},closeModal:()=>{a(!1),e.forceUpdate(),Lf&&(o(-1),Lf=!1)},noCommunity:t.profile.company.noCommunities||t.profile.company.forcePoints,hide:e=>{a=e}})]})},Mf=b.c.create({arrowClick:{height:10,width:10,resizeMode:"contain",alignSelf:"center"},backgroundGreen:{backgroundColor:u.y.GREEN,borderRadius:16},backgroundPurple:{backgroundColor:u.y.PURPLE,borderRadius:16},h3:{fontSize:20,fontWeight:"500",textAlign:"left",color:u.y.BLACK},text:{fontSize:16,fontWeight:"400",textAlign:"left",color:u.y.BLACK},textSmall:{fontSize:15,textAlign:"left",color:u.y.GREY2},numberIndividual:{fontSize:24,color:u.y.GREEN,fontWeight:"700"},numberCollective:{fontSize:24,color:u.y.PURPLE,fontWeight:"700"},pointsCollective:{fontSize:24,color:u.y.PURPLE,fontWeight:"700"},odd:{fontSize:14,textAlign:"center",color:u.y.WHITE},marginTopBig:{marginTop:25},marginTopMedium:{marginTop:10},marginBottomBig:{marginBottom:20},emoji:{fontSize:30,textAlign:"center"}}),Nf=e=>{const t=Date.now();let n=Math.floor(e-t)/1e3,r=Math.floor(n/60),o=Math.floor(r/60);const i=Math.floor(o/24);return r-=60*o,n=n-60*o*60-60*r,o-=24*i,{days:i,hours:o,minutes:r,seconds:n,distance:e-t}},Uf=e=>{const t=d.useContext(yn.S);d.useEffect((()=>{let t=!0;const n=setInterval((()=>{t?o(Nf(e.from)):clearInterval(n)}),1e3);return()=>{t=!1}}),[]);const[r,o]=d.useState(Nf(e.from));return(0,An.jsxs)(p.c,{style:[bn.horizontal,tl.out_bottom_xs,{justifyContent:"space-between"}],children:[(0,An.jsxs)(p.c,{style:[bn.horizontal,bn.align_item_center],children:[(0,An.jsx)(le.c,{style:{height:t.expanded?24:16,width:t.expanded?24:16,marginRight:4},source:e.imageTimer||n(456)}),(0,An.jsx)(En,{style:{fontSize:t.expanded?16:14,fontWeight:"700",color:e.textColor||u.y.WHITE},children:(0,hn._)(yf.timeLeft)})]}),(0,An.jsx)(En,{style:{fontSize:t.expanded?16:14,fontWeight:"700",color:e.numbersColor||u.y.WHITE},children:(()=>{let t="";return r.distance>0?(0!==r.days&&(t+=r.days+" "+("fr"===hn.O.get()?"j":"d")),0!==Math.round(r.days)&&(t+=" \u2022 "),0!==Math.round(r.hours)&&(t+=Math.round(r.hours)+" h"),0!==Math.round(r.hours)&&0!==Math.round(r.minutes)&&(t+=" \u2022 "),0!==Math.round(r.minutes)&&(t+=Math.round(r.minutes)+" min"),0===Math.round(r.minutes)&&0===Math.round(r.hours)||0===Math.round(r.seconds)||(t+=" \u2022 "),0!==Math.round(r.seconds)&&(t+=Math.round(r.seconds)+" s")):e.reload(),t})()})]})},Ff=e=>{var t,n;return(0,An.jsx)("iframe",{title:"webview",src:e.url,style:{width:"100%",height:"100%",border:"none",marginLeft:null!==(t=e.sideMargins)&&void 0!==t?t:0,marginRight:null!==(n=e.sideMargins)&&void 0!==n?n:0}})},Hf=e=>{const t=d.useContext(yn.S),r=1===e.data.status&&!!e.data.form&&!e.data.formDone,[o,i]=d.useState("");return(0,An.jsxs)(p.c,{style:[{width:"100%"},t.expanded?{}:{marginTop:16}],children:[(0,An.jsx)(le.c,{source:{uri:e.data.cover},resizeMode:"cover",style:[{position:"absolute",width:"100%",height:"100%"},t.expanded?{}:{borderRadius:16,borderColor:u.y.WHITE,borderWidth:1}]}),(0,An.jsx)(p.c,{style:[{backgroundColor:"black",opacity:.5,position:"absolute",width:"100%",height:"100%"},t.expanded?{}:{borderRadius:16,borderColor:u.y.WHITE,borderWidth:1}]}),(0,An.jsxs)(p.c,{style:[{padding:24},t.expanded?{}:{borderRadius:16,borderColor:u.y.WHITE,borderWidth:1}],children:[(0,An.jsxs)(p.c,{style:[bn.horizontal,bn.align_item_center],children:[(0,An.jsx)(p.c,{style:[bn.horizontal,bn.flex1],children:(0,An.jsxs)(cn.c,{style:{alignItems:"center",flexDirection:"row"},onPress:e.goBack,children:[(0,An.jsx)(le.c,{style:{height:24,width:24},source:n(516)}),t.expanded?(0,An.jsx)(En,{children:(0,hn._)(yf.goBack),style:[pr.body2,fr.white,tl.out_left_s]}):(0,An.jsx)(p.c,{})]})}),(0,An.jsxs)(p.c,{style:[bn.horizontal,bn.align_item_center],children:[t.expanded?(0,An.jsx)(En,{style:[pr.h5,fr.white,tl.out_right_s],children:e.data.isCollective?(0,hn._)(yf.collectiveChallenge):(0,hn._)(yf.individualChallenge)}):(0,An.jsx)(p.c,{}),(0,An.jsx)(le.c,{style:{height:24,width:24},source:e.data.isCollective?n(2064):n(9372)})]})]}),(0,An.jsx)(En,{style:[pr.h3,fr.white,t.expanded?{textAlign:"center",marginBottom:24,marginTop:24}:{marginBottom:16,marginTop:16},{maxWidth:500,alignSelf:"center",width:"100%",textAlign:"center"}],children:(0,hn._)(e.data.name)}),3!==e.data.status&&(0,An.jsx)(p.c,{style:{maxWidth:200,alignSelf:"center"},children:(0,An.jsx)(xl,{fontSize:14,color:r?u.y.GREY1:u.y.WHITE,textColor:r?u.y.GREY2:u.y.BLACK,fontWeight:"700",style:{paddingLeft:12,paddingRight:12,alignSelf:"center"},children:1===e.data.status?(0,hn._)(yf.validate):(0,hn._)(yf.challengeParticipate),onPress:()=>{r?i((0,hn._)({fr:"Vous n'avez pas encore rempli le questionnaire du challenge",en:"You haven't filled the challenge form yet"})):1===e.data.status?e.onValidate():e.onParticipate()}})}),""!==o&&(0,An.jsx)(p.c,{style:{marginTop:12,alignSelf:"center"},children:(0,An.jsx)(En,{style:[fr.red],children:o})}),3===e.data.status&&(0,An.jsx)(p.c,{style:{alignSelf:"center"},children:(0,An.jsx)(En,{style:[pr.h5,tl.out_top_s,fr.white],children:(0,hn._)({fr:"Vous avez valid\xe9 ce challenge ! \ud83c\udf89",en:"You have validated this challenge ! \ud83c\udf89"})})}),(0,An.jsxs)(p.c,{style:[bn.horizontal,bn.flex1,{marginTop:24},t.expanded?{marginBottom:18}:{}],children:[(0,An.jsx)(le.c,{style:{height:16,width:16,marginRight:6},source:(()=>{switch(e.data.kind){case Vf.awareness:return n(3796);case Vf.test:return n(1896);case Vf.embody:return n(4312);case Vf.transform:return n(7604)}})()}),(0,An.jsx)(En,{style:[pr.caption,fr.white],children:(()=>{switch(e.data.kind){case Vf.awareness:return(0,hn._)(yf.tagAwerness);case Vf.test:return(0,hn._)(yf.tagTest);case Vf.embody:return(0,hn._)(yf.tagEmbody);case Vf.transform:return(0,hn._)(yf.tagTransform)}})()})]})]}),t.expanded?(0,An.jsx)(p.c,{style:{height:24,marginTop:-20},children:(0,An.jsx)(p.c,{style:{backgroundColor:u.y.WHITE,borderTopLeftRadius:24,borderTopRightRadius:24,height:"100%"}})}):(0,An.jsx)(p.c,{})]})},Gf=e=>{var t,o,i,a;const[c,h]=d.useState(0),[g,m]=d.useState(!0),[y,v]=d.useState("");let b,A=()=>{};const x=Date.now(),S=d.useContext(yn.S),w=(0,f.Yi)();let C=!0;if(d.useEffect((()=>()=>{C=!1}),[]),"undefined"===typeof e.data.name)return e.setCurrentSection(0),(0,An.jsx)(p.c,{});const _=e.data.form&&e.data.form.questions.length>0;return(0,An.jsxs)(p.c,{style:[bn.full_width],children:[(0,An.jsx)(Hf,{data:e.data,goBack:()=>e.setCurrentSection(0),onParticipate:()=>{e.data.status=1,e.data.users.push({id:S.profile.id,name:[S.profile.firstname,S.profile.lastname].join(" "),picture:S.profile.picture}),s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:challenge/join"}).execute({id:e.data.id}).then((()=>{h(c+1)})),m(!1);const t=setTimeout((()=>{g&&C?m(!0):clearTimeout(t)}),3e3)},onValidate:()=>A(!0),ended:3===e.data.status}),(0,An.jsxs)(p.c,{style:{alignSelf:"center",width:"100%",maxWidth:1050,marginRight:"auto",marginLeft:"auto"},children:[(0,An.jsxs)(p.c,{children:[1===e.data.status&&!g&&(0,An.jsxs)(p.c,{style:{alignSelf:"center"},children:[(0,An.jsx)(En,{style:[Mf.emoji,tl.out_top_m],children:(0,An.jsx)($l,{children:"\ud83d\ude80"})}),(0,An.jsx)(En,{style:[pr.h3,tl.out_top_s,fr.white],children:(0,hn._)(yf.letsGo)})]}),1===e.data.status&&g&&(0,An.jsxs)(p.c,{style:[{minWidth:250},tl.out_top_m],children:[(0,An.jsx)(Uf,{reload:e.reload,from:e.data.end_date,textColor:u.y.BLUE_DARK,numbersColor:u.y.BLUE_DARK,imageTimer:n(4599)}),(0,An.jsx)(Gu,{ratio:(x-e.data.start_date)/(e.data.end_date-e.data.start_date),color:u.y.BLUE_DARK,backgroundColor:u.y.GREY1}),(0,An.jsx)(cc,{content:{message:e.data.isCollective?yf.collectiveChallengeConfirm:yf.individualChallengeConfirm,buttonRight:{text:yf.yes,backgroundColor:e.data.isCollective?u.y.PURPLE:u.y.GREEN},buttonLeft:{text:yf.no}},onPress:()=>{A(!1),b(!0),s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:challenge/done"}).execute({id:e.data.id}),e.data.status=2},closeModal:()=>{A(!1)},hide:e=>{A=e}}),(0,An.jsx)(Bf,{challengeDone:e.data.challengeDone,collective:e.data.isCollective,themeColor:e.data.isCollective?u.y.PURPLE:u.y.GREEN,onClose:()=>e.setCurrentSection(0),getReward:()=>({co2:e.data.co2,points:e.data.points}),share:()=>{b(!1),S.setTab(0)},closeModal:()=>{e.setCurrentSection(0),b(!1)},hide:e=>{b=e},noCommunity:S.profile.company.noCommunities||(null===(t=S.profile)||void 0===t||null===(o=t.company)||void 0===o?void 0:o.forcePoints)})]})]}),(0,An.jsxs)(p.c,{style:{backgroundColor:u.y.WHITE,maxWidth:1200,alignSelf:"center",marginBottom:30,width:"100%"},children:[!!e.data.users&&(0,An.jsxs)(p.c,{children:[(0,An.jsx)(En,{style:[pr.h3,fr.black,tl.out_top_l,tl.out_bottom_xs,S.expanded||"web"!==r.default.OS?{}:{marginBottom:6}],children:(0,hn._)(yf.participantsTitle)}),(0,An.jsx)(p.c,{style:[bn.horizontal,bn.full_width],children:(0,An.jsx)(Rf,{challengeInProgress:1===e.data.status||3===e.data.status,participants:e.data.users,colorText:u.y.BLACK,textStyle:pr.body1,introText:". "+(0,hn._)(yf.participantsDetails),challengeEnded:3===e.data.status})})]}),(0,An.jsx)(En,{style:[pr.h3,fr.black,tl.out_top_l],children:(0,hn._)(yf.stakesTitle)}),(0,An.jsx)(En,{style:[pr.body1,fr.black,tl.out_top_s],children:(0,hn._)(e.data.context)}),(0,An.jsx)(En,{style:[pr.h3,fr.black,tl.out_top_l],children:(0,hn._)(yf.oddTitle)}),e.data.odd.map(((e,t)=>(0,An.jsx)(p.c,{style:[tl.out_top_s,{backgroundColor:Kp[e],borderColor:Kp[e],borderRadius:4,borderWidth:1,alignSelf:"flex-start",padding:4}],children:(0,An.jsx)(En,{style:[pr.caption,fr.white],children:(0,hn._)(ju(e))},t)},t))),(0,An.jsx)(En,{style:[pr.h3,fr.black,tl.out_top_l],children:(0,hn._)(e.data.isCollective?yf.ourChallenge:yf.myChallenge)}),(0,An.jsx)(Oc,{linkStyle:{color:u.y.BLUE_DARK},onPress:e=>{"web"===r.default.OS?window.open(e,"_blank"):kn.c.openURL(e)},children:(0,An.jsx)(En,{style:[pr.body1,fr.black,tl.out_top_s],children:(0,hn._)(e.data.description)})}),(_&&!e.data.secondaryLinkUseForm||e.data.link&&e.data.link.fr&&e.data.link.en)&&(0,An.jsx)(xl,{onPress:()=>{if(_&&!e.data.secondaryLinkUseForm)w.navigate(ln.g.FORM,{id:e.data.id,data:e.data.form});else{const t=(0,hn._)(e.data.link).trim();e.data.linkInApp?v(t):(0,l.kB)(t)}},children:(0,hn._)(e.data.linkButton),textColor:e.data.isCollective?u.y.PURPLE:u.y.GREEN,style:[{alignSelf:"flex-start",paddingLeft:10,paddingRight:10,borderWidth:1,borderColor:e.data.isCollective?u.y.PURPLE:u.y.GREEN},tl.out_top_s],fontWeight:"600"}),(_&&e.data.secondaryLinkUseForm||e.data.secondaryLink&&e.data.secondaryLink.fr&&e.data.secondaryLink.en)&&(0,An.jsx)(xl,{onPress:()=>{if(_&&e.data.secondaryLinkUseForm)w.navigate(ln.g.FORM,{id:e.data.id,data:e.data.form});else{const t=(0,hn._)(e.data.secondaryLink).trim();e.data.secondaryLinkInApp?v(t):(0,l.kB)(t)}},children:(0,hn._)(e.data.secondaryText),textColor:u.y.GREY2,style:[{alignSelf:"flex-start",paddingLeft:10,paddingRight:10,borderWidth:1,borderColor:u.y.GREY2},tl.out_top_s],fontWeight:"600"}),e.data.isCollective&&(0,An.jsxs)(p.c,{style:[{backgroundColor:u.y.GREY_LIGHT_X,borderColor:u.y.GREY_LIGHT_X,borderWidth:1,borderRadius:16,padding:S.expanded?24:16},tl.out_top_l],children:[(0,An.jsx)(En,{style:[pr.h3,fr.black,tl.out_bottom_xs],children:(0,hn._)(yf.collectiveChallengeGroup)}),(0,An.jsx)(En,{style:[pr.body1,fr.black,tl.out_top_s],children:(0,hn._)(yf.collectiveChallengeGroupDetail)}),(0,An.jsxs)(p.c,{style:S.expanded?{marginTop:-30}:{flexDirection:"column-reverse"},children:[e.data.isCollective&&(0,An.jsx)(mf,{text:(0,hn._)(yf.goToChat),unreadMessages:e.unreadMessages}),S.expanded&&(0,An.jsx)(yr,{color:u.y.GREY1,height:1,minWidth:"100%",style:{marginTop:24}}),(0,An.jsx)(p.c,{style:[S.expanded?{flexDirection:"row",flexWrap:"wrap"}:{marginBottom:16}],children:Object.keys(e.team).map((t=>(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center",marginTop:16,minWidth:S.expanded?"33%":"100%"},children:[(0,An.jsx)(Rn,{bgColor:u.y.BLUE_LIGHT,name:e.team[t].user,source:e.team[t].picture,color:u.y.BLACK,size:40,style:{marginRight:8}}),(0,An.jsxs)(p.c,{children:[(0,An.jsx)(En,{style:{fontSize:15,fontWeight:"700",color:u.y.BLACK,textAlign:"left",marginBottom:3},children:e.team[t].user}),(0,An.jsx)(En,{style:[Mf.textSmall],children:e.team[t].email})]})]},t)))})]})]}),(0,An.jsx)(En,{style:[pr.h3,fr.black,tl.out_top_l],children:(0,hn._)(e.data.isCollective?yf.ourObjective:yf.myObjective)}),e.data.co2?(0,An.jsx)(En,{style:[tl.out_top_s,e.data.isCollective?Mf.numberCollective:Mf.numberIndividual],children:(0,hn._)(yf.gram(e.data.co2))}):null,e.data.co2?(0,An.jsx)(En,{style:[Mf.textSmall],children:(0,hn._)(yf.co2Avoid)}):null,(0,An.jsx)(En,{style:[tl.out_top_m,e.data.isCollective?Mf.numberCollective:Mf.numberIndividual],children:(0,hn._)(yf.points(e.data.points))}),(0,An.jsx)(En,{style:[Mf.textSmall],children:(0,hn._)(yf.pointEarned(S.profile.company.noCommunities||(null===(i=S.profile)||void 0===i||null===(a=i.company)||void 0===a?void 0:a.forcePoints)))}),3!==e.data.status&&(0,An.jsx)(En,{style:[tl.out_top_m,e.data.isCollective?Mf.numberCollective:Mf.numberIndividual],children:ql(hn.O.get(),(e.data.end_date-x)/1e3,!0)}),3!==e.data.status&&(0,An.jsx)(En,{style:[Mf.textSmall],children:(0,hn._)(yf.remainingTime)})]})]}),(0,An.jsx)(yc,{isVisible:""!==y,hide:()=>v(""),color:u.y.WHITE,content:(0,An.jsx)(Ff,{url:y}),paddingTop:0,maxWidth:null})]})};let zf=function(e){return e.TEXT="text",e.CHOICES_RESPONSE="choices_response",e.CHOICES_SINGLE="choices_single",e.CHOICES_SINGLE_OTHER="choices_single_other",e.CHOICES_MULTI="choices_multi",e}({}),Vf=function(e){return e.awareness="awareness",e.test="test",e.embody="embody",e.transform="transform",e}({});const Wf=e=>{const[t,n]=d.useState(void 0),[o,i]=d.useState(0),a=()=>{0===o&&(c(0),i(o+1))};d.useEffect((()=>{let e=!0;return s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:actions/v2"}).execute({platform:r.default.OS}).then((t=>{e&&n(t)})),()=>{e=!1}}),[o]);const[l,c]=d.useState(0),[u,h]=d.useState(-1);if("undefined"===typeof t)return(0,An.jsx)(p.c,{});if(1===l){if(-1===u)return(0,An.jsx)(p.c,{});let n={};return"string"===typeof u?(s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:challenges/retrieve"}).execute({id:u}).then(h),(0,An.jsx)(p.c,{})):(n="number"===typeof u?t.challenges.current[u]:u,(0,An.jsx)(Gf,{reload:a,data:n,team:t.challenges.team,setCurrentSection:t=>{c(t),e.scrollOnTop()},unreadMessages:t.messages.unread}))}return 2===l?(0,An.jsx)(Df,{data:t,addRoutine:e=>{t.routines.done.push(e),n(t)},setCurrentSection:t=>{c(t),e.scrollOnTop()},setFavorite:e=>{s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:routine/favorite"}).execute({id:e}).then((()=>{i(o+1)}))},forceUpdate:()=>i(o+1)}):(0,An.jsx)(Tf,{reload:a,data:t,setCurrentSection:(t,n)=>{c(t),h("undefined"!==typeof n?n:-1),e.scrollOnTop()}})},Qf=()=>{var e,t;const r=d.useContext(yn.S),o=r.profile.company.cover;return(0,An.jsxs)(p.c,{style:{width:"100%"},children:[(0,An.jsx)(le.c,{source:o&&{uri:o}||n(8488),resizeMode:"cover",style:{width:"100%",height:r.expanded?280:150}}),(0,An.jsx)(p.c,{style:{maxWidth:1050,width:"100%",alignSelf:"center",paddingLeft:16,position:"absolute",bottom:r.expanded?50:42},children:(0,An.jsx)(Rn,{bgColor:u.y.BLUE_LIGHT,source:null===(e=r.profile)||void 0===e||null===(t=e.company)||void 0===t?void 0:t.picture,color:u.y.BLACK,size:r.expanded?110:90})}),(0,An.jsx)(p.c,{style:{backgroundColor:u.y.WHITE,borderTopLeftRadius:24,borderTopRightRadius:24,height:24,width:"100%",position:"absolute",bottom:0}})]})},Yf={fr:"Nos engagements",en:"Our commitments"},Kf={fr:"Nos objectifs",en:"Our goals"},qf={fr:"Programme d'engagement",en:"Commitment program"},Xf={fr:"Voir plus",en:"See more"},Jf=e=>{switch(e){case"environment":return{fr:"Environnement",en:"Environment"};case"social":return{fr:"Social",en:"Social"};case"governance":return{fr:"Gouvernance",en:"Governance"}}},Zf=e=>{const t=Math.floor(100*e);return{fr:t+"% accompli",en:t+"% completed"}},$f={fr:"Participer au temps fort",en:"Join in this highlight"},eg={fr:"Voir tous les temps forts",en:"See all the highlights"},tg={fr:"Ressources",en:"Resources"},ng={fr:"Document",en:"Document"},rg={fr:"D\xe9couvrir",en:"Discover"},og={fr:"Tous les temps forts",en:"All the highlights"},ig=e=>{switch(e){case hg.CURRENT:return{fr:"En cours",en:"Ongoing"};case hg.COMING:return{fr:"\xc0 venir",en:"Coming"};default:return{fr:"Termin\xe9",en:"Completed"}}},ag=e=>{const t=d.useContext(yn.S),r=(0,f.Yi)();return(0,An.jsx)(p.c,{style:[bn.horizontal,{backgroundColor:e.bgColor,minHeight:50,paddingTop:8,paddingBottom:8,paddingLeft:16,paddingRight:16,borderBottomColor:e.borderColor,borderBottomWidth:e.borderWidth}],children:(0,An.jsxs)(p.c,{style:[bn.horizontal,{alignItems:"center",width:"100%",flex:1}],children:[(0,An.jsx)(xl,{textColor:u.y.WHITE,fontSize:24,style:{borderWidth:0,marginRight:8},children:"",onPress:()=>{var t,n;e.forceGoBack?r.goBack():(r.replace((null===(t=e.goBack)||void 0===t?void 0:t.page)||ln.g.SETTINGS),vn.O.add((null===(n=e.goBack)||void 0===n?void 0:n.section)||vn.S.SETTINGS,!0))},sideLeft:(0,An.jsx)(le.c,{style:{height:24,width:24,resizeMode:"contain",alignContent:"center"},source:e.blackArrow?n(6364):n(516)})}),(0,An.jsx)(En,{style:[t.expanded?{flexWrap:"wrap"}:{maxWidth:"90%"},e.titleStyle],children:e.title}),e.children]})})},sg=e=>{const t=(0,f.Yi)();return(0,An.jsxs)(p.c,{children:[(0,An.jsxs)(p.c,{style:[bn.horizontal,{backgroundColor:e.bgColor,height:100,justifyContent:"center"}],children:[(0,An.jsx)(p.c,{style:[bn.horizontal,{position:"absolute",top:36,left:16}],children:(0,An.jsx)(xl,{textColor:u.y.WHITE,color:u.y.BLUE_DARK,fontSize:16,children:"Retour",style:{shadowOpacity:0},onPress:()=>{var n,r;e.backToPreviousPage?(t.goBack(),vn.O.goBack()):(t.replace((null===(n=e.goBack)||void 0===n?void 0:n.page)||ln.g.SETTINGS),vn.O.add((null===(r=e.goBack)||void 0===r?void 0:r.section)||vn.S.SETTINGS,!0))},sideLeft:(0,An.jsx)(le.c,{style:{height:24,width:24,resizeMode:"contain",alignContent:"center",marginRight:16},source:n(516)})})}),(0,An.jsx)(un.c,{style:[pr.h1,fr.white,bn.text_center,tl.out_top_l,tl.out_bottom_l],children:e.title})]}),(0,An.jsx)(p.c,{style:{backgroundColor:u.y.BLUE_DARK,height:24},children:(0,An.jsx)(p.c,{style:{backgroundColor:e.bgColorRadius||u.y.WHITE,borderTopLeftRadius:24,borderTopRightRadius:24,height:"100%"}})})]})},lg=e=>{let t=u.y.GREEN_LIGHT,n=yf.highlightsPassed;const r=Date.now();return r{const t=Date.now(),r=t>e.project.start_date,o=t>e.project.end_date;return(0,An.jsxs)(p.c,{style:[tl.out_bottom_m],children:[!e.hideTitle&&(0,An.jsx)(En,{style:[pr.h2,fr.black,tl.out_bottom_l],children:(0,hn._)(e.project.name)}),(0,An.jsx)(lg,{startDate:e.project.start_date,endDate:e.project.end_date}),e.project.start_date&&(0,An.jsxs)(p.c,{style:[bn.flex1,bn.horizontal,tl.out_bottom_s,tl.out_top_m],children:[(0,An.jsx)(le.c,{style:{height:24,width:24,marginRight:8},source:n(6964)}),(0,An.jsx)(En,{style:[o?fr.green:r?fr.purple:fr.yellow,pr.h5],children:(0,hn._)(yf.startDate(e.project.start_date,e.project.end_date,r))})]}),e.project.progress&&e.project.start_date&&(0,An.jsx)(p.c,{style:{marginBottom:16},children:(0,An.jsx)(Gu,{color:o?u.y.GREEN:r?u.y.PURPLE:u.y.YELLOW_DARK,ratio:e.project.progress,backgroundColor:o?u.y.GREEN_LIGHT:r?u.y.PURPLE_LIGHT:u.y.YELLOW_LIGHT})}),e.project.odd&&e.project.odd.map(((e,t)=>(0,An.jsx)(p.c,{style:{marginTop:8},children:(0,An.jsx)(Bu,{number:e})},t))),(0,An.jsx)(En,{style:[tl.out_top_m,pr.body1,fr.black],children:(0,hn._)(e.project.context)})]})},ug=e=>{const t=d.useContext(yn.S),{push:o}=(0,f.Yi)(),[i,a]=d.useState(!1),[s,l]=d.useState();return(0,An.jsxs)(p.c,{style:t.expanded&&e.modeColumn?{flexDirection:"row"}:{},children:[e.projects.map(((i,s)=>(0,An.jsxs)(cn.c,{style:t.expanded?{flex:1}:{},onPress:()=>{"web"===r.default.OS?(a(!0),l(i)):o(ln.g.HIGHLIGHT_DETAILS,{project:i})},children:[(0,An.jsxs)(p.c,{style:[{flex:1,flexDirection:"row",alignItems:"center"},t.expanded&&e.modeColumn?{borderColor:u.y.GREY_LIGHT,borderRadius:16,borderWidth:1,padding:16,marginRight:16}:{marginBottom:10,marginTop:8}],children:[(0,An.jsxs)(p.c,{style:{flex:1},children:[(0,An.jsx)(En,{children:(0,hn._)(i.name),style:[pr.body1,fr.black,tl.out_bottom_s]}),(0,An.jsx)(lg,{startDate:i.start_date,endDate:i.end_date})]}),(0,An.jsx)(le.c,{source:n(9036),style:{width:24,height:24}})]}),(!t.expanded||!0!==e.modeColumn)&&(0,An.jsx)(yr,{color:u.y.GREY1,height:1,minWidth:"100%"})]},e.type+s))),s&&"web"===r.default.OS&&(0,An.jsx)(yc,{isVisible:i,color:"white",margin:20,hide:()=>a(!1),content:(0,An.jsx)(jr.c,{children:(0,An.jsx)(cg,{project:s,barBgColor:e.color})})})]})};function dg(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];const t=Date.now();return[...e].reduce(((e,n)=>(n.start_date>t?e.inComing.push(n):n.end_date>t?e.inProgress.push(n):e.past.push(n),e)),{inProgress:[],inComing:[],past:[]})}let hg=function(e){return e[e.CURRENT=0]="CURRENT",e[e.COMING=1]="COMING",e[e.PAST=2]="PAST",e}({});const pg=e=>{const t=d.useContext(yn.S),o=(0,f.Yi)(),[i,a]=d.useState(!1),[s,l]=d.useState();if(0===e.highlights.length)return null;let c=[];if(e.highlights){var h;const t=dg(e.highlights);c=[...t.inProgress,...t.inComing].slice(0,3),c.length<3&&(null===(h=t.past)||void 0===h?void 0:h.length)>0&&(c=[...c,...t.past.slice(t.past.length-1-(3-c.length-1))])}return(0,An.jsxs)(p.c,{children:[(0,An.jsx)(En,{style:[pr.h3,fr.black,tl.out_bottom_m,tl.out_top_l],children:(0,hn._)(qf)}),(0,An.jsxs)(p.c,{style:{borderColor:u.y.GREY_LIGHT,borderWidth:1,borderRadius:20,padding:16},children:[c.map(((i,s)=>{const c=(()=>{const e=Date.now();return i.start_date>e?hg.COMING:i.end_date{switch(c){case hg.CURRENT:return u.y.PURPLE;case hg.COMING:return u.y.YELLOW_DARK;default:return u.y.GREEN}})();return(0,An.jsxs)(cn.c,{onPress:()=>{"web"===r.default.OS?(a(!0),l(i)):o.push(ln.g.HIGHLIGHT_DETAILS,{project:i})},children:[(0,An.jsxs)(p.c,{style:[tl.out_bottom_s],children:[(0,An.jsxs)(p.c,{style:[bn.horizontal,bn.align_item_center],children:[(0,An.jsx)(En,{style:[pr.h3,bn.flex1,bn.align_item_center,fr.black],children:(0,hn._)(i.name)}),(0,An.jsx)(le.c,{style:{height:24,width:24},source:n(9820)})]}),(0,An.jsxs)(p.c,{style:[bn.horizontal,bn.align_item_center],children:[(0,An.jsx)(En,{style:[pr.h5,{color:d},bn.flex1],children:(0,hn._)(ig(c))}),c===hg.CURRENT&&(0,An.jsx)(En,{style:[pr.caption,fr.purple],children:(0,hn._)(Zf(i.progress))})]})]}),(0,An.jsx)(p.c,{style:[tl.out_bottom_s],children:(0,An.jsx)(Gu,{ratio:i.progress,backgroundColor:(()=>{switch(c){case hg.CURRENT:return u.y.PURPLE_LIGHT;case hg.COMING:return u.y.YELLOW_LIGHT;default:return u.y.GREEN_LIGHT}})(),color:d})}),c===hg.CURRENT&&(0,An.jsx)(xl,{children:(0,hn._)($f),onPress:()=>{t.setTab(1),vn.O.add(vn.S.ACTIONS,!0),e.scrollOnTop()},color:u.y.PURPLE,fontSize:13,fontWeight:"700",textColor:u.y.WHITE,style:{borderColor:u.y.PURPLE,borderWidth:1,borderRadius:24,paddingLeft:12,paddingRight:12,alignSelf:"flex-start",marginBottom:6,marginTop:8}}),(0,An.jsx)(yr,{color:u.y.GREY_LIGHT,height:1,minWidth:"100%",style:[tl.out_bottom_m,tl.out_top_m]})]},s)})),(0,An.jsx)(xl,{children:(0,hn._)(eg),color:u.y.WHITE,fontSize:13,fontWeight:"700",textColor:u.y.BLACK,style:{borderColor:u.y.GREY1,borderWidth:1,borderRadius:24,paddingLeft:12,paddingRight:12,alignSelf:"flex-start"},onPress:()=>{o.push(ln.g.HIGHLIGHTS,{projects:e.highlights}),vn.O.add(vn.S.HIGHLIGHTS,!0)}})]}),s&&"web"===r.default.OS&&(0,An.jsx)(yc,{isVisible:i,color:"white",margin:20,hide:()=>a(!1),content:(0,An.jsx)(jr.c,{children:(0,An.jsx)(cg,{project:s})})})]})},fg=e=>{var t;const{push:n}=(0,f.Yi)();return 0===(null===e||void 0===e||null===(t=e.commitments)||void 0===t?void 0:t.length)?(0,An.jsx)(p.c,{}):(0,An.jsxs)(p.c,{children:[(0,An.jsx)(En,{style:[pr.h3,fr.black,tl.out_bottom_m,tl.out_top_l],children:(0,hn._)(Yf)}),(0,An.jsxs)(p.c,{style:{borderColor:u.y.GREY_LIGHT,borderWidth:1,borderRadius:20,paddingLeft:16,paddingRight:16,paddingBottom:16},children:[((null===e||void 0===e?void 0:e.commitments)||[]).map(((e,t)=>(0,An.jsxs)(p.c,{children:[(0,An.jsx)(En,{style:[pr.h3,fr.black,tl.out_bottom_m,tl.out_top_m],children:(0,hn._)(e.title)}),(0,An.jsx)(En,{style:[pr.body1,fr.black],children:(0,hn._)(e.content)}),(0,An.jsx)(yr,{color:u.y.GREY_LIGHT,style:[tl.out_top_m],height:1,minWidth:"100%"})]},t))),(0,An.jsx)(xl,{onPress:()=>{n(ln.g.PROGRAM_COMMITMENTS,{commitments:e.commitments,button:e.button})},children:(0,hn._)(Xf),color:u.y.WHITE,fontSize:13,fontWeight:"700",textColor:u.y.BLACK,style:[{borderColor:u.y.GREY1,borderWidth:1,borderRadius:24,paddingLeft:12,paddingRight:12,alignSelf:"flex-start"},tl.out_top_m]})]})]})},gg=e=>{if(!e.goals||0===Object.values(e.goals).reduce(((e,t)=>e+t.length),0))return null;const t=Object.keys(e.goals);return(0,An.jsxs)(p.c,{children:[(0,An.jsx)(En,{style:[pr.h3,fr.black,tl.out_top_l,tl.out_bottom_m],children:(0,hn._)(Kf)}),(0,An.jsx)(p.c,{style:{borderColor:u.y.GREY_LIGHT,borderWidth:1,borderRadius:20,paddingLeft:16,paddingRight:16,paddingBottom:16,paddingTop:6},children:t.map(((r,o)=>{const i=e.goals[r];return i&&0!==i.length?(0,An.jsxs)(p.c,{children:[(0,An.jsxs)(p.c,{style:[bn.horizontal,tl.out_top_m],children:[(0,An.jsx)(le.c,{style:{width:24,height:24,marginRight:8,alignSelf:"center"},source:(()=>{switch(r){case"environment":return n(1316);case"governance":return n(3656);case"social":return n(6012)}})()}),(0,An.jsx)(En,{style:[pr.h5,fr.black],children:(0,hn._)(Jf(r))})]}),i.map(((e,t)=>e?(0,An.jsxs)(p.c,{children:[(0,An.jsx)(En,{style:[pr.h3,fr.green,tl.out_top_m,(()=>{switch(r){case"environment":return fr.green;case"social":return fr.orange;case"governance":return fr.purple}})()],children:e.value}),(0,An.jsx)(En,{style:[pr.body1,fr.black,tl.out_bottom_xs],children:(0,hn._)(e.description)})]},t):null)),o!==t.length-1&&(0,An.jsx)(yr,{color:u.y.GREY_LIGHT,style:[tl.out_top_m,tl.out_bottom_s],height:1,minWidth:"100%"})]},o):null}))})]})},mg=e=>{const t=d.useContext(yn.S);return e.resources?(0,An.jsxs)(p.c,{children:[(0,An.jsx)(En,{style:[pr.h3,fr.black,tl.out_top_l],children:(0,hn._)(tg)}),(0,An.jsx)(p.c,{style:{flexWrap:"wrap",flexDirection:"row",justifyContent:"space-between"},children:e.resources.map(((e,r)=>(0,An.jsxs)(p.c,{style:[{backgroundColor:u.y.BLUE_LIGHT_X,borderColor:u.y.BLUE_LIGHT_X,borderWidth:1,borderRadius:16,padding:16,marginTop:24},t.expanded?{width:"30%"}:{width:"48%"}],children:[(0,An.jsxs)(p.c,{style:{flexDirection:"row"},children:[(0,An.jsx)(le.c,{style:{height:14,width:14,marginRight:6},source:n(388)}),(0,An.jsx)(En,{style:[tl.out_bottom_m,fr.blue_dark,pr.caption],children:(0,hn._)(ng)})]}),(0,An.jsx)(En,{style:[pr.h5,fr.blue_dark,tl.out_bottom_m,{alignSelf:"center",textAlign:"center"}],children:(0,hn._)(e.title)}),(0,An.jsx)(xl,{children:(0,hn._)(rg),color:u.y.BLUE_LIGHT_X,fontSize:13,fontWeight:"700",textColor:u.y.BLUE_DARK,style:{borderColor:u.y.BLUE_DARK,borderWidth:1,borderRadius:24,paddingLeft:12,paddingRight:12,alignSelf:"center"},onPress:()=>(0,l.kB)((0,hn._)(e.url).trim())})]},r)))})]}):(0,An.jsx)(p.c,{})},yg=e=>{let[t,n]=d.useState();return d.useEffect((()=>{let e=!0;return s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:program"}).execute({platform:r.default.OS}).then((t=>{e&&n(t)})),()=>{e=!1}}),[]),t?(0,An.jsxs)(p.c,{style:{width:"100%",maxWidth:1050,marginRight:"auto",marginLeft:"auto",paddingTop:32,paddingLeft:16,paddingRight:16,paddingBottom:32,flex:1,backgroundColor:u.y.WHITE},children:[(0,An.jsx)(En,{style:[pr.h2,fr.black,tl.out_bottom_m],children:(0,hn._)(t.title)}),(0,An.jsx)(En,{style:[pr.body1,fr.black,tl.out_bottom_m],children:(0,hn._)(t.description)}),(0,An.jsx)(fg,{commitments:t.commitments,button:t.button}),(0,An.jsx)(gg,{goals:t.goals}),(0,An.jsx)(mg,{resources:t.resources}),(0,An.jsx)(pg,{highlights:t.highlights,scrollOnTop:e.scrollOnTop})]}):null},vg=e=>{const t=d.useContext(yn.S),{replace:r}=(0,f.Yi)();return(0,An.jsxs)(p.c,{style:[fc.footerContainer],children:[(0,An.jsxs)(cn.c,{style:fc.footerElement,onPress:()=>{e.onSettings&&(r(ln.g.ADMIN),vn.O.add(vn.S.ACTIONS,!0)),t.setTab(0)},children:[(0,An.jsx)(le.c,{style:fc.image,source:0===t.tab?n(1308):n(7504)}),(0,An.jsx)(un.c,{style:0===t.tab?fc.textSelected:fc.text,children:(0,hn._)(pn)})]}),(0,An.jsxs)(cn.c,{style:fc.footerElement,onPress:()=>{e.onSettings&&(r(ln.g.ADMIN),vn.O.add(vn.S.ACTIONS,!0)),t.setTab(1)},children:[(0,An.jsx)(le.c,{style:fc.image,source:1===t.tab?n(6176):n(1956)}),(0,An.jsx)(un.c,{style:1===t.tab?fc.textSelected:fc.text,children:(0,hn._)(fn)})]}),(0,An.jsxs)(cn.c,{style:fc.footerElement,onPress:()=>{e.onSettings&&(r(ln.g.ADMIN),vn.O.add(vn.S.ACTIONS,!0)),t.setTab(2)},children:[(0,An.jsx)(le.c,{style:fc.image,source:2===t.tab?n(1132):n(7892)}),(0,An.jsx)(un.c,{style:2===t.tab?fc.textSelected:fc.text,children:(0,hn._)(gn)})]}),(0,An.jsxs)(cn.c,{style:fc.footerElement,onPress:()=>{e.onSettings&&(r(ln.g.ADMIN),vn.O.add(vn.S.ACTIONS,!0)),t.setTab(3)},children:[(0,An.jsx)(le.c,{style:fc.image,source:3===t.tab?n(451):n(3140)}),(0,An.jsx)(un.c,{style:3===t.tab?fc.textSelected:fc.text,children:(0,hn._)(mn)})]})]})};var bg=n(2124),Ag=n(8884);const xg=b.c.create({page:{flex:1,backgroundColor:u.y.WHITE},content:{marginTop:10,marginBottom:20}}),Sg=e=>{const t=(0,f.Yi)(),o=d.useContext(yn.S);let i=e=>{},l=e=>{};const[c,h]=d.useState(!1),[g,m]=d.useState(""),[y,v]=d.useState(""),b=()=>{var e;e=e=>{o.setPicture(e),pc()},Ac(((t,n)=>{s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:users/picture"}).execute({image:t,type:n}).then((t=>{let{picture:n}=t;e(n)}))}))},A=()=>{Ac(((t,n)=>{s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:users/team/update"}).execute({picture:{image:t,type:n}}).then((t=>{let{picture:n}=t;e.setTeamPicture(n)}))}))};return(0,An.jsxs)(p.c,{style:o.expanded?{width:"100%",maxWidth:600,marginRight:"auto",marginLeft:"auto",height:"100%",marginTop:16}:{marginLeft:16,marginRight:16,marginTop:16},children:[(0,An.jsxs)(p.c,{children:[(0,An.jsxs)(p.c,{style:{flex:1,marginBottom:24,minHeight:"web"!==r.default.OS||o.expanded?void 0:"auto"},children:[(0,An.jsx)(En,{style:[pr.h4,fr.black,tl.out_bottom_m],children:(0,hn._)(On)}),(0,An.jsxs)(cn.c,{style:{flexDirection:"row",alignItems:"center"},onPress:b,children:[(0,An.jsx)(Rn,{name:[e.firstname,e.lastname],size:80,bgColor:u.y.GREY_LIGHT_X,color:u.y.BLUE_DARK,source:o.picture,style:{borderColor:u.y.GREY_LIGHT,borderWidth:1,marginRight:16,height:80}}),(0,An.jsx)(xl,{color:u.y.WHITE,textColor:u.y.BLACK,fontSize:14,fontWeight:"700",style:{borderWidth:1,borderColor:u.y.GREY_LIGHT,borderRadius:40,height:36,paddingLeft:8,paddingRight:8},children:(0,hn._)(jn),onPress:b})]})]}),(0,An.jsxs)(p.c,{children:[e.error.length>0&&(0,An.jsx)(En,{style:{textAlign:"center",color:u.y.ORANGE,marginBottom:15},children:e.error}),(0,An.jsxs)(p.c,{style:[tl.out_bottom_s],children:[(0,An.jsx)(En,{style:[pr.h6,fr.grey2,tl.out_bottom_xs],children:(0,hn._)(Bn)}),(0,An.jsx)(kt.c,{value:e.firstname,onChangeText:t=>{e.setFirstname(t)},style:[pr.body1,fr.black,tl.in_bottom_xs]}),(0,An.jsx)(yr,{color:u.y.GREY1,bgColor:"transparent",height:1,minWidth:"100%",style:[tl.out_bottom_s]})]}),(0,An.jsxs)(p.c,{style:[tl.out_bottom_s],children:[(0,An.jsx)(En,{style:[pr.h6,fr.grey2,tl.out_bottom_xs],children:(0,hn._)(Ln)}),(0,An.jsx)(kt.c,{value:e.lastname,onChangeText:t=>{e.setLastname(t)},style:[pr.body1,fr.black,tl.in_bottom_xs]}),(0,An.jsx)(yr,{color:u.y.GREY1,bgColor:"transparent",height:1,minWidth:"100%",style:[tl.out_bottom_s]})]}),(0,An.jsxs)(p.c,{style:[tl.out_bottom_s],children:[(0,An.jsx)(En,{style:[pr.h6,fr.grey2,tl.out_bottom_xs],children:(0,hn._)(Dn)}),(0,An.jsx)(kt.c,{textContentType:"emailAddress",value:e.email,onChangeText:t=>{e.setEmail(t)},style:[pr.body1,fr.black,tl.in_bottom_xs]}),(0,An.jsx)(yr,{color:u.y.GREY1,bgColor:"transparent",height:1,minWidth:"100%",style:[tl.out_bottom_s]})]}),(0,An.jsxs)(p.c,{style:[tl.out_bottom_s],children:[(0,An.jsx)(En,{style:[pr.h6,fr.grey2,tl.out_bottom_xs],children:(0,hn._)(Mn)}),(0,An.jsx)(kt.c,{value:e.position,onChangeText:t=>{e.setPosition(t)},style:[pr.body1,fr.black,tl.in_bottom_xs]}),(0,An.jsx)(yr,{color:u.y.GREY1,bgColor:"transparent",height:1,minWidth:"100%",style:[tl.out_bottom_s]})]}),0!==e.departments.length&&(0,An.jsxs)(p.c,{style:[tl.out_bottom_s],children:[(0,An.jsx)(En,{style:[pr.h6,fr.grey2,tl.out_bottom_xs],children:(0,hn._)(Nn)}),(0,An.jsx)(el,{values:e.departments.reduce(((e,t)=>(e[t]=t,e)),{}),onChange:t=>e.setDepartment(t),label:{fr:"Choisir dans la liste",en:"Choose from the list"},value:e.department}),(0,An.jsx)(yr,{color:u.y.GREY1,bgColor:"transparent",height:1,minWidth:"100%",style:[tl.out_bottom_s]})]}),(0,An.jsxs)(p.c,{style:[tl.out_bottom_l],children:[(0,An.jsx)(En,{style:[pr.h6,fr.grey2,tl.out_bottom_xs],children:(0,hn._)(Un)}),(0,An.jsx)(el,{values:Rl,onChange:t=>e.setCountry(t),label:{fr:"Choisir dans la liste",en:"Choose from the list"},value:e.country}),(0,An.jsx)(yr,{color:u.y.GREY1,bgColor:"transparent",height:1,minWidth:"100%",style:[tl.out_bottom_s]})]}),"undefined"!==typeof e.teamName&&(0,An.jsxs)(p.c,{style:[tl.out_bottom_l],children:[(0,An.jsx)(En,{style:[pr.h4,fr.black,tl.out_bottom_m],children:(0,hn._)(dr)}),(0,An.jsxs)(p.c,{style:{flex:1},children:[(0,An.jsxs)(cn.c,{style:[{flexDirection:"row",alignItems:"center"},tl.out_bottom_m],onPress:A,children:[(0,An.jsx)(Rn,{style:[{borderColor:u.y.GREY_LIGHT,borderWidth:1,marginRight:16},tl.out_right_m],size:80,bgColor:u.y.GREY_LIGHT_X,color:u.y.BLUE_DARK,name:e.teamName,source:e.teamPicture}),(0,An.jsx)(xl,{color:u.y.WHITE,textColor:u.y.BLACK,fontSize:14,fontWeight:"700",style:{borderWidth:1,borderColor:u.y.GREY_LIGHT,borderRadius:40,height:36,paddingLeft:8,paddingRight:8},children:(0,hn._)(Pn),onPress:A})]}),(0,An.jsxs)(p.c,{style:{paddingRight:16,flex:1},children:[(0,An.jsx)(En,{style:[pr.h6,fr.grey2,tl.out_bottom_xs],children:(0,hn._)(hr)}),(0,An.jsx)(kt.c,{value:e.teamName,onChangeText:e.setTeamName,style:[pr.body1,fr.black,tl.in_bottom_xs]}),(0,An.jsx)(yr,{color:u.y.GREY1,bgColor:"transparent",height:1,minWidth:"100%",style:[tl.out_bottom_s]})]})]})]}),(0,An.jsxs)(p.c,{style:[tl.out_bottom_l],children:[(0,An.jsx)(En,{style:[pr.h4,fr.black,tl.out_bottom_m],children:(0,hn._)(er)}),(0,An.jsx)(En,{style:[pr.h6,fr.grey2,tl.out_bottom_s],children:(0,hn._)(tr)}),(0,An.jsxs)(p.c,{style:{flexDirection:"row",justifyContent:"flex-start",flex:1},children:[(0,An.jsx)(xl,{children:"Fran\xe7ais",textColor:u.y.BLACK,color:"fr"===e.locale?u.y.GREY_LIGHT:void 0,fontWeight:"700",style:{borderColor:u.y.GREY_LIGHT,borderRadius:50,borderWidth:1,width:90,marginRight:16,padding:"ios"===r.default.OS?0:4},fontSize:14,sideLeft:"fr"===e.locale?(0,An.jsx)(le.c,{source:n(1056),style:{width:14,height:14,marginRight:4}}):void 0,onPress:()=>e.setLocale("fr")}),(0,An.jsx)(xl,{children:"English",color:"en"===e.locale?u.y.GREY_LIGHT:void 0,textColor:u.y.BLACK,fontWeight:"700",style:{borderColor:u.y.GREY_LIGHT,borderRadius:50,borderWidth:1,width:90,padding:"ios"===r.default.OS?0:4},fontSize:14,sideLeft:"en"===e.locale?(0,An.jsx)(le.c,{source:n(1056),style:{width:14,height:14,marginRight:4}}):void 0,onPress:()=>e.setLocale("en")})]})]})]}),(0,An.jsxs)(p.c,{style:[tl.out_bottom_l],children:[(0,An.jsx)(En,{style:[pr.h6,fr.grey2,tl.out_bottom_s],children:(0,hn._)(rr)}),o.profile.fcm||!e.emailsOnly?(0,An.jsxs)(p.c,{style:{flexDirection:"row",justifyContent:"flex-start",marginBottom:14,flex:1},children:[(0,An.jsx)(xl,{children:(0,hn._)(ir),color:e.emailsOnly?void 0:u.y.GREY_LIGHT,textColor:u.y.BLACK,fontWeight:"700",style:{borderColor:u.y.GREY_LIGHT,borderRadius:50,borderWidth:1,width:90,marginRight:16,padding:"ios"===r.default.OS?0:4},fontSize:14,sideLeft:e.emailsOnly?void 0:(0,An.jsx)(le.c,{source:n(1056),style:{width:14,height:14,marginRight:4}}),onPress:()=>e.setEmailsOnly(!e.emailsOnly)}),(0,An.jsx)(xl,{children:(0,hn._)(or),textColor:u.y.BLACK,color:e.emailsOnly?u.y.GREY_LIGHT:void 0,fontWeight:"700",style:{borderColor:u.y.GREY_LIGHT,borderRadius:50,borderWidth:1,width:90,padding:"ios"===r.default.OS?void 0:4},fontSize:14,sideLeft:e.emailsOnly?(0,An.jsx)(le.c,{source:n(1056),style:{width:14,height:14,marginRight:4}}):void 0,onPress:()=>e.setEmailsOnly(!e.emailsOnly)})]}):null,(0,An.jsx)(cn.c,{onPress:()=>e.setNotifications("challenge",!e.notifications.challenge),children:(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center"},children:[(0,An.jsx)(le.c,{source:e.notifications.challenge?n(5948):n(9168),style:{width:22,height:12,marginRight:9}}),(0,An.jsx)(un.c,{children:(0,hn._)(ar),style:e.notifications.challenge?{color:"black"}:{color:"#848D9B"}})]})}),!e.emailsOnly&&(0,An.jsx)(cn.c,{style:{marginTop:12},onPress:()=>e.setNotifications("share",!e.notifications.share),children:(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center"},children:[(0,An.jsx)(le.c,{source:e.notifications.share?n(5948):n(9168),style:{width:22,height:12,marginRight:9}}),(0,An.jsx)(un.c,{children:(0,hn._)(sr),style:e.notifications.share?{color:u.y.BLACK}:{color:"#848D9B"}})]})}),!e.emailsOnly&&(0,An.jsx)(cn.c,{style:{marginTop:12},onPress:()=>e.setNotifications("reminder",!e.notifications.reminder),children:(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center"},children:[(0,An.jsx)(le.c,{source:e.notifications.reminder?n(5948):n(9168),style:{width:22,height:12,marginRight:9}}),(0,An.jsx)(un.c,{children:(0,hn._)(lr),style:e.notifications.reminder?{color:u.y.BLACK}:{color:"#848D9B"}})]})}),e.emailsOnly&&(0,An.jsx)(cn.c,{style:{marginTop:12},onPress:()=>e.setNotifications("summary",!e.notifications.summary),children:(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center"},children:[(0,An.jsx)(le.c,{source:e.notifications.summary?n(5948):n(9168),style:{width:22,height:12,marginRight:9}}),(0,An.jsx)(un.c,{children:(0,hn._)(cr),style:e.notifications.summary?{color:u.y.BLACK}:{color:"#848D9B"}})]})}),!e.emailsOnly&&(0,An.jsx)(cn.c,{style:{marginTop:12},onPress:()=>e.setNotifications("chat",!e.notifications.chat),children:(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center"},children:[(0,An.jsx)(le.c,{source:e.notifications.chat?n(5948):n(9168),style:{width:22,height:12,marginRight:9}}),(0,An.jsx)(un.c,{children:(0,hn._)(ur),style:e.notifications.chat?{color:"black"}:{color:"#848D9B"}})]})})]}),o.expanded&&e.displaySave&&(0,An.jsxs)(p.c,{style:{marginBottom:24},children:[(0,An.jsxs)(p.c,{style:[bn.horizontal,{paddingBottom:32}],children:[(0,An.jsx)(xl,{children:(0,hn._)(Fn),color:u.y.YELLOW_DARK,textColor:u.y.WHITE,style:{width:250,alignSelf:"flex-start",height:50,borderRadius:50,marginRight:16},onPress:e.save}),(0,An.jsx)(xl,{color:u.y.WHITE,textColor:u.y.BLACK,fontSize:14,fontWeight:"700",style:{borderWidth:1,borderColor:u.y.GREY_LIGHT,borderRadius:50,height:50,width:100,paddingLeft:8,paddingRight:8},children:(0,hn._)(Gn),onPress:e.cancel})]}),(0,An.jsx)(yr,{color:u.y.GREY1,bgColor:"transparent",height:1,minWidth:"100%",style:[tl.out_bottom_s]})]}),!o.expanded&&(0,An.jsxs)(p.c,{style:[[bn.flex1,bn.horizontal,tl.out_bottom_m,{alignItems:"center"}],{width:"100%"}],children:[(0,An.jsx)(le.c,{style:{width:20,height:20,resizeMode:"contain",marginRight:8},source:n(260)}),(0,An.jsx)(cn.c,{style:{width:"100%"},onPress:()=>{gr()},children:(0,An.jsx)(En,{style:[pr.h6,fr.black],children:(0,hn._)(nr)})})]}),(0,An.jsx)(cn.c,{style:{width:o.expanded?300:"100%"},onPress:()=>{i(!0)},children:(0,An.jsxs)(p.c,{style:[bn.flex1,bn.horizontal,tl.out_bottom_m,{alignItems:"center"}],children:[(0,An.jsx)(le.c,{style:{width:20,height:20,resizeMode:"contain",marginRight:8},source:n(3328)}),(0,An.jsx)(En,{style:[pr.h6,fr.black],children:(0,hn._)(Vn)})]})}),(0,An.jsx)(cn.c,{style:{width:o.expanded?300:"100%"},onPress:()=>{l(!0)},children:(0,An.jsxs)(p.c,{style:[bn.flex1,bn.horizontal,tl.out_bottom_l,{alignItems:"center"}],children:[(0,An.jsx)(le.c,{style:{width:20,height:20,resizeMode:"contain",marginRight:8},source:n(6624)}),(0,An.jsx)(En,{style:[pr.h6,fr.red],children:(0,hn._)(Kn)})]})})]}),(0,An.jsx)(sc,{width:"80%",style:o.expanded?{width:"60%"}:{},handler:e=>{i=e},children:(0,An.jsxs)(p.c,{style:{width:"100%",alignItems:"center",marginTop:16},children:[(0,An.jsx)(En,{style:[bn.text_center,pr.h3,fr.black],children:(0,hn._)(Wn)}),(0,An.jsxs)(p.c,{style:[{flexDirection:"row",justifyContent:"space-around",width:o.expanded?"78%":"100%",marginTop:24,marginBottom:16},o.expanded||"web"!==r.default.OS?{}:{flexWrap:"wrap"}],children:[(0,An.jsx)(xl,{color:"white",textColor:u.y.BLACK,fontWeight:"bold",fontSize:14,style:[{width:o.expanded?160:130,borderWidth:1,borderColor:u.y.BLUE_DARK,marginRight:"ios"===r.default.OS?4:0,height:40},o.expanded||"web"!==r.default.OS?{}:{marginBottom:8,marginRight:4}],onPress:()=>{i(!1)},children:(0,hn._)(Yn)}),(0,An.jsx)(xl,{color:u.y.YELLOW_DARK,textColor:u.y.BLACK,fontWeight:"bold",fontSize:14,style:[{width:o.expanded?160:130,height:40,paddingLeft:4,paddingRight:4},o.expanded||"web"!==r.default.OS?{}:{marginBottom:8,marginLeft:4}],onPress:()=>{a.cp.removeItem("token").then((()=>{t.replace(ln.g.OFFLINE),vn.O.add(vn.S.OFFLINE,!1),o.setTab(0),s.g.recipes.metrics.get({project:"maoboa:app",id:"maoboa:app:v3:disconnected"}).add(),"web"!==r.default.OS&&(s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:setFCM"}).execute(),window.location.reload())}))},children:(0,hn._)(Qn)})]})]})}),(0,An.jsx)(sc,{width:"80%",handler:e=>{l=e},children:(0,An.jsxs)(p.c,{style:{width:"100%",alignItems:"center",marginTop:16,padding:"ios"===r.default.OS?0:16},children:[!c&&(0,An.jsxs)(p.c,{style:{width:"100%"},children:[(0,An.jsx)(En,{style:[bn.text_center,pr.h3,fr.black],children:(0,hn._)(qn)}),(0,An.jsx)(En,{style:{color:u.y.BLACK,fontSize:16,textAlign:"center",marginTop:8},children:(0,hn._)(Xn)})]})||(0,An.jsxs)(p.c,{style:{width:"100%"},children:[(0,An.jsxs)(En,{style:{color:u.y.BLACK,textAlign:"center"},children:[(0,hn._)(Jn)," ",e.email]}),(0,An.jsx)(kt.c,{value:g,style:{width:120,fontSize:20,borderColor:u.y.BLUE_DARK,padding:10,alignSelf:"center",borderWidth:1},onChangeText:e=>{m(e)}}),y.length>0&&(0,An.jsx)(En,{style:{textAlign:"center",color:u.y.RED,marginTop:10,marginBottom:10},children:y})]}),(0,An.jsxs)(p.c,{style:[{flexDirection:"row",justifyContent:"space-around",width:o.expanded?"78%":"100%",marginTop:24,marginBottom:20},o.expanded||"web"!==r.default.OS?{}:{flexWrap:"wrap"}],children:[(0,An.jsx)(xl,{color:"white",textColor:u.y.BLACK,fontWeight:"bold",fontSize:14,style:[{width:o.expanded?160:130,height:40,borderWidth:1,borderColor:u.y.BLUE_DARK},o.expanded||"web"!==r.default.OS?{}:{marginBottom:8,marginRight:4}],onPress:()=>{l(!1)},children:(0,hn._)($n)}),(0,An.jsx)(xl,{color:u.y.YELLOW_DARK,textColor:u.y.BLACK,fontWeight:"bold",style:[{width:o.expanded?160:130,height:40},o.expanded||"web"!==r.default.OS?{}:{marginBottom:8,marginLeft:4}],fontSize:14,onPress:()=>{c?(v(""),s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:users/delete"}).execute({code:g}).then((()=>{h(!1),a.cp.removeItem("token").then((()=>{t.replace(ln.g.OFFLINE),vn.O.add(vn.S.OFFLINE,!1),o.setTab(0)}))})).catch((e=>{v((0,hn._)(e))}))):s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:users/deleteCode"}).execute().then((()=>{h(!0)}))},children:(0,hn._)(Zn)})]})]})})]})},wg=e=>{const t=(0,f.Yi)(),o=d.useContext(yn.S);return(0,An.jsxs)(p.c,{children:[o.expanded&&(0,An.jsxs)(p.c,{style:[bn.horizontal,{backgroundColor:u.y.BLUE_DARK,height:100,justifyContent:"center"}],children:[(0,An.jsx)(p.c,{style:[bn.horizontal,{position:"absolute",top:36,left:15}],children:(0,An.jsx)(xl,{textColor:u.y.WHITE,color:u.y.BLUE_DARK,fontSize:16,children:(0,hn._)(In),style:[{shadowOpacity:0},"web"===r.default.OS?{boxShadow:"none"}:{}],onPress:()=>{t.replace(ln.g.ADMIN),vn.O.add(vn.S.ACTIONS,!0),o.setTab(1)},sideLeft:(0,An.jsx)(le.c,{style:{height:24,width:24,resizeMode:"contain",alignContent:"center",marginRight:16},source:n(516)})})}),(0,An.jsx)(un.c,{style:[o.expanded?pr.h1Expanded:pr.h1,fr.white,bn.text_center,tl.out_top_l,tl.out_bottom_l],children:(0,hn._)(Tn)})]}),!o.expanded&&(0,An.jsxs)(p.c,{style:[bn.horizontal,{backgroundColor:u.y.BLUE_DARK,justifyContent:"space-between",alignItems:"center",paddingLeft:16,paddingRight:16,paddingTop:"ios"===r.default.OS?0:32,paddingBottom:"ios"===r.default.OS?0:16}],children:[(0,An.jsxs)(p.c,{style:[bn.horizontal,{alignItems:"center"}],children:[(0,An.jsx)(xl,{textColor:u.y.WHITE,color:u.y.BLUE_DARK,fontSize:16,children:"",onPress:()=>{t.replace(ln.g.ADMIN),vn.O.add(vn.S.ACTIONS,!0),o.setTab(1)},sideLeft:(0,An.jsx)(le.c,{style:{height:24,width:24,resizeMode:"contain",alignContent:"center",marginRight:8},source:n(516)})}),(0,An.jsx)(un.c,{style:[pr.h3,fr.white,bn.text_center],children:(0,hn._)(Tn)})]}),e.displaySave&&(0,An.jsx)(xl,{color:u.y.BLUE_DARK,textColor:u.y.YELLOW_DARK,fontSize:14,fontWeight:"700",children:(0,hn._)(Hn),onPress:e.save})]})]})},Cg=e=>/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(e),_g=()=>{const e=(0,f.Yi)();return(0,An.jsx)(p.c,{children:(0,An.jsx)(p.c,{style:[bn.horizontal,{backgroundColor:u.y.BLUE_DARK,height:64,paddingLeft:16,paddingRight:16,paddingTop:8,paddingBottom:8}],children:(0,An.jsxs)(p.c,{style:[bn.horizontal,{alignItems:"center",width:"100%",justifyContent:"flex-start"}],children:[(0,An.jsx)(xl,{textColor:u.y.WHITE,fontSize:16,style:[{borderWidth:0,marginRight:8},"web"===r.default.OS?{boxShadow:"none"}:{}],children:"",onPress:()=>{e.goBack(),vn.O.add(vn.S.ACTIONS,!0)},sideLeft:(0,An.jsx)(le.c,{style:{height:24,width:24,resizeMode:"contain",alignContent:"center"},source:n(516)})}),(0,An.jsx)(p.c,{style:{justifyContent:"center",flex:1},children:(0,An.jsx)(En,{style:[pr.h3,fr.white],children:"Notifications"})})]})})})},Eg=e=>{const[t,n]=d.useState(),[r,o]=d.useState(1);return d.useEffect((()=>{s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:feed/get"}).execute(e.id).then((e=>{n(e)}))}),[r]),t?(0,An.jsx)(p.c,{style:{padding:10,borderWidth:1,borderColor:u.y.GREY1,marginBottom:10,borderRadius:20},children:(0,An.jsx)(Dc,{data:t,forceUpdate:()=>{o(r+1)}})}):(0,An.jsx)(p.c,{})};let Rg=()=>{};const kg=b.c.create({container:{backgroundColor:u.y.BLUE_DARK,width:"100%"}}),Ig=b.c.create({h4:{textAlign:"center",fontWeight:"600",color:u.y.WHITE,fontSize:24,maxWidth:"95%",alignSelf:"center"},maxWidth:{maxWidth:650},cards:{flex:1,flexDirection:"row",flexWrap:"wrap",paddingLeft:5,paddingRight:5,marginTop:10,marginBottom:100,alignItems:"center",height:"100%",minWidth:300},cardOut:{width:"100%",paddingLeft:5,paddingRight:5,paddingTop:10},cardIn:{minHeight:70,justifyContent:"center",padding:15},submit:{position:"absolute",alignSelf:"center",bottom:30,paddingLeft:26,paddingRight:26,paddingTop:6,paddingBottom:6,borderRadius:20,elevation:3},description:{fontSize:16,color:u.y.BLACK,marginTop:5},containerPicture:{borderColor:u.y.WHITE,borderWidth:1,borderRadius:50,marginRight:20,padding:5,backgroundColor:u.y.WHITE},arrow:{height:16,width:16,marginTop:8,marginBottom:8,transform:[{rotate:"180deg"}]},arrowDown:{height:16,width:16,marginTop:8,marginBottom:8},arrowButton:{alignItems:"center",width:80,borderColor:u.y.BLUE_DARK,borderWidth:1,borderRadius:20}}),Tg=(e,t,n)=>{const r=e.reduce(((e,n,r)=>(r!==t&&e.push(n),e)),[]);return r.splice(n,0,Object.assign({},e[t])),r},Og=b.c.create({container:{backgroundColor:u.y.BLUE_DARK,width:"100%",alignContent:"center"},card:{backgroundColor:u.y.BLUE_LIGHT,maxWidth:325,width:"100%"},borderRadiusTop:{borderTopLeftRadius:10,borderTopRightRadius:10},borderRadiusBottom:{borderBottomLeftRadius:10,borderBottomRightRadius:10},projectContainer:{flexDirection:"row",alignItems:"center",marginBottom:10},projectColumn:{alignItems:"flex-start"},x:{marginTop:20,marginBottom:20,fontWeight:"bold",alignSelf:"center",fontSize:25,color:"white"},button:{marginTop:40,marginBottom:40,alignSelf:"center",width:180,elevation:3}}),jg={fr:"Bienvenue dans votre communaut\xe9",en:"Welcome in your community"},Pg={fr:"Ma communaut\xe9",en:"My community"},Bg={fr:"Commencer",en:"Start"},Lg=b.c.create({container:{backgroundColor:u.y.WHITE,alignItems:"center",width:"100%"},space:{width:"85%",marginTop:20},h1:{fontSize:24,color:"white",fontFamily:"ios"===r.default.OS?"Brown":"Brown-Bold"},marginBottom:{marginBottom:30}}),Dg={fr:"R\xe9initialisation du mot de passe",en:"Password Reset"},Mg={fr:"E-mail professionnel",en:"E-mail address"},Ng={fr:"Code de v\xe9rification",en:"Verification code"},Ug={fr:"Nouveau mot de passe",en:"New password"},Fg={fr:"Confirmation du nouveau mot de passe",en:"Confirmation of the new password"},Hg={fr:"Le format de votre adresse e-mail n'est pas valide",en:"The format of your e-mail address is not valid"},Gg={fr:"Un code de v\xe9rification vous a \xe9t\xe9 envoy\xe9 par e-mail",en:"A verification code has been sent to you by e-mail"},zg={fr:"Votre code vous a \xe9t\xe9 envoy\xe9 par e-mail",en:"Please check your email address"},Vg={fr:"Vous devez d\xe9finir un mot de passe",en:"You must provide a password"},Wg={fr:"Votre mot de passe doit contenir au minimum 8 caract\xe8res",en:"Your password must contain at least 8 characters"},Qg={fr:"La confirmation de votre mot de passe est incorrecte",en:"Your password confirmation is incorrect"},Yg={fr:"Envoyer",en:"Reset"},Kg={fr:"Vous ne voulez pas r\xe9initialiser votre mot de passe ?",en:"Back to connection"},qg={fr:"Se connecter",en:"Back to connection"},Xg={fr:"Retour",en:"Go back"},Jg={fr:"Chat d'\xe9quipe",en:"Team Chat"},Zg={fr:"Voir les membres",en:"View members"},$g={fr:"Mon \xe9quipe",en:"My team"},em={fr:"Voici les membres de votre \xe9quipe pour r\xe9aliser ce challenge collectif.",en:"Here are your team members to complete your collective challenge."},tm={fr:"Bienvenue dans votre chat d'\xe9quipe !",en:"Welcome in your team chat!"},nm={fr:"Cet espace de discussion vous permet d'\xe9changer et de collaborer dans le cadre des challenges collectifs.",en:"This chat room allows you to exchange and collaborate in the context of collective challenges."},rm={fr:"Envoyer un message",en:"Send a message"},om={fr:"membres",en:"members"},im=e=>{const t=d.useContext(yn.S),n=(Array.isArray(e.users)?e.users:Object.keys(e.users).map((t=>e.users[t]))).filter((e=>!e.deleted));return(0,An.jsx)(p.c,{style:{flexDirection:"row",flexWrap:"wrap"},children:n.map(((n,r)=>(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center",marginTop:16,width:t.expanded?"50%":"100%"},children:[(0,An.jsx)(Rn,{bgColor:u.y.BLUE_LIGHT,name:n.name,source:n.picture,color:"black",size:40,style:{marginRight:16}}),(0,An.jsxs)(p.c,{children:[(0,An.jsx)(En,{style:[pr.h5,fr.white,{color:u.y.BLACK,textAlign:"left"}],children:n.name}),(0,An.jsx)(En,{style:[pr.body1,fr.grey2],children:n.email}),e.displayPoints&&"undefined"!==typeof n.points&&(0,An.jsxs)(En,{style:[pr.h6,fr.black],children:[n.points," points"]})]})]},r)))})},am=e=>{const t=d.useContext(yn.S),o=(0,f.Yi)(),[i,a]=d.useState(!1);if(t.expanded)return(0,An.jsxs)(p.c,{children:[(0,An.jsx)(p.c,{style:[bn.horizontal,{backgroundColor:u.y.BLUE_DARK,height:90,alignItems:"center",paddingLeft:16,paddingRight:16}],children:(0,An.jsxs)(p.c,{style:[bn.horizontal,{alignItems:"center",width:"100%",justifyContent:"center"}],children:[(0,An.jsx)(xl,{textColor:u.y.WHITE,fontSize:16,style:{position:"absolute",left:0,borderWidth:0,shadowOpacity:0},children:(0,hn._)(Xg),onPress:()=>{o.goBack(),vn.O.add(vn.S.ACTIONS,!0)},sideLeft:(0,An.jsx)(le.c,{style:{height:24,width:24,resizeMode:"contain",alignContent:"center",marginRight:16},source:n(516)})}),(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center"},children:[(0,An.jsx)(En,{style:[pr.h3,fr.white,bn.text_center,{marginRight:10}],children:(0,hn._)(Jg)}),(0,An.jsx)(Jp,{users:e.users,bgColor:u.y.WHITE,color:u.y.BLUE_DARK,bgColorPlus:u.y.WHITE,size:24,max:9,dots:!0})]}),(0,An.jsx)(xl,{children:(0,hn._)(Zg),textColor:u.y.WHITE,fontSize:16,fontWeight:"700",style:{paddingLeft:16,paddingRight:16,marginLeft:12},onPress:()=>{a(!0)}})]})}),(0,An.jsx)(p.c,{style:{backgroundColor:u.y.BLUE_DARK,height:24},children:(0,An.jsx)(p.c,{style:{backgroundColor:u.y.WHITE,borderTopLeftRadius:24,borderTopRightRadius:24,height:"100%"}})}),(0,An.jsx)(yc,{isVisible:i,hide:()=>a(!1),color:"white",margin:30,content:(0,An.jsxs)(p.c,{style:[tl.out_bottom_m],children:[(0,An.jsx)(En,{style:[pr.h3,fr.black],children:(0,hn._)($g)}),(0,An.jsx)(En,{style:[pr.body1,fr.black,tl.out_top_s,tl.out_bottom_s],children:(0,hn._)(em)}),(0,An.jsx)(im,{users:e.users})]})})]});const s=Object.values(e.users).map((e=>e.name));return(0,An.jsx)(p.c,{children:(0,An.jsx)(p.c,{style:[bn.horizontal,{backgroundColor:u.y.BLUE_DARK,height:64,paddingLeft:16,paddingRight:16,paddingTop:8,paddingBottom:8}],children:(0,An.jsxs)(p.c,{style:[bn.horizontal,{alignItems:"flex-start",width:"100%",justifyContent:"flex-start"}],children:[(0,An.jsx)(xl,{textColor:u.y.WHITE,fontSize:16,style:[{borderWidth:0,marginRight:8},"web"===r.default.OS?{boxShadow:"none"}:{}],children:"",onPress:()=>{o.goBack(),vn.O.add(vn.S.ACTIONS,!0)},sideLeft:(0,An.jsx)(le.c,{style:{height:24,width:24,resizeMode:"contain",alignContent:"center"},source:n(516)})}),(0,An.jsxs)(p.c,{style:{justifyContent:"flex-start",flex:1},children:[(0,An.jsx)(En,{style:[pr.h3,fr.white],children:(0,hn._)(Jg)}),(0,An.jsx)(un.c,{numberOfLines:1,ellipsizeMode:"tail",style:[bn.flex1,pr.body2,fr.white],children:"".concat(s.length," ").concat((0,hn._)(om)," : ").concat(s.join(", ")),onPress:()=>{o.navigate(ln.g.CHAT_MEMBERS,{users:e.users}),vn.O.add(vn.S.CHAT_MEMBERS,!0)}})]})]})})})},sm=e=>{var t,n,o;return(0,An.jsx)(p.c,{children:(0,An.jsxs)(p.c,{style:{flexDirection:"row",marginBottom:16},children:[(0,An.jsx)(Rn,{size:40,bgColor:u.y.BLUE_LIGHT_X,color:u.y.BLUE_DARK,name:(null===(t=e.users[e.data.author])||void 0===t?void 0:t.name)||"",source:null===(n=e.users[e.data.author])||void 0===n?void 0:n.picture}),(0,An.jsxs)(p.c,{style:{marginLeft:16,flex:1},children:[(0,An.jsxs)(p.c,{style:[bn.horizontal,tl.out_bottom_xs,{alignItems:"center"}],children:[(0,An.jsx)(un.c,{style:[pr.h6,fr.black],children:(null===(o=e.users[e.data.author])||void 0===o?void 0:o.name)||""}),(0,An.jsxs)(un.c,{style:[pr.caption,fr.grey2,{marginLeft:4}],children:["[",Jl(e.data.date),"]"]})]}),(0,An.jsx)(Oc,{linkStyle:{color:u.y.BLUE_DARK},onPress:e=>{"web"===r.default.OS?window.open(e,"_blank"):kn.c.openURL(e)},children:(0,An.jsx)(En,{style:[pr.body2,fr.black],children:e.data.text})})]})]})})},lm=e=>{const[t,n]=d.useState(e.messages),r=d.useContext(yn.S),o=function(t){let r=arguments.length>1&&void 0!==arguments[1]&&arguments[1];const o=r||e.isScrollAtBottom();n((e=>[...e,t])),o&&setTimeout((()=>{e.scrollToBottom(!r)}),100)};return d.useEffect((()=>{e.scrollToBottom();const t=new WebSocket((0,l.Ke)());return t.onopen=()=>{t.send('{"jwt":"'.concat(s.g.config.getToken(),'"}')),e.setSendMessage((e=>{o({author:r.profile.id,date:Date.now(),text:e},!0),t.send('{"new":"'.concat(e.split("\n"),'"}'))}))},t.onmessage=e=>{o(JSON.parse(e.data))},()=>t.close()}),[]),(0,An.jsx)(p.c,{children:t.map(((t,n)=>(0,An.jsx)(sm,{users:e.users,data:t},n)))})},cm=()=>(0,An.jsxs)(p.c,{style:{alignItems:"center",marginTop:8},children:[(0,An.jsx)(le.c,{style:{height:40,width:40},source:n(4611)}),(0,An.jsx)(un.c,{children:(0,hn._)(tm),style:[pr.h4,fr.black,tl.out_top_m,tl.out_bottom_xs,bn.text_center]}),(0,An.jsx)(un.c,{children:(0,hn._)(nm),style:[pr.body2,fr.grey2,bn.text_center]})]}),um=e=>{const t=d.useContext(yn.S),[o,i]=d.useState(""),a=t.expanded?60:45;return(0,An.jsxs)(p.c,{style:[{width:"100%",flexDirection:"row",alignItems:"center"},t.expanded?{maxWidth:1050,marginLeft:"auto",marginRight:"auto",marginBottom:45}:{}],children:[(0,An.jsx)(kt.c,{maxLength:2e3,placeholder:(0,hn._)(rm),placeholderTextColor:u.y.GREY2,multiline:!0,value:o,onKeyPress:t=>{"web"===r.default.OS&&"Enter"===t.nativeEvent.key&&0!==o.length&&(e.send(o),i(""),t.preventDefault())},onChangeText:e=>{i(e)},style:[{height:a,flex:1,paddingTop:t.expanded?16:8,paddingLeft:16,backgroundColor:t.expanded?u.y.WHITE:u.y.GREY_LIGHT_X,borderTopLeftRadius:50,borderBottomLeftRadius:50,borderTopWidth:1,borderLeftWidth:1,borderBottomWidth:1,borderColor:u.y.GREY_LIGHT},pr.body1,fr.black]}),(0,An.jsx)(p.c,{style:{height:a,justifyContent:"center",backgroundColor:t.expanded?u.y.WHITE:u.y.GREY_LIGHT_X,borderBottomRightRadius:50,borderTopRightRadius:50,borderTopWidth:1,borderRightWidth:1,borderBottomWidth:1,borderColor:u.y.GREY_LIGHT},children:(0,An.jsx)(xl,{textColor:u.y.WHITE,color:t.expanded?u.y.PURPLE:u.y.GREY_LIGHT_X,style:{width:48,height:48,padding:6,borderRadius:50,margin:10},fontSize:16,children:"",onPress:()=>{0!==o.length&&(e.send(o),i(""))},sideLeft:(0,An.jsx)(le.c,{style:{height:22,width:22,resizeMode:"contain",alignContent:"center"},source:t.expanded?n(9964):n(2312)})})})]})},dm=e=>{const t=d.useContext(yn.S),n=d.useRef(null);let o=!1,i=()=>{};return(0,An.jsxs)(Or.c,{behavior:"ios"===r.default.OS?"padding":"height",keyboardVerticalOffset:"ios"===r.default.OS?50:30,style:[{flex:1,alignItems:"center"},t.expanded?{}:{marginLeft:4,marginRight:4,marginBottom:4}],children:[(0,An.jsxs)(jr.c,{ref:n,onScroll:e=>{const t=e.nativeEvent.contentOffset.y+e.nativeEvent.layoutMeasurement.height,n=e.nativeEvent.contentSize.height;o=t>=n-100},scrollEventThrottle:16,style:[{width:"100%",backgroundColor:u.y.WHITE},t.expanded?{}:{paddingLeft:16,paddingRight:16}],contentContainerStyle:t.expanded?{flexGrow:1,flexShrink:1,flexBasis:1,justifyContent:"flex-start"}:{width:"100%"},children:[(0,An.jsx)(cm,{}),(0,An.jsx)(p.c,{style:[tl.out_top_l,tl.out_bottom_m,t.expanded?{paddingLeft:16,paddingRight:16,maxWidth:1050,marginLeft:"auto",marginRight:"auto",width:"100%"}:{}],children:(0,An.jsx)(lm,{users:e.users,messages:e.messages,scrollToBottom:e=>{var t;null===(t=n.current)||void 0===t||t.scrollToEnd({animated:!!e}),o=!0},isScrollAtBottom:()=>o,setSendMessage:e=>{i=e}})})]}),(0,An.jsx)(um,{send:e=>i(e)})]})},hm={minutes:e=>({fr:e+" mn",en:e+" mn"}),quizCompleted:e=>({fr:e+"% accompli",en:e+"% completed"}),inputText:{fr:"Compl\xe9ter ici",en:"Complete here"},inputTextError:{fr:"Veuillez remplir ce champ",en:"Please fill out this field"},choicesTextError:{fr:"Vous devez faire une s\xe9lection",en:"You may select an option"},rightAnswer:{fr:"Bonne r\xe9ponse \ud83e\udd29",en:"Right answer \ud83e\udd29"},wrongAnswer:{fr:"Mauvaise r\xe9ponse \ud83d\ude41",en:"Wrong answer \ud83d\ude41"},validateButton:{fr:"Valider",en:"Validate"},nextButton:{fr:"Suivant",en:"Next"},thanksTitle:{fr:"Merci pour votre participation \ud83e\udd29",en:"Thank you for your participation \ud83e\udd29"},thanksDescription:{fr:"Vous pouvez partager vos impressions sur le fil d'actualit\xe9 pour faire vivre le sujet dans votre organisation.",en:"You can share your impressions on the newsfeed to discuss about this subject with your colleagues."},validationChallenge:{fr:"Valider mon challenge",en:"Confirm my challenge"},shareChallenge:{fr:"Partager sur le fil d\u2019actualit\xe9",en:"Share on the news feed"}},pm=e=>(0,An.jsxs)(p.c,{children:[(0,An.jsx)(kt.c,{maxLength:2e3,placeholder:(0,hn._)(hm.inputText),placeholderTextColor:u.y.GREY1,multiline:!0,value:e.response,onChangeText:e.setResponse,style:[{fontFamily:"Roboto",fontSize:17},pr.body1,fr.black,tl.in_bottom_xs]}),(0,An.jsx)(yr,{color:e.response?u.y.GREEN:u.y.GREY1,height:1,minWidth:"100%"})]}),fm=e=>{const t=e.multiple?""===e.response?[]:e.response.split(","):[e.response],r=e.other&&!e.multiple&&e.response.startsWith("#"),o=e.solution&&e.isBack;return(0,An.jsxs)(p.c,{children:[[...e.answers,...!e.other||e.multiple||e.solution?[]:[{fr:"Autre",en:"Other"}]].map(((i,a)=>{const s="".concat(a+1),l=a===e.answers.length,c=r&&l||t.includes(s);return(0,An.jsxs)(cn.c,{disabled:o,onPress:()=>{if(!o)if(e.multiple)if(c){const n=t.filter((e=>e!==s));e.setResponse(n.join(","))}else e.setResponse([...t,s].join(","));else l?e.setResponse("#"):e.setResponse(c?"":s)},style:[{flexDirection:"row",backgroundColor:c?u.y.BLUE_DARK:u.y.BLUE_LIGHT,paddingLeft:8,paddingRight:c?12:8,paddingTop:4,paddingBottom:4,borderRadius:4,borderWidth:1,borderColor:c?u.y.BLUE_DARK:u.y.BLUE_LIGHT,alignItems:"center",alignSelf:"flex-start"},tl.out_bottom_m],children:[(0,An.jsx)(le.c,{style:{height:18,width:18,marginRight:8},source:c?n(4520):e.multiple?n(8080):n(5440)}),(0,An.jsx)(En,{style:[pr.body1,c?fr.white:fr.black],children:(0,hn._)(i)})]},a)})),r&&(0,An.jsx)(pm,{response:e.response.substring(1),setResponse:t=>e.setResponse("#".concat(t))})]})},gm=e=>(0,An.jsxs)(p.c,{children:[(0,An.jsx)(En,{style:[pr.h3,e.correct?fr.green:fr.black,tl.out_bottom_xs],children:(0,hn._)(e.correct?hm.rightAnswer:hm.wrongAnswer)}),(0,An.jsx)(En,{style:[pr.body1,fr.black,tl.out_bottom_l],children:e.explanation?(0,hn._)(e.explanation):""}),(0,An.jsx)(xl,{onPress:e.next,color:u.y.BLUE_DARK,fontSize:14,fontWeight:"700",textColor:u.y.WHITE,children:(0,hn._)(hm.nextButton),style:{paddingLeft:12,paddingRight:12,alignSelf:"center"}})]}),mm=e=>{const t=e.current===e.total,n=e.current/e.total;return(0,An.jsxs)(p.c,{children:[(0,An.jsxs)(p.c,{style:[bn.full_width,bn.horizontal,tl.out_bottom_s],children:[(0,An.jsx)(En,{style:t?[pr.h3,fr.white,bn.flex1]:[pr.h3,fr.blue_dark,bn.flex1],children:(0,hn._)(e.name)}),(0,An.jsx)(En,{style:[...t?[pr.h5,fr.white]:[pr.h5,fr.blue_dark],{marginLeft:15}],children:(0,hn._)(hm.quizCompleted(Math.floor(100*n)))})]}),(0,An.jsx)(Gu,{ratio:n,backgroundColor:t?u.y.WHITE:u.y.BLUE_LIGHT,color:t?u.y.WHITE:u.y.BLUE_DARK})]})},ym=e=>{const t=0!==e.step,r=e.step{t&&e.setStep(e.step-1)},children:(0,An.jsx)(p.c,{style:{backgroundColor:t?u.y.BLUE_DARK:u.y.GREY1,borderTopLeftRadius:4,borderBottomLeftRadius:4,padding:4,marginRight:2},children:(0,An.jsx)(le.c,{style:{width:22,height:22,transform:[{rotate:"180deg"}],resizeMode:"contain"},source:n(t?3693:480)})})}),(0,An.jsx)(cn.c,{onPress:()=>{r&&e.setStep(e.step+1)},style:{flexDirection:"row"},children:(0,An.jsx)(p.c,{style:{backgroundColor:r?u.y.BLUE_DARK:u.y.GREY1,borderTopRightRadius:4,borderBottomRightRadius:4,padding:4,marginRight:2},children:(0,An.jsx)(le.c,{style:{width:22,height:22,resizeMode:"contain"},source:n(r?3693:480)})})})]})]})},vm=e=>(0,An.jsx)(p.c,{style:[tl.out_top_l],children:(0,An.jsx)(xl,{onPress:e.setNextStep,disabled:!e.ready,color:e.ready?u.y.BLUE_DARK:u.y.GREY_LIGHT,fontSize:14,fontWeight:"700",textColor:e.ready?u.y.WHITE:u.y.GREY2,children:(0,hn._)(hm.validateButton),style:{paddingLeft:16,paddingRight:16,paddingTop:2,paddingBottom:2,alignSelf:"center"}})}),bm=e=>{const t=d.useContext(yn.S),{push:n}=(0,f.Yi)();d.useEffect((()=>{s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:actions/form"}).execute(e)}),[]);const r=async()=>{await s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:challenge/done"}).execute({id:e.challenge})},o=Object.keys(e.quizResponses).length;let i=0;if(0!==o)for(const a in e.quizResponses)e.quizResponses[a]===e.responses[parseInt(a)]&&i++;return(0,An.jsxs)(p.c,{style:[bn.align_item_center,bn.justify_center,{paddingTop:32,paddingBottom:32,flex:1}],children:[(0,An.jsx)(En,{children:(0,hn._)(hm.thanksTitle),style:[t.expanded?pr.h1Expanded:pr.h1,fr.white,tl.out_bottom_s,bn.text_center]}),0!==o&&(0,An.jsx)(En,{children:(0,hn._)({fr:"Vous avez obtenu un score de "+i+"/"+o,en:"You got a score of "+i+"/"+o}),style:[pr.h3,fr.white,tl.out_bottom_s,bn.text_center]}),(0,An.jsx)(En,{children:(0,hn._)(hm.thanksDescription),style:[pr.body1,fr.white,tl.in_bottom_xl,bn.text_center]}),(0,An.jsx)(xl,{onPress:async()=>{await r(),n(ln.g.ADMIN),t.setTab(1),vn.O.add(vn.S.ACTIONS,!0)},color:u.y.WHITE,fontSize:14,fontWeight:"700",textColor:u.y.BLUE_DARK,children:(0,hn._)(hm.validationChallenge),style:{paddingLeft:16,paddingRight:16,paddingTop:1,paddingBottom:1,alignSelf:"center",marginBottom:18}}),(0,An.jsx)(xl,{onPress:()=>{r(),n(ln.g.ADMIN),t.setTab(0),vn.O.add(vn.S.INFO,!0)},color:u.y.BLUE_DARK,fontSize:14,fontWeight:"700",textColor:u.y.WHITE,children:(0,hn._)(hm.shareChallenge),style:{paddingLeft:16,paddingRight:16,paddingTop:1,paddingBottom:1,alignSelf:"center",borderColor:u.y.WHITE,borderWidth:1,borderRadius:24}})]})},Am=e=>{var t;const[n,o]=d.useState(e.getResponse(e.step)),[i,a]=d.useState(!1),s=e.step===e.total,l=(null===e||void 0===e||null===(t=e.question)||void 0===t?void 0:t.type)===zf.CHOICES_RESPONSE&&e.completed>e.step;return(0,An.jsxs)(Or.c,{behavior:"ios"===r.default.OS?"padding":"height",style:[bn.full_width,{maxWidth:1050,marginRight:"auto",marginLeft:"auto",paddingTop:32,paddingLeft:16,paddingRight:16,flex:1,backgroundColor:e.background}],children:[(0,An.jsx)(mm,{name:e.name,current:e.step,total:e.total}),s?(0,An.jsx)(bm,{challenge:e.challenge,responses:e.responses,quizResponses:e.quizResponses}):(0,An.jsxs)(jr.c,{style:{flex:1},children:[(0,An.jsx)(En,{style:[pr.h4,fr.black,tl.out_top_l,tl.out_bottom_xs],children:(0,hn._)(e.question.name)}),(0,An.jsx)(En,{style:[pr.body1,fr.grey2,tl.out_bottom_m],children:(0,hn._)(e.question.description)}),e.question.type===zf.TEXT&&(0,An.jsx)(pm,{response:n,setResponse:o})||e.question.type===zf.CHOICES_MULTI&&zf.CHOICES_RESPONSE&&(0,An.jsx)(fm,{answers:e.question.answers||[],multiple:!0,response:n,setResponse:o})||(e.question.type===zf.CHOICES_SINGLE||e.question.type===zf.CHOICES_SINGLE_OTHER)&&(0,An.jsx)(fm,{answers:e.question.answers||[],response:n,setResponse:o,other:e.question.type===zf.CHOICES_SINGLE_OTHER})||e.question.type===zf.CHOICES_RESPONSE&&(i?(0,An.jsx)(gm,{next:()=>{e.setStep(e.step+1),o(e.getResponse(e.step+1)),a(!1)},correct:n===e.question.solution,explanation:e.question.explanation}):(0,An.jsx)(fm,{solution:!0,answers:e.question.answers||[],response:n,setResponse:o,isBack:l})),!i&&(0,An.jsx)(vm,{ready:!l&&!!n&&"#"!==n,setNextStep:()=>{var t;l||(e.setResponse(e.step,n),(null===(t=e.question)||void 0===t?void 0:t.type)===zf.CHOICES_RESPONSE?a(!0):(e.setStep(e.step+1),o(e.getResponse(e.step+1))))}})]}),(0,An.jsx)(ym,{duration:e.duration,isFinished:s,step:e.step,completed:e.completed,setStep:t=>{t{const{navigate:e}=(0,f.Yi)(),t=d.useContext(yn.S),n=d.useRef(null),o=()=>{const e=()=>{var e;return null===(e=n.current)||void 0===e?void 0:e.scrollTo({y:0,x:0,animated:!1})};if(n.current)e();else{const t=setInterval((()=>{n.current&&(clearInterval(t),e())}),100)}};if(!t.expanded)return(0,An.jsxs)(Pr.K,{name:ln.g.ADMIN,navigate:e,style:{backgroundColor:u.y.WHITE,...(t.expanded||r.default.OS,{})},children:[0===t.tab&&(0,An.jsx)(Nc,{})||1===t.tab&&(0,An.jsx)(jr.c,{style:{paddingLeft:"5%",paddingRight:"5%",alignContent:"center"},showsVerticalScrollIndicator:!t.expanded,ref:n,children:(0,An.jsx)(Wf,{scrollOnTop:o})})||2===t.tab&&(0,An.jsx)(jr.c,{style:{paddingLeft:"5%",paddingRight:"5%",alignContent:"center",paddingBottom:20},showsVerticalScrollIndicator:!t.expanded,children:(0,An.jsx)(_f,{})})||3===t.tab&&(0,An.jsxs)(jr.c,{children:[(0,An.jsx)(Qf,{}),(0,An.jsx)(yg,{scrollOnTop:o})]}),(0,An.jsx)(vg,{onSettings:!1})]});let i;return(0,An.jsx)(Pr.K,{name:ln.g.ADMIN,navigate:e,onStartShouldSetResponder:e=>(e.persist(),"undefined"!==typeof i&&i(e.target),!0),children:(()=>{switch(t.tab){case 0:return(0,An.jsx)(Nc,{dropdownOutsideClick:e=>{i=e}});case 1:return(0,An.jsx)(jr.c,{style:t.expanded?fc.containerExpanded:fc.container,ref:n,children:(0,An.jsx)(p.c,{style:{alignSelf:"center",width:"100%"},children:(0,An.jsx)(Wf,{scrollOnTop:o})})});case 2:return(0,An.jsx)(jr.c,{style:t.expanded?fc.containerExpanded:fc.container,children:(0,An.jsx)(p.c,{style:t.expanded?fc.contentExpanded:fc.content,children:(0,An.jsx)(_f,{})})});case 3:return(0,An.jsxs)(jr.c,{style:t.expanded?fc.containerExpanded:fc.container,children:[(0,An.jsx)(Qf,{}),(0,An.jsx)(yg,{scrollOnTop:o})]});default:return(0,An.jsx)(p.c,{})}})()})},[ln.g.SETTINGS]:()=>{var e,t,n,o,i,a,l,c,h;const g=(0,f.Yi)(),m=d.useContext(yn.S),[y,v]=d.useState({firstname:null===(e=m.profile)||void 0===e?void 0:e.firstname,lastname:null===(t=m.profile)||void 0===t?void 0:t.lastname,email:null===(n=m.profile)||void 0===n?void 0:n.email,position:null===(o=m.profile)||void 0===o?void 0:o.position,department:null===(i=m.profile)||void 0===i?void 0:i.department,country:null===(a=m.profile)||void 0===a?void 0:a.country,emails_only:null===(l=m.profile)||void 0===l?void 0:l.emails_only}),[b,A]=d.useState(null===y||void 0===y?void 0:y.firstname),[x,S]=d.useState(null===y||void 0===y?void 0:y.lastname),[w,C]=d.useState(null===y||void 0===y?void 0:y.email),[_,E]=d.useState(null===y||void 0===y?void 0:y.position),[R,k]=d.useState(null===y||void 0===y?void 0:y.department),[I,T]=d.useState(null===y||void 0===y?void 0:y.country),[O,j]=d.useState(null===y||void 0===y?void 0:y.emails_only),[P,B]=d.useState(""),[L,D]=d.useState(""),[M,N]=d.useState();d.useEffect((()=>{s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:users/team/retrieve"}).execute().then((e=>{e&&(B(e.name),D(e.name),N(e.picture))}))}),[]);const[U,F]=d.useState(hn.O.get()),[H,G]=d.useState(m.profile.notificationsPreferences),[z,V]=d.useState(""),W=async()=>{if(Cg(w)){V("");const e={email:w,firstname:b,lastname:x,position:_,department:R,country:I,emails_only:O,language:U,notificationsPreferences:H,team_name:L},t=await s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:users/update"}).execute(e);t&&t.error?V(t.error):(await s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:users/team/update"}).execute({name:L}),B(L),K?"web"===r.default.OS?window.location.reload():(hn.O.set(U),m.setTab(1),g.replace(ln.g.LOADING)):(v(e),m.setProfile(e),pc()))}else V((0,hn._)(zn))},Q=b!==(null===y||void 0===y?void 0:y.firstname)||x!==(null===y||void 0===y?void 0:y.lastname)||w!==(null===y||void 0===y?void 0:y.email)||_!==(null===y||void 0===y?void 0:y.position)||R!==(null===y||void 0===y?void 0:y.department)||I!==(null===y||void 0===y?void 0:y.country)||O!==(null===y||void 0===y?void 0:y.emails_only)||L!==P,Y=H.challenge!==m.profile.notificationsPreferences.challenge||H.share!==m.profile.notificationsPreferences.share||H.reminder!==m.profile.notificationsPreferences.reminder||H.summary!==m.profile.notificationsPreferences.summary||H.chat!==m.profile.notificationsPreferences.chat,K=U!==hn.O.get(),q=Q||Y||K;let X=[];return null!==m&&void 0!==m&&null!==(c=m.profile)&&void 0!==c&&null!==(h=c.company)&&void 0!==h&&h.departments&&(X=m.profile.company.departments.split(",").map((e=>e.trim())).filter((e=>0!==e.length))),(0,An.jsx)(Pr.K,{name:ln.g.SETTINGS,navigate:g.replace,style:m.expanded?{minHeight:"inherit",height:"100vh"}:{},children:(0,An.jsxs)(Ag.c,{style:xg.page,children:[(0,An.jsx)(wg,{displaySave:q,save:W}),(0,An.jsx)(p.c,{style:{backgroundColor:u.y.BLUE_DARK,height:24},children:(0,An.jsx)(p.c,{style:{backgroundColor:u.y.WHITE,borderTopLeftRadius:24,borderTopRightRadius:24,height:"100%"}})}),(0,An.jsx)(jr.c,{style:{flex:1},children:"undefined"===typeof m.profile?(0,An.jsx)(p.c,{}):(0,An.jsx)(Sg,{error:z,email:w,setEmail:C,firstname:b,setFirstname:A,lastname:x,setLastname:S,position:_,setPosition:E,department:R,setDepartment:k,country:I,setCountry:T,save:W,cancel:()=>{A(y.firstname),S(y.lastname),C(y.email),E(y.position),k(y.department),T(y.country),D(P||"")},displaySave:q,emailsOnly:O,setEmailsOnly:j,locale:U,setLocale:F,notifications:H,setNotifications:(e,t)=>{G({...H,[e]:t})},departments:X,teamName:L,setTeamName:D,teamPicture:M,setTeamPicture:N})})]})})},[ln.g.NOTIFICATIONS]:()=>{const{navigate:e}=(0,f.Yi)(),[t,n]=d.useState(void 0);Rg=()=>{s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:notifications/list"}).execute().then((e=>{n(e)}))};const r=d.useContext(yn.S),o=(0,f.MJ)(),{replace:i}=(0,f.Yi)(),a=e=>()=>{r.setTab(e),o.name!==ln.g.ADMIN&&(i(ln.g.ADMIN),vn.O.add(vn.S.ACTIONS,!0))};d.useEffect((()=>{let e=!0;return Rg(),s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:notifications/seen"}).execute().then((()=>{e&&r.setNotifications(0)})),()=>{e=!1}}),[]);const[l,c]=d.useState();return(0,An.jsxs)(Pr.K,{style:r.expanded?{width:"60%",marginRight:"auto",marginLeft:"auto",paddingTop:20}:{},name:ln.g.NOTIFICATIONS,navigate:e,children:[!r.expanded&&(0,An.jsx)(_g,{}),(0,An.jsx)(jr.c,{style:{backgroundColor:u.y.WHITE},children:"undefined"!==typeof t&&t.map(((e,t)=>(0,An.jsxs)(p.c,{style:{backgroundColor:e.seen?"white":u.y.GREY_LIGHT_X,paddingTop:15,paddingRight:15,paddingLeft:15},children:[(0,An.jsx)(En,{children:Jl(e.date),style:{alignSelf:"flex-end",color:u.y.GREY2}}),(0,An.jsx)(cn.c,{onPress:()=>{switch(e.type){case 1:case 2:a(1)();break;case 3:a(0)();break;case 5:l&&l.id===e._id?c(void 0):c({id:e._id,feed:e.feed})}},children:(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center",flex:1,paddingLeft:10,paddingBottom:10},children:["undefined"!==typeof e.author_picture&&(0,An.jsx)(Rn,{bgColor:u.y.GREY_LIGHT_X,color:"black",size:40,name:e.author_name,source:e.author_picture,style:{marginRight:10}}),(0,An.jsxs)(p.c,{style:{flex:1},children:[(0,An.jsx)(En,{style:{fontWeight:"bold",color:u.y.GREY2,fontSize:15},children:e.title}),(0,An.jsx)(En,{style:{alignItems:"stretch",flexDirection:"row",width:"100%",flex:1},children:(0,An.jsx)(En,{style:{fontSize:15},children:(()=>{if(e.message){const t=e.message.split("**");return 1===t.length?t[0]:[(0,An.jsx)(En,{style:{fontWeight:"bold"},children:t[1]},"0"),(0,An.jsx)(En,{children:t[2]},"1")]}return""})()})})]})]})}),(null===l||void 0===l?void 0:l.id)===e._id&&l.feed&&(0,An.jsx)(p.c,{children:(0,An.jsx)(Eg,{id:l.feed})}),(0,An.jsx)(yr,{color:u.y.GREY1,minWidth:"90%",height:1,style:{paddingTop:20}})]},t)))})]})},[ln.g.OFFLINE]:()=>{const{navigate:e,replace:t}=(0,f.Yi)(),n=d.useContext(yn.S),[o,i]=d.useState(l.Av.authErrorGoogle),[s,h]=d.useState(l.Av.authErrorMS),[g,m]=d.useState(l.Av.authErrorLP);(0,d.useEffect)((()=>{"web"!==r.default.OS&&(a.cp.getItem("authErrorMS").then((e=>{e&&(h(e),a.cp.removeItem("authErrorMS"))})),a.cp.getItem("authErrorGoogle").then((e=>{e&&(i(e),a.cp.removeItem("authErrorGoogle"))})),a.cp.getItem("authErrorLP").then((e=>{e&&(m(e),a.cp.removeItem("authErrorLP"))})))}),[]);const y="cmacgm"!==c.Y.name;return(0,An.jsx)(Pr.K,{name:ln.g.OFFLINE,style:{backgroundColor:u.y.BLUE_DARK},navigate:e,children:(0,An.jsx)(jr.c,{children:(0,An.jsxs)(p.c,{style:[{backgroundColor:u.y.BLUE_DARK,alignItems:"center",paddingLeft:n.expanded||"web"!==r.default.OS?40:24,paddingRight:n.expanded||"web"!==r.default.OS?40:24},n.expanded?{width:"60%",marginRight:"auto",marginLeft:"auto",marginTop:20}:{},n.expanded||"web"!==r.default.OS?{}:{width:"100%"}],children:[(0,An.jsx)(En,{style:[bn.text_center,pr.h2,fr.white,tl.out_top_l],children:(0,hn._)(Sl)}),(0,An.jsx)(En,{style:[bn.text_center,pr.body1,fr.white,tl.out_top_m],children:(0,hn._)(wl)}),(0,An.jsxs)(p.c,{style:{width:n.expanded||"web"!==r.default.OS?"100%":"70%",minWidth:n.expanded||"web"!==r.default.OS?0:300,marginTop:32,paddingRight:n.expanded||"web"!==r.default.OS?40:0,paddingLeft:n.expanded||"web"!==r.default.OS?40:0},children:[y&&(0,An.jsx)(xl,{fontWeight:"700",color:u.y.YELLOW_DARK,textColor:"black",fontSize:16,children:(0,hn._)({fr:"Se connecter avec votre compte entreprise",en:"Sign in with your company account"}),style:[rc.button,n.expanded?{width:"70%",minWidth:200,maxWidth:400,marginRight:"auto",marginLeft:"auto",marginTop:20}:{marginTop:22,paddingLeft:4,paddingRight:4}],onPress:()=>{t(ln.g.LOGIN,{company:!0}),vn.O.add(vn.S.LOGIN,!1)}}),o&&(0,An.jsx)(En,{children:(0,hn._)(El(o,"Google")),style:[pr.body2,fr.red,tl.out_top_m,bn.text_center]}),s&&(0,An.jsx)(En,{children:(0,hn._)(El(s,"Microsoft")),style:[pr.body2,fr.red,tl.out_top_m,bn.text_center]}),g&&(0,An.jsx)(En,{children:(0,hn._)(El(g,"La Poste")),style:[pr.body2,fr.red,tl.out_top_m,bn.text_center]}),y&&(0,An.jsx)(yr,{height:1,color:u.y.WHITE,style:{width:n.expanded?"70%":"100%",marginTop:28,marginBottom:n.expanded?7:0}}),(0,An.jsx)(xl,{style:[rc.button,n.expanded?{width:"70%",minWidth:200,maxWidth:400,marginRight:"auto",marginLeft:"auto",marginTop:20}:{}],color:u.y.WHITE,textColor:u.y.BLUE_DARK,fontWeight:"700",fontSize:16,children:(0,hn._)(_l),onPress:()=>{t(ln.g.LOGIN),vn.O.add(vn.S.LOGIN,!1)}}),(0,An.jsx)(un.c,{style:[{fontSize:16,fontWeight:"700",color:u.y.WHITE,textDecorationLine:"underline",textAlign:"center",marginTop:32},n.expanded?{width:"70%",minWidth:200,maxWidth:400,marginRight:"auto",marginLeft:"auto"}:{}],children:(0,hn._)(Cl),onPress:()=>{t(ln.g.REGISTER),vn.O.add(vn.S.REGISTER,!1)}})]}),(0,An.jsx)(mr,{})]})})})},[ln.g.LOGIN]:e=>{var t,n;const{navigate:o,replace:i}=(0,f.Yi)(),c=d.useContext(yn.S),[h,g]=d.useState(""),[m,y]=d.useState(""),[v,b]=d.useState(!1),[A,x]=d.useState(""),[S,w]=d.useState(null),[C,_]=d.useState(0),E=!(null!==(t=e.route)&&void 0!==t&&null!==(n=t.params)&&void 0!==n&&n.company),R=v||!h||E&&!m;function k(){s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:users/sso"}).execute({email:h}).then((e=>{let{error:t,type:n}=e;if(t)throw t;if(!n)throw(0,hn._)(Wl);{const e=(0,l.Ki)(n);"web"===r.default.OS?window.location.href=e:kn.c.openURL(e)}})).catch((e=>{x("string"===typeof e?e:(0,hn._)(Wl))})).finally((()=>{_(C+1),b(!1)}))}return(0,An.jsx)(Pr.K,{name:ln.g.LOGIN,navigate:o,style:{flex:1,backgroundColor:u.y.WHITE},children:(0,An.jsx)(Or.c,{style:[Ll.container,{backgroundColor:u.y.WHITE}],behavior:"ios"===r.default.OS?"padding":"height",children:(0,An.jsx)(jr.c,{style:{width:"100%"},children:(0,An.jsxs)(p.c,{style:{width:"100%"},children:[(0,An.jsx)(Pl,{bgColor:u.y.BLUE_DARK,title:(0,hn._)(Ml)}),(0,An.jsx)(p.c,{style:{backgroundColor:u.y.WHITE,flex:1},children:(0,An.jsxs)(p.c,{style:[{maxWidth:400,marginRight:"auto",marginLeft:"auto",width:"100%"},c.expanded?{}:{paddingLeft:16,paddingRight:16}],children:[(0,An.jsx)(bl,{fields:[{name:(0,hn._)(Ul),value:h,onChange:g},...E?[{name:(0,hn._)(Fl),value:m,onChange:y,password:!0}]:[]]}),(0,An.jsx)(Ol,{onChange:w,action:"login"},"captcha-login-"+C),E&&(0,An.jsx)(cn.c,{onPress:()=>{i(ln.g.PASSWORD_RESET),vn.O.add(vn.S.RESET,!1)},style:[tl.out_top_m],children:(0,An.jsx)(En,{style:[fr.black,pr.body1,{textDecorationLine:"underline"}],children:(0,hn._)(Gl)})}),v&&(0,An.jsx)(En,{style:[bn.text_center,pr.body1,tl.out_bottom_m,fr.green_light],children:(0,hn._)(Nl)})||A.length>0&&(0,An.jsx)(En,{children:A,style:[pr.body2,fr.red,tl.out_top_m,bn.text_center]}),(0,An.jsx)(xl,{style:[c.expanded?{minWidth:200}:{},{borderRadius:50,height:40,marginTop:16}],color:R?u.y.GREY1:u.y.YELLOW_DARK,textColor:R?u.y.GREY2:u.y.BLUE_DARK,fontWeight:"700",fontSize:16,disabled:R,children:(0,hn._)(Hl),onPress:()=>{v||(b(!0),E?s.g.account.login(h,m,S).then((e=>{e&&a.cp.setItem("token",e.jwt).then((()=>{Promise.resolve((0,Dl.e)()),Tl(),i(ln.g.LOADING)}))})).catch((e=>{"string"===typeof e?"EXTERNAL_ACCOUNT"===e?k():x(e):x((0,hn._)(Wl))})).finally((()=>{_(C+1),b(!1)})):k())}}),(0,An.jsx)(yr,{minWidth:"100%",color:u.y.GREY1,height:1,style:[tl.out_top_l,tl.in_bottom_m]}),E&&(0,An.jsx)(En,{style:[fr.black,pr.h5,tl.in_bottom_m],children:(0,hn._)(zl)}),E&&(0,An.jsx)(cn.c,{onPress:()=>{i(ln.g.REGISTER),vn.O.add(vn.S.REGISTER,!1)},children:(0,An.jsx)(Bl,{text:(0,hn._)(Vl)})}),E&&(0,An.jsx)(yr,{minWidth:"100%",color:u.y.GREY1,height:1,style:[tl.out_top_m,tl.in_bottom_m]}),(0,An.jsx)(jl,{})]})})]})})})})},[ln.g.REGISTER]:()=>{const e=(0,f.Yi)(),t=d.useContext(yn.S),[o,i]=d.useState(""),[l,c]=d.useState(""),[h,g]=d.useState(""),[m,y]=d.useState(""),[v,b]=d.useState(""),[A,x]=d.useState(""),[S,w]=d.useState(!1),[C,_]=d.useState(!1),[E,R]=d.useState(""),[k,I]=d.useState(null),[T,O]=d.useState(!1),[j,P]=d.useState(0);let B=!0;return d.useEffect((()=>()=>{B=!1}),[]),(0,An.jsx)(Pr.K,{name:ln.g.REGISTER,navigate:e.navigate,style:{flex:1,backgroundColor:u.y.WHITE},children:(0,An.jsx)(Or.c,{behavior:"ios"===r.default.OS?"padding":"height",style:{width:"100%"},children:(0,An.jsx)(jr.c,{style:{width:"100%"},children:(0,An.jsxs)(p.c,{style:{flex:1,backgroundColor:u.y.WHITE,width:"100%",marginBottom:32},children:[(0,An.jsx)(Pl,{bgColor:u.y.BLUE_DARK,title:(0,hn._)(nl)}),(0,An.jsxs)(p.c,{style:[{maxWidth:400,marginRight:"auto",marginLeft:"auto",width:"100%"},t.expanded?{}:{paddingLeft:16,paddingRight:16}],children:[(0,An.jsx)(bl,{setReady:_,fields:[{name:(0,hn._)(rl),value:o,onChange:i,error:(0,hn._)(hl)},{name:(0,hn._)(ol),value:l,onChange:c,error:(0,hn._)(pl)},{name:(0,hn._)(il),value:h,onChange:g,error:(0,hn._)(fl)},{name:(0,hn._)(al),value:v,onChange:b,type:"choices",values:Rl,error:(0,hn._)(ml)},{name:(0,hn._)(sl),value:m,onChange:y,type:"email"},{name:(0,hn._)(ll),value:A,onChange:x,password:!0}]}),(0,An.jsx)(Ol,{onChange:I,action:"register"},"captcha-register-"+j),(0,An.jsx)(cn.c,{onPress:()=>{let e;e="fr"===hn.O.get()?"https://www.maoboa.co/reglesrgpdplateforme":"https://www.maoboa.co/privacypolicy","web"===r.default.OS?window.open(e,"_blank"):kn.c.openURL(e)},style:[tl.out_top_m],children:(0,An.jsx)(En,{style:[{textDecorationLine:"underline"},fr.black,pr.body2,bn.text_center],children:(0,hn._)(cl)})}),E.length>0&&(0,An.jsx)(En,{style:[pr.body2,fr.red,tl.out_top_m,bn.text_center],children:E}),T&&(0,An.jsx)(En,{style:[pr.body2,fr.red,tl.out_top_m,bn.text_center],children:(0,hn._)(vl("web"===r.default.OS))}),T&&(0,An.jsx)(cn.c,{onPress:()=>{const e="mailto:support@maoboa.co";"web"===r.default.OS?window.open(e,"_blank"):kn.c.openURL(e)},children:(0,An.jsx)(En,{style:[{textDecorationLine:"underline"},fr.red,pr.body2,bn.text_center],children:"support@maoboa.co"})}),(0,An.jsx)(xl,{style:[tl.out_top_m,{borderRadius:50,height:40,marginTop:16}],color:S||!C?u.y.GREY1:u.y.YELLOW_DARK,textColor:S||!C?u.y.GREY2:u.y.BLUE_DARK,disabled:S||!C,fontWeight:"700",fontSize:16,onPress:()=>{S||(R(""),w(!0),O(!1),s.g.account.resolve({code:o}).then((()=>{s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:users/register"}).execute({invitationCodeField:o,firstnameField:l,lastnameField:h,emailField:m,passwordField1:A,locale:hn.O.get(),country:v,captcha:k}).then((t=>{B&&(R(""),s.g.config.setToken(t.jwt),a.cp.setItem("token",t.jwt).then((()=>{B&&(Tl(),e.replace(ln.g.LOADING))})))})).catch((e=>{B&&("CAPTCHA"===e?O(!0):R(e))})).finally((()=>{P(j+1),B&&w(!1)}))})))},children:(0,hn._)(Cl)}),(0,An.jsx)(yr,{minWidth:"100%",color:u.y.GREY1,height:1,style:[tl.out_top_l,tl.in_bottom_m]}),(0,An.jsx)(En,{style:[fr.black,pr.h5,tl.in_bottom_m],children:(0,hn._)(ul)}),(0,An.jsx)(cn.c,{onPress:()=>{e.replace(ln.g.LOGIN),vn.O.add(vn.S.LOGIN,!1)},children:(0,An.jsx)(Bl,{text:(0,hn._)(dl),picture:n(7700)})}),(0,An.jsx)(yr,{minWidth:"100%",color:u.y.GREY1,height:1,style:[tl.out_top_m,tl.in_bottom_m]}),(0,An.jsx)(jl,{})]})]})})})})},[ln.g.WELCOME]:()=>{var e,t;const{navigate:r,replace:o}=(0,f.Yi)(),i=d.useContext(yn.S),[a,l]=d.useState(!1);return d.useEffect((()=>{let e=!0;return setTimeout((()=>{e&&(i.profile.company.noCommunities?(r(ln.g.ADMIN),vn.O.add(vn.S.ACTIONS,!0)):(o(ln.g.PROJECTS,{user:i.profile}),vn.O.add(vn.S.PROJECTS,!0)))}),4e3),i.profile.company.noCommunities&&s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:users/noCommunities"}).execute(),()=>{e=!1}}),[]),(0,An.jsx)(Pr.K,{name:ln.g.WELCOME,navigate:r,style:kg.container,children:(0,An.jsxs)(p.c,{style:{flex:1,alignItems:"center",justifyContent:"center"},children:[(0,An.jsx)(le.c,{style:{width:200,height:100,resizeMode:"contain"},source:n(560)}),(0,An.jsx)(En,{style:{color:"white",fontWeight:"bold",marginBottom:15,fontSize:20},children:"X"}),(0,An.jsx)(p.c,{style:{borderRadius:100},children:(0,An.jsx)(le.c,{style:{width:150,height:150,resizeMode:"contain"},source:{uri:null===(e=i.profile)||void 0===e||null===(t=e.company)||void 0===t?void 0:t.picture},onLoadEnd:()=>{a||l(!0)}})})]})})},[ln.g.PROJECTS]:()=>{const e=d.useContext(yn.S),[t,o]=d.useState([]);d.useEffect((()=>{let e=!0;return 0===t.length&&s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:projects/list"}).execute().then((t=>{e&&Array.isArray(t)&&o(t)})).catch((e=>{console.log("[ERROR]",e)})),()=>{e=!1}}),[]);const{navigate:i,replace:a}=(0,f.Yi)(),l=e=>{s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:users/setProjects"}).execute({projects:t.map((e=>e._id))}).then((()=>{a(ln.g.COUNTDOWN,{skip:e}),vn.O.add(vn.S.COUNTDOWN,!0)}))};return 1===t.length?(l(!0),null):(0,An.jsx)(Pr.K,{style:{backgroundColor:u.y.BLUE_DARK},name:ln.g.PROJECTS,navigate:i,children:0!==t.length&&(0,An.jsxs)(jr.c,{style:e.expanded?{height:"1vh"}:{},children:[(0,An.jsxs)(p.c,{style:{marginTop:20,marginBottom:20},children:[(0,An.jsx)(En,{style:[tl.out_top_m,bn.text_center,fr.white,pr.h2,{maxWidth:"95%",alignSelf:"center"}],children:(0,hn._)(Zp)}),(0,An.jsx)(En,{style:[fr.white,pr.body1,tl.out_bottom_m,tl.out_top_s,bn.text_center,{maxWidth:"95%",alignSelf:"center"}],children:(0,hn._)($p)})]}),(0,An.jsx)(p.c,{style:{backgroundColor:u.y.WHITE},children:(0,An.jsx)(p.c,{style:[Ig.cards],children:t.map(((a,l)=>(0,An.jsx)(p.c,{style:[Ig.cardOut],children:(()=>{let c;return"web"===r.default.OS&&(c=e=>{}),(0,An.jsxs)(p.c,{style:e.expanded?{maxWidth:1e3,alignSelf:"center",width:"100%"}:{},children:[(0,An.jsxs)(En,{style:[pr.h6,fr.black,tl.out_top_m,tl.out_bottom_s],children:[(0,hn._)(ef),l+1]}),(0,An.jsxs)(p.c,{style:[Ig.cardIn,{backgroundColor:u.y.BLUE_LIGHT_X,borderRadius:20}],children:[(0,An.jsxs)(p.c,{style:e.expanded?{flexDirection:"row",justifyContent:"space-between"}:{},children:[(0,An.jsxs)(p.c,{style:Ig.maxWidth,children:[(0,An.jsx)(En,{style:[pr.h4,fr.blue_dark,tl.out_top_s],children:(0,hn._)(a.data.name)}),(0,An.jsx)(En,{style:[pr.caption,fr.blue_dark,tl.out_bottom_s,tl.out_top_xs],children:(0,hn._)(a.data.tag)}),(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center",paddingRight:50},children:[(0,An.jsx)(Rn,{bgColor:u.y.WHITE,color:u.y.BLACK,size:40,source:a.data.organization.picture,name:a.data.organization.name,style:{alignSelf:"center",marginTop:10,marginBottom:10,marginRight:10}}),(0,An.jsx)(En,{style:[pr.h4,fr.blue_dark],children:a.data.organization.name})]})]}),(0,An.jsxs)(p.c,{style:[{flexDirection:"row",justifyContent:"space-around",alignItems:"center"},e.expanded?{minWidth:300}:{}],children:[(0,An.jsx)(xl,{onPress:()=>{s.g.recipes.metrics.get({project:"maoboa:app",id:"maoboa:app:v3:projects/selected"}).add({projectName:a.data.name}),"web"===r.default.OS?c(!0):i(ln.g.PROJECT_INFO,{project:a})},children:(0,hn._)(af),color:u.y.BLUE_LIGHT_X,textColor:u.y.BLUE_DARK,fontWeight:"700",fontSize:16,style:{marginTop:20,marginBottom:20,paddingLeft:12,paddingRight:12,borderColor:u.y.BLUE_DARK,borderWidth:1}}),(0,An.jsx)(cn.c,{disabled:l===t.length-1,onPress:()=>o(Tg(t,l,l+1)),children:(0,An.jsx)(p.c,{style:[Ig.arrowButton,{opacity:l===t.length-1?.2:1}],children:(0,An.jsx)(le.c,{style:Ig.arrow,source:n(6724)})})}),(0,An.jsx)(cn.c,{disabled:0===l,onPress:()=>o(Tg(t,l,l-1)),children:(0,An.jsx)(p.c,{style:[Ig.arrowButton,{opacity:0===l?.2:1}],children:(0,An.jsx)(le.c,{style:Ig.arrowDown,source:n(6724)})})})]})]}),(0,An.jsx)(sc,{width:e.expanded||"web"!==r.default.OS?800:"100%",handler:e=>{c=e},children:(0,An.jsx)(jr.c,{style:{marginTop:8,paddingLeft:16,paddingRight:16,paddingBottom:16},children:(0,An.jsx)(cf,{data:a.data})}),style:{height:"100%",maxHeight:700}})]})]})})()},a._id)))})}),(0,An.jsx)(cn.c,{onPress:()=>l(!1),style:[Ig.submit,{backgroundColor:u.y.YELLOW_DARK}],children:(0,An.jsx)(En,{style:[pr.h4,fr.blue_dark],children:(0,hn._)(sf)})})]})})},[ln.g.PROJECT_INFO]:e=>{const{navigate:t,goBack:n}=(0,f.Yi)();return(0,An.jsx)(Pr.K,{name:ln.g.PROJECT_INFO,navigate:t,style:{backgroundColor:u.y.WHITE},children:(0,An.jsx)(jr.c,{children:(0,An.jsx)(cf,{data:e.route.params.project.data,goBack:n})})})},[ln.g.COUNTDOWN]:e=>{var t,r;const{replace:o,navigate:i}=(0,f.Yi)(),[a]=d.useState(new X.default.Value(0)),l=a.interpolate({inputRange:[0,1],outputRange:["0deg","360deg"]}),c=!(null===e||void 0===e||null===(t=e.route)||void 0===t||null===(r=t.params)||void 0===r||!r.skip),[u,h]=d.useState({});return d.useEffect((()=>{let e=!0;return s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:countdown"}).execute().then((t=>{if(t=new Date(t),e){const e=t.getTime()>(new Date).getTime();h({startDate:t,countdown:e}),e||(c?(o(ln.g.VALIDATION,{skip:!0}),vn.O.add(vn.S.VALIDATION,!0)):(X.default.loop(X.default.timing(a,{toValue:1,easing:de.c.linear,useNativeDriver:!0,duration:4e3})).start(),setTimeout((()=>{o(ln.g.VALIDATION,{skip:!1}),vn.O.add(vn.S.VALIDATION,!0)}),4e3)))}})),()=>{e=!1}}),[]),(0,An.jsx)(Pr.K,{name:ln.g.COUNTDOWN,style:Ql.container,navigate:i,children:!u.startDate&&(0,An.jsx)(p.c,{})||(u.countdown?(0,An.jsxs)(p.c,{style:{flex:1,alignItems:"center"},children:[(0,An.jsx)(En,{style:[fr.white,pr.h2,tl.out_top_l,tl.out_bottom_m,{paddingLeft:10,paddingRight:10}],children:(0,hn._)(ec)}),(0,An.jsx)($l,{style:[pr.h2,tl.out_bottom_s,{maxWidth:250,textAlign:"center"}],children:"\ud83c\udf89"}),(0,An.jsx)(En,{style:[fr.white,pr.body1,tl.out_bottom_m,tl.out_top_m,{maxWidth:250,textAlign:"center"}],children:(0,hn._)(tc)}),(0,An.jsx)(p.c,{style:{marginTop:25},children:(0,An.jsx)(Zl,{date:u.startDate,duration:172800,onComplete:()=>{o(ln.g.VALIDATION,{skip:c}),vn.O.add(vn.S.VALIDATION,!0)}})})]}):(0,An.jsxs)(p.c,{style:{flex:1,alignItems:"center",justifyContent:"center"},children:[(0,An.jsxs)(p.c,{style:{width:86,height:86,justifyContent:"center",alignItems:"center",marginBottom:25},children:[(0,An.jsx)(le.c,{source:n(7440),style:{width:36,height:18}}),(0,An.jsx)(X.default.Image,{source:n(5284),style:{width:86,height:86,position:"absolute",transform:[{rotate:l}]}})]}),(0,An.jsx)(En,{style:[pr.h4,fr.white,bn.text_center,{marginLeft:20,marginRight:20}],children:(0,hn._)(nc)})]}))})},[ln.g.VALIDATION]:e=>{const{navigate:t,replace:n}=(0,f.Yi)(),r=d.useContext(yn.S),[o,i]=d.useState(void 0),a=()=>{s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:users/validate"}).execute().then((()=>{n(ln.g.LOADING)}))};return d.useEffect((()=>{let t=!0;return s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:projects/attribution"}).execute().then((n=>{var r,o;t&&(null!==e&&void 0!==e&&null!==(r=e.route)&&void 0!==r&&null!==(o=r.params)&&void 0!==o&&o.skip?a():i(n))})).catch((e=>{console.log("[ERROR]",e)})),()=>{t=!1}}),[]),(0,An.jsx)(Pr.K,{name:ln.g.VALIDATION,navigate:t,children:o?(0,An.jsx)(jr.c,{style:Og.container,children:(0,An.jsxs)(p.c,{style:[Og.container,r.expanded?{width:"60%",marginRight:"auto",marginLeft:"auto",marginTop:20,alignItems:"center"}:{width:"90%",marginRight:"auto",marginLeft:"auto"}],children:[(0,An.jsx)(En,{style:[pr.h2,fr.white,tl.out_bottom_m,tl.out_top_l,bn.text_center,{alignSelf:"center"}],children:(0,hn._)(jg)}),(0,An.jsxs)(p.c,{style:[Og.card,tl.out_top_m,Og.borderRadiusTop,r.expanded?{padding:20}:{padding:15,alignSelf:"center"}],children:[(0,An.jsxs)(p.c,{style:{alignItems:"flex-start"},children:[(0,An.jsx)(En,{style:[pr.h3,fr.blue_dark],children:(0,hn._)(o.project.name)}),(0,An.jsx)(En,{style:[tl.out_bottom_m,tl.out_top_s,fr.blue_dark,pr.body2],children:(0,hn._)(o.project.tag)})]}),(0,An.jsx)(p.c,{style:[Og.projectContainer],children:(0,An.jsxs)(p.c,{style:[{flexDirection:"row",alignItems:"center"}],children:[(0,An.jsx)(Rn,{source:o.project.organization.picture,name:o.project.organization.name,size:50,bgColor:"white",color:"red",style:{marginRight:16}}),(0,An.jsx)(En,{style:[fr.blue_dark,pr.h4,{maxWidth:200}],children:o.project.organization.name})]})})]}),(0,An.jsxs)(p.c,{style:[Og.card,Og.borderRadiusBottom,r.expanded?{paddingLeft:20,paddingBottom:20,paddingRight:20}:{paddingLeft:15,paddingBottom:15,paddingRight:15,alignSelf:"center"}],children:[(0,An.jsx)(En,{style:[fr.blue_dark,pr.h3,tl.out_bottom_m,{textAlign:"left"}],children:(0,hn._)(Pg)}),(0,An.jsx)(Jp,{users:o.users,bgColor:u.y.WHITE,color:u.y.BLUE_DARK,bgColorPlus:u.y.WHITE,max:5,size:35})]}),(0,An.jsx)(xl,{children:(0,hn._)(Bg),color:u.y.YELLOW_DARK,textColor:u.y.BLUE_DARK,fontSize:16,fontWeight:"700",style:Og.button,onPress:a})]})}):(0,An.jsx)(p.c,{})})},[ln.g.PASSWORD_RESET]:()=>{const e=(0,f.Yi)(),t=d.useContext(yn.S),[n,o]=d.useState(""),[i,l]=d.useState(""),[c,h]=d.useState(""),[g,m]=d.useState(""),[y,v]=d.useState(""),[b,A]=d.useState(!1),[x,S]=d.useState(null),[w,C]=d.useState(0);let _=!0;return d.useEffect((()=>()=>{_=!1}),[]),(0,An.jsx)(Pr.K,{name:ln.g.REGISTER,navigate:e.navigate,style:Lg.container,children:(0,An.jsx)(Or.c,{style:[Ll.container,{backgroundColor:u.y.WHITE}],behavior:"ios"===r.default.OS?"padding":"height",children:(0,An.jsxs)(jr.c,{style:{width:"100%"},children:[(0,An.jsx)(p.c,{style:{width:"100%"},children:(0,An.jsx)(Pl,{bgColor:u.y.BLUE_DARK,title:(0,hn._)(Dg)})}),(0,An.jsxs)(p.c,{style:[{maxWidth:400,marginRight:"auto",marginLeft:"auto",width:"100%"},t.expanded?{}:{paddingLeft:16,paddingRight:16}],children:[b&&(0,An.jsx)(bl,{fields:[{name:(0,hn._)(Ng),value:i,onChange:l},{name:(0,hn._)(Ug),value:g,onChange:m,password:!0},{name:(0,hn._)(Fg),value:y,onChange:v,password:!0}]},"step2")||(0,An.jsx)(bl,{fields:[{name:(0,hn._)(Mg),value:n,onChange:o}]},"step1"),(0,An.jsx)(Ol,{onChange:S,action:"password"},"captcha-password-"+w),c.length>0&&(0,An.jsx)(En,{style:[pr.body2,fr.red,bn.text_center,tl.out_top_m],children:c}),(0,An.jsx)(xl,{style:[{width:"100%",height:40,borderRadius:50,marginTop:16}],color:u.y.YELLOW_DARK,textColor:u.y.BLACK,fontSize:16,fontWeight:"700",onPress:()=>{b?0===i.length?h((0,hn._)(zg)):0===g.length?h((0,hn._)(Vg)):g.length<8?h((0,hn._)(Wg)):g!==y?h((0,hn._)(Qg)):s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:users/resetPasswordUpdate"}).execute({email:n,code:i,password:g,locale:hn.O.get(),captcha:x}).then((t=>{let{jwt:n}=t;n&&a.cp.setItem("token",n).then((()=>{_&&(Tl(),e.replace(ln.g.LOADING))}))})).catch((e=>{C(w+1),h(e)})):Cg(n)?s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:users/resetPasswordCode"}).execute({email:n}).then((e=>{e.message?h(e.message):(h((0,hn._)(Gg)),A(!0))})):h((0,hn._)(Hg))},children:(0,hn._)(Yg)}),(0,An.jsx)(yr,{minWidth:"100%",color:u.y.GREY1,height:1,style:[tl.out_top_l,tl.in_bottom_m]}),(0,An.jsx)(En,{style:[fr.black,pr.h5,tl.in_bottom_m],children:(0,hn._)(Kg)}),(0,An.jsx)(cn.c,{onPress:()=>{e.replace(ln.g.LOGIN),vn.O.add(vn.S.LOGIN,!1)},children:(0,An.jsx)(Bl,{text:(0,hn._)(qg)})}),(0,An.jsx)(yr,{minWidth:"100%",color:u.y.GREY1,height:1,style:[tl.out_top_m,tl.in_bottom_m]}),(0,An.jsx)(jl,{})]})]})})})},[ln.g.CHAT]:()=>{const e=d.useContext(yn.S),t=(0,f.Yi)(),[n,o]=d.useState({loaded:!1,users:{},messages:[]});return d.useEffect((()=>("android"===r.default.OS&&i.c.setBackgroundColor(u.y.PURPLE),s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:chat"}).execute().then((e=>{o({...e,loaded:!0})})),e.setMessages(0),()=>{"android"===r.default.OS&&i.c.setBackgroundColor(u.y.BLUE_DARK)})),[]),(0,An.jsx)(Pr.K,{name:ln.g.CHAT,navigate:t.navigate,style:{backgroundColor:u.y.BLUE_DARK},children:(0,An.jsxs)(Ag.c,{style:{backgroundColor:u.y.WHITE,flex:1},children:[n.loaded&&(0,An.jsx)(am,{users:n.users}),n.loaded&&(0,An.jsx)(dm,{users:n.users,messages:n.messages})]})})},[ln.g.CHAT_MEMBERS]:e=>{const{navigate:t,goBack:o}=(0,f.Yi)();return(0,An.jsxs)(Pr.K,{name:ln.g.CHAT_MEMBERS,navigate:t,children:[(0,An.jsxs)(p.c,{style:[bn.horizontal,{backgroundColor:u.y.BLUE_DARK,height:50,paddingLeft:16,paddingRight:16,paddingTop:6,paddingBottom:6,alignItems:"center"}],children:[(0,An.jsx)(xl,{fontSize:16,style:[{borderWidth:0},"web"===r.default.OS?{boxShadow:"none"}:{}],sideLeft:(0,An.jsx)(le.c,{style:{height:24,width:24,resizeMode:"contain",alignContent:"center",marginRight:8},source:n(516)}),children:"",onPress:()=>{o(),e.route.params.standalone?vn.O.add(vn.S.IMPACT,!0):vn.O.add(vn.S.CHAT,!0)}}),(0,An.jsx)(un.c,{style:[pr.h3,fr.white],children:(0,hn._)($g)})]}),(0,An.jsxs)(jr.c,{style:{paddingLeft:16,paddingRight:16,backgroundColor:u.y.WHITE},children:[!e.route.params.standalone&&(0,An.jsx)(un.c,{style:[pr.body1,fr.black,tl.out_top_s,tl.out_bottom_s],children:(0,hn._)(em)}),(0,An.jsx)(im,{users:e.route.params.users,displayPoints:!0})]})]})},[ln.g.COMMUNITY_MEMBERS]:e=>{const{navigate:t}=(0,f.Yi)();return(0,An.jsxs)(Pr.K,{name:ln.g.COMMUNITY_MEMBERS,navigate:t,style:{backgroundColor:u.y.WHITE},children:[(0,An.jsx)(ag,{bgColor:u.y.WHITE,blackArrow:!0,title:(0,hn._)(Af),titleStyle:[pr.h3,fr.black]}),(0,An.jsx)(jr.c,{style:{paddingLeft:16,paddingRight:16,paddingBottom:16},children:(0,An.jsx)(Pc,{users:e.route.params.users,bgColor:u.y.BLUE_LIGHT_X,color:u.y.BLUE_DARK,size:50,description:(0,hn._)(xf),textStyle:[pr.body1,fr.black,tl.out_bottom_s]})})]})},[ln.g.HIGHLIGHTS]:e=>{var t;const{navigate:n}=(0,f.Yi)(),o=d.useContext(yn.S),[i,a]=d.useState(dg(null===(t=e.route.params)||void 0===t?void 0:t.projects));return d.useEffect((()=>{var t;let n=!0;return null!==(t=e.route.params)&&void 0!==t&&t.projects||s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:program"}).execute({platform:r.default.OS}).then((e=>{n&&a({...dg(e.highlights)})})),()=>{n=!1}}),[e.route.params]),(0,An.jsxs)(Pr.K,{name:ln.g.HIGHLIGHTS,navigate:n,style:{backgroundColor:u.y.WHITE},children:[o.expanded&&(0,An.jsx)(p.c,{children:(0,An.jsx)(sg,{bgColor:u.y.BLUE_DARK,title:(0,hn._)(og),goBack:{page:ln.g.ADMIN,section:vn.S.PROGRAM}})}),!o.expanded&&(0,An.jsx)(p.c,{children:(0,An.jsx)(ag,{bgColor:u.y.WHITE,blackArrow:!0,title:(0,hn._)(og),titleStyle:[pr.h3,fr.black],goBack:{page:ln.g.ADMIN,section:vn.S.PROGRAM}})}),(0,An.jsxs)(jr.c,{style:o.expanded?{maxWidth:1050,marginLeft:"auto",marginRight:"auto",width:"100%",paddingTop:50}:{paddingLeft:16,paddingRight:16,width:"100%"},children:[(0,An.jsx)(En,{children:(0,hn._)(ig(hg.CURRENT)),style:[pr.h3,fr.black,tl.out_bottom_xs]}),(0,An.jsx)(yr,{height:1,color:u.y.GREY1,minWidth:"100%"}),(0,An.jsx)(ug,{type:"inProgress",projects:i.inProgress}),(0,An.jsx)(En,{children:(0,hn._)(ig(hg.COMING)),style:[pr.h3,fr.black,tl.out_bottom_xs,tl.out_top_m]}),(0,An.jsx)(yr,{height:1,color:u.y.GREY1,minWidth:"100%"}),(0,An.jsx)(ug,{type:"inComing",projects:i.inComing}),(0,An.jsx)(En,{children:(0,hn._)(ig(hg.PAST)),style:[pr.h3,fr.black,tl.out_bottom_xs,tl.out_top_m]}),(0,An.jsx)(yr,{height:1,color:u.y.GREY1,minWidth:"100%"}),(0,An.jsx)(ug,{type:"past",projects:i.past})]})]})},[ln.g.HIGHLIGHT_DETAILS]:e=>{const{navigate:t}=(0,f.Yi)(),n=d.useContext(yn.S);return(0,An.jsxs)(Pr.K,{name:ln.g.HIGHLIGHT_DETAILS,navigate:t,style:{backgroundColor:u.y.WHITE},children:[(0,An.jsx)(p.c,{children:(0,An.jsx)(ag,{bgColor:u.y.WHITE,blackArrow:!0,title:(0,hn._)(e.route.params.project.name),titleStyle:[pr.h3,fr.black],forceGoBack:!0})}),(0,An.jsx)(jr.c,{style:n.expanded?{maxWidth:1050,marginLeft:"auto",marginRight:"auto",width:"100%",paddingTop:50}:{paddingLeft:16,paddingRight:16,width:"100%"},children:(0,An.jsx)(cg,{project:e.route.params.project,hideTitle:!0})})]})},[ln.g.NEW_MESSAGE]:e=>{const{navigate:t,replace:o}=(0,f.Yi)(),i=d.useContext(yn.S),[a,l]=d.useState(void 0),[c,h]=d.useState(""),[g,m]=d.useState(!1),[y,v]=d.useState(!1),[b,A]=d.useState(!1);return(0,An.jsxs)(Pr.K,{name:ln.g.NEW_MESSAGE,style:{backgroundColor:u.y.WHITE},navigate:t,children:[(0,An.jsx)(ag,{blackArrow:!0,forceGoBack:!0,bgColor:u.y.WHITE,borderColor:u.y.GREY1,borderWidth:1,children:(0,An.jsx)(p.c,{children:(0,An.jsxs)(p.c,{style:{flexDirection:"row",marginRight:16},children:[b?void 0:(0,An.jsx)(vc.c,{accessibilityRole:"link",onPress:()=>{"undefined"!==typeof a?l(void 0):Ac(((e,t)=>{l({picture:e,type:t})}))},children:(0,An.jsx)(le.c,{style:{width:24,height:24,resizeMode:"contain",marginBottom:"undefined"===typeof a?3:0,marginRight:15,alignSelf:"center"},source:n("undefined"===typeof a?5428:5892)})}),(0,An.jsx)(xl,{children:(0,hn._)(uc.send),color:b?u.y.GREY1:u.y.YELLOW_DARK,textColor:u.y.WHITE,fontSize:16,fontWeight:"700",disabled:0===c.length&&"undefined"===typeof a||b,onPress:()=>{if(!b){var e;A(!0);const t={text:c};i.profile&&null!==(e=i.profile)&&void 0!==e&&e.can_submit_on_company&&(t.notify=g,t.pin=y),"undefined"!==typeof a&&(t.picture=a.picture,t.pictureFormat=a.type),s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:feed/add"}).execute(t).then((()=>{l(void 0),h(""),A(!1),o(ln.g.ADMIN),vn.O.add(vn.S.ACTIONS,!0),i.setTab(0)}))}},style:{paddingLeft:16,paddingRight:16,marginBottom:5,marginTop:5}})]})})}),(0,An.jsx)(jr.c,{style:[{width:"100%",backgroundColor:u.y.WHITE},i.expanded?{}:{paddingLeft:16,paddingRight:16}],contentContainerStyle:i.expanded?{flexGrow:1,flexShrink:1,flexBasis:1,justifyContent:"flex-start"}:{width:"100%"},showsVerticalScrollIndicator:"web"===r.default.OS,children:(0,An.jsx)(xc,{message:c,setMessage:h,upload:a,notifyCompany:g,setNotifyCompany:m,pin:y,setPin:v,locked:b,setLocked:A,hasPins:()=>e.route.params.hasPins})})]})},[ln.g.TEAMS_RANKING]:e=>{const{navigate:t,goBack:r}=(0,f.Yi)();return(0,An.jsxs)(Pr.K,{name:ln.g.CHAT_MEMBERS,navigate:t,children:[(0,An.jsxs)(p.c,{style:[bn.horizontal,{backgroundColor:u.y.BLUE_DARK,height:50,paddingLeft:16,paddingRight:16,paddingTop:6,paddingBottom:6,alignItems:"center"}],children:[(0,An.jsx)(xl,{fontSize:16,style:{borderWidth:0},sideLeft:(0,An.jsx)(le.c,{style:{height:24,width:24,resizeMode:"contain",alignContent:"center",marginRight:8},source:n(516)}),children:"",onPress:()=>{r(),vn.O.add(vn.S.IMPACT,!0)}}),(0,An.jsx)(un.c,{style:[pr.h3,fr.white],children:(0,hn._)($c)})]}),(0,An.jsx)(jr.c,{style:{paddingLeft:16,paddingRight:16,backgroundColor:u.y.WHITE},children:(0,An.jsx)(gf,{teams:e.route.params.teams,current:e.route.params.current,members:e.route.params.members,listOnly:!0})})]})},[ln.g.FORM]:e=>{const t=d.useContext(yn.S),n=(0,f.Yi)(),[r,o]=d.useState([]),[i,a]=d.useState(0),s=e.route.params.data;if(!s)return n.replace(ln.g.LOADING),null;const l=i===s.questions.length;return(0,An.jsxs)(Pr.K,{name:ln.g.FORM,navigate:n.navigate,style:[{backgroundColor:u.y.BLUE_DARK},t.expanded?{minHeight:"inherit",height:"100vh"}:{}],children:[t.expanded&&(0,An.jsx)(sg,{bgColor:u.y.BLUE_DARK,title:(0,hn._)(s.title),bgColorRadius:l?u.y.BLUE_DARK:u.y.WHITE,goBack:{page:ln.g.ADMIN,section:vn.S.ACTIONS}})||(0,An.jsx)(ag,{bgColor:u.y.BLUE_DARK,title:(0,hn._)(s.title),titleStyle:[pr.h3,fr.white],goBack:{page:ln.g.ADMIN,section:vn.S.ACTIONS}}),(0,An.jsx)(Am,{challenge:e.route.params.id,background:l?u.y.BLUE_DARK:u.y.WHITE,name:s.name,step:i,total:s.questions.length,completed:r.length,question:l?void 0:s.questions[i],duration:s.duration,setStep:a,getResponse:e=>r[e]||"",setResponse:(e,t)=>{o([...r.slice(0,e),t,...r.slice(e+1)])},responses:r,quizResponses:s.questions.reduce(((e,t,n)=>(t.type===zf.CHOICES_RESPONSE&&t.solution&&(e[n]=t.solution),e)),{})})]})},[ln.g.PROGRAM_COMMITMENTS]:e=>{const t=(0,f.Yi)(),n=d.useContext(yn.S);return(0,An.jsxs)(Pr.K,{name:ln.g.PROGRAM_COMMITMENTS,navigate:t.navigate,style:[{backgroundColor:u.y.BLUE_DARK},n.expanded?{minHeight:"inherit",height:"100vh"}:{}],children:[n.expanded&&(0,An.jsx)(sg,{bgColor:u.y.BLUE_DARK,title:(0,hn._)(Yf),bgColorRadius:u.y.WHITE,goBack:{page:ln.g.ADMIN,section:vn.S.PROGRAM}})||(0,An.jsx)(ag,{bgColor:u.y.BLUE_DARK,title:(0,hn._)(Yf),titleStyle:[pr.h3,fr.white],goBack:{page:ln.g.ADMIN,section:vn.S.PROGRAM}}),(0,An.jsxs)(jr.c,{style:[{maxWidth:1050,marginRight:"auto",marginLeft:"auto",backgroundColor:u.y.WHITE,width:"100%"},n.expanded?{width:"100%"}:{}],children:[e.route.params.commitments.map(((e,t)=>(0,An.jsxs)(p.c,{style:{paddingTop:32,paddingLeft:16,paddingRight:16,paddingBottom:32},children:[(0,An.jsx)(En,{style:[pr.h3,fr.black,tl.out_bottom_m,tl.out_top_m],children:(0,hn._)(e.title)}),(0,An.jsx)(En,{style:[pr.body1,fr.black],children:(0,hn._)(e.content)})]},t))),e.route.params.button&&(0,An.jsx)(xl,{onPress:()=>{const t=(0,hn._)(e.route.params.button.url);"web"===r.default.OS?window.open(t,"_blank"):kn.c.openURL(t)},children:(0,hn._)(e.route.params.button.title),color:u.y.WHITE,fontSize:13,fontWeight:"700",textColor:u.y.BLACK,style:[{borderColor:u.y.GREY1,borderWidth:1,borderRadius:24,paddingLeft:12,paddingRight:12,alignSelf:"flex-start",marginLeft:16},tl.out_top_m]})]})]})},[ln.g.FEED_LIKES]:e=>{const{navigate:t}=(0,f.Yi)();return(0,An.jsxs)(Pr.K,{name:ln.g.FEED_LIKES,navigate:t,style:{backgroundColor:u.y.WHITE},children:[(0,An.jsx)(ag,{bgColor:u.y.WHITE,blackArrow:!0,title:(0,hn._)(uc.likesInteraction),titleStyle:[pr.h3,fr.black],forceGoBack:!0}),(0,An.jsx)(jr.c,{style:{paddingLeft:16,paddingRight:16,paddingBottom:16},children:(0,An.jsx)(Pc,{users:e.route.params.likes,bgColor:u.y.BLUE_LIGHT_X,color:u.y.BLUE_DARK,size:50,textStyle:[pr.body1,fr.black,tl.out_bottom_s]})})]})}};function Sm(e){const t=d.useContext(yn.S),{data:o}=e;if(!o)return(0,An.jsx)(p.c,{});const i=o.rankings.communities.reduce(((e,t,n)=>{const r=Math.floor(n/3);return e[r]||(e[r]=[]),e[r].push(t),e}),[]);return(0,An.jsxs)(jr.c,{style:[bn.flex1,{backgroundColor:"web"===r.default.OS?u.y.WHITE:u.y.BLUE_DARK},"web"===r.default.OS?{maxHeight:"calc(100vh - 64px)"}:{}],children:[(0,An.jsxs)(p.c,{style:{backgroundColor:u.y.BLUE_DARK,height:150,justifyContent:"center",paddingTop:16,paddingBottom:16},children:[(0,An.jsx)(un.c,{style:[pr.h2,fr.white,bn.text_center],children:(0,hn._)({fr:"Vous n\u2019avez plus acc\xe8s \xe0 la plateforme \ud83d\ude22",en:"You no longer have access to the platform \ud83d\ude22"})}),(0,An.jsx)(un.c,{style:[pr.h5,fr.white,bn.text_center,tl.out_top_m],children:(0,hn._)({fr:"Le programme d\u2019engagement a pris fin le ".concat(o.end),en:"The engagement program ended on ".concat(o.end)})})]}),(0,An.jsx)(p.c,{style:{backgroundColor:u.y.BLUE_DARK,height:20},children:(0,An.jsx)(p.c,{style:{backgroundColor:u.y.WHITE,backfaceVisibility:"hidden",borderTopLeftRadius:24,borderTopRightRadius:24,height:"100%"}})}),(0,An.jsxs)(p.c,{style:{maxWidth:1050,alignSelf:"center",width:"100%",padding:16,backgroundColor:"white"},children:[(0,An.jsx)(le.c,{source:{uri:o.logo},style:{height:60,width:250,resizeMode:"cover",alignSelf:"center"}}),(0,An.jsx)(un.c,{style:[pr.h2,fr.black,tl.out_top_m,tl.out_bottom_l],children:(0,hn._)({fr:"Bilan de votre programme d\u2019engagement",en:"Summary of your engagement program"})}),(0,An.jsxs)(p.c,{style:{flexDirection:"row",flexWrap:"wrap",justifyContent:"space-between"},children:[(0,An.jsxs)(p.c,{style:[Au.blueInsert,t.expanded?{width:"23%"}:{width:"48%"}],children:[(0,An.jsx)(un.c,{style:[pr.h5,fr.blue_dark],children:(0,hn._)(vu.globalUsers)}),(0,An.jsx)(un.c,{style:[pr.h2,fr.blue_dark,tl.out_top_m,tl.out_bottom_m],children:mu(o.users.total)}),(0,An.jsx)(Iu,{width:130,height:10,objective:o.users.invited,points:o.users.total,shift:0,bonus:0,backgroundColor:u.y.GREY1,borderRadius:10}),(0,An.jsx)(un.c,{style:[pr.caption,fr.grey2,tl.out_top_m],children:(0,hn._)(vu.globalUsersDescription(Math.round(o.users.total/o.users.invited*1e4)/100,o.users.invited))})]}),(0,An.jsxs)(p.c,{style:[Au.blueInsert,t.expanded?{width:"23%"}:{width:"48%"}],children:[(0,An.jsx)(un.c,{style:[pr.h5,fr.blue_dark],children:(0,hn._)(vu.globalActionsDone)}),(0,An.jsx)(un.c,{style:[pr.h2,fr.blue_dark,tl.out_top_m],children:mu(o.actions.total)}),(0,An.jsxs)(p.c,{style:[Au.horizontal,tl.out_top_m],children:[(0,An.jsx)(p.c,{style:Au.blueLightSquare}),(0,An.jsx)(un.c,{style:[pr.caption,fr.grey2],children:(0,hn._)(vu.globalActionsChallenges(100*o.actions.challenges))})]}),(0,An.jsxs)(p.c,{style:[Au.horizontal,tl.out_top_s],children:[(0,An.jsx)(p.c,{style:Au.blueDarkSquare}),(0,An.jsx)(un.c,{style:[pr.caption,fr.grey2],children:(0,hn._)(vu.globalActionsRoutines(100*o.actions.routines))})]})]}),(0,An.jsxs)(p.c,{style:[Au.blueInsert,t.expanded?{width:"23%"}:{width:"48%"}],children:[(0,An.jsx)(un.c,{style:[pr.h5,fr.blue_dark],children:(0,hn._)(vu.globalCO2)}),(0,An.jsx)(un.c,{style:[pr.h2,fr.blue_dark,tl.out_top_m,tl.out_bottom_s],children:yu(o.co2.total)}),(0,An.jsx)(le.c,{style:{width:16,height:16},source:n(5680)}),(0,An.jsx)(un.c,{style:[pr.caption,fr.grey2,tl.out_top_xs],children:(0,hn._)(vu.globalCO2Description(o.co2.car))})]}),(0,An.jsxs)(p.c,{style:[Au.blueInsert,t.expanded?{width:"23%"}:{width:"48%"}],children:[(0,An.jsx)(un.c,{style:[pr.h5,fr.blue_dark],children:(0,hn._)(vu.globalEarned)}),(0,An.jsxs)(un.c,{style:[pr.h2,fr.blue_dark,tl.out_top_m,tl.out_bottom_m],children:[mu(o.earned.total)," \u20ac"]}),(0,An.jsx)(Iu,{width:130,height:10,objective:100,points:o.earned.total,shift:0,bonus:0,backgroundColor:u.y.GREY1,borderRadius:10}),(0,An.jsx)(un.c,{style:[pr.caption,fr.grey2,tl.out_top_m],children:(0,hn._)(vu.globalEarnedDescription(100,o.earned.target))})]})]}),(0,An.jsx)(Nu,{data:{ranking:{ambassadors:o.rankings.users.map((e=>({name:(0,hn._)(e.name),picture:e.picture,points:e.points}))),challenges:o.rankings.challenges.map((e=>({name:(0,hn._)(e.name),odd:"",proportion:e.participation}))),routines:o.rankings.routines.map((e=>({name:(0,hn._)(e.name),odd:"",total:e.count}))),communities:[],odds:[]}}}),(0,An.jsxs)(p.c,{style:[{borderRadius:24,borderWidth:1,borderColor:u.y.GREY_LIGHT,width:"100%",marginBottom:32,padding:24,backgroundColor:"white"}],children:[(0,An.jsx)(un.c,{style:[pr.h5],children:(0,hn._)({fr:"Classement des communaut\xe9s",en:"Community ranking"})}),(0,An.jsx)(p.c,{style:{width:"100%"},children:i.map(((e,n)=>(0,An.jsxs)(p.c,{children:[(0,An.jsx)(p.c,{style:[t.expanded?{flexDirection:"row"}:{flexDirection:"column"},tl.out_top_m,{width:"100%"}],children:e.map(((r,o)=>(0,An.jsxs)(p.c,{style:{flex:1,flexDirection:"row",alignItems:"center"},children:[(0,An.jsx)(un.c,{style:[t.expanded?pr.h1Expanded:pr.h1,{color:u.y.YELLOW_DARK,marginRight:16}],children:o+1+(0===n?0:i.length*n+1)}),(0,An.jsxs)(p.c,{style:{flex:1},children:[(0,An.jsx)(un.c,{style:[{flexWrap:"wrap"}],children:(0,hn._)(r.name)}),(0,An.jsxs)(p.c,{style:{flexDirection:"row",marginTop:12},children:[(0,An.jsx)(le.c,{source:{uri:r.picture},style:{width:24,height:24,borderRadius:25}}),(0,An.jsx)(un.c,{style:[{alignSelf:"center",marginLeft:8,fontWeight:"bold"}],children:r.organization})]}),(0,An.jsxs)(un.c,{style:[{flexWrap:"wrap",color:u.y.GREY2,marginTop:8}],children:[mu(r.earned)," \u20ac \xb7 ",mu(r.users)," ",(0,hn._)({fr:"membres",en:"members"})]}),!t.expanded&&e.length-1!==o&&(0,An.jsx)(p.c,{style:{backgroundColor:u.y.GREY_LIGHT,height:2,paddingLeft:18,paddingRight:18,marginTop:14,marginBottom:14,width:"100%"}})]}),t.expanded&&e.length-1!==o&&(0,An.jsx)(p.c,{style:{backgroundColor:u.y.GREY_LIGHT,width:2,marginLeft:18,marginRight:18,paddingTop:14,paddingBottom:14,height:"100%"}})]},o)))}),t.expanded&&i.length-1!==n&&(0,An.jsx)(p.c,{style:{backgroundColor:u.y.GREY_LIGHT,height:2,paddingLeft:18,paddingRight:18,marginTop:14,width:"100%"}})]},n)))})]}),(0,An.jsxs)(p.c,{style:{backgroundColor:u.y.GREEN_LIGHT,borderRadius:24,padding:24,flexDirection:"column",marginBottom:32},children:[(0,An.jsx)(un.c,{style:[pr.h2,fr.green,tl.out_bottom_m,tl.out_top_s],children:(0,hn._)({fr:"Vous souhaitez continuer \xe0 vous engager dans votre entreprise?",en:"You want to continue to engage in your company?"})}),(0,An.jsxs)(p.c,{style:[t.expanded?{flexDirection:"row",marginTop:16}:{flexDirection:"column",padding:8,marginTop:8},{alignItems:"center"}],children:[(0,An.jsxs)(p.c,{style:[bn.flex1,t.expanded?{marginRight:24}:{maxWidth:300}],children:[(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center"},children:[(0,An.jsx)(le.c,{source:{uri:o.link.picture},style:{width:36,height:36,borderRadius:25}}),(0,An.jsx)(un.c,{style:[pr.h3,fr.black,tl.out_left_s],children:o.link.name})]}),(0,An.jsx)(un.c,{children:(0,hn._)(o.link.description),style:[tl.out_top_s,pr.body2,fr.grey2]})]}),(0,An.jsx)(xl,{color:u.y.GREEN,textColor:u.y.WHITE,fontSize:13,fontWeight:"bold",onPress:()=>{"web"===r.default.OS?window.open(o.link.url,"_blank"):Promise.resolve(kn.c.openURL(o.link.url))},children:(0,hn._)({fr:"Participer",en:"Participate"}),style:{padding:4,width:230,borderRadius:24,marginTop:24,marginBottom:24}})]}),(0,An.jsxs)(p.c,{style:[t.expanded?{flexDirection:"row",marginTop:24}:{flexDirection:"column",marginTop:8},{alignItems:"center"}],children:[(0,An.jsxs)(p.c,{style:[t.expanded?{marginRight:24,flex:1}:{maxWidth:300}],children:[(0,An.jsxs)(p.c,{style:{flexDirection:"row",alignItems:"center"},children:[(0,An.jsx)(le.c,{source:n(7304),style:{width:36,height:36,borderRadius:36}}),(0,An.jsx)(un.c,{children:(0,hn._)({fr:"Continuer l\u2019aventure m\xe3o boa",en:"Continue the m\xe3o boa adventure"}),style:[pr.h3,fr.black,tl.out_left_s,{maxWidth:260}]})]}),(0,An.jsx)(un.c,{children:(0,hn._)({fr:"Vous avez appr\xe9ci\xe9 l\u2019exp\xe9rience m\xe3o boa et vous souhaitez continuer d\u2019agir au quotidien ?",en:"You enjoyed the m\xe3o boa experience and want to continue acting on a daily basis?"}),style:[tl.out_top_s,pr.body2,fr.grey2]})]}),(0,An.jsx)(xl,{color:u.y.GREEN_LIGHT,textColor:u.y.GREEN,fontWeight:"bold",fontSize:13,style:{borderWidth:1,borderColor:u.y.GREEN,padding:4,width:230,borderRadius:24,marginTop:24,marginBottom:24},onPress:()=>{const e="fr"===hn.O.get()?"https://form.typeform.com/to/rdWSf7Ii":"https://form.typeform.com/to/aC1Az1Ad";"web"===r.default.OS?window.open(e,"_blank"):Promise.resolve(kn.c.openURL(e))},children:(0,hn._)({fr:"Continuer l\u2019aventure m\xe3o boa ",en:"Continue the m\xe3o boa adventure"})})]})]})]})]})}const wm=()=>{const e=Qt(),[t,n]=d.useState(0),[r,o]=d.useState();return d.useEffect((()=>{let e=!0;return s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:offboarding/cmacgm"}).execute().then((t=>{e&&o(t)})),()=>{e=!1}}),[]),(0,An.jsx)(sn,{children:(0,An.jsx)(e.Navigator,{children:(0,An.jsx)(e.Screen,{name:"m\xe3o boa",component:()=>(0,An.jsx)(Sm,{data:r}),options:{headerStyle:{backgroundColor:u.y.BLUE_DARK},headerTintColor:"#fff",headerTitle:()=>(0,An.jsx)(p.c,{style:{width:"100%",alignItems:"center"}}),headerLeft:()=>(0,An.jsx)(Sn,{}),headerRight:()=>(0,An.jsx)(br,{standalone:()=>n(t+1)})}})})})};function Cm(){const[e,t]=d.useState("web"===r.default.OS);return d.useEffect((()=>{e||a.cp.getItem("resolving").then(c.u).then((()=>t(!0)))}),[]),e?"cmacgm"===c.Y.name?(0,An.jsx)(wm,{}):Tr(xm):(0,An.jsx)(p.c,{})}function _m(){return(0,An.jsx)(Cm,{})}e=n.hmd(e);"tanum"===c.Y.name?(c.Y.name="tanum",s.g.config.setAccountAPI(l._U.tanum.accounts),s.g.config.setRecipesAPI(l._U.tanum.api)):"undefined"!==typeof e.hot&&("android"===r.default.OS?(s.g.config.setAccountAPI("http://10.0.2.2:8080","api.account.dropin.local"),s.g.config.setRecipesAPI("http://10.0.2.2:8080/v0","api.dropin.local")):(s.g.config.setAccountAPI("http://api.account.dropin.local:8080"),s.g.config.setRecipesAPI("http://api.dropin.local:8080/v0"))),s.g.config.setRealm("maoboa:main");let Em,Rm,km="web"===r.default.OS,Im=null;if(km){const e=new URLSearchParams(document.location.search),t=e.get("goto");if(Rm=e.get("redirect"),Im=e.get("token"),null===t||null===Rm){km=!1;for(const[t,n]of e.entries())l.Av[t]=n}else Em=e.get("env")||"prod"}if(km){const e=e=>{null!==e&&Em&&Rm?(s.g.config.setToken(e),s.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:wenow/generate"}).execute().then((e=>{let t,{uuid:n}=e;t="test"===Em?"https://preprod-cmacgm.engagenow.fun":"dev"===Em?"http://localhost":"https://cmacgm.engagenow.fun",window.location.href=t+"/pipeline/maoboa/"+n+"?url="+encodeURIComponent(Rm)+"&referer="+encodeURIComponent(window.location.href)}))):window.location.href="https://maoboa.co"};Im?e(Im):a.cp.getItem("token").then((t=>{e(t)}))}else o.c.registerComponent("maoboa",(()=>_m)),"web"===r.default.OS?o.c.runApplication("maoboa",{rootTag:document.getElementById("root")}):"android"===r.default.OS&&i.c.setBackgroundColor(u.y.BLUE_DARK)},2124:(e,t,n)=>{"use strict";n.d(t,{K:()=>v});var r=n(9060),o=n(992),i=n(3280),a=n(9020),s=n(7172),l=n(7511),c=n(1976),u=n(268),d=n(8100);var h=n(6720),p=n(1012),f=n(4340),g=n(16),m=n(2496);e=n.hmd(e);const y=function(e,t){let n,r,o=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];if("web"===p.default.OS){const e=window.location.pathname;r=h.O.page(e,o),"undefined"!==typeof r&&(r===s.g.ADMIN&&(e===h.S.INFO?t(0):e===h.S.IMPACT?t(2):e===h.S.PROGRAM&&t(3)),n=e)}e(r||(o?s.g.ADMIN:s.g.OFFLINE)),h.O.init(n||(o?h.S.ACTIONS:h.S.OFFLINE),e,o)},v=()=>{const{replace:t,navigate:n}=(0,o.Yi)(),v=r.useContext(u.S);return r.useEffect((()=>{let n=!0;return a.q||(async()=>{try{let r=null;"undefined"!==typeof f.Av.token?(r=f.Av.token,i.cp.setItem("token",r),delete f.Av.token):r=await i.cp.getItem("token"),null!==r?(c.g.config.setToken(r),Promise.resolve((0,l.e)()),(t=>c.g.recipes.pipelines.get({project:"maoboa:app",id:"maoboa:app:v3:users/retrieve"}).execute().catch((async t=>{var n;"undefined"===typeof(null===(n=e)||void 0===n?void 0:n.hot)&&(await i.cp.removeItem("token"),"web"===p.default.OS&&window.location.reload())})).then((e=>(e&&(t.setProfile(e),t.setPicture(e.picture),t.setNotifications(e.notifications),t.setMessages(e.messages),e.language&&(d.O.set(e.language),(0,g.C)("profile.language",e.language)),(async e=>{})(e.id),e.id&&(0,g.C)("profile.id",e.id)),e))))(v).then((e=>{n&&e&&("undefined"===typeof e.selected_projects||0===e.selected_projects.length?(t(s.g.WELCOME),h.O.init(h.S.WELCOME,t,!0)):e.company.noCommunities?y(t,v.setTab):e.community?e.validated?y(t,v.setTab):(t(s.g.VALIDATION,{}),h.O.init(h.S.VALIDATION,t,!0)):(t(s.g.COUNTDOWN,{}),h.O.init(h.S.COUNTDOWN,t,!0)))}))):n&&y(t,v.setTab,!1)}catch(r){console.log("[ERROR]",r)}})(),()=>{n=!1}}),[]),(0,m.jsx)(a.K,{name:s.g.LOADING,navigate:n})}},7511:(e,t,n)=>{"use strict";async function r(){}n.d(t,{e:()=>r})},8100:(e,t,n)=>{"use strict";n.d(t,{O:()=>a,_:()=>s});var r=n(1012),o=n(4752);const i=["fr","en"],a=(()=>{let e=(()=>{switch(r.default.OS){case"web":if(navigator.language)return navigator.language.slice(0,2);if(navigator.userLanguage)return navigator.userLanguage.slice(0,2);break;case"android":if(o.c.I18nManager.localeIdentifier)return o.c.I18nManager.localeIdentifier.slice(0,2);break;case"ios":if(o.c.SettingsManager.settings.AppleLocale)return o.c.SettingsManager.settings.AppleLocale.slice(0,2);if(o.c.SettingsManager.settings.AppleLanguages[0])return o.c.SettingsManager.settings.AppleLanguages[0].slice(0,2)}return"en"})();return-1===i.indexOf(e)&&(e="en"),{get:()=>e,set:t=>{e=t}}})(),s=e=>"object"!==typeof e||null===e?e:e[a.get()]},8440:(e,t,n)=>{"use strict";n.d(t,{y:()=>r});let r=function(e){return e.BLUE_LIGHT_X="#EFF4F6",e.BLUE_LIGHT="#D7E4E9",e.BLUE_DARK="#324158",e.YELLOW_DARK="#FCCC56",e.YELLOW_LIGHT="#FEF2D5",e.GREY_LIGHT_X="#F5F5F5",e.GREY_LIGHT="#E9E9E9",e.GREY1="#D3D3D3",e.GREY2="#848D9B",e.GREEN="#418069",e.GREEN_LIGHT="#ECF2F0",e.RED="#BB0B0B",e.ORANGE="#DE805C",e.ORANGE_LIGHT="#F7DFD6",e.PURPLE="#42409B",e.PURPLE_LIGHT="#ECECF5",e.WHITE="#FFFFFF",e.BLACK="#282828",e}({})},3504:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r,o=l(n(9060)),i=(r=n(8224))&&r.__esModule?r:{default:r},a=l(n(9788));function s(){if("function"!==typeof WeakMap)return null;var e=new WeakMap;return s=function(){return e},e}function l(e){if(e&&e.__esModule)return e;if(null===e||"object"!==c(e)&&"function"!==typeof e)return{default:e};var t=s();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var i=r?Object.getOwnPropertyDescriptor(e,o):null;i&&(i.get||i.set)?Object.defineProperty(n,o,i):n[o]=e[o]}return n.default=e,t&&t.set(e,n),n}function c(e){return c="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},c(e)}function u(e,t){for(var n=0;n{"use strict";var r=n(3248);function o(){if("function"!==typeof WeakMap)return null;var e=new WeakMap;return o=function(){return e},e}function i(e){return i="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i(e)}function a(e,t,n,r,o,i,a){try{var s=e[i](a),l=s.value}catch(c){return void n(c)}s.done?t(l):Promise.resolve(l).then(r,o)}function s(e,t){for(var n=0;n{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.PortalContext=void 0;var r,o=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==l(e)&&"function"!==typeof e)return{default:e};var t=s();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var i=r?Object.getOwnPropertyDescriptor(e,o):null;i&&(i.get||i.set)?Object.defineProperty(n,o,i):n[o]=e[o]}n.default=e,t&&t.set(e,n);return n}(n(9060)),i=n(5241),a=(r=n(9708))&&r.__esModule?r:{default:r};function s(){if("function"!==typeof WeakMap)return null;var e=new WeakMap;return s=function(){return e},e}function l(e){return l="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},l(e)}function c(e,t){for(var n=0;n-1?n.queue[o]=r:n.queue.push(r)}})),p(d(n),"unmount",(function(e){n.manager?n.manager.unmount(e):n.queue.push({type:"unmount",key:e})})),n.nextKey=0,n.queue=[],n.manager=void 0,n}var n,r,s;return function(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&h(e,t)}(t,e),n=t,(r=[{key:"componentDidMount",value:function(){for(var e=this.manager,t=this.queue;t.length&&e;){var n=t.pop();if(n)switch(n.type){case"mount":e.mount(n.key,n.children);break;case"update":e.update(n.key,n.children);break;case"unmount":e.unmount(n.key)}}}},{key:"render",value:function(){return o.createElement(f.Provider,{value:{mount:this.mount,update:this.update,unmount:this.unmount}},o.createElement(i.View,{style:m.container,collapsable:!1,pointerEvents:"box-none"},this.props.children),o.createElement(a.default,{ref:this.setManager}))}}])&&c(n.prototype,r),s&&c(n,s),t}(o.Component),m=i.StyleSheet.create({container:{flex:1}}),y=g;t.default=y},9708:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==a(e)&&"function"!==typeof e)return{default:e};var t=i();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var s=r?Object.getOwnPropertyDescriptor(e,o):null;s&&(s.get||s.set)?Object.defineProperty(n,o,s):n[o]=e[o]}n.default=e,t&&t.set(e,n);return n}(n(9060)),o=n(5241);function i(){if("function"!==typeof WeakMap)return null;var e=new WeakMap;return i=function(){return e},e}function a(e){return a="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},a(e)}function s(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function l(e){return function(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t{"use strict";var r;t.c=void 0;var o=((r=n(3504))&&r.__esModule?r:{default:r}).default;t.c=o},7704:(e,t,n)=>{var r=n(2411);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=r(n(4064)),i=r(n(6024)),a=r(n(4408)),s=function(e,t){return new Promise((function(n,r){try{var o=e();t&&t(null,o),n(o)}catch(i){t&&t(i),r(i)}}))},l=function(e,t,n){return Promise.all(e).then((function(e){var r=n?n(e):null;return t&&t(null,r),Promise.resolve(r)}),(function(e){return t&&t(e),Promise.reject(e)}))},c=function(){function e(){(0,o.default)(this,e)}return(0,i.default)(e,null,[{key:"getItem",value:function(e,t){return s((function(){return window.localStorage.getItem(e)}),t)}},{key:"setItem",value:function(e,t,n){return s((function(){window.localStorage.setItem(e,t)}),n)}},{key:"removeItem",value:function(e,t){return s((function(){return window.localStorage.removeItem(e)}),t)}},{key:"mergeItem",value:function(e,t,n){return s((function(){!function(e,t){var n=window.localStorage.getItem(e),r=JSON.parse(n),o=JSON.parse(t),i=JSON.stringify((0,a.default)({},r,o));window.localStorage.setItem(e,i)}(e,t)}),n)}},{key:"clear",value:function(e){return s((function(){window.localStorage.clear()}),e)}},{key:"getAllKeys",value:function(e){return s((function(){for(var e=window.localStorage.length,t=[],n=0;n{var r=n(2411);Object.defineProperty(t,"__esModule",{value:!0}),t.useAsyncStorage=function(e){return{getItem:function(){for(var t=arguments.length,n=new Array(t),r=0;r{var r=n(2411);t.cp=void 0;var o=r(n(7704)),i=n(2940),a=o.default;t.cp=a},8656:e=>{"use strict";function t(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+6*(t-e)*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function n(e,n,r){const o=r<.5?r*(1+n):r+n-r*n,i=2*r-o,a=t(i,o,e+1/3),s=t(i,o,e),l=t(i,o,e-1/3);return Math.round(255*a)<<24|Math.round(255*s)<<16|Math.round(255*l)<<8}const r="[-+]?\\d*\\.?\\d+",o=r+"%";function i(){for(var e=arguments.length,t=new Array(e),n=0;n255?255:t}function u(e){return(parseFloat(e)%360+360)%360/360}function d(e){const t=parseFloat(e);return t<0?0:t>1?255:Math.round(255*t)}function h(e){const t=parseFloat(e);return t<0?0:t>100?1:t/100}e.exports=function(e){if("number"===typeof e)return e>>>0===e&&e>=0&&e<=4294967295?e:null;if("string"!==typeof e)return null;const p=function(){void 0===l&&(l={rgb:new RegExp("rgb"+i(r,r,r)),rgba:new RegExp("rgba("+s(r,r,r,r)+"|"+a(r,r,r,r)+")"),hsl:new RegExp("hsl"+i(r,o,o)),hsla:new RegExp("hsla("+s(r,o,o,r)+"|"+a(r,o,o,r)+")"),hwb:new RegExp("hwb"+i(r,o,o)),hex3:/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex4:/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#([0-9a-fA-F]{6})$/,hex8:/^#([0-9a-fA-F]{8})$/});return l}();let f;if(f=p.hex6.exec(e))return parseInt(f[1]+"ff",16)>>>0;const g=function(e){switch(e){case"transparent":return 0;case"aliceblue":return 4042850303;case"antiquewhite":return 4209760255;case"aqua":case"cyan":return 16777215;case"aquamarine":return 2147472639;case"azure":return 4043309055;case"beige":return 4126530815;case"bisque":return 4293182719;case"black":return 255;case"blanchedalmond":return 4293643775;case"blue":return 65535;case"blueviolet":return 2318131967;case"brown":return 2771004159;case"burlywood":return 3736635391;case"burntsienna":return 3934150143;case"cadetblue":return 1604231423;case"chartreuse":return 2147418367;case"chocolate":return 3530104575;case"coral":return 4286533887;case"cornflowerblue":return 1687547391;case"cornsilk":return 4294499583;case"crimson":return 3692313855;case"darkblue":return 35839;case"darkcyan":return 9145343;case"darkgoldenrod":return 3095792639;case"darkgray":case"darkgrey":return 2846468607;case"darkgreen":return 6553855;case"darkkhaki":return 3182914559;case"darkmagenta":return 2332068863;case"darkolivegreen":return 1433087999;case"darkorange":return 4287365375;case"darkorchid":return 2570243327;case"darkred":return 2332033279;case"darksalmon":return 3918953215;case"darkseagreen":return 2411499519;case"darkslateblue":return 1211993087;case"darkslategray":case"darkslategrey":return 793726975;case"darkturquoise":return 13554175;case"darkviolet":return 2483082239;case"deeppink":return 4279538687;case"deepskyblue":return 12582911;case"dimgray":case"dimgrey":return 1768516095;case"dodgerblue":return 512819199;case"firebrick":return 2988581631;case"floralwhite":return 4294635775;case"forestgreen":return 579543807;case"fuchsia":case"magenta":return 4278255615;case"gainsboro":return 3705462015;case"ghostwhite":return 4177068031;case"gold":return 4292280575;case"goldenrod":return 3668254975;case"gray":case"grey":return 2155905279;case"green":return 8388863;case"greenyellow":return 2919182335;case"honeydew":return 4043305215;case"hotpink":return 4285117695;case"indianred":return 3445382399;case"indigo":return 1258324735;case"ivory":return 4294963455;case"khaki":return 4041641215;case"lavender":return 3873897215;case"lavenderblush":return 4293981695;case"lawngreen":return 2096890111;case"lemonchiffon":return 4294626815;case"lightblue":return 2916673279;case"lightcoral":return 4034953471;case"lightcyan":return 3774873599;case"lightgoldenrodyellow":return 4210742015;case"lightgray":case"lightgrey":return 3553874943;case"lightgreen":return 2431553791;case"lightpink":return 4290167295;case"lightsalmon":return 4288707327;case"lightseagreen":return 548580095;case"lightskyblue":return 2278488831;case"lightslategray":case"lightslategrey":return 2005441023;case"lightsteelblue":return 2965692159;case"lightyellow":return 4294959359;case"lime":return 16711935;case"limegreen":return 852308735;case"linen":return 4210091775;case"maroon":return 2147483903;case"mediumaquamarine":return 1724754687;case"mediumblue":return 52735;case"mediumorchid":return 3126187007;case"mediumpurple":return 2473647103;case"mediumseagreen":return 1018393087;case"mediumslateblue":return 2070474495;case"mediumspringgreen":return 16423679;case"mediumturquoise":return 1221709055;case"mediumvioletred":return 3340076543;case"midnightblue":return 421097727;case"mintcream":return 4127193855;case"mistyrose":return 4293190143;case"moccasin":return 4293178879;case"navajowhite":return 4292783615;case"navy":return 33023;case"oldlace":return 4260751103;case"olive":return 2155872511;case"olivedrab":return 1804477439;case"orange":return 4289003775;case"orangered":return 4282712319;case"orchid":return 3664828159;case"palegoldenrod":return 4008225535;case"palegreen":return 2566625535;case"paleturquoise":return 2951671551;case"palevioletred":return 3681588223;case"papayawhip":return 4293907967;case"peachpuff":return 4292524543;case"peru":return 3448061951;case"pink":return 4290825215;case"plum":return 3718307327;case"powderblue":return 2967529215;case"purple":return 2147516671;case"rebeccapurple":return 1714657791;case"red":return 4278190335;case"rosybrown":return 3163525119;case"royalblue":return 1097458175;case"saddlebrown":return 2336560127;case"salmon":return 4202722047;case"sandybrown":return 4104413439;case"seagreen":return 780883967;case"seashell":return 4294307583;case"sienna":return 2689740287;case"silver":return 3233857791;case"skyblue":return 2278484991;case"slateblue":return 1784335871;case"slategray":case"slategrey":return 1887473919;case"snow":return 4294638335;case"springgreen":return 16744447;case"steelblue":return 1182971135;case"tan":return 3535047935;case"teal":return 8421631;case"thistle":return 3636451583;case"tomato":return 4284696575;case"turquoise":return 1088475391;case"violet":return 4001558271;case"wheat":return 4125012991;case"white":return 4294967295;case"whitesmoke":return 4126537215;case"yellow":return 4294902015;case"yellowgreen":return 2597139199}return null}(e);return null!=g?g:(f=p.rgb.exec(e))?(c(f[1])<<24|c(f[2])<<16|c(f[3])<<8|255)>>>0:(f=p.rgba.exec(e))?void 0!==f[6]?(c(f[6])<<24|c(f[7])<<16|c(f[8])<<8|d(f[9]))>>>0:(c(f[2])<<24|c(f[3])<<16|c(f[4])<<8|d(f[5]))>>>0:(f=p.hex3.exec(e))?parseInt(f[1]+f[1]+f[2]+f[2]+f[3]+f[3]+"ff",16)>>>0:(f=p.hex8.exec(e))?parseInt(f[1],16)>>>0:(f=p.hex4.exec(e))?parseInt(f[1]+f[1]+f[2]+f[2]+f[3]+f[3]+f[4]+f[4],16)>>>0:(f=p.hsl.exec(e))?(255|n(u(f[1]),h(f[2]),h(f[3])))>>>0:(f=p.hsla.exec(e))?void 0!==f[6]?(n(u(f[6]),h(f[7]),h(f[8]))|d(f[9]))>>>0:(n(u(f[2]),h(f[3]),h(f[4]))|d(f[5]))>>>0:(f=p.hwb.exec(e))?(255|function(e,n,r){if(n+r>=1){const e=Math.round(255*n/(n+r));return e<<24|e<<16|e<<8}const o=t(0,1,e+1/3)*(1-n-r)+n,i=t(0,1,e)*(1-n-r)+n,a=t(0,1,e-1/3)*(1-n-r)+n;return Math.round(255*o)<<24|Math.round(255*i)<<16|Math.round(255*a)<<8}(u(f[1]),h(f[2]),h(f[3])))>>>0:null}},992:(e,t,n)=>{"use strict";n.d(t,{eM:()=>I,AH:()=>m,_2:()=>y,ay:()=>Ee,w3:()=>Re,Oo:()=>j,UP:()=>p,GW:()=>B,wB:()=>G,sL:()=>K,Yi:()=>ue,Ij:()=>we,MJ:()=>Ce,eu:()=>F});var r={};function o(){return{type:"GO_BACK"}}function i(){if("string"===typeof(arguments.length<=0?void 0:arguments[0]))return{type:"NAVIGATE",payload:{name:arguments.length<=0?void 0:arguments[0],params:arguments.length<=1?void 0:arguments[1]}};{const e=(arguments.length<=0?void 0:arguments[0])||{};if(!e.hasOwnProperty("key")&&!e.hasOwnProperty("name"))throw new Error("You need to specify name or key when calling navigate with an object as the argument. See https://reactnavigation.org/docs/navigation-actions#navigate for usage.");return{type:"NAVIGATE",payload:e}}}function a(e){return{type:"RESET",payload:e}}function s(e){return{type:"SET_PARAMS",payload:{params:e}}}n.r(r),n.d(r,{goBack:()=>o,navigate:()=>i,reset:()=>a,setParams:()=>s});var l=n(9060);const c="The 'navigation' object hasn't been initialized yet. This might happen if you don't have a navigator mounted, or if the navigator hasn't finished mounting. See https://reactnavigation.org/docs/navigating-without-navigation-prop#handling-initialization for more details.";const u='Another navigator is already registered for this container. You likely have multiple navigators under a single "NavigationContainer" or "Screen". Make sure each navigator is under a separate "Screen" container. See https://reactnavigation.org/docs/nesting-navigators for a guide on nesting.',d=l.createContext(void 0);function h(e){let{children:t}=e;const n=l.useRef(),r=l.useMemo((()=>({register(e){const t=n.current;if(void 0!==t&&e!==t)throw new Error(u);n.current=e},unregister(e){e===n.current&&(n.current=void 0)}})),[]);return l.createElement(d.Provider,{value:r},t)}function p(e){var t,n,r;let o=e;for(;null!=(null===(s=o)||void 0===s?void 0:s.routes[null!==(i=o.index)&&void 0!==i?i:0].state);){var i,a,s;o=o.routes[null!==(a=o.index)&&void 0!==a?a:0].state}return null===(n=o)||void 0===n?void 0:n.routes[null!==(t=null===(r=o)||void 0===r?void 0:r.index)&&void 0!==t?t:0]}const f=l.createContext({onDispatchAction:()=>{},onOptionsChange:()=>{}}),g=l.createContext(void 0),m=l.createContext(void 0),y=l.createContext(void 0),v="Couldn't find a navigation context. Have you wrapped your app with 'NavigationContainer'? See https://reactnavigation.org/docs/getting-started for setup instructions.",b=l.createContext({isDefault:!0,get getKey(){throw new Error(v)},get setKey(){throw new Error(v)},get getState(){throw new Error(v)},get setState(){throw new Error(v)},get getIsInitial(){throw new Error(v)}}),A=l.createContext(void 0);function x(){const{current:e}=l.useRef({action:[],focus:[]}),t=l.useCallback(((t,n)=>{e[t].push(n);let r=!1;return()=>{const o=e[t].indexOf(n);!r&&o>-1&&(r=!0,e[t].splice(o,1))}}),[e]);return{listeners:e,addListener:t}}function S(e){const t=l.useRef(e);l.useEffect((()=>{t.current=e}));const n=l.useRef(Object.create(null)),r=l.useCallback((e=>{const t=(t,r)=>{const o=n.current[t]?n.current[t][e]:void 0;if(!o)return;const i=o.indexOf(r);i>-1&&o.splice(i,1)};return{addListener:(r,o)=>{n.current[r]=n.current[r]||{},n.current[r][e]=n.current[r][e]||[],n.current[r][e].push(o);let i=!1;return()=>{i||(i=!0,t(r,o))}},removeListener:t}}),[]),o=l.useCallback((e=>{var r,o;let{type:i,data:a,target:s,canPreventDefault:l}=e;const c=n.current[i]||{},u=void 0!==s?null===(r=c[s])||void 0===r?void 0:r.slice():[].concat(...Object.keys(c).map((e=>c[e]))).filter(((e,t,n)=>n.lastIndexOf(e)===t)),d={get type(){return i}};if(void 0!==s&&Object.defineProperty(d,"target",{enumerable:!0,get:()=>s}),void 0!==a&&Object.defineProperty(d,"data",{enumerable:!0,get:()=>a}),l){let e=!1;Object.defineProperties(d,{defaultPrevented:{enumerable:!0,get:()=>e},preventDefault:{enumerable:!0,value(){e=!0}}})}return null===(o=t.current)||void 0===o||o.call(t,d),null===u||void 0===u||u.forEach((e=>e(d))),d}),[]);return l.useMemo((()=>({create:r,emit:o})),[r,o])}function w(){const{current:e}=l.useRef(Object.assign(Object.create(null),{getState:{},beforeRemove:{}})),t=l.useCallback(((t,n,r)=>(e[t][n]=r,()=>{e[t][n]=void 0})),[e]);return{keyedListeners:e,addKeyedListener:t}}function C(e){let{key:t,options:n,navigation:r}=e;const o=l.useRef(n),i=l.useRef({}),{onOptionsChange:a}=l.useContext(f),{addOptionsGetter:s}=l.useContext(b),c=l.useCallback((()=>{var e;const t=null===(e=null===r||void 0===r?void 0:r.isFocused())||void 0===e||e,n=Object.keys(i.current).length;var s;t&&!n&&a(null!==(s=o.current)&&void 0!==s?s:{})}),[r,a]);l.useEffect((()=>(o.current=n,c(),null===r||void 0===r?void 0:r.addListener("focus",c))),[r,n,c]);const u=l.useCallback((()=>{for(let n in i.current)if(i.current.hasOwnProperty(n)){var e,t;const r=null===(e=(t=i.current)[n])||void 0===e?void 0:e.call(t);if(null!==r)return r}return null}),[]),d=l.useCallback((()=>{var e;if(!(null===(e=null===r||void 0===r?void 0:r.isFocused())||void 0===e||e))return null;const t=u();return null!==t?t:o.current}),[r,u]);l.useEffect((()=>null===s||void 0===s?void 0:s(t,d)),[d,s,t]);const h=l.useCallback(((e,t)=>(i.current[e]=t,c(),()=>{delete i.current[e],c()})),[c]);return{addOptionsGetter:h,getCurrentOptions:d}}const _="Couldn't find a schedule context.",E=l.createContext({scheduleUpdate(){throw new Error(_)},flushUpdates(){throw new Error(_)}});const R={};const k=e=>{if(void 0===e)return;const{key:t,routeNames:n,...r}=e;return{...r,stale:!0,routes:e.routes.map((e=>void 0===e.state?e:{...e,state:k(e.state)}))}},I=l.forwardRef((function(e,t){let{initialState:n,onStateChange:o,onUnhandledAction:i,independent:s,children:u}=e;if(!l.useContext(b).isDefault&&!s)throw new Error("Looks like you have nested a 'NavigationContainer' inside another. Normally you need only one container at the root of the app, so this was probably an error. If this was intentional, pass 'independent={true}' explicitly. Note that this will make the child navigators disconnected from the parent and you won't be able to navigate between them.");const[d,v,_,I,T]=function(e){const t=l.useRef(R),n=l.useRef(!1),r=l.useRef(!0);l.useEffect((()=>(r.current=!0,()=>{r.current=!1})),[]),t.current===R&&(t.current="function"===typeof e?e():e);const[o,i]=l.useState(t.current),a=l.useCallback((()=>t.current),[]),s=l.useCallback((e=>{e!==t.current&&r.current&&(t.current=e,n.current||i(e))}),[]),c=l.useCallback((e=>{n.current=!0;try{e()}finally{n.current=!1}}),[]),u=l.useCallback((()=>{r.current&&i(t.current)}),[]);o!==t.current&&i(t.current);const d=t.current;return l.useDebugValue(d),[d,a,s,c,u]}((()=>k(null==n?void 0:n))),O=l.useRef(!0),j=l.useRef(),P=l.useCallback((()=>j.current),[]),B=l.useCallback((e=>{j.current=e}),[]),{listeners:L,addListener:D}=x(),{keyedListeners:M,addKeyedListener:N}=w(),U=l.useCallback((e=>{null==L.focus[0]?console.error(c):L.focus[0]((t=>t.dispatch(e)))}),[L.focus]),F=l.useCallback((()=>{if(null==L.focus[0])return!1;const{result:e,handled:t}=L.focus[0]((e=>e.canGoBack()));return!!t&&e}),[L.focus]),H=l.useCallback((e=>{var t,n,r;const o=null!==(t=null===e||void 0===e?void 0:e.key)&&void 0!==t?t:null===(n=(r=M.getState).root)||void 0===n?void 0:n.call(r).key;null==o?console.error(c):L.focus[0]((t=>t.dispatch({...a(e),target:o})))}),[M.getState,L.focus]),G=l.useCallback((()=>{var e,t;return null===(e=(t=M.getState).root)||void 0===e?void 0:e.call(t)}),[M.getState]),z=l.useCallback((()=>{const e=G();if(null==e)return;return p(e)}),[G]),V=S(),{addOptionsGetter:W,getCurrentOptions:Q}=C({}),Y=l.useMemo((()=>({...Object.keys(r).reduce(((e,t)=>(e[t]=function(){return U(r[t](...arguments))},e)),{}),...V.create("root"),dispatch:U,resetRoot:H,isFocused:()=>!0,canGoBack:F,getParent:()=>{},getState:()=>oe.current,getRootState:G,getCurrentRoute:z,getCurrentOptions:Q,isReady:()=>null!=L.focus[0]})),[F,U,V,Q,z,G,L.focus,H]);l.useImperativeHandle(t,(()=>Y),[Y]);const K=l.useCallback(((e,t)=>{V.emit({type:"__unsafe_action__",data:{action:e,noop:t,stack:J.current}})}),[V]),q=l.useRef(),X=l.useCallback((e=>{q.current!==e&&(q.current=e,V.emit({type:"options",data:{options:e}}))}),[V]),J=l.useRef(),Z=l.useMemo((()=>({addListener:D,addKeyedListener:N,onDispatchAction:K,onOptionsChange:X,stackRef:J})),[D,N,K,X]),$=l.useMemo((()=>({scheduleUpdate:I,flushUpdates:T})),[I,T]),ee=l.useRef(!0),te=l.useCallback((()=>ee.current),[]),ne=l.useMemo((()=>({state:d,getState:v,setState:_,getKey:P,setKey:B,getIsInitial:te,addOptionsGetter:W})),[d,v,_,P,B,te,W]),re=l.useRef(o),oe=l.useRef(d);l.useEffect((()=>{ee.current=!1,re.current=o,oe.current=d})),l.useEffect((()=>{const e=G();V.emit({type:"state",data:{state:d}}),!O.current&&re.current&&re.current(e),O.current=!1}),[G,V,d]);const ie=l.useCallback((e=>{}),[]);let ae=l.createElement(g.Provider,{value:Y},l.createElement(E.Provider,{value:$},l.createElement(f.Provider,{value:Z},l.createElement(b.Provider,{value:ne},l.createElement(A.Provider,{value:null!==i&&void 0!==i?i:ie},l.createElement(h,null,u))))));return s&&(ae=l.createElement(y.Provider,{value:void 0},l.createElement(m.Provider,{value:void 0},ae))),ae}));function T(e){return null}function O(e){return null}function j(e){return function(){if(void 0!==arguments[0])throw new Error("Creating a navigator doesn't take an argument. Maybe you are trying to use React Navigation 4 API? See https://reactnavigation.org/docs/hello-react-navigation for the latest API and guides.");return{Navigator:e,Group:T,Screen:O}}}const P=l.createContext(void 0);function B(e,t){var n,r;const o=t?L(t):{},i=null!=e.index?e.routes.slice(0,e.index+1):e.routes;if(0===i.length)return;if(!(1===i.length&&void 0===i[0].key||2===i.length&&void 0===i[0].key&&i[0].name===(null===o||void 0===o?void 0:o.initialRouteName)&&void 0===i[1].key))return{type:"RESET",payload:e};const a=e.routes[null!==(n=e.index)&&void 0!==n?n:e.routes.length-1];let s=null===a||void 0===a?void 0:a.state,l=null===o||void 0===o||null===(r=o.screens)||void 0===r?void 0:r[null===a||void 0===a?void 0:a.name],c={...a.params},u=a?{name:a.name,path:a.path,params:c}:void 0;for(;s;){var d,h,p;if(0===s.routes.length)return;const e=null!=s.index?s.routes.slice(0,s.index+1):s.routes,t=e[e.length-1];if(Object.assign(c,{initial:void 0,screen:void 0,params:void 0,state:void 0}),1===e.length&&void 0===e[0].key)c.initial=!0,c.screen=t.name;else{if(2!==e.length||void 0!==e[0].key||e[0].name!==(null===(d=l)||void 0===d?void 0:d.initialRouteName)||void 0!==e[1].key){c.state=s;break}c.initial=!1,c.screen=t.name}t.state?(c.params={...t.params},c=c.params):(c.path=t.path,c.params=t.params),s=t.state,l=null===(h=l)||void 0===h||null===(p=h.screens)||void 0===p?void 0:p[t.name]}return u?{type:"NAVIGATE",payload:u}:void 0}const L=e=>"object"===typeof e&&null!=e?{initialRouteName:e.initialRouteName,screens:null!=e.screens?D(e.screens):void 0}:{},D=e=>Object.entries(e).reduce(((e,t)=>{let[n,r]=t;return e[n]=L(r),e}),{});Symbol("CHILD_STATE");var M=n(2184);function N(e){return e.reduce(((e,t)=>{let[n,r]=t;if(e.hasOwnProperty(n))throw new Error("A value for key '".concat(n,"' already exists in the object."));return e[n]=r,e}),{})}const U=e=>e.map((e=>"- ".concat(e))).join("\n");function F(e){const t=["initialRouteName","screens"];!(arguments.length>1&&void 0!==arguments[1])||arguments[1]||t.push("path","exact","stringify","parse");const n=Object.keys(e).filter((e=>!t.includes(e)));if(n.length)throw new Error("Found invalid properties in the configuration:\n".concat(U(n),"\n\nDid you forget to specify them under a 'screens' property?\n\nYou can only specify the following properties:\n").concat(U(t),"\n\nSee https://reactnavigation.org/docs/configuring-links for more details on how to specify a linking configuration."));e.screens&&Object.entries(e.screens).forEach((e=>{let[t,n]=e;"string"!==typeof n&&F(n,!1)}))}const H=e=>{const t="number"===typeof e.index?e.routes[e.index]:e.routes[e.routes.length-1];return t.state?H(t.state):t};function G(e,t){if(null==e)throw Error("Got 'undefined' for the navigation state. You must pass a valid state object.");t&&F(t);const n=null!==t&&void 0!==t&&t.screens?W(null===t||void 0===t?void 0:t.screens):{};let r="/",o=e;const i={};for(;o;){let t,l,c="number"===typeof o.index?o.index:0,u=o.routes[c],d=H(e),h=n,p=[],f=!0;for(;u.name in h&&f;){if(t=h[u.name].pattern,p.push(u.name),u.params){var a;const e=null===(a=h[u.name])||void 0===a?void 0:a.stringify,n=N(Object.entries(u.params).map((t=>{let[n,r]=t;return[n,null!==e&&void 0!==e&&e[n]?e[n](r):String(r)]})));var s;if(t&&Object.assign(i,n),d===u)l={...n},null===(s=t)||void 0===s||s.split("/").filter((e=>e.startsWith(":"))).forEach((e=>{const t=z(e);l&&delete l[t]}))}if(h[u.name].screens&&void 0!==u.state){c="number"===typeof u.state.index?u.state.index:u.state.routes.length-1;const e=u.state.routes[c],t=h[u.name].screens;t&&e.name in t?(u=e,h=t):f=!1}else f=!1}if(void 0===t&&(t=p.join("/")),void 0!==h[u.name]?r+=t.split("/").map((e=>{const t=z(e);if("*"===e)return u.name;if(e.startsWith(":")){const n=i[t];return void 0===n&&e.endsWith("?")?"":encodeURIComponent(n)}return encodeURIComponent(e)})).join("/"):r+=encodeURIComponent(u.name),l||(l=d.params),u.state)r+="/";else if(l){for(let t in l)"undefined"===l[t]&&delete l[t];const e=M.stringify(l,{sort:!1});e&&(r+="?".concat(e))}o=u.state}return r=r.replace(/\/+/g,"/"),r=r.length>1?r.replace(/\/$/,""):r,r}const z=e=>e.replace(/^:/,"").replace(/\?$/,""),V=function(){for(var e=arguments.length,t=new Array(e),n=0;ne.split("/")))).filter(Boolean).join("/")},W=(e,t)=>N(Object.entries(e).map((e=>{let[n,r]=e;const o=((e,t)=>{var n;if("string"===typeof e)return{pattern:t?V(t,e):e};let r;if(e.exact&&void 0===e.path)throw new Error("A 'path' needs to be specified when specifying 'exact: true'. If you don't want this screen in the URL, specify it as empty string, e.g. `path: ''`.");r=!0!==e.exact?V(t||"",e.path||""):e.path||"";const o=e.screens?W(e.screens,r):void 0;return{pattern:null===(n=r)||void 0===n?void 0:n.split("/").filter(Boolean).join("/"),stringify:e.stringify,screens:o}})(r,t);return[n,o]})));var Q=n(8128),Y=n.n(Q);function K(e,t){t&&F(t);let n=[];null!==t&&void 0!==t&&t.initialRouteName&&n.push({initialRouteName:t.initialRouteName,parentScreens:[]});const r=null===t||void 0===t?void 0:t.screens;let o=e.replace(/\/+/g,"/").replace(/^\//,"").replace(/\?.*$/,"");if(o=o.endsWith("/")?o:"".concat(o,"/"),void 0===r){const t=o.split("/").filter(Boolean).map((e=>({name:decodeURIComponent(e)})));return t.length?te(e,t,n):void 0}const i=[].concat(...Object.keys(r).map((e=>J(e,r,[],n,[])))).sort(((e,t)=>{if(e.pattern===t.pattern)return t.routeNames.join(">").localeCompare(e.routeNames.join(">"));if(e.pattern.startsWith(t.pattern))return-1;if(t.pattern.startsWith(e.pattern))return 1;const n=e.pattern.split("/"),r=t.pattern.split("/");for(let o=0;o{if(e[t.pattern]){const n=e[t.pattern].routeNames,r=t.routeNames;if(!(n.length>r.length?r.every(((e,t)=>n[t]===e)):n.every(((e,t)=>r[t]===e))))throw new Error("Found conflicting screens with the same pattern. The pattern '".concat(t.pattern,"' resolves to both '").concat(n.join(" > "),"' and '").concat(r.join(" > "),"'. Patterns must be unique and cannot resolve to more than one screen."))}return Object.assign(e,{[t.pattern]:t})}),{}),"/"===o){const t=i.find((e=>""===e.path&&e.routeNames.every((e=>{var t;return!(null!==(t=i.find((t=>t.screen===e)))&&void 0!==t&&t.path)}))));return t?te(e,t.routeNames.map((e=>({name:e}))),n,i):void 0}let a,s;const{routes:l,remainingPath:c}=X(o,i.map((e=>({...e,regex:e.regex?new RegExp(e.regex.source+"$"):void 0}))));if(void 0!==l&&(s=te(e,l,n,i),o=c,a=s),null!=s&&null!=a)return a}const q=function(){for(var e=arguments.length,t=new Array(e),n=0;ne.split("/")))).filter(Boolean).join("/")},X=(e,t)=>{let n,r=e;for(const i of t){if(!i.regex)continue;const e=r.match(i.regex);if(e){var o;const a=null===(o=i.pattern)||void 0===o?void 0:o.split("/").filter((e=>e.startsWith(":"))).reduce(((t,n,r)=>Object.assign(t,{[n]:e[2*(r+1)].replace(/\//,"")})),{});n=i.routeNames.map((e=>{var n;const r=t.find((t=>t.screen===e)),o=null===r||void 0===r||null===(n=r.path)||void 0===n?void 0:n.split("/").filter((e=>e.startsWith(":"))).reduce(((e,t)=>{const n=a[t];if(n){var o;const i=t.replace(/^:/,"").replace(/\?$/,"");e[i]=null!==(o=r.parse)&&void 0!==o&&o[i]?r.parse[i](n):n}return e}),{});return o&&Object.keys(o).length?{name:e,params:o}:{name:e}})),r=r.replace(e[1],"");break}}return{routes:n,remainingPath:r}},J=function(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],r=arguments.length>3?arguments[3]:void 0,o=arguments.length>4?arguments[4]:void 0,i=arguments.length>5?arguments[5]:void 0;const a=[];n.push(e),o.push(e);const s=t[e];if("string"===typeof s){const t=i?q(i,s):s;a.push(Z(e,n,t,s))}else if("object"===typeof s){let t;if("string"===typeof s.path){if(s.exact&&void 0===s.path)throw new Error("A 'path' needs to be specified when specifying 'exact: true'. If you don't want this screen in the URL, specify it as empty string, e.g. `path: ''`.");t=!0!==s.exact?q(i||"",s.path||""):s.path||"",a.push(Z(e,n,t,s.path,s.parse))}s.screens&&(s.initialRouteName&&r.push({initialRouteName:s.initialRouteName,parentScreens:o}),Object.keys(s.screens).forEach((e=>{var l;const c=J(e,s.screens,n,r,[...o],null!==(l=t)&&void 0!==l?l:i);a.push(...c)})))}return n.pop(),a},Z=(e,t,n,r,o)=>({screen:e,regex:(n=n.split("/").filter(Boolean).join("/"))?new RegExp("^(".concat(n.split("/").map((e=>e.startsWith(":")?"(([^/]+\\/)".concat(e.endsWith("?")?"?":"",")"):"".concat("*"===e?".*":Y()(e),"\\/"))).join(""),")")):void 0,pattern:n,path:r,routeNames:[...t],parse:o}),$=(e,t,n)=>{for(const r of n)if(t.length===r.parentScreens.length){let n=!0;for(let e=0;en?e?{index:1,routes:[{name:e},t]}:{routes:[t]}:e?{index:1,routes:[{name:e},{...t,state:{routes:[]}}]}:{routes:[{...t,state:{routes:[]}}]},te=(e,t,n,r)=>{let o,i=t.shift();const a=[];let s=$(i.name,a,n);if(a.push(i.name),o=ee(s,i,0===t.length),t.length>0){let e=o;for(;i=t.shift();){s=$(i.name,a,n);const r=e.index||e.routes.length-1;e.routes[r].state=ee(s,i,0===t.length),t.length>0&&(e=e.routes[r].state),a.push(i.name)}}i=p(o),i.path=e;const l=ne(e,r?((e,t)=>{for(const n of t)if(e===n.routeNames[n.routeNames.length-1])return n.parse})(i.name,r):void 0);return l&&(i.params={...i.params,...l}),o},ne=(e,t)=>{const n=e.split("?")[1],r=M.parse(n);return t&&Object.keys(r).forEach((e=>{Object.hasOwnProperty.call(t,e)&&"string"===typeof r[e]&&(r[e]=t[e](r[e]))})),Object.keys(r).length?r:void 0},re=l.createContext(void 0),oe=l.createContext(void 0);var ie=n(9891),ae=n(3792),se=n.n(ae);const le=e=>[...e.values()].reduce(((e,t)=>{var n;let{routeKey:r,preventRemove:o}=t;return e[r]={preventRemove:(null===(n=e[r])||void 0===n?void 0:n.preventRemove)||o},e}),{});function ce(e){let{children:t}=e;const[n]=l.useState((()=>(0,ie.S)())),[r,o]=l.useState(new Map),i=l.useContext(re),a=l.useContext(y),s=l.useContext(oe),c=null===s||void 0===s?void 0:s.setPreventRemove,u=se()(((e,t,n)=>{if(n&&(null==i||null!==i&&void 0!==i&&i.getState().routes.every((e=>e.key!==t))))throw new Error("Couldn't find a route with the key ".concat(t,". Is your component inside NavigationContent?"));o((r=>{var o,i;if(t===(null===(o=r.get(e))||void 0===o?void 0:o.routeKey)&&n===(null===(i=r.get(e))||void 0===i?void 0:i.preventRemove))return r;const a=new Map(r);return n?a.set(e,{routeKey:t,preventRemove:n}):a.delete(e),a}))})),d=[...r.values()].some((e=>{let{preventRemove:t}=e;return t}));l.useEffect((()=>{if(void 0!==(null===a||void 0===a?void 0:a.key)&&void 0!==c)return c(n,a.key,d),()=>{c(n,a.key,!1)}}),[n,d,null===a||void 0===a?void 0:a.key,c]);const h=l.useMemo((()=>({setPreventRemove:u,preventedRoutes:le(r)})),[u,r]);return l.createElement(oe.Provider,{value:h},t)}function ue(){const e=l.useContext(g),t=l.useContext(m);if(void 0===t&&void 0===e)throw new Error("Couldn't find a navigation object. Is your component inside NavigationContainer?");return null!==t&&void 0!==t?t:e}n(7192);function de(e,t){return e===t||e.length===t.length&&e.every(((e,n)=>e===t[n]))}const he=e=>{let{render:t,children:n}=e;return t(n)};function pe(e){const t=l.useRef(e);return t.current=e,l.useEffect((()=>{t.current=null})),l.useRef((e=>{let{children:n}=e;const r=t.current;if(null===r)throw new Error("The returned component must be rendered in the same render phase as the hook.");return l.createElement(he,{render:r},n)})).current}function fe(e){return e.children}const ge=l.memo(fe,((e,t)=>{const n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(const o of n)if("children"!==o&&e[o]!==t[o])return!1;return!0}));function me(e){let{screen:t,route:n,navigation:r,routeState:o,getState:i,setState:a,options:s,clearOptions:c}=e;const u=l.useRef(),d=l.useCallback((()=>u.current),[]),{addOptionsGetter:p}=C({key:n.key,options:s,navigation:r}),f=l.useCallback((e=>{u.current=e}),[]),g=l.useCallback((()=>{const e=i().routes.find((e=>e.key===n.key));return e?e.state:void 0}),[i,n.key]),m=l.useCallback((e=>{const t=i();a({...t,routes:t.routes.map((t=>t.key===n.key?{...t,state:e}:t))})}),[i,n.key,a]),y=l.useRef(!0);l.useEffect((()=>{y.current=!1})),l.useEffect((()=>c),[]);const v=l.useCallback((()=>y.current),[]),A=l.useMemo((()=>({state:o,getState:g,setState:m,getKey:d,setKey:f,getIsInitial:v,addOptionsGetter:p})),[o,g,m,d,f,v,p]),x=t.getComponent?t.getComponent():t.component;return l.createElement(b.Provider,{value:A},l.createElement(h,null,l.createElement(ge,{name:t.name,render:x||t.children,navigation:r,route:n},void 0!==x?l.createElement(x,{navigation:r,route:n}):void 0!==t.children?t.children({navigation:r,route:n}):null)))}function ye(e){let{state:t,screens:n,navigation:o,screenOptions:i,defaultScreenOptions:a,onAction:s,getState:c,setState:u,addListener:d,addKeyedListener:h,onRouteFocus:p,router:g,emitter:v}=e;const[b,A]=l.useState({}),{onDispatchAction:x,onOptionsChange:S,stackRef:w}=l.useContext(f),C=l.useMemo((()=>({navigation:o,onAction:s,addListener:d,addKeyedListener:h,onRouteFocus:p,onDispatchAction:x,onOptionsChange:S,stackRef:w})),[o,s,d,h,p,x,S,w]),_=function(e){let{state:t,getState:n,navigation:o,setOptions:i,router:a,emitter:s}=e;const{stackRef:c}=l.useContext(f),u=l.useMemo((()=>({current:{}})),[n,o,i,a,s]),d={...a.actionCreators,...r};return u.current=t.routes.reduce(((e,t)=>{const r=u.current[t.key];if(r)e[t.key]=r;else{const{emit:r,...a}=o,l=e=>{const r="function"===typeof e?e(n()):e;null!=r&&o.dispatch({source:t.key,...r})},c=e=>{try{e()}finally{}},u=Object.keys(d).reduce(((e,t)=>(e[t]=function(){for(var e=arguments.length,n=new Array(e),r=0;rl(d[t](...n))))},e)),{});e[t.key]={...a,...u,...s.create(t.key),dispatch:e=>c((()=>l(e))),getParent:n=>void 0!==n&&n===a.getId()?e[t.key]:a.getParent(n),setOptions:e=>i((n=>({...n,[t.key]:{...n[t.key],...e}}))),isFocused:()=>{const e=n();return e.routes[e.index].key===t.key&&(!o||o.isFocused())}}}return e}),{}),u.current}({state:t,getState:c,navigation:o,setOptions:A,router:g,emitter:v});return function(e){return l.useMemo((()=>({current:new Map})),[]),e}(t.routes).reduce(((e,r,o)=>{const s=n[r.name],d=s.props,h=_[r.key],p=[i,...s.options?s.options.filter(Boolean):[],d.options,b[r.key]].reduce(((e,t)=>Object.assign(e,"function"!==typeof t?t:t({route:r,navigation:h}))),{}),g={..."function"===typeof a?a({route:r,navigation:h,options:p}):a,...p},v=()=>A((e=>{if(r.key in e){const{[r.key]:t,...n}=e;return n}return e}));return e[r.key]={route:r,navigation:h,render:()=>l.createElement(f.Provider,{key:r.key,value:C},l.createElement(m.Provider,{value:h},l.createElement(y.Provider,{value:r},l.createElement(me,{navigation:h,route:r,screen:d,routeState:t.routes[o].state,getState:c,setState:u,options:g,clearOptions:v})))),options:g},e}),{})}const ve=Symbol("VISITED_ROUTE_KEYS"),be=(e,t,n,r,o)=>{var i;const a=r.map((e=>e.key)),s=n.filter((e=>!a.includes(e.key))).reverse(),l=null!==(i=o[ve])&&void 0!==i?i:new Set,c={...o,[ve]:l};for(const d of s){var u;if(l.has(d.key))continue;if(null===(u=t[d.key])||void 0===u?void 0:u.call(t,c))return!0;l.add(d.key);if(e.emit({type:"beforeRemove",target:d.key,data:{action:c},canPreventDefault:!0}).defaultPrevented)return!0}return!1};function Ae(e){let{router:t,getState:n,setState:r,key:o,actionListeners:i,beforeRemoveListeners:a,routerConfigOptions:s,emitter:c}=e;const{onAction:u,onRouteFocus:d,addListener:h,onDispatchAction:p}=l.useContext(f),g=l.useRef(s);l.useEffect((()=>{g.current=s}));const m=l.useCallback((function(e){let s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:new Set;const l=n();if(s.has(l.key))return!1;if(s.add(l.key),"string"!==typeof e.target||e.target===l.key){let n=t.getStateForAction(l,e,g.current);if(n=null===n&&e.target===l.key?l:n,null!==n){if(p(e,l===n),l!==n){if(be(c,a,l.routes,n.routes,e))return!0;r(n)}if(void 0!==d){t.shouldActionChangeFocus(e)&&void 0!==o&&d(o)}return!0}}if(void 0!==u&&u(e,s))return!0;for(let t=i.length-1;t>=0;t--){if((0,i[t])(e,s))return!0}return!1}),[i,a,c,n,o,u,p,d,t,r]);return function(e){let{getState:t,emitter:n,beforeRemoveListeners:r}=e;const{addKeyedListener:o}=l.useContext(f),i=l.useContext(y),a=null===i||void 0===i?void 0:i.key;l.useEffect((()=>{if(a)return null===o||void 0===o?void 0:o("beforeRemove",a,(e=>{const o=t();return be(n,r,o.routes,[],e)}))}),[o,r,n,t,a])}({getState:n,emitter:c,beforeRemoveListeners:a}),l.useEffect((()=>null===h||void 0===h?void 0:h("action",m)),[h,m]),m}const xe=e=>void 0===e||"string"===typeof e&&""!==e,Se=(e,t,n)=>l.Children.toArray(e).reduce(((e,r)=>{var o,i;if(l.isValidElement(r)){if(r.type===O){if(!xe(r.props.navigationKey))throw new Error("Got an invalid 'navigationKey' prop (".concat(JSON.stringify(r.props.navigationKey),") for the screen '").concat(r.props.name,"'. It must be a non-empty string or 'undefined'."));return e.push({keys:[t,r.props.navigationKey],options:n,props:r.props}),e}if(r.type===l.Fragment||r.type===T){if(!xe(r.props.navigationKey))throw new Error("Got an invalid 'navigationKey' prop (".concat(JSON.stringify(r.props.navigationKey),") for the group. It must be a non-empty string or 'undefined'."));return e.push(...Se(r.props.children,r.props.navigationKey,r.type!==T?n:null!=n?[...n,r.props.screenOptions]:[r.props.screenOptions])),e}}throw new Error("A navigator can only contain 'Screen', 'Group' or 'React.Fragment' as its direct children (found ".concat(l.isValidElement(r)?"'".concat("string"===typeof r.type?r.type:null===(o=r.type)||void 0===o?void 0:o.name,"'").concat(null!=r.props&&"object"===typeof r.props&&"name"in r.props&&null!==(i=r.props)&&void 0!==i&&i.name?" for the screen '".concat(r.props.name,"'"):""):"object"===typeof r?JSON.stringify(r):"'".concat(String(r),"'"),"). To render this component in the navigator, pass it in the 'component' prop to 'Screen'."))}),[]);function we(e,t){const n=function(){const[e]=l.useState((()=>(0,ie.S)())),t=l.useContext(d);if(void 0===t)throw new Error("Couldn't register the navigator. Have you wrapped your app with 'NavigationContainer'?\n\nThis can also happen if there are multiple copies of '@react-navigation' packages installed.");return l.useEffect((()=>{const{register:n,unregister:r}=t;return n(e),()=>r(e)}),[t,e]),e}(),o=l.useContext(y),{children:s,screenListeners:c,...u}=t,{current:h}=l.useRef(e({...u,...null!==o&&void 0!==o&&o.params&&null==o.params.state&&!1!==o.params.initial&&"string"===typeof o.params.screen?{initialRouteName:o.params.screen}:null})),p=Se(s),g=p.reduce(((e,t)=>{if(t.props.name in e)throw new Error("A navigator cannot contain multiple 'Screen' components with the same name (found duplicate screen named '".concat(t.props.name,"')"));return e[t.props.name]=t,e}),{}),v=p.map((e=>e.props.name)),C=v.reduce(((e,t)=>(e[t]=g[t].keys.map((e=>null!==e&&void 0!==e?e:"")).join(":"),e)),{}),_=v.reduce(((e,t)=>{const{initialParams:n}=g[t].props;return e[t]=n,e}),{}),R=v.reduce(((e,t)=>Object.assign(e,{[t]:g[t].props.getId})),{});if(!v.length)throw new Error("Couldn't find any screens for the navigator. Have you defined any screens as its children?");const k=l.useCallback((e=>void 0===e.type||e.type===h.type),[h.type]),I=l.useCallback((e=>void 0!==e&&!1===e.stale&&k(e)),[k]),{state:T,getState:O,setState:j,setKey:B,getKey:L,getIsInitial:D}=l.useContext(b),M=l.useRef(!1),N=l.useCallback((()=>{j(void 0),M.current=!0}),[j]),U=l.useCallback((e=>{M.current||j(e)}),[j]),[F,H]=l.useMemo((()=>{var e;const t=v.reduce(((e,t)=>{var n,r,i;const{initialParams:a}=g[t].props,s=null==(null===o||void 0===o||null===(n=o.params)||void 0===n?void 0:n.state)&&!1!==(null===o||void 0===o||null===(r=o.params)||void 0===r?void 0:r.initial)&&(null===o||void 0===o||null===(i=o.params)||void 0===i?void 0:i.screen)===t?o.params.params:void 0;return e[t]=void 0!==a||void 0!==s?{...a,...s}:void 0,e}),{});var n,r;return void 0!==T&&k(T)||null!=(null===o||void 0===o||null===(e=o.params)||void 0===e?void 0:e.state)?[h.getRehydratedState(null!==(n=null===o||void 0===o||null===(r=o.params)||void 0===r?void 0:r.state)&&void 0!==n?n:T,{routeNames:v,routeParamList:t,routeGetIdList:R}),!1]:[h.getInitialState({routeNames:v,routeParamList:t,routeGetIdList:R}),!0]}),[T,h,k]),G=l.useRef(C);l.useEffect((()=>{G.current=C}));const z=G.current;let V=I(T)?T:F,W=V;de(V.routeNames,v)&&function(e,t){if(e===t)return!0;const n=Object.keys(e),r=Object.keys(t);return n.length===r.length&&n.every((n=>e[n]===t[n]))}(C,z)||(W=h.getStateForRouteNamesChange(V,{routeNames:v,routeParamList:_,routeGetIdList:R,routeKeyChanges:Object.keys(C).filter((e=>z.hasOwnProperty(e)&&C[e]!==z[e]))}));const Q=l.useRef(null===o||void 0===o?void 0:o.params);if(l.useEffect((()=>{Q.current=null===o||void 0===o?void 0:o.params}),[null===o||void 0===o?void 0:o.params]),null!==o&&void 0!==o&&o.params){const e=Q.current;let t;"object"===typeof o.params.state&&null!=o.params.state&&o.params!==e?t=a(o.params.state):"string"===typeof o.params.screen&&(!1===o.params.initial&&H||o.params!==e)&&(t=i({name:o.params.screen,params:o.params.params,path:o.params.path}));const n=t?h.getStateForAction(W,t,{routeNames:v,routeParamList:_,routeGetIdList:R}):null;W=null!==n?h.getRehydratedState(n,{routeNames:v,routeParamList:_,routeGetIdList:R}):W}const Y=V!==W;!function(e){const{scheduleUpdate:t,flushUpdates:n}=l.useContext(E);t(e),l.useEffect(n)}((()=>{Y&&U(W)})),V=W,l.useEffect((()=>(B(n),D()||U(W),()=>{setTimeout((()=>{void 0!==O()&&L()===n&&N()}),0)})),[]);const K=l.useRef();K.current=F;const q=l.useCallback((()=>{const e=O();return I(e)?e:K.current}),[O,I]),X=S((e=>{let t,n=[];var r;e.target?(t=V.routes.find((t=>t.key===e.target)),null!==(r=t)&&void 0!==r&&r.name&&n.push(t.name)):(t=V.routes[V.index],n.push(...Object.keys(g).filter((e=>{var n;return(null===(n=t)||void 0===n?void 0:n.name)===e}))));if(null==t)return;const o=ae[t.key].navigation;[].concat(...[c,...n.map((e=>{const{listeners:t}=g[e].props;return t}))].map((n=>{const r="function"===typeof n?n({route:t,navigation:o}):n;return r?Object.keys(r).filter((t=>t===e.type)).map((e=>null===r||void 0===r?void 0:r[e])):void 0}))).filter(((e,t,n)=>e&&n.lastIndexOf(e)===t)).forEach((t=>null===t||void 0===t?void 0:t(e)))}));!function(e){let{state:t,emitter:n}=e;const r=l.useContext(m),o=l.useRef(),i=t.routes[t.index].key;l.useEffect((()=>null===r||void 0===r?void 0:r.addListener("focus",(()=>{o.current=i,n.emit({type:"focus",target:i})}))),[i,n,r]),l.useEffect((()=>null===r||void 0===r?void 0:r.addListener("blur",(()=>{o.current=void 0,n.emit({type:"blur",target:i})}))),[i,n,r]),l.useEffect((()=>{const e=o.current;o.current=i,void 0!==e||r||n.emit({type:"focus",target:i}),e===i||r&&!r.isFocused()||void 0!==e&&(n.emit({type:"blur",target:e}),n.emit({type:"focus",target:i}))}),[i,n,r])}({state:V,emitter:X}),l.useEffect((()=>{X.emit({type:"state",data:{state:V}})}),[X,V]);const{listeners:J,addListener:Z}=x(),{keyedListeners:$,addKeyedListener:ee}=w(),te=Ae({router:h,getState:q,setState:U,key:null===o||void 0===o?void 0:o.key,actionListeners:J.action,beforeRemoveListeners:$.beforeRemove,routerConfigOptions:{routeNames:v,routeParamList:_,routeGetIdList:R},emitter:X}),ne=function(e){let{router:t,getState:n,key:r,setState:o}=e;const{onRouteFocus:i}=l.useContext(f);return l.useCallback((e=>{const a=n(),s=t.getStateForRouteFocus(a,e);s!==a&&o(s),void 0!==i&&void 0!==r&&i(r)}),[n,i,t,o,r])}({router:h,key:null===o||void 0===o?void 0:o.key,getState:q,setState:U}),oe=function(e){let{id:t,onAction:n,getState:o,emitter:i,router:a}=e;const s=l.useContext(A),c=l.useContext(m);return l.useMemo((()=>{const e=e=>{const t="function"===typeof e?e(o()):e;n(t)||null===s||void 0===s||s(t)},l={...a.actionCreators,...r},u=Object.keys(l).reduce(((t,n)=>(t[n]=function(){return e(l[n](...arguments))},t)),{}),d={...c,...u,dispatch:e,emit:i.emit,isFocused:c?c.isFocused:()=>!0,canGoBack:()=>{const e=o();return null!==a.getStateForAction(e,{type:"GO_BACK"},{routeNames:e.routeNames,routeParamList:{},routeGetIdList:{}})||(null===c||void 0===c?void 0:c.canGoBack())||!1},getId:()=>t,getParent:e=>{if(void 0!==e){let t=d;for(;t&&e!==t.getId();)t=t.getParent();return t}return c},getState:o};return d}),[t,i.emit,o,n,s,c,a])}({id:t.id,onAction:te,getState:q,emitter:X,router:h});!function(e){let{navigation:t,focusedListeners:n}=e;const{addListener:r}=l.useContext(f),o=l.useCallback((e=>{if(t.isFocused()){for(const t of n){const{handled:n,result:r}=t(e);if(n)return{handled:n,result:r}}return{handled:!0,result:e(t)}}return{handled:!1,result:null}}),[n,t]);l.useEffect((()=>null===r||void 0===r?void 0:r("focus",o)),[r,o])}({navigation:oe,focusedListeners:J.focus}),function(e){let{getState:t,getStateListeners:n}=e;const{addKeyedListener:r}=l.useContext(f),o=l.useContext(y),i=o?o.key:"root",a=l.useCallback((()=>{const e=t(),r=e.routes.map((e=>{var t;const r=null===(t=n[e.key])||void 0===t?void 0:t.call(n);return e.state===r?e:{...e,state:r}}));return de(e.routes,r)?e:{...e,routes:r}}),[t,n]);l.useEffect((()=>null===r||void 0===r?void 0:r("getState",i,a)),[r,a,i])}({getState:q,getStateListeners:$.getState});const ae=ye({state:V,screens:g,navigation:oe,screenOptions:t.screenOptions,defaultScreenOptions:t.defaultScreenOptions,onAction:te,getState:q,setState:U,onRouteFocus:ne,addListener:Z,addKeyedListener:ee,router:h,emitter:X});!function(e){let{state:t,navigation:n,descriptors:r}=e;const o=l.useContext(P);o&&n.isFocused()&&(o.options=r[t.routes[t.index].key].options)}({state:V,navigation:oe,descriptors:ae});const se=pe((e=>l.createElement(re.Provider,{value:oe},l.createElement(ce,null,e))));return{state:V,navigation:oe,descriptors:ae,NavigationContent:se}}function Ce(){const e=l.useContext(y);if(void 0===e)throw new Error("Couldn't find a route object. Is your component inside a screen in a navigator?");return e}const _e={getStateForAction(e,t){switch(t.type){case"SET_PARAMS":{const n=t.source?e.routes.findIndex((e=>e.key===t.source)):e.index;return-1===n?null:{...e,routes:e.routes.map(((e,r)=>r===n?{...e,params:{...e.params,...t.payload.params}}:e))}}case"RESET":{const n=t.payload;return 0===n.routes.length||n.routes.some((t=>!e.routeNames.includes(t.name)))?null:!1===n.stale?e.routeNames.length!==n.routeNames.length||n.routeNames.some((t=>!e.routeNames.includes(t)))?null:{...n,routes:n.routes.map((e=>e.key?e:{...e,key:"".concat(e.name,"-").concat((0,ie.S)())}))}:n}default:return null}},shouldActionChangeFocus:e=>"NAVIGATE"===e.type},Ee={replace:(e,t)=>({type:"REPLACE",payload:{name:e,params:t}}),push:(e,t)=>({type:"PUSH",payload:{name:e,params:t}}),pop(){return{type:"POP",payload:{count:arguments.length>0&&void 0!==arguments[0]?arguments[0]:1}}},popToTop:()=>({type:"POP_TO_TOP"})};function Re(e){const t={..._e,type:"stack",getInitialState(t){let{routeNames:n,routeParamList:r}=t;const o=void 0!==e.initialRouteName&&n.includes(e.initialRouteName)?e.initialRouteName:n[0];return{stale:!1,type:"stack",key:"stack-".concat((0,ie.S)()),index:0,routeNames:n,routes:[{key:"".concat(o,"-").concat((0,ie.S)()),name:o,params:r[o]}]}},getRehydratedState(t,n){let{routeNames:r,routeParamList:o}=n,i=t;if(!1===i.stale)return i;const a=i.routes.filter((e=>r.includes(e.name))).map((e=>({...e,key:e.key||"".concat(e.name,"-").concat((0,ie.S)()),params:void 0!==o[e.name]?{...o[e.name],...e.params}:e.params})));if(0===a.length){const t=void 0!==e.initialRouteName?e.initialRouteName:r[0];a.push({key:"".concat(t,"-").concat((0,ie.S)()),name:t,params:o[t]})}return{stale:!1,type:"stack",key:"stack-".concat((0,ie.S)()),index:a.length-1,routeNames:r,routes:a}},getStateForRouteNamesChange(t,n){let{routeNames:r,routeParamList:o,routeKeyChanges:i}=n;const a=t.routes.filter((e=>r.includes(e.name)&&!i.includes(e.name)));if(0===a.length){const t=void 0!==e.initialRouteName&&r.includes(e.initialRouteName)?e.initialRouteName:r[0];a.push({key:"".concat(t,"-").concat((0,ie.S)()),name:t,params:o[t]})}return{...t,routeNames:r,routes:a,index:Math.min(t.index,a.length-1)}},getStateForRouteFocus(e,t){const n=e.routes.findIndex((e=>e.key===t));return-1===n||n===e.index?e:{...e,index:n,routes:e.routes.slice(0,n+1)}},getStateForAction(e,n,r){const{routeParamList:o}=r;switch(n.type){case"REPLACE":{const t=n.target===e.key&&n.source?e.routes.findIndex((e=>e.key===n.source)):e.index;if(-1===t)return null;const{name:r,key:i,params:a}=n.payload;return e.routeNames.includes(r)?{...e,routes:e.routes.map(((e,n)=>n===t?{key:void 0!==i?i:"".concat(r,"-").concat((0,ie.S)()),name:r,params:void 0!==o[r]?{...o[r],...a}:a}:e))}:null}case"PUSH":if(e.routeNames.includes(n.payload.name)){const t=r.routeGetIdList[n.payload.name],i=null===t||void 0===t?void 0:t({params:n.payload.params}),a=i?e.routes.find((e=>e.name===n.payload.name&&i===(null===t||void 0===t?void 0:t({params:e.params})))):void 0;let s;return a?(s=e.routes.filter((e=>e.key!==a.key)),s.push({...a,params:void 0!==o[n.payload.name]?{...o[n.payload.name],...n.payload.params}:n.payload.params})):s=[...e.routes,{key:"".concat(n.payload.name,"-").concat((0,ie.S)()),name:n.payload.name,params:void 0!==o[n.payload.name]?{...o[n.payload.name],...n.payload.params}:n.payload.params}],{...e,index:s.length-1,routes:s}}return null;case"POP":{const t=n.target===e.key&&n.source?e.routes.findIndex((e=>e.key===n.source)):e.index;if(t>0){const r=Math.max(t-n.payload.count+1,1),o=e.routes.slice(0,r).concat(e.routes.slice(t+1));return{...e,index:o.length-1,routes:o}}return null}case"POP_TO_TOP":return t.getStateForAction(e,{type:"POP",payload:{count:e.routes.length-1}},r);case"NAVIGATE":if(void 0!==n.payload.name&&!e.routeNames.includes(n.payload.name))return null;if(n.payload.key||n.payload.name){var i;let t=-1;const s=void 0===n.payload.key&&void 0!==n.payload.name?r.routeGetIdList[n.payload.name]:void 0,l=null===s||void 0===s?void 0:s({params:n.payload.params});if(l)t=e.routes.findIndex((e=>e.name===n.payload.name&&l===(null===s||void 0===s?void 0:s({params:e.params}))));else if(e.routes[e.index].name===n.payload.name&&void 0===n.payload.key||e.routes[e.index].key===n.payload.key)t=e.index;else for(let r=e.routes.length-1;r>=0;r--)if(e.routes[r].name===n.payload.name&&void 0===n.payload.key||e.routes[r].key===n.payload.key){t=r;break}if(-1===t&&n.payload.key&&void 0===n.payload.name)return null;if(-1===t&&void 0!==n.payload.name){var a;const t=[...e.routes,{key:null!==(a=n.payload.key)&&void 0!==a?a:"".concat(n.payload.name,"-").concat((0,ie.S)()),name:n.payload.name,path:n.payload.path,params:void 0!==o[n.payload.name]?{...o[n.payload.name],...n.payload.params}:n.payload.params}];return{...e,routes:t,index:t.length-1}}const c=e.routes[t];let u;return u=n.payload.merge?void 0!==n.payload.params||void 0!==o[c.name]?{...o[c.name],...c.params,...n.payload.params}:c.params:void 0!==o[c.name]?{...o[c.name],...n.payload.params}:n.payload.params,{...e,index:t,routes:[...e.routes.slice(0,t),u!==c.params||n.payload.path&&n.payload.path!==c.path?{...c,path:null!==(i=n.payload.path)&&void 0!==i?i:c.path,params:u}:e.routes[t]]}}return null;case"GO_BACK":return e.index>0?t.getStateForAction(e,{type:"POP",payload:{count:1},target:n.target,source:n.source},r):null;default:return _e.getStateForAction(e,n)}},actionCreators:Ee};return t}},1684:(e,t)=>{"use strict";var n="function"===typeof Symbol&&Symbol.for,r=n?Symbol.for("react.element"):60103,o=n?Symbol.for("react.portal"):60106,i=n?Symbol.for("react.fragment"):60107,a=n?Symbol.for("react.strict_mode"):60108,s=n?Symbol.for("react.profiler"):60114,l=n?Symbol.for("react.provider"):60109,c=n?Symbol.for("react.context"):60110,u=n?Symbol.for("react.async_mode"):60111,d=n?Symbol.for("react.concurrent_mode"):60111,h=n?Symbol.for("react.forward_ref"):60112,p=n?Symbol.for("react.suspense"):60113,f=n?Symbol.for("react.suspense_list"):60120,g=n?Symbol.for("react.memo"):60115,m=n?Symbol.for("react.lazy"):60116,y=n?Symbol.for("react.block"):60121,v=n?Symbol.for("react.fundamental"):60117,b=n?Symbol.for("react.responder"):60118,A=n?Symbol.for("react.scope"):60119;function x(e){if("object"===typeof e&&null!==e){var t=e.$$typeof;switch(t){case r:switch(e=e.type){case u:case d:case i:case s:case a:case p:return e;default:switch(e=e&&e.$$typeof){case c:case h:case m:case g:case l:return e;default:return t}}case o:return t}}}function S(e){return x(e)===d}},7192:(e,t,n)=>{"use strict";n(1684)},8668:(e,t,n)=>{"use strict";n.d(t,{M:()=>a});var r=n(2688),o=n(7036),i=n(1832);function a(){(0,o.W)(),(0,i.ao)()&&function(){const t=(0,r.m2)();if(!t.__SENTRY__)return;const n={mongodb:()=>new((0,i.iq)(e,"./node/integrations/mongo").Mongo),mongoose:()=>new((0,i.iq)(e,"./node/integrations/mongo").Mongo),mysql:()=>new((0,i.iq)(e,"./node/integrations/mysql").Mysql),pg:()=>new((0,i.iq)(e,"./node/integrations/postgres").Postgres)},o=Object.keys(n).filter((e=>!!(0,i.kf)(e))).map((e=>{try{return n[e]()}catch(t){return}})).filter((e=>e));o.length>0&&(t.__SENTRY__.integrations=[...t.__SENTRY__.integrations||[],...o])}()}e=n.hmd(e)},8112:(e,t,n)=>{"use strict";n.d(t,{a:()=>r});const r="production"},5828:(e,t,n)=>{"use strict";n.d(t,{Q:()=>r});const r="undefined"===typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__},6140:(e,t,n)=>{"use strict";n.d(t,{ao:()=>a,gf:()=>i,oV:()=>o});var r=n(2688);function o(){const e=(0,r.WS)();for(var t=arguments.length,n=new Array(t),o=0;o(e.getStackTop().scope=t,r(t)))):e.withScope(r)}return e.withScope(n[0])}function i(){return(0,r.WS)().getClient()}function a(){return(0,r.WS)().getScope()}},2688:(e,t,n)=>{"use strict";n.d(t,{WS:()=>k,Ud:()=>I,m2:()=>E,Uz:()=>O});var r,o=n(8104),i=n(5660),a=n(1008),s=n(2012),l=n(7988),c=n(8112),u=n(5828);!function(e){e[e.PENDING=0]="PENDING";e[e.RESOLVED=1]="RESOLVED";e[e.REJECTED=2]="REJECTED"}(r||(r={}));class d{constructor(e){d.prototype.__init.call(this),d.prototype.__init2.call(this),d.prototype.__init3.call(this),d.prototype.__init4.call(this),this._state=r.PENDING,this._handlers=[];try{e(this._resolve,this._reject)}catch(t){this._reject(t)}}then(e,t){return new d(((n,r)=>{this._handlers.push([!1,t=>{if(e)try{n(e(t))}catch(o){r(o)}else n(t)},e=>{if(t)try{n(t(e))}catch(o){r(o)}else r(e)}]),this._executeHandlers()}))}catch(e){return this.then((e=>e),e)}finally(e){return new d(((t,n)=>{let r,o;return this.then((t=>{o=!1,r=t,e&&e()}),(t=>{o=!0,r=t,e&&e()})).then((()=>{o?n(r):t(r)}))}))}__init(){this._resolve=e=>{this._setResult(r.RESOLVED,e)}}__init2(){this._reject=e=>{this._setResult(r.REJECTED,e)}}__init3(){this._setResult=(e,t)=>{this._state===r.PENDING&&((0,o.Oe)(t)?t.then(this._resolve,this._reject):(this._state=e,this._value=t,this._executeHandlers()))}}__init4(){this._executeHandlers=()=>{if(this._state===r.PENDING)return;const e=this._handlers.slice();this._handlers=[],e.forEach((e=>{e[0]||(this._state===r.RESOLVED&&e[1](this._value),this._state===r.REJECTED&&e[2](this._value),e[0]=!0)}))}}}function h(){return(0,l.a)("globalEventProcessors",(()=>[]))}function p(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0;return new d(((i,a)=>{const l=e[r];if(null===t||"function"!==typeof l)i(t);else{const c=l({...t},n);u.Q&&l.id&&null===c&&s.QE.log('Event processor "'.concat(l.id,'" dropped event')),(0,o.Oe)(c)?c.then((t=>p(e,t,n,r+1).then(i))).then(null,a):p(e,c,n,r+1).then(i).then(null,a)}}))}var f=n(3643);function g(e){const t=(0,a.Go)(),n={sid:(0,i.OW)(),init:!0,timestamp:t,started:t,duration:0,status:"ok",errors:0,ignoreDuration:!1,toJSON:()=>function(e){return(0,f.Sy)({sid:"".concat(e.sid),init:e.init,started:new Date(1e3*e.started).toISOString(),timestamp:new Date(1e3*e.timestamp).toISOString(),status:e.status,errors:e.errors,did:"number"===typeof e.did||"string"===typeof e.did?"".concat(e.did):void 0,duration:e.duration,abnormal_mechanism:e.abnormal_mechanism,attrs:{release:e.release,environment:e.environment,ip_address:e.ipAddress,user_agent:e.userAgent}})}(n)};return e&&m(n,e),n}function m(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(t.user&&(!e.ipAddress&&t.user.ip_address&&(e.ipAddress=t.user.ip_address),e.did||t.did||(e.did=t.user.id||t.user.email||t.user.username)),e.timestamp=t.timestamp||(0,a.Go)(),t.abnormal_mechanism&&(e.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(e.ignoreDuration=t.ignoreDuration),t.sid&&(e.sid=32===t.sid.length?t.sid:(0,i.OW)()),void 0!==t.init&&(e.init=t.init),!e.did&&t.did&&(e.did="".concat(t.did)),"number"===typeof t.started&&(e.started=t.started),e.ignoreDuration)e.duration=void 0;else if("number"===typeof t.duration)e.duration=t.duration;else{const t=e.timestamp-e.started;e.duration=t>=0?t:0}t.release&&(e.release=t.release),t.environment&&(e.environment=t.environment),!e.ipAddress&&t.ipAddress&&(e.ipAddress=t.ipAddress),!e.userAgent&&t.userAgent&&(e.userAgent=t.userAgent),"number"===typeof t.errors&&(e.errors=t.errors),t.status&&(e.status=t.status)}var y=n(9072),v=n(1240),b=n(6704);function A(e,t){const{fingerprint:n,span:r,breadcrumbs:o,sdkProcessingMetadata:a}=t;!function(e,t){const{extra:n,tags:r,user:o,contexts:i,level:a,transactionName:s}=t,l=(0,f.Sy)(n);l&&Object.keys(l).length&&(e.extra={...l,...e.extra});const c=(0,f.Sy)(r);c&&Object.keys(c).length&&(e.tags={...c,...e.tags});const u=(0,f.Sy)(o);u&&Object.keys(u).length&&(e.user={...u,...e.user});const d=(0,f.Sy)(i);d&&Object.keys(d).length&&(e.contexts={...d,...e.contexts});a&&(e.level=a);s&&(e.transaction=s)}(e,t),r&&function(e,t){e.contexts={trace:(0,b.I1)(t),...e.contexts};const n=(0,v.U)(t);if(n){e.sdkProcessingMetadata={dynamicSamplingContext:(0,y.w)(t),...e.sdkProcessingMetadata};const r=(0,b.U0)(n).description;r&&(e.tags={transaction:r,...e.tags})}}(e,r),function(e,t){e.fingerprint=e.fingerprint?(0,i.gV)(e.fingerprint):[],t&&(e.fingerprint=e.fingerprint.concat(t));e.fingerprint&&!e.fingerprint.length&&delete e.fingerprint}(e,n),function(e,t){const n=[...e.breadcrumbs||[],...t];e.breadcrumbs=n.length?n:void 0}(e,o),function(e,t){e.sdkProcessingMetadata={...e.sdkProcessingMetadata,...t}}(e,a)}class x{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext=S()}static clone(e){return e?e.clone():new x}clone(){const e=new x;return e._breadcrumbs=[...this._breadcrumbs],e._tags={...this._tags},e._extra={...this._extra},e._contexts={...this._contexts},e._user=this._user,e._level=this._level,e._span=this._span,e._session=this._session,e._transactionName=this._transactionName,e._fingerprint=this._fingerprint,e._eventProcessors=[...this._eventProcessors],e._requestSession=this._requestSession,e._attachments=[...this._attachments],e._sdkProcessingMetadata={...this._sdkProcessingMetadata},e._propagationContext={...this._propagationContext},e._client=this._client,e}setClient(e){this._client=e}getClient(){return this._client}addScopeListener(e){this._scopeListeners.push(e)}addEventProcessor(e){return this._eventProcessors.push(e),this}setUser(e){return this._user=e||{email:void 0,id:void 0,ip_address:void 0,segment:void 0,username:void 0},this._session&&m(this._session,{user:e}),this._notifyScopeListeners(),this}getUser(){return this._user}getRequestSession(){return this._requestSession}setRequestSession(e){return this._requestSession=e,this}setTags(e){return this._tags={...this._tags,...e},this._notifyScopeListeners(),this}setTag(e,t){return this._tags={...this._tags,[e]:t},this._notifyScopeListeners(),this}setExtras(e){return this._extra={...this._extra,...e},this._notifyScopeListeners(),this}setExtra(e,t){return this._extra={...this._extra,[e]:t},this._notifyScopeListeners(),this}setFingerprint(e){return this._fingerprint=e,this._notifyScopeListeners(),this}setLevel(e){return this._level=e,this._notifyScopeListeners(),this}setTransactionName(e){return this._transactionName=e,this._notifyScopeListeners(),this}setContext(e,t){return null===t?delete this._contexts[e]:this._contexts[e]=t,this._notifyScopeListeners(),this}setSpan(e){return this._span=e,this._notifyScopeListeners(),this}getSpan(){return this._span}getTransaction(){const e=this._span;return e&&e.transaction}setSession(e){return e?this._session=e:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(e){if(!e)return this;if("function"===typeof e){const t=e(this);return t instanceof x?t:this}return e instanceof x?(this._tags={...this._tags,...e._tags},this._extra={...this._extra,...e._extra},this._contexts={...this._contexts,...e._contexts},e._user&&Object.keys(e._user).length&&(this._user=e._user),e._level&&(this._level=e._level),e._fingerprint&&(this._fingerprint=e._fingerprint),e._requestSession&&(this._requestSession=e._requestSession),e._propagationContext&&(this._propagationContext=e._propagationContext)):(0,o.oF)(e)&&(this._tags={...this._tags,...e.tags},this._extra={...this._extra,...e.extra},this._contexts={...this._contexts,...e.contexts},e.user&&(this._user=e.user),e.level&&(this._level=e.level),e.fingerprint&&(this._fingerprint=e.fingerprint),e.requestSession&&(this._requestSession=e.requestSession),e.propagationContext&&(this._propagationContext=e.propagationContext)),this}clear(){return this._breadcrumbs=[],this._tags={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._requestSession=void 0,this._span=void 0,this._session=void 0,this._notifyScopeListeners(),this._attachments=[],this._propagationContext=S(),this}addBreadcrumb(e,t){const n="number"===typeof t?t:100;if(n<=0)return this;const r={timestamp:(0,a.CG)(),...e},o=this._breadcrumbs;return o.push(r),this._breadcrumbs=o.length>n?o.slice(-n):o,this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(e){return this._attachments.push(e),this}getAttachments(){return this.getScopeData().attachments}clearAttachments(){return this._attachments=[],this}getScopeData(){const{_breadcrumbs:e,_attachments:t,_contexts:n,_tags:r,_extra:o,_user:i,_level:a,_fingerprint:s,_eventProcessors:l,_propagationContext:c,_sdkProcessingMetadata:u,_transactionName:d,_span:h}=this;return{breadcrumbs:e,attachments:t,contexts:n,tags:r,extra:o,user:i,level:a,fingerprint:s||[],eventProcessors:l,propagationContext:c,sdkProcessingMetadata:u,transactionName:d,span:h}}applyToEvent(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[];A(e,this.getScopeData());return p([...n,...h(),...this._eventProcessors],e,t)}setSDKProcessingMetadata(e){return this._sdkProcessingMetadata={...this._sdkProcessingMetadata,...e},this}setPropagationContext(e){return this._propagationContext=e,this}getPropagationContext(){return this._propagationContext}captureException(e,t){const n=t&&t.event_id?t.event_id:(0,i.OW)();if(!this._client)return s.QE.warn("No client configured on scope - will not capture exception!"),n;const r=new Error("Sentry syntheticException");return this._client.captureException(e,{originalException:e,syntheticException:r,...t,event_id:n},this),n}captureMessage(e,t,n){const r=n&&n.event_id?n.event_id:(0,i.OW)();if(!this._client)return s.QE.warn("No client configured on scope - will not capture message!"),r;const o=new Error(e);return this._client.captureMessage(e,t,{originalException:e,syntheticException:o,...n,event_id:r},this),r}captureEvent(e,t){const n=t&&t.event_id?t.event_id:(0,i.OW)();return this._client?(this._client.captureEvent(e,{...t,event_id:n},this),n):(s.QE.warn("No client configured on scope - will not capture event!"),n)}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach((e=>{e(this)})),this._notifyingListeners=!1)}}function S(){return{traceId:(0,i.OW)(),spanId:(0,i.OW)().substring(16)}}const w=parseFloat("7.100.1"),C=100;class _{constructor(e,t,n){let r,o,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:w;this._version=i,t?r=t:(r=new x,r.setClient(e)),n?o=n:(o=new x,o.setClient(e)),this._stack=[{scope:r}],e&&this.bindClient(e),this._isolationScope=o}isOlderThan(e){return this._version(this.popScope(),e)),(e=>{throw this.popScope(),e})):(this.popScope(),n)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStack(){return this._stack}getStackTop(){return this._stack[this._stack.length-1]}captureException(e,t){const n=this._lastEventId=t&&t.event_id?t.event_id:(0,i.OW)(),r=new Error("Sentry syntheticException");return this.getScope().captureException(e,{originalException:e,syntheticException:r,...t,event_id:n}),n}captureMessage(e,t,n){const r=this._lastEventId=n&&n.event_id?n.event_id:(0,i.OW)(),o=new Error(e);return this.getScope().captureMessage(e,t,{originalException:e,syntheticException:o,...n,event_id:r}),r}captureEvent(e,t){const n=t&&t.event_id?t.event_id:(0,i.OW)();return e.type||(this._lastEventId=n),this.getScope().captureEvent(e,{...t,event_id:n}),n}lastEventId(){return this._lastEventId}addBreadcrumb(e,t){const{scope:n,client:r}=this.getStackTop();if(!r)return;const{beforeBreadcrumb:o=null,maxBreadcrumbs:i=C}=r.getOptions&&r.getOptions()||{};if(i<=0)return;const l={timestamp:(0,a.CG)(),...e},c=o?(0,s.QD)((()=>o(l,t))):l;null!==c&&(r.emit&&r.emit("beforeAddBreadcrumb",c,t),n.addBreadcrumb(c,i))}setUser(e){this.getScope().setUser(e),this.getIsolationScope().setUser(e)}setTags(e){this.getScope().setTags(e),this.getIsolationScope().setTags(e)}setExtras(e){this.getScope().setExtras(e),this.getIsolationScope().setExtras(e)}setTag(e,t){this.getScope().setTag(e,t),this.getIsolationScope().setTag(e,t)}setExtra(e,t){this.getScope().setExtra(e,t),this.getIsolationScope().setExtra(e,t)}setContext(e,t){this.getScope().setContext(e,t),this.getIsolationScope().setContext(e,t)}configureScope(e){const{scope:t,client:n}=this.getStackTop();n&&e(t)}run(e){const t=R(this);try{e(this)}finally{R(t)}}getIntegration(e){const t=this.getClient();if(!t)return null;try{return t.getIntegration(e)}catch(n){return u.Q&&s.QE.warn("Cannot retrieve integration ".concat(e.id," from the current Hub")),null}}startTransaction(e,t){const n=this._callExtensionMethod("startTransaction",e,t);if(u.Q&&!n){this.getClient()?s.QE.warn("Tracing extension 'startTransaction' has not been added. Call 'addTracingExtensions' before calling 'init':\nSentry.addTracingExtensions();\nSentry.init({...});\n"):s.QE.warn("Tracing extension 'startTransaction' is missing. You should 'init' the SDK before calling 'startTransaction'")}return n}traceHeaders(){return this._callExtensionMethod("traceHeaders")}captureSession(){if(arguments.length>0&&void 0!==arguments[0]&&arguments[0])return this.endSession();this._sendSessionUpdate()}endSession(){const e=this.getStackTop().scope,t=e.getSession();t&&function(e,t){let n={};t?n={status:t}:"ok"===e.status&&(n={status:"exited"}),m(e,n)}(t),this._sendSessionUpdate(),e.setSession()}startSession(e){const{scope:t,client:n}=this.getStackTop(),{release:r,environment:o=c.a}=n&&n.getOptions()||{},{userAgent:i}=l.GLOBAL_OBJ.navigator||{},a=g({release:r,environment:o,user:t.getUser(),...i&&{userAgent:i},...e}),s=t.getSession&&t.getSession();return s&&"ok"===s.status&&m(s,{status:"exited"}),this.endSession(),t.setSession(a),a}shouldSendDefaultPii(){const e=this.getClient(),t=e&&e.getOptions();return Boolean(t&&t.sendDefaultPii)}_sendSessionUpdate(){const{scope:e,client:t}=this.getStackTop(),n=e.getSession();n&&t&&t.captureSession&&t.captureSession(n)}_callExtensionMethod(e){const t=E().__SENTRY__;if(t&&t.extensions&&"function"===typeof t.extensions[e]){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o0&&void 0!==arguments[0]?arguments[0]:E();return j(e)&&!P(e).isOlderThan(w)||B(e,new _),P(e)}function O(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const n=E();return n.__SENTRY__&&n.__SENTRY__.acs?n.__SENTRY__.acs.runWithAsyncContext(e,t):e()}function j(e){return!!(e&&e.__SENTRY__&&e.__SENTRY__.hub)}function P(e){return(0,l.a)("hub",(()=>new _),e)}function B(e,t){if(!e)return!1;return(e.__SENTRY__=e.__SENTRY__||{}).hub=t,!0}},1928:(e,t,n)=>{"use strict";n.d(t,{Oy:()=>i,Ul:()=>o,ec:()=>a,y_:()=>r});const r="sentry.source",o="sentry.sample_rate",i="sentry.op",a="sentry.origin"},9072:(e,t,n)=>{"use strict";n.d(t,{g:()=>l,w:()=>c});var r=n(3643),o=n(8112),i=n(6140),a=n(1240),s=n(6704);function l(e,t,n){const i=t.getOptions(),{publicKey:a}=t.getDsn()||{},{segment:s}=n&&n.getUser()||{},l=(0,r.Sy)({environment:i.environment||o.a,release:i.release,user_segment:s,public_key:a,trace_id:e});return t.emit&&t.emit("createDsc",l),l}function c(e){const t=(0,i.gf)();if(!t)return{};const n=l((0,s.U0)(e).trace_id||"",t,(0,i.ao)()),r=(0,a.U)(e);if(!r)return n;const o=r&&r._frozenDynamicSamplingContext;if(o)return o;const{sampleRate:c,source:u}=r.metadata;null!=c&&(n.sample_rate="".concat(c));const d=(0,s.U0)(r);return u&&"url"!==u&&(n.transaction=d.description),n.sampled=String((0,s._M)(r)),t.emit&&t.emit("createDsc",n),n}},7036:(e,t,n)=>{"use strict";n.d(t,{W:()=>E,I:()=>_});var r=n(2012),o=n(5828),i=n(2688),a=n(6704),s=n(7988),l=n(7848);let c=null;function u(){c=s.GLOBAL_OBJ.onerror,s.GLOBAL_OBJ.onerror=function(e,t,n,r,o){const i={column:r,error:o,line:n,msg:e,url:t};return(0,l.mw)("error",i),!(!c||c.__SENTRY_LOADER__)&&c.apply(this,arguments)},s.GLOBAL_OBJ.onerror.__SENTRY_INSTRUMENTED__=!0}let d=null;function h(){d=s.GLOBAL_OBJ.onunhandledrejection,s.GLOBAL_OBJ.onunhandledrejection=function(e){const t=e;return(0,l.mw)("unhandledrejection",t),!(d&&!d.__SENTRY_LOADER__)||d.apply(this,arguments)},s.GLOBAL_OBJ.onunhandledrejection.__SENTRY_INSTRUMENTED__=!0}var p=n(2844);let f=!1;function g(){f||(f=!0,function(e){const t="error";(0,l.st)(t,e),(0,l.qA)(t,u)}(m),function(e){const t="unhandledrejection";(0,l.st)(t,e),(0,l.qA)(t,h)}(m))}function m(){const e=(0,p.gB)();if(e){const t="internal_error";o.Q&&r.QE.log("[Tracing] Transaction: ".concat(t," -> Global error occured")),e.setStatus(t)}}m.tag="sentry_tracingErrorCallback";var y=n(9784),v=n(8104),b=n(1928),A=n(9420);function x(e,t,n){if(!(0,A.K)(t))return e.sampled=!1,e;if(void 0!==e.sampled)return e.setAttribute(b.Ul,Number(e.sampled)),e;let i;return"function"===typeof t.tracesSampler?(i=t.tracesSampler(n),e.setAttribute(b.Ul,Number(i))):void 0!==n.parentSampled?i=n.parentSampled:"undefined"!==typeof t.tracesSampleRate?(i=t.tracesSampleRate,e.setAttribute(b.Ul,Number(i))):(i=1,e.setAttribute(b.Ul,i)),function(e){if((0,v.WO)(e)||"number"!==typeof e&&"boolean"!==typeof e)return o.Q&&r.QE.warn("[Tracing] Given sample rate is invalid. Sample rate must be a boolean or a number between 0 and 1. Got ".concat(JSON.stringify(e)," of type ").concat(JSON.stringify(typeof e),".")),!1;if(e<0||e>1)return o.Q&&r.QE.warn("[Tracing] Given sample rate is invalid. Sample rate must be between 0 and 1. Got ".concat(e,".")),!1;return!0}(i)?i?(e.sampled=Math.random()7&&void 0!==arguments[7]&&arguments[7];const l=e.getClient(),c=l&&l.getOptions()||{};let u=new y.if(t,e,n,r,a,o,s);return u=x(u,c,{name:t.name,parentSampled:t.parentSampled,transactionContext:t,attributes:{...t.data,...t.attributes},...i}),u.isRecording()&&u.initSpanRecorder(c._experiments&&c._experiments.maxSpans),l&&l.emit&&l.emit("startTransaction",u),u}function E(){const e=(0,i.m2)();e.__SENTRY__&&(e.__SENTRY__.extensions=e.__SENTRY__.extensions||{},e.__SENTRY__.extensions.startTransaction||(e.__SENTRY__.extensions.startTransaction=C),e.__SENTRY__.extensions.traceHeaders||(e.__SENTRY__.extensions.traceHeaders=w),g())}},9784:(e,t,n)=>{"use strict";n.d(t,{Su:()=>c,if:()=>h});var r=n(2012),o=n(1008),i=n(5828),a=n(6704),s=n(5308),l=n(3436);const c={idleTimeout:1e3,finalTimeout:3e4,heartbeatInterval:5e3},u=["heartbeatFailed","idleTimeout","documentHidden","finalTimeout","externalFinish","cancelled"];class d extends s.U{constructor(e,t,n,r){super(r),this._pushActivity=e,this._popActivity=t,this.transactionSpanId=n}add(e){var t=this;if(e.spanContext().spanId!==this.transactionSpanId){const n=e.end;e.end=function(){t._popActivity(e.spanContext().spanId);for(var r=arguments.length,o=new Array(r),i=0;i2&&void 0!==arguments[2]?arguments[2]:c.idleTimeout,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:c.finalTimeout,a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:c.heartbeatInterval,s=arguments.length>5&&void 0!==arguments[5]&&arguments[5],l=arguments.length>6&&void 0!==arguments[6]&&arguments[6];super(e,t),this._idleHub=t,this._idleTimeout=n,this._finalTimeout=o,this._heartbeatInterval=a,this._onScope=s,this.activities={},this._heartbeatCounter=0,this._finished=!1,this._idleTimeoutCanceledPermanently=!1,this._beforeFinishCallbacks=[],this._finishReason=u[4],this._autoFinishAllowed=!l,s&&(i.Q&&r.QE.log("Setting idle transaction on scope. Span ID: ".concat(this.spanContext().spanId)),t.getScope().setSpan(this)),l||this._restartIdleTimeout(),setTimeout((()=>{this._finished||(this.setStatus("deadline_exceeded"),this._finishReason=u[3],this.end())}),this._finalTimeout)}end(e){const t=(0,a.EJ)(e);if(this._finished=!0,this.activities={},"ui.action.click"===this.op&&this.setAttribute("finishReason",this._finishReason),this.spanRecorder){i.Q&&r.QE.log("[Tracing] finishing IdleTransaction",new Date(1e3*t).toISOString(),this.op);for(const e of this._beforeFinishCallbacks)e(this,t);this.spanRecorder.spans=this.spanRecorder.spans.filter((e=>{if(e.spanContext().spanId===this.spanContext().spanId)return!0;(0,a.U0)(e).timestamp||(e.setStatus("cancelled"),e.end(t),i.Q&&r.QE.log("[Tracing] cancelling span since transaction ended early",JSON.stringify(e,void 0,2)));const{start_timestamp:n,timestamp:o}=(0,a.U0)(e),s=n&&n{this._finished||this._pushActivity(e)},n=e=>{this._finished||this._popActivity(e)};this.spanRecorder=new d(t,n,this.spanContext().spanId,e),i.Q&&r.QE.log("Starting heartbeat"),this._pingHeartbeat()}this.spanRecorder.add(this)}cancelIdleTimeout(e){let{restartOnChildSpanChange:t}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{restartOnChildSpanChange:!0};this._idleTimeoutCanceledPermanently=!1===t,this._idleTimeoutID&&(clearTimeout(this._idleTimeoutID),this._idleTimeoutID=void 0,0===Object.keys(this.activities).length&&this._idleTimeoutCanceledPermanently&&(this._finishReason=u[5],this.end(e)))}setFinishReason(e){this._finishReason=e}sendAutoFinishSignal(){this._autoFinishAllowed||(i.Q&&r.QE.log("[Tracing] Received finish signal for idle transaction."),this._restartIdleTimeout(),this._autoFinishAllowed=!0)}_restartIdleTimeout(e){this.cancelIdleTimeout(),this._idleTimeoutID=setTimeout((()=>{this._finished||0!==Object.keys(this.activities).length||(this._finishReason=u[1],this.end(e))}),this._idleTimeout)}_pushActivity(e){this.cancelIdleTimeout(void 0,{restartOnChildSpanChange:!this._idleTimeoutCanceledPermanently}),i.Q&&r.QE.log("[Tracing] pushActivity: ".concat(e)),this.activities[e]=!0,i.Q&&r.QE.log("[Tracing] new activities count",Object.keys(this.activities).length)}_popActivity(e){if(this.activities[e]&&(i.Q&&r.QE.log("[Tracing] popActivity ".concat(e)),delete this.activities[e],i.Q&&r.QE.log("[Tracing] new activities count",Object.keys(this.activities).length)),0===Object.keys(this.activities).length){const e=(0,o.Go)();this._idleTimeoutCanceledPermanently?this._autoFinishAllowed&&(this._finishReason=u[5],this.end(e)):this._restartIdleTimeout(e+this._idleTimeout/1e3)}}_beat(){if(this._finished)return;const e=Object.keys(this.activities).join("");e===this._prevHeartbeatString?this._heartbeatCounter++:this._heartbeatCounter=1,this._prevHeartbeatString=e,this._heartbeatCounter>=3?this._autoFinishAllowed&&(i.Q&&r.QE.log("[Tracing] Transaction finished because of no change for 3 heart beats"),this.setStatus("deadline_exceeded"),this._finishReason=u[0],this.end()):this._pingHeartbeat()}_pingHeartbeat(){i.Q&&r.QE.log("pinging Heartbeat -> current counter: ".concat(this._heartbeatCounter)),setTimeout((()=>{this._beat()}),this._heartbeatInterval)}}},5308:(e,t,n)=>{"use strict";n.d(t,{C:()=>p,U:()=>h});var r=n(5660),o=n(1008),i=n(2012),a=n(3643),s=n(5828),l=n(1928),c=n(1240),u=n(6704),d=n(8032);class h{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1e3;this._maxlen=e,this.spans=[]}add(e){this.spans.length>this._maxlen?e.spanRecorder=void 0:this.spans.push(e)}}class p{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this._traceId=e.traceId||(0,r.OW)(),this._spanId=e.spanId||(0,r.OW)().substring(16),this._startTime=e.startTimestamp||(0,o.Go)(),this.tags=e.tags?{...e.tags}:{},this.data=e.data?{...e.data}:{},this.instrumenter=e.instrumenter||"sentry",this._attributes={},this.setAttributes({[l.ec]:e.origin||"manual",[l.Oy]:e.op,...e.attributes}),this._name=e.name||e.description,e.parentSpanId&&(this._parentSpanId=e.parentSpanId),"sampled"in e&&(this._sampled=e.sampled),e.status&&(this._status=e.status),e.endTimestamp&&(this._endTime=e.endTimestamp)}get name(){return this._name||""}set name(e){this.updateName(e)}get description(){return this._name}set description(e){this._name=e}get traceId(){return this._traceId}set traceId(e){this._traceId=e}get spanId(){return this._spanId}set spanId(e){this._spanId=e}set parentSpanId(e){this._parentSpanId=e}get parentSpanId(){return this._parentSpanId}get sampled(){return this._sampled}set sampled(e){this._sampled=e}get attributes(){return this._attributes}set attributes(e){this._attributes=e}get startTimestamp(){return this._startTime}set startTimestamp(e){this._startTime=e}get endTimestamp(){return this._endTime}set endTimestamp(e){this._endTime=e}get status(){return this._status}set status(e){this._status=e}get op(){return this._attributes[l.Oy]}set op(e){this.setAttribute(l.Oy,e)}get origin(){return this._attributes[l.ec]}set origin(e){this.setAttribute(l.ec,e)}spanContext(){const{_spanId:e,_traceId:t,_sampled:n}=this;return{spanId:e,traceId:t,traceFlags:n?u.Gg:u.KK}}startChild(e){const t=new p({...e,parentSpanId:this._spanId,sampled:this._sampled,traceId:this._traceId});t.spanRecorder=this.spanRecorder,t.spanRecorder&&t.spanRecorder.add(t);const n=(0,c.U)(this);if(t.transaction=n,s.Q&&n){const r=e&&e.op||"< unknown op >",o=(0,u.U0)(t).description||"< unknown name >",a=n.spanContext().spanId,s="[Tracing] Starting '".concat(r,"' span on transaction '").concat(o,"' (").concat(a,").");i.QE.log(s),this._logMessage=s}return t}setTag(e,t){return this.tags={...this.tags,[e]:t},this}setData(e,t){return this.data={...this.data,[e]:t},this}setAttribute(e,t){void 0===t?delete this._attributes[e]:this._attributes[e]=t}setAttributes(e){Object.keys(e).forEach((t=>this.setAttribute(t,e[t])))}setStatus(e){return this._status=e,this}setHttpStatus(e){return(0,d.iI)(this,e),this}setName(e){this.updateName(e)}updateName(e){return this._name=e,this}isSuccess(){return"ok"===this._status}finish(e){return this.end(e)}end(e){if(this._endTime)return;const t=(0,c.U)(this);if(s.Q&&t&&t.spanContext().spanId!==this._spanId){const e=this._logMessage;e&&i.QE.log(e.replace("Starting","Finishing"))}this._endTime=(0,u.EJ)(e)}toTraceparent(){return(0,u.eA)(this)}toContext(){return(0,a.Sy)({data:this._getData(),description:this._name,endTimestamp:this._endTime,op:this.op,parentSpanId:this._parentSpanId,sampled:this._sampled,spanId:this._spanId,startTimestamp:this._startTime,status:this._status,tags:this.tags,traceId:this._traceId})}updateWithContext(e){return this.data=e.data||{},this._name=e.name||e.description,this._endTime=e.endTimestamp,this.op=e.op,this._parentSpanId=e.parentSpanId,this._sampled=e.sampled,this._spanId=e.spanId||this._spanId,this._startTime=e.startTimestamp||this._startTime,this._status=e.status,this.tags=e.tags||{},this._traceId=e.traceId||this._traceId,this}getTraceContext(){return(0,u.I1)(this)}getSpanJSON(){return(0,a.Sy)({data:this._getData(),description:this._name,op:this._attributes[l.Oy],parent_span_id:this._parentSpanId,span_id:this._spanId,start_timestamp:this._startTime,status:this._status,tags:Object.keys(this.tags).length>0?this.tags:void 0,timestamp:this._endTime,trace_id:this._traceId,origin:this._attributes[l.ec]})}isRecording(){return!this._endTime&&!!this._sampled}toJSON(){return this.getSpanJSON()}_getData(){const{data:e,_attributes:t}=this,n=Object.keys(e).length>0,r=Object.keys(t).length>0;if(n||r)return n&&r?{...e,...t}:n?e:t}}},8032:(e,t,n)=>{"use strict";var r;function o(e){if(e<400&&e>=100)return"ok";if(e>=400&&e<500)switch(e){case 401:return"unauthenticated";case 403:return"permission_denied";case 404:return"not_found";case 409:return"already_exists";case 413:return"failed_precondition";case 429:return"resource_exhausted";default:return"invalid_argument"}if(e>=500&&e<600)switch(e){case 501:return"unimplemented";case 503:return"unavailable";case 504:return"deadline_exceeded";default:return"internal_error"}return"unknown_error"}n.d(t,{iI:()=>i}),function(e){e.Ok="ok";e.DeadlineExceeded="deadline_exceeded";e.Unauthenticated="unauthenticated";e.PermissionDenied="permission_denied";e.NotFound="not_found";e.ResourceExhausted="resource_exhausted";e.InvalidArgument="invalid_argument";e.Unimplemented="unimplemented";e.Unavailable="unavailable";e.InternalError="internal_error";e.UnknownError="unknown_error";e.Cancelled="cancelled";e.AlreadyExists="already_exists";e.FailedPrecondition="failed_precondition";e.Aborted="aborted";e.OutOfRange="out_of_range";e.DataLoss="data_loss"}(r||(r={}));function i(e,t){e.setTag("http.status_code",String(t)),e.setData("http.response.status_code",t);const n=o(t);"unknown_error"!==n&&e.setStatus(n)}},12:(e,t,n)=>{"use strict";n.d(t,{iu:()=>y,Yz:()=>d,MQ:()=>u});var r=n(3643),o=n(6140),i=n(2688),a=n(8104);function s(e,t){let n,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:()=>{};try{n=e()}catch(o){throw t(o),r(),o}return function(e,t,n){if((0,a.Oe)(e))return e.then((e=>(n(),e)),(e=>{throw t(e),n(),e}));return n(),e}(n,t,r)}var l=n(9420),c=n(6704);function u(e,t){const n=p(e);return(0,i.Uz)((()=>(0,o.oV)(e.scope,(r=>{const o=(0,i.WS)(),a=r.getSpan(),l=e.onlyIfParent&&!a?void 0:h(o,a,n);return r.setSpan(l),s((()=>t(l)),(()=>{if(l){const{status:e}=(0,c.U0)(l);e&&"ok"!==e||l.setStatus("internal_error")}}),(()=>l&&l.end()))}))))}function d(e){if(!(0,l.K)())return;const t=p(e),n=(0,i.WS)(),r=e.scope?e.scope.getSpan():(0,o.ao)().getSpan();if(e.onlyIfParent&&!r)return;const a=(0,i.Ud)(),s=(0,o.ao)();let c;if(r)c=r.startChild(t);else{const{traceId:e,dsc:r,parentSpanId:o,sampled:i}={...a.getPropagationContext(),...s.getPropagationContext()};c=n.startTransaction({traceId:e,parentSpanId:o,parentSampled:i,...t,metadata:{dynamicSamplingContext:r,...t.metadata}})}return m(c,s,a),c}function h(e,t,n){if(!(0,l.K)())return;const r=(0,i.Ud)(),a=(0,o.ao)();let s;if(t)s=t.startChild(n);else{const{traceId:t,dsc:o,parentSpanId:i,sampled:l}={...r.getPropagationContext(),...a.getPropagationContext()};s=e.startTransaction({traceId:t,parentSpanId:i,parentSampled:l,...n,metadata:{dynamicSamplingContext:o,...n.metadata}})}return m(s,a,r),s}function p(e){if(e.startTime){const t={...e};return t.startTimestamp=(0,c.EJ)(e.startTime),delete t.startTime,t}return e}const f="_sentryScope",g="_sentryIsolationScope";function m(e,t,n){e&&((0,r.QB)(e,g,n),(0,r.QB)(e,f,t))}function y(e){return{scope:e[f],isolationScope:e[g]}}},3436:(e,t,n)=>{"use strict";n.d(t,{I:()=>h});var r=n(3643),o=n(2012),i=n(5828),a=n(2688),s=n(1928),l=n(6704),c=n(9072),u=n(5308),d=n(12);class h extends u.C{constructor(e,t){super(e),this._measurements={},this._contexts={},this._hub=t||(0,a.WS)(),this._name=e.name||"",this._metadata={...e.metadata},this._trimEnd=e.trimEnd,this.transaction=this;const n=this._metadata.dynamicSamplingContext;n&&(this._frozenDynamicSamplingContext={...n})}get name(){return this._name}set name(e){this.setName(e)}get metadata(){return{source:"custom",spanMetadata:{},...this._metadata,...this._attributes[s.y_]&&{source:this._attributes[s.y_]},...this._attributes[s.Ul]&&{sampleRate:this._attributes[s.Ul]}}}set metadata(e){this._metadata=e}setName(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"custom";this._name=e,this.setAttribute(s.y_,t)}updateName(e){return this._name=e,this}initSpanRecorder(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1e3;this.spanRecorder||(this.spanRecorder=new u.U(e)),this.spanRecorder.add(this)}setContext(e,t){null===t?delete this._contexts[e]:this._contexts[e]=t}setMeasurement(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"";this._measurements[e]={value:t,unit:n}}setMetadata(e){this._metadata={...this._metadata,...e}}end(e){const t=(0,l.EJ)(e),n=this._finishTransaction(t);if(n)return this._hub.captureEvent(n)}toContext(){const e=super.toContext();return(0,r.Sy)({...e,name:this._name,trimEnd:this._trimEnd})}updateWithContext(e){return super.updateWithContext(e),this._name=e.name||"",this._trimEnd=e.trimEnd,this}getDynamicSamplingContext(){return(0,c.w)(this)}setHub(e){this._hub=e}_finishTransaction(e){if(void 0!==this._endTime)return;this._name||(i.Q&&o.QE.warn("Transaction has no name, falling back to ``."),this._name=""),super.end(e);const t=this._hub.getClient();if(t&&t.emit&&t.emit("finishTransaction",this),!0!==this._sampled)return i.Q&&o.QE.log("[Tracing] Discarding transaction because its trace was not chosen to be sampled."),void(t&&t.recordDroppedEvent("sample_rate","transaction"));const n=this.spanRecorder?this.spanRecorder.spans.filter((e=>e!==this&&(0,l.U0)(e).timestamp)):[];if(this._trimEnd&&n.length>0){const e=n.map((e=>(0,l.U0)(e).timestamp)).filter(Boolean);this._endTime=e.reduce(((e,t)=>e>t?e:t))}const{scope:r,isolationScope:a}=(0,d.iu)(this),{metadata:s}=this,{source:u}=s,h={contexts:{...this._contexts,trace:(0,l.I1)(this)},spans:n,start_timestamp:this._startTime,tags:this.tags,timestamp:this._endTime,transaction:this._name,type:"transaction",sdkProcessingMetadata:{...s,capturedSpanScope:r,capturedSpanIsolationScope:a,dynamicSamplingContext:(0,c.w)(this)},...u&&{transaction_info:{source:u}}};return Object.keys(this._measurements).length>0&&(i.Q&&o.QE.log("[Measurements] Adding measurements to transaction",JSON.stringify(this._measurements,void 0,2)),h.measurements=this._measurements),i.Q&&o.QE.log("[Tracing] Finishing ".concat(this.op," transaction: ").concat(this._name,".")),h}}},2844:(e,t,n)=>{"use strict";n.d(t,{gB:()=>o});var r=n(2688);function o(e){return(e||(0,r.WS)()).getScope().getTransaction()}},1240:(e,t,n)=>{"use strict";function r(e){return e.transaction}n.d(t,{U:()=>r})},9420:(e,t,n)=>{"use strict";n.d(t,{K:()=>o});var r=n(6140);function o(e){if("boolean"===typeof __SENTRY_TRACING__&&!__SENTRY_TRACING__)return!1;const t=(0,r.gf)(),n=e||t&&t.getOptions();return!!n&&(n.enableTracing||"tracesSampleRate"in n||"tracesSampler"in n)}},6704:(e,t,n)=>{"use strict";n.d(t,{EJ:()=>u,Gg:()=>s,I1:()=>l,KK:()=>a,U0:()=>h,_M:()=>p,eA:()=>c});var r=n(3643),o=n(2628),i=n(1008);const a=0,s=1;function l(e){const{spanId:t,traceId:n}=e.spanContext(),{data:o,op:i,parent_span_id:a,status:s,tags:l,origin:c}=h(e);return(0,r.Sy)({data:o,op:i,parent_span_id:a,span_id:t,status:s,tags:l,trace_id:n,origin:c})}function c(e){const{traceId:t,spanId:n}=e.spanContext(),r=p(e);return(0,o.mA)(t,n,r)}function u(e){return"number"===typeof e?d(e):Array.isArray(e)?e[0]+e[1]/1e9:e instanceof Date?d(e.getTime()):(0,i.Go)()}function d(e){return e>9999999999?e/1e3:e}function h(e){return function(e){return"function"===typeof e.getSpanJSON}(e)?e.getSpanJSON():"function"===typeof e.toJSON?e.toJSON():{}}function p(e){const{traceFlags:t}=e.spanContext();return Boolean(t&s)}},5632:(e,t,n)=>{"use strict";n.d(t,{a8:()=>a,wd:()=>d,y_:()=>u});var r=n(5424),o=n(8104),i=n(2012);const a="baggage",s="sentry-",l=/^sentry-/,c=8192;function u(e){if(!(0,o.ct)(e)&&!Array.isArray(e))return;let t={};if(Array.isArray(e))t=e.reduce(((e,t)=>{const n=h(t);for(const r of Object.keys(n))e[r]=n[r];return e}),{});else{if(!e)return;t=h(e)}const n=Object.entries(t).reduce(((e,t)=>{let[n,r]=t;if(n.match(l)){e[n.slice(s.length)]=r}return e}),{});return Object.keys(n).length>0?n:void 0}function d(e){if(!e)return;return function(e){if(0===Object.keys(e).length)return;return Object.entries(e).reduce(((e,t,n)=>{let[o,a]=t;const s="".concat(encodeURIComponent(o),"=").concat(encodeURIComponent(a)),l=0===n?s:"".concat(e,",").concat(s);return l.length>c?(r.Q&&i.QE.warn("Not adding key: ".concat(o," with val: ").concat(a," to baggage header due to exceeding baggage size limits.")),e):l}),"")}(Object.entries(e).reduce(((e,t)=>{let[n,r]=t;return r&&(e["".concat(s).concat(n)]=r),e}),{}))}function h(e){return e.split(",").map((e=>e.split("=").map((e=>decodeURIComponent(e.trim()))))).reduce(((e,t)=>{let[n,r]=t;return e[n]=r,e}),{})}},5424:(e,t,n)=>{"use strict";n.d(t,{Q:()=>r});const r="undefined"===typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__},7848:(e,t,n)=>{"use strict";n.d(t,{mw:()=>u,qA:()=>c,st:()=>l});var r=n(5424),o=n(2012),i=n(9944);const a={},s={};function l(e,t){a[e]=a[e]||[],a[e].push(t)}function c(e,t){s[e]||(t(),s[e]=!0)}function u(e,t){const n=e&&a[e];if(n)for(const a of n)try{a(t)}catch(s){r.Q&&o.QE.error("Error while triggering instrumentation handler.\nType: ".concat(e,"\nName: ").concat((0,i.kJ)(a),"\nError:"),s)}}},8104:(e,t,n)=>{"use strict";n.d(t,{Oe:()=>l,QX:()=>s,WO:()=>c,aG:()=>u,ct:()=>i,oF:()=>a});const r=Object.prototype.toString;function o(e,t){return r.call(e)==="[object ".concat(t,"]")}function i(e){return o(e,"String")}function a(e){return o(e,"Object")}function s(e){return o(e,"RegExp")}function l(e){return Boolean(e&&e.then&&"function"===typeof e.then)}function c(e){return"number"===typeof e&&e!==e}function u(e,t){try{return e instanceof t}catch(n){return!1}}},2012:(e,t,n)=>{"use strict";n.d(t,{QD:()=>s,QE:()=>l});var r=n(5424),o=n(7988);const i=["debug","info","warn","error","log","assert","trace"],a={};function s(e){if(!("console"in o.GLOBAL_OBJ))return e();const t=o.GLOBAL_OBJ.console,n={},r=Object.keys(a);r.forEach((e=>{const r=a[e];n[e]=t[e],t[e]=r}));try{return e()}finally{r.forEach((e=>{t[e]=n[e]}))}}const l=function(){let e=!1;const t={enable:()=>{e=!0},disable:()=>{e=!1},isEnabled:()=>e};return r.Q?i.forEach((n=>{t[n]=function(){for(var t=arguments.length,r=new Array(t),i=0;i{o.GLOBAL_OBJ.console[n]("".concat("Sentry Logger ","[").concat(n,"]:"),...r)}))}})):i.forEach((e=>{t[e]=()=>{}})),t}()},5660:(e,t,n)=>{"use strict";n.d(t,{OW:()=>o,gV:()=>i});var r=n(7988);function o(){const e=r.GLOBAL_OBJ,t=e.crypto||e.msCrypto;let n=()=>16*Math.random();try{if(t&&t.randomUUID)return t.randomUUID().replace(/-/g,"");t&&t.getRandomValues&&(n=()=>{const e=new Uint8Array(1);return t.getRandomValues(e),e[0]})}catch(o){}return([1e7]+1e3+4e3+8e3+1e11).replace(/[018]/g,(e=>(e^(15&n())>>e/4).toString(16)))}function i(e){return Array.isArray(e)?e:[e]}},1832:(e,t,n)=>{"use strict";function r(){return!("undefined"!==typeof __SENTRY_BROWSER_BUNDLE__&&__SENTRY_BROWSER_BUNDLE__)&&"[object process]"===Object.prototype.toString.call("undefined"!==typeof process?process:0)}function o(e,t){return e.require(t)}function i(t){let n;try{n=o(e,t)}catch(r){}try{const{cwd:r}=o(e,"process");n=o(e,"".concat(r(),"/node_modules/").concat(t))}catch(r){}return n}n.d(t,{iq:()=>o,ao:()=>r,kf:()=>i}),e=n.hmd(e)},3643:(e,t,n)=>{"use strict";n.d(t,{QB:()=>s,Sy:()=>l,ym:()=>a});var r=n(5424),o=n(8104),i=n(2012);function a(e,t,n){if(!(t in e))return;const r=e[t],o=n(r);"function"===typeof o&&function(e,t){try{const n=t.prototype||{};e.prototype=t.prototype=n,s(e,"__sentry_original__",t)}catch(n){}}(o,r),e[t]=o}function s(e,t,n){try{Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0})}catch(o){r.Q&&i.QE.log('Failed to add non-enumerable property "'.concat(t,'" to object'),e)}}function l(e){return c(e,new Map)}function c(e,t){if(function(e){if(!(0,o.oF)(e))return!1;try{const t=Object.getPrototypeOf(e).constructor.name;return!t||"Object"===t}catch(t){return!0}}(e)){const n=t.get(e);if(void 0!==n)return n;const r={};t.set(e,r);for(const o of Object.keys(e))"undefined"!==typeof e[o]&&(r[o]=c(e[o],t));return r}if(Array.isArray(e)){const n=t.get(e);if(void 0!==n)return n;const r=[];return t.set(e,r),e.forEach((e=>{r.push(c(e,t))})),r}return e}},9944:(e,t,n)=>{"use strict";n.d(t,{kJ:()=>o});const r="";function o(e){try{return e&&"function"===typeof e&&e.name||r}catch(t){return r}}},1008:(e,t,n)=>{"use strict";n.d(t,{CG:()=>i,Go:()=>a,W2:()=>l});var r=n(7988);const o=1e3;function i(){return Date.now()/o}const a=function(){const{performance:e}=r.GLOBAL_OBJ;if(!e||!e.now)return i;const t=Date.now()-e.now(),n=void 0==e.timeOrigin?t:e.timeOrigin;return()=>(n+e.now())/o}();let s;const l=(()=>{const{performance:e}=r.GLOBAL_OBJ;if(!e||!e.now)return void(s="none");const t=36e5,n=e.now(),o=Date.now(),i=e.timeOrigin?Math.abs(e.timeOrigin+n-o):t,a=i{"use strict";n.d(t,{Ib:()=>s,mA:()=>l});var r=n(5632),o=n(5660);const i=new RegExp("^[ \\t]*([0-9a-f]{32})?-?([0-9a-f]{16})?-?([01])?[ \\t]*$");function a(e){if(!e)return;const t=e.match(i);if(!t)return;let n;return"1"===t[3]?n=!0:"0"===t[3]&&(n=!1),{traceId:t[1],parentSampled:n,parentSpanId:t[2]}}function s(e,t){const n=a(e),i=(0,r.y_)(t),{traceId:s,parentSpanId:l,parentSampled:c}=n||{};return n?{traceId:s||(0,o.OW)(),parentSpanId:l||(0,o.OW)().substring(16),spanId:(0,o.OW)().substring(16),sampled:c,dsc:i||{}}:{traceId:s||(0,o.OW)(),spanId:(0,o.OW)().substring(16)}}function l(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:(0,o.OW)(),t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:(0,o.OW)().substring(16),n=arguments.length>2?arguments[2]:void 0,r="";return void 0!==n&&(r=n?"-1":"-0"),"".concat(e,"-").concat(t).concat(r)}},7988:(e,t,n)=>{"use strict";function r(e){return e&&e.Math==Math?e:void 0}n.d(t,{GLOBAL_OBJ:()=>o,a:()=>a,m:()=>i});const o="object"==typeof globalThis&&r(globalThis)||"object"==typeof window&&r(window)||"object"==typeof self&&r(self)||"object"==typeof n.g&&r(n.g)||function(){return this}()||{};function i(){return o}function a(e,t,n){const r=n||o,i=r.__SENTRY__=r.__SENTRY__||{};return i[e]||(i[e]=t())}},8476:e=>{"use strict";e.exports={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}},120:(e,t,n)=>{var r=n(8476),o=n(2828),i=Object.hasOwnProperty,a=Object.create(null);for(var s in r)i.call(r,s)&&(a[r[s]]=s);var l=e.exports={to:{},get:{}};function c(e,t,n){return Math.min(Math.max(t,e),n)}function u(e){var t=Math.round(e).toString(16).toUpperCase();return t.length<2?"0"+t:t}l.get=function(e){var t,n;switch(e.substring(0,3).toLowerCase()){case"hsl":t=l.get.hsl(e),n="hsl";break;case"hwb":t=l.get.hwb(e),n="hwb";break;default:t=l.get.rgb(e),n="rgb"}return t?{model:n,value:t}:null},l.get.rgb=function(e){if(!e)return null;var t,n,o,a=[0,0,0,1];if(t=e.match(/^#([a-f0-9]{6})([a-f0-9]{2})?$/i)){for(o=t[2],t=t[1],n=0;n<3;n++){var s=2*n;a[n]=parseInt(t.slice(s,s+2),16)}o&&(a[3]=parseInt(o,16)/255)}else if(t=e.match(/^#([a-f0-9]{3,4})$/i)){for(o=(t=t[1])[3],n=0;n<3;n++)a[n]=parseInt(t[n]+t[n],16);o&&(a[3]=parseInt(o+o,16)/255)}else if(t=e.match(/^rgba?\(\s*([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/)){for(n=0;n<3;n++)a[n]=parseInt(t[n+1],0);t[4]&&(t[5]?a[3]=.01*parseFloat(t[4]):a[3]=parseFloat(t[4]))}else{if(!(t=e.match(/^rgba?\(\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/)))return(t=e.match(/^(\w+)$/))?"transparent"===t[1]?[0,0,0,0]:i.call(r,t[1])?((a=r[t[1]])[3]=1,a):null:null;for(n=0;n<3;n++)a[n]=Math.round(2.55*parseFloat(t[n+1]));t[4]&&(t[5]?a[3]=.01*parseFloat(t[4]):a[3]=parseFloat(t[4]))}for(n=0;n<3;n++)a[n]=c(a[n],0,255);return a[3]=c(a[3],0,1),a},l.get.hsl=function(e){if(!e)return null;var t=e.match(/^hsla?\(\s*([+-]?(?:\d{0,3}\.)?\d+)(?:deg)?\s*,?\s*([+-]?[\d\.]+)%\s*,?\s*([+-]?[\d\.]+)%\s*(?:[,|\/]\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/);if(t){var n=parseFloat(t[4]);return[(parseFloat(t[1])%360+360)%360,c(parseFloat(t[2]),0,100),c(parseFloat(t[3]),0,100),c(isNaN(n)?1:n,0,1)]}return null},l.get.hwb=function(e){if(!e)return null;var t=e.match(/^hwb\(\s*([+-]?\d{0,3}(?:\.\d+)?)(?:deg)?\s*,\s*([+-]?[\d\.]+)%\s*,\s*([+-]?[\d\.]+)%\s*(?:,\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/);if(t){var n=parseFloat(t[4]);return[(parseFloat(t[1])%360+360)%360,c(parseFloat(t[2]),0,100),c(parseFloat(t[3]),0,100),c(isNaN(n)?1:n,0,1)]}return null},l.to.hex=function(){var e=o(arguments);return"#"+u(e[0])+u(e[1])+u(e[2])+(e[3]<1?u(Math.round(255*e[3])):"")},l.to.rgb=function(){var e=o(arguments);return e.length<4||1===e[3]?"rgb("+Math.round(e[0])+", "+Math.round(e[1])+", "+Math.round(e[2])+")":"rgba("+Math.round(e[0])+", "+Math.round(e[1])+", "+Math.round(e[2])+", "+e[3]+")"},l.to.rgb.percent=function(){var e=o(arguments),t=Math.round(e[0]/255*100),n=Math.round(e[1]/255*100),r=Math.round(e[2]/255*100);return e.length<4||1===e[3]?"rgb("+t+"%, "+n+"%, "+r+"%)":"rgba("+t+"%, "+n+"%, "+r+"%, "+e[3]+")"},l.to.hsl=function(){var e=o(arguments);return e.length<4||1===e[3]?"hsl("+e[0]+", "+e[1]+"%, "+e[2]+"%)":"hsla("+e[0]+", "+e[1]+"%, "+e[2]+"%, "+e[3]+")"},l.to.hwb=function(){var e=o(arguments),t="";return e.length>=4&&1!==e[3]&&(t=", "+e[3]),"hwb("+e[0]+", "+e[1]+"%, "+e[2]+"%"+t+")"},l.to.keyword=function(e){return a[e.slice(0,3)]}},2772:(e,t,n)=>{const r=n(120),o=n(4892),i=["keyword","gray","hex"],a={};for(const p of Object.keys(o))a[[...o[p].labels].sort().join("")]=p;const s={};function l(e,t){if(!(this instanceof l))return new l(e,t);if(t&&t in i&&(t=null),t&&!(t in o))throw new Error("Unknown model: "+t);let n,c;if(null==e)this.model="rgb",this.color=[0,0,0],this.valpha=1;else if(e instanceof l)this.model=e.model,this.color=[...e.color],this.valpha=e.valpha;else if("string"===typeof e){const t=r.get(e);if(null===t)throw new Error("Unable to parse color from string: "+e);this.model=t.model,c=o[this.model].channels,this.color=t.value.slice(0,c),this.valpha="number"===typeof t.value[c]?t.value[c]:1}else if(e.length>0){this.model=t||"rgb",c=o[this.model].channels;const n=Array.prototype.slice.call(e,0,c);this.color=h(n,c),this.valpha="number"===typeof e[c]?e[c]:1}else if("number"===typeof e)this.model="rgb",this.color=[e>>16&255,e>>8&255,255&e],this.valpha=1;else{this.valpha=1;const t=Object.keys(e);"alpha"in e&&(t.splice(t.indexOf("alpha"),1),this.valpha="number"===typeof e.alpha?e.alpha:0);const r=t.sort().join("");if(!(r in a))throw new Error("Unable to parse color from object: "+JSON.stringify(e));this.model=a[r];const{labels:i}=o[this.model],s=[];for(n=0;n(e%360+360)%360)),saturationl:u("hsl",1,d(100)),lightness:u("hsl",2,d(100)),saturationv:u("hsv",1,d(100)),value:u("hsv",2,d(100)),chroma:u("hcg",1,d(100)),gray:u("hcg",2,d(100)),white:u("hwb",1,d(100)),wblack:u("hwb",2,d(100)),cyan:u("cmyk",0,d(100)),magenta:u("cmyk",1,d(100)),yellow:u("cmyk",2,d(100)),black:u("cmyk",3,d(100)),x:u("xyz",0,d(95.047)),y:u("xyz",1,d(100)),z:u("xyz",2,d(108.833)),l:u("lab",0,d(100)),a:u("lab",1),b:u("lab",2),keyword(e){return void 0!==e?new l(e):o[this.model].keyword(this.color)},hex(e){return void 0!==e?new l(e):r.to.hex(this.rgb().round().color)},hexa(e){if(void 0!==e)return new l(e);const t=this.rgb().round().color;let n=Math.round(255*this.valpha).toString(16).toUpperCase();return 1===n.length&&(n="0"+n),r.to.hex(t)+n},rgbNumber(){const e=this.rgb().color;return(255&e[0])<<16|(255&e[1])<<8|255&e[2]},luminosity(){const e=this.rgb().color,t=[];for(const[n,r]of e.entries()){const e=r/255;t[n]=e<=.04045?e/12.92:((e+.055)/1.055)**2.4}return.2126*t[0]+.7152*t[1]+.0722*t[2]},contrast(e){const t=this.luminosity(),n=e.luminosity();return t>n?(t+.05)/(n+.05):(n+.05)/(t+.05)},level(e){const t=this.contrast(e);return t>=7?"AAA":t>=4.5?"AA":""},isDark(){const e=this.rgb().color;return(2126*e[0]+7152*e[1]+722*e[2])/1e4<128},isLight(){return!this.isDark()},negate(){const e=this.rgb();for(let t=0;t<3;t++)e.color[t]=255-e.color[t];return e},lighten(e){const t=this.hsl();return t.color[2]+=t.color[2]*e,t},darken(e){const t=this.hsl();return t.color[2]-=t.color[2]*e,t},saturate(e){const t=this.hsl();return t.color[1]+=t.color[1]*e,t},desaturate(e){const t=this.hsl();return t.color[1]-=t.color[1]*e,t},whiten(e){const t=this.hwb();return t.color[1]+=t.color[1]*e,t},blacken(e){const t=this.hwb();return t.color[2]+=t.color[2]*e,t},grayscale(){const e=this.rgb().color,t=.3*e[0]+.59*e[1]+.11*e[2];return l.rgb(t,t,t)},fade(e){return this.alpha(this.valpha-this.valpha*e)},opaquer(e){return this.alpha(this.valpha+this.valpha*e)},rotate(e){const t=this.hsl();let n=t.color[0];return n=(n+e)%360,n=n<0?360+n:n,t.color[0]=n,t},mix(e,t){if(!e||!e.rgb)throw new Error('Argument to "mix" was not a Color instance, but rather an instance of '+typeof e);const n=e.rgb(),r=this.rgb(),o=void 0===t?.5:t,i=2*o-1,a=n.alpha()-r.alpha(),s=((i*a===-1?i:(i+a)/(1+i*a))+1)/2,c=1-s;return l.rgb(s*n.red()+c*r.red(),s*n.green()+c*r.green(),s*n.blue()+c*r.blue(),n.alpha()*o+r.alpha()*(1-o))}};for(const p of Object.keys(o)){if(i.includes(p))continue;const{channels:e}=o[p];l.prototype[p]=function(){if(this.model===p)return new l(this);for(var e=arguments.length,t=new Array(e),n=0;n0?new l(t,p):new l([...(r=o[this.model][p].raw(this.color),Array.isArray(r)?r:[r]),this.valpha],p);var r},l[p]=function(){for(var t=arguments.length,n=new Array(t),r=0;r{const r=n(8476),o={};for(const a of Object.keys(r))o[r[a]]=a;const i={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};e.exports=i;for(const a of Object.keys(i)){if(!("channels"in i[a]))throw new Error("missing channels property: "+a);if(!("labels"in i[a]))throw new Error("missing channel labels property: "+a);if(i[a].labels.length!==i[a].channels)throw new Error("channel and label counts mismatch: "+a);const{channels:e,labels:t}=i[a];delete i[a].channels,delete i[a].labels,Object.defineProperty(i[a],"channels",{value:e}),Object.defineProperty(i[a],"labels",{value:t})}i.rgb.hsl=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,o=Math.min(t,n,r),i=Math.max(t,n,r),a=i-o;let s,l;i===o?s=0:t===i?s=(n-r)/a:n===i?s=2+(r-t)/a:r===i&&(s=4+(t-n)/a),s=Math.min(60*s,360),s<0&&(s+=360);const c=(o+i)/2;return l=i===o?0:c<=.5?a/(i+o):a/(2-i-o),[s,100*l,100*c]},i.rgb.hsv=function(e){let t,n,r,o,i;const a=e[0]/255,s=e[1]/255,l=e[2]/255,c=Math.max(a,s,l),u=c-Math.min(a,s,l),d=function(e){return(c-e)/6/u+.5};return 0===u?(o=0,i=0):(i=u/c,t=d(a),n=d(s),r=d(l),a===c?o=r-n:s===c?o=1/3+t-r:l===c&&(o=2/3+n-t),o<0?o+=1:o>1&&(o-=1)),[360*o,100*i,100*c]},i.rgb.hwb=function(e){const t=e[0],n=e[1];let r=e[2];const o=i.rgb.hsl(e)[0],a=1/255*Math.min(t,Math.min(n,r));return r=1-1/255*Math.max(t,Math.max(n,r)),[o,100*a,100*r]},i.rgb.cmyk=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,o=Math.min(1-t,1-n,1-r);return[100*((1-t-o)/(1-o)||0),100*((1-n-o)/(1-o)||0),100*((1-r-o)/(1-o)||0),100*o]},i.rgb.keyword=function(e){const t=o[e];if(t)return t;let n,i=1/0;for(const o of Object.keys(r)){const t=r[o],l=(s=t,((a=e)[0]-s[0])**2+(a[1]-s[1])**2+(a[2]-s[2])**2);l.04045?((t+.055)/1.055)**2.4:t/12.92,n=n>.04045?((n+.055)/1.055)**2.4:n/12.92,r=r>.04045?((r+.055)/1.055)**2.4:r/12.92;return[100*(.4124*t+.3576*n+.1805*r),100*(.2126*t+.7152*n+.0722*r),100*(.0193*t+.1192*n+.9505*r)]},i.rgb.lab=function(e){const t=i.rgb.xyz(e);let n=t[0],r=t[1],o=t[2];n/=95.047,r/=100,o/=108.883,n=n>.008856?n**(1/3):7.787*n+16/116,r=r>.008856?r**(1/3):7.787*r+16/116,o=o>.008856?o**(1/3):7.787*o+16/116;return[116*r-16,500*(n-r),200*(r-o)]},i.hsl.rgb=function(e){const t=e[0]/360,n=e[1]/100,r=e[2]/100;let o,i,a;if(0===n)return a=255*r,[a,a,a];o=r<.5?r*(1+n):r+n-r*n;const s=2*r-o,l=[0,0,0];for(let c=0;c<3;c++)i=t+1/3*-(c-1),i<0&&i++,i>1&&i--,a=6*i<1?s+6*(o-s)*i:2*i<1?o:3*i<2?s+(o-s)*(2/3-i)*6:s,l[c]=255*a;return l},i.hsl.hsv=function(e){const t=e[0];let n=e[1]/100,r=e[2]/100,o=n;const i=Math.max(r,.01);r*=2,n*=r<=1?r:2-r,o*=i<=1?i:2-i;return[t,100*(0===r?2*o/(i+o):2*n/(r+n)),100*((r+n)/2)]},i.hsv.rgb=function(e){const t=e[0]/60,n=e[1]/100;let r=e[2]/100;const o=Math.floor(t)%6,i=t-Math.floor(t),a=255*r*(1-n),s=255*r*(1-n*i),l=255*r*(1-n*(1-i));switch(r*=255,o){case 0:return[r,l,a];case 1:return[s,r,a];case 2:return[a,r,l];case 3:return[a,s,r];case 4:return[l,a,r];case 5:return[r,a,s]}},i.hsv.hsl=function(e){const t=e[0],n=e[1]/100,r=e[2]/100,o=Math.max(r,.01);let i,a;a=(2-n)*r;const s=(2-n)*o;return i=n*o,i/=s<=1?s:2-s,i=i||0,a/=2,[t,100*i,100*a]},i.hwb.rgb=function(e){const t=e[0]/360;let n=e[1]/100,r=e[2]/100;const o=n+r;let i;o>1&&(n/=o,r/=o);const a=Math.floor(6*t),s=1-r;i=6*t-a,0!==(1&a)&&(i=1-i);const l=n+i*(s-n);let c,u,d;switch(a){default:case 6:case 0:c=s,u=l,d=n;break;case 1:c=l,u=s,d=n;break;case 2:c=n,u=s,d=l;break;case 3:c=n,u=l,d=s;break;case 4:c=l,u=n,d=s;break;case 5:c=s,u=n,d=l}return[255*c,255*u,255*d]},i.cmyk.rgb=function(e){const t=e[0]/100,n=e[1]/100,r=e[2]/100,o=e[3]/100;return[255*(1-Math.min(1,t*(1-o)+o)),255*(1-Math.min(1,n*(1-o)+o)),255*(1-Math.min(1,r*(1-o)+o))]},i.xyz.rgb=function(e){const t=e[0]/100,n=e[1]/100,r=e[2]/100;let o,i,a;return o=3.2406*t+-1.5372*n+-.4986*r,i=-.9689*t+1.8758*n+.0415*r,a=.0557*t+-.204*n+1.057*r,o=o>.0031308?1.055*o**(1/2.4)-.055:12.92*o,i=i>.0031308?1.055*i**(1/2.4)-.055:12.92*i,a=a>.0031308?1.055*a**(1/2.4)-.055:12.92*a,o=Math.min(Math.max(0,o),1),i=Math.min(Math.max(0,i),1),a=Math.min(Math.max(0,a),1),[255*o,255*i,255*a]},i.xyz.lab=function(e){let t=e[0],n=e[1],r=e[2];t/=95.047,n/=100,r/=108.883,t=t>.008856?t**(1/3):7.787*t+16/116,n=n>.008856?n**(1/3):7.787*n+16/116,r=r>.008856?r**(1/3):7.787*r+16/116;return[116*n-16,500*(t-n),200*(n-r)]},i.lab.xyz=function(e){let t,n,r;n=(e[0]+16)/116,t=e[1]/500+n,r=n-e[2]/200;const o=n**3,i=t**3,a=r**3;return n=o>.008856?o:(n-16/116)/7.787,t=i>.008856?i:(t-16/116)/7.787,r=a>.008856?a:(r-16/116)/7.787,t*=95.047,n*=100,r*=108.883,[t,n,r]},i.lab.lch=function(e){const t=e[0],n=e[1],r=e[2];let o;o=360*Math.atan2(r,n)/2/Math.PI,o<0&&(o+=360);return[t,Math.sqrt(n*n+r*r),o]},i.lch.lab=function(e){const t=e[0],n=e[1],r=e[2]/360*2*Math.PI;return[t,n*Math.cos(r),n*Math.sin(r)]},i.rgb.ansi16=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;const[n,r,o]=e;let a=null===t?i.rgb.hsv(e)[2]:t;if(a=Math.round(a/50),0===a)return 30;let s=30+(Math.round(o/255)<<2|Math.round(r/255)<<1|Math.round(n/255));return 2===a&&(s+=60),s},i.hsv.ansi16=function(e){return i.rgb.ansi16(i.hsv.rgb(e),e[2])},i.rgb.ansi256=function(e){const t=e[0],n=e[1],r=e[2];if(t===n&&n===r)return t<8?16:t>248?231:Math.round((t-8)/247*24)+232;return 16+36*Math.round(t/255*5)+6*Math.round(n/255*5)+Math.round(r/255*5)},i.ansi16.rgb=function(e){let t=e%10;if(0===t||7===t)return e>50&&(t+=3.5),t=t/10.5*255,[t,t,t];const n=.5*(1+~~(e>50));return[(1&t)*n*255,(t>>1&1)*n*255,(t>>2&1)*n*255]},i.ansi256.rgb=function(e){if(e>=232){const t=10*(e-232)+8;return[t,t,t]}let t;e-=16;return[Math.floor(e/36)/5*255,Math.floor((t=e%36)/6)/5*255,t%6/5*255]},i.rgb.hex=function(e){const t=(((255&Math.round(e[0]))<<16)+((255&Math.round(e[1]))<<8)+(255&Math.round(e[2]))).toString(16).toUpperCase();return"000000".substring(t.length)+t},i.hex.rgb=function(e){const t=e.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!t)return[0,0,0];let n=t[0];3===t[0].length&&(n=n.split("").map((e=>e+e)).join(""));const r=parseInt(n,16);return[r>>16&255,r>>8&255,255&r]},i.rgb.hcg=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,o=Math.max(Math.max(t,n),r),i=Math.min(Math.min(t,n),r),a=o-i;let s,l;return s=a<1?i/(1-a):0,l=a<=0?0:o===t?(n-r)/a%6:o===n?2+(r-t)/a:4+(t-n)/a,l/=6,l%=1,[360*l,100*a,100*s]},i.hsl.hcg=function(e){const t=e[1]/100,n=e[2]/100,r=n<.5?2*t*n:2*t*(1-n);let o=0;return r<1&&(o=(n-.5*r)/(1-r)),[e[0],100*r,100*o]},i.hsv.hcg=function(e){const t=e[1]/100,n=e[2]/100,r=t*n;let o=0;return r<1&&(o=(n-r)/(1-r)),[e[0],100*r,100*o]},i.hcg.rgb=function(e){const t=e[0]/360,n=e[1]/100,r=e[2]/100;if(0===n)return[255*r,255*r,255*r];const o=[0,0,0],i=t%1*6,a=i%1,s=1-a;let l=0;switch(Math.floor(i)){case 0:o[0]=1,o[1]=a,o[2]=0;break;case 1:o[0]=s,o[1]=1,o[2]=0;break;case 2:o[0]=0,o[1]=1,o[2]=a;break;case 3:o[0]=0,o[1]=s,o[2]=1;break;case 4:o[0]=a,o[1]=0,o[2]=1;break;default:o[0]=1,o[1]=0,o[2]=s}return l=(1-n)*r,[255*(n*o[0]+l),255*(n*o[1]+l),255*(n*o[2]+l)]},i.hcg.hsv=function(e){const t=e[1]/100,n=t+e[2]/100*(1-t);let r=0;return n>0&&(r=t/n),[e[0],100*r,100*n]},i.hcg.hsl=function(e){const t=e[1]/100,n=e[2]/100*(1-t)+.5*t;let r=0;return n>0&&n<.5?r=t/(2*n):n>=.5&&n<1&&(r=t/(2*(1-n))),[e[0],100*r,100*n]},i.hcg.hwb=function(e){const t=e[1]/100,n=t+e[2]/100*(1-t);return[e[0],100*(n-t),100*(1-n)]},i.hwb.hcg=function(e){const t=e[1]/100,n=1-e[2]/100,r=n-t;let o=0;return r<1&&(o=(n-r)/(1-r)),[e[0],100*r,100*o]},i.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]},i.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]},i.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]},i.gray.hsl=function(e){return[0,0,e[0]]},i.gray.hsv=i.gray.hsl,i.gray.hwb=function(e){return[0,100,e[0]]},i.gray.cmyk=function(e){return[0,0,0,e[0]]},i.gray.lab=function(e){return[e[0],0,0]},i.gray.hex=function(e){const t=255&Math.round(e[0]/100*255),n=((t<<16)+(t<<8)+t).toString(16).toUpperCase();return"000000".substring(n.length)+n},i.rgb.gray=function(e){return[(e[0]+e[1]+e[2])/3/255*100]}},4892:(e,t,n)=>{const r=n(280),o=n(5416),i={};Object.keys(r).forEach((e=>{i[e]={},Object.defineProperty(i[e],"channels",{value:r[e].channels}),Object.defineProperty(i[e],"labels",{value:r[e].labels});const t=o(e);Object.keys(t).forEach((n=>{const r=t[n];i[e][n]=function(e){const t=function(){for(var t=arguments.length,n=new Array(t),r=0;r1&&(n=o);const i=e(n);if("object"===typeof i)for(let e=i.length,a=0;a1&&(n=o),e(n))};return"conversion"in e&&(t.conversion=e.conversion),t}(r)}))})),e.exports=i},5416:(e,t,n)=>{const r=n(280);function o(e){const t=function(){const e={},t=Object.keys(r);for(let n=t.length,r=0;r{"use strict";function r(e){return r="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}function o(e){return function(e){if(Array.isArray(e))return i(e)}(e)||function(e){if("undefined"!==typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"===typeof e)return i(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return i(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);ns,camelCaseProperty:()=>h,cssifyDeclaration:()=>g,cssifyObject:()=>m,hyphenateProperty:()=>f,isPrefixedProperty:()=>v,isPrefixedValue:()=>A,isUnitlessProperty:()=>O,normalizeProperty:()=>B,resolveArrayValue:()=>L,unprefixProperty:()=>P,unprefixValue:()=>M});var l=/-([a-z])/g,c=/^Ms/g,u={};function d(e){return e[1].toUpperCase()}function h(e){if(u.hasOwnProperty(e))return u[e];var t=e.replace(l,d).replace(c,"ms");return u[e]=t,t}var p=n(2928);function f(e){return(0,p.default)(e)}function g(e,t){return f(e)+":"+t}function m(e){var t="";for(var n in e){var r=e[n];"string"!==typeof r&&"number"!==typeof r||(t&&(t+=";"),t+=g(n,r))}return t}var y=/^(Webkit|Moz|O|ms)/;function v(e){return y.test(e)}var b=/-webkit-|-moz-|-ms-/;function A(e){return"string"===typeof e&&b.test(e)}var x={borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,fontWeight:!0,lineHeight:!0,opacity:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},S=["animationIterationCount","boxFlex","boxFlexGroup","boxOrdinalGroup","columnCount","flex","flexGrow","flexPositive","flexShrink","flexNegative","flexOrder","gridColumn","gridColumnEnd","gridColumnStart","gridRow","gridRowEnd","gridRowStart","lineClamp","order"],w=["Webkit","ms","Moz","O"];function C(e,t){return e+t.charAt(0).toUpperCase()+t.slice(1)}for(var _=0,E=S.length;_{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return(0,i.default)(e)};var r,o=n(2928),i=(r=o)&&r.__esModule?r:{default:r}},228:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return"string"===typeof e&&n.test(e)};var n=/-webkit-|-moz-|-ms-/},507:(e,t,n)=>{"use strict";n.d(t,{KM:()=>i,SI:()=>a,cp:()=>A,eu:()=>w,gC:()=>o,q:()=>_,uI:()=>C,w7:()=>O});var r=n(7616);function o(){}var i=.7,a=1/i,s="\\s*([+-]?\\d+)\\s*",l="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)\\s*",c="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)%\\s*",u=/^#([0-9a-f]{3,8})$/,d=new RegExp("^rgb\\("+[s,s,s]+"\\)$"),h=new RegExp("^rgb\\("+[c,c,c]+"\\)$"),p=new RegExp("^rgba\\("+[s,s,s,l]+"\\)$"),f=new RegExp("^rgba\\("+[c,c,c,l]+"\\)$"),g=new RegExp("^hsl\\("+[l,c,c]+"\\)$"),m=new RegExp("^hsla\\("+[l,c,c,l]+"\\)$"),y={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function v(){return this.rgb().formatHex()}function b(){return this.rgb().formatRgb()}function A(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=u.exec(e))?(n=t[1].length,t=parseInt(t[1],16),6===n?x(t):3===n?new _(t>>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):8===n?S(t>>24&255,t>>16&255,t>>8&255,(255&t)/255):4===n?S(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|240&t,((15&t)<<4|15&t)/255):null):(t=d.exec(e))?new _(t[1],t[2],t[3],1):(t=h.exec(e))?new _(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=p.exec(e))?S(t[1],t[2],t[3],t[4]):(t=f.exec(e))?S(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=g.exec(e))?I(t[1],t[2]/100,t[3]/100,1):(t=m.exec(e))?I(t[1],t[2]/100,t[3]/100,t[4]):y.hasOwnProperty(e)?x(y[e]):"transparent"===e?new _(NaN,NaN,NaN,0):null}function x(e){return new _(e>>16&255,e>>8&255,255&e,1)}function S(e,t,n,r){return r<=0&&(e=t=n=NaN),new _(e,t,n,r)}function w(e){return e instanceof o||(e=A(e)),e?new _((e=e.rgb()).r,e.g,e.b,e.opacity):new _}function C(e,t,n,r){return 1===arguments.length?w(e):new _(e,t,n,null==r?1:r)}function _(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}function E(){return"#"+k(this.r)+k(this.g)+k(this.b)}function R(){var e=this.opacity;return(1===(e=isNaN(e)?1:Math.max(0,Math.min(1,e)))?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(1===e?")":", "+e+")")}function k(e){return((e=Math.max(0,Math.min(255,Math.round(e)||0)))<16?"0":"")+e.toString(16)}function I(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new j(e,t,n,r)}function T(e){if(e instanceof j)return new j(e.h,e.s,e.l,e.opacity);if(e instanceof o||(e=A(e)),!e)return new j;if(e instanceof j)return e;var t=(e=e.rgb()).r/255,n=e.g/255,r=e.b/255,i=Math.min(t,n,r),a=Math.max(t,n,r),s=NaN,l=a-i,c=(a+i)/2;return l?(s=t===a?(n-r)/l+6*(n0&&c<1?0:s,new j(s,l,c,e.opacity)}function O(e,t,n,r){return 1===arguments.length?T(e):new j(e,t,n,null==r?1:r)}function j(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function P(e,t,n){return 255*(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)}(0,r.c)(o,A,{copy:function(e){return Object.assign(new this.constructor,this,e)},displayable:function(){return this.rgb().displayable()},hex:v,formatHex:v,formatHsl:function(){return T(this).formatHsl()},formatRgb:b,toString:b}),(0,r.c)(_,C,(0,r.S)(o,{brighter:function(e){return e=null==e?a:Math.pow(a,e),new _(this.r*e,this.g*e,this.b*e,this.opacity)},darker:function(e){return e=null==e?i:Math.pow(i,e),new _(this.r*e,this.g*e,this.b*e,this.opacity)},rgb:function(){return this},displayable:function(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:E,formatHex:E,formatRgb:R,toString:R})),(0,r.c)(j,O,(0,r.S)(o,{brighter:function(e){return e=null==e?a:Math.pow(a,e),new j(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=null==e?i:Math.pow(i,e),new j(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=this.h%360+360*(this.h<0),t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,o=2*n-r;return new _(P(e>=240?e-240:e+120,o,r),P(e,o,r),P(e<120?e+240:e-120,o,r),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl:function(){var e=this.opacity;return(1===(e=isNaN(e)?1:Math.max(0,Math.min(1,e)))?"hsl(":"hsla(")+(this.h||0)+", "+100*(this.s||0)+"%, "+100*(this.l||0)+"%"+(1===e?")":", "+e+")")}}))},8816:(e,t,n)=>{"use strict";n.d(t,{c:()=>f});var r=n(7616),o=n(507),i=n(5560),a=-.14861,s=1.78277,l=-.29227,c=-.90649,u=1.97294,d=u*c,h=u*s,p=s*l-c*a;function f(e,t,n,r){return 1===arguments.length?function(e){if(e instanceof g)return new g(e.h,e.s,e.l,e.opacity);e instanceof o.q||(e=(0,o.eu)(e));var t=e.r/255,n=e.g/255,r=e.b/255,a=(p*r+d*t-h*n)/(p+d-h),s=r-a,f=(u*(n-a)-l*s)/c,m=Math.sqrt(f*f+s*s)/(u*a*(1-a)),y=m?Math.atan2(f,s)*i.U-120:NaN;return new g(y<0?y+360:y,m,a,e.opacity)}(e):new g(e,t,n,null==r?1:r)}function g(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}(0,r.c)(g,f,(0,r.S)(o.gC,{brighter:function(e){return e=null==e?o.SI:Math.pow(o.SI,e),new g(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=null==e?o.KM:Math.pow(o.KM,e),new g(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=isNaN(this.h)?0:(this.h+120)*i.E,t=+this.l,n=isNaN(this.s)?0:this.s*t*(1-t),r=Math.cos(e),d=Math.sin(e);return new o.q(255*(t+n*(a*r+s*d)),255*(t+n*(l*r+c*d)),255*(t+n*(u*r)),this.opacity)}}))},7616:(e,t,n)=>{"use strict";function r(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function o(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}n.d(t,{S:()=>o,c:()=>r})},5560:(e,t,n)=>{"use strict";n.d(t,{E:()=>r,U:()=>o});var r=Math.PI/180,o=180/Math.PI},3124:function(e,t,n){!function(e,t){"use strict";function n(e,t){var n=[],r=[];function o(e,t){if(1===e.length)n.push(e[0]),r.push(e[0]);else{for(var i=Array(e.length-1),a=0;a=3&&(t.x1=e[1][0],t.y1=e[1][1]),t.x=e[e.length-1][0],t.y=e[e.length-1][1],4===e.length?t.type="C":3===e.length?t.type="Q":t.type="L",t}function o(e,t){for(var r=[],o=e,i=1/(t=t||2),a=0;a0?a-=1:a0&&(a-=1))}return t[a]=(t[a]||0)+1,t}),[]).reduce((function(t,n,r){if(r===e.length-1){var o=l(n,a({},e[e.length-1]));return"M"===o[0].type&&o.forEach((function(e){e.type="L"})),t.concat(o)}return t.concat(h(e[r],e[r+1],n))}),[]);return s.unshift(e[0]),s}function f(e,n,r){var o=null==e?"":e.replace(/[Z]/gi,"").replace(/([MLCSTQAHV])\s*/gi,"$1"),i=null==n?"":n.replace(/[Z]/gi,"").replace(/([MLCSTQAHV])\s*/gi,"$1"),a=""===o?[]:o.split(/(?=[MLCSTQAHV])/gi),s=""===i?[]:i.split(/(?=[MLCSTQAHV])/gi);if(!a.length&&!s.length)return function(){return""};a.length?s.length||s.push(a[0]):a.push(s[0]);var l=a.map(c),h=s.map(c);0!==Math.abs(s.length-a.length)&&(h.length>l.length?l=p(l,h,r):h.length{"use strict";n.d(t,{Y:()=>a,c:()=>i});var r=n(9180),o=n(5224);function i(e,t){return((0,o.g)(t)?o.c:a)(e,t)}function a(e,t){var n,o=t?t.length:0,i=e?Math.min(o,e.length):0,a=new Array(i),s=new Array(o);for(n=0;n{"use strict";function r(e,t,n,r,o){var i=e*e,a=i*e;return((1-3*e+3*i-a)*t+(4-6*i+3*a)*n+(1+3*e+3*i-3*a)*r+a*o)/6}function o(e){var t=e.length-1;return function(n){var o=n<=0?n=0:n>=1?(n=1,t-1):Math.floor(n*t),i=e[o],a=e[o+1],s=o>0?e[o-1]:2*i-a,l=oo,c:()=>r})},4376:(e,t,n)=>{"use strict";n.d(t,{c:()=>o});var r=n(5056);function o(e){var t=e.length;return function(n){var o=Math.floor(((n%=1)<0?++n:n)*t),i=e[(o+t-1)%t],a=e[o%t],s=e[(o+1)%t],l=e[(o+2)%t];return(0,r.c)((n-o/t)*t,i,a,s,l)}}},5012:(e,t,n)=>{"use strict";n.d(t,{Eh:()=>i,cp:()=>s,oR:()=>a});var r=n(7808);function o(e,t){return function(n){return e+n*t}}function i(e,t){var n=t-e;return n?o(e,n>180||n<-180?n-360*Math.round(n/360):n):(0,r.c)(isNaN(e)?t:e)}function a(e){return 1===(e=+e)?s:function(t,n){return n-t?function(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}(t,n,e):(0,r.c)(isNaN(t)?n:t)}}function s(e,t){var n=t-e;return n?o(e,n):(0,r.c)(isNaN(e)?t:e)}},7808:(e,t,n)=>{"use strict";function r(e){return function(){return e}}n.d(t,{c:()=>r})},3548:(e,t,n)=>{"use strict";n.d(t,{c:()=>a,o:()=>s});var r=n(8816),o=n(5012);function i(e){return function t(n){function i(t,i){var a=e((t=(0,r.c)(t)).h,(i=(0,r.c)(i)).h),s=(0,o.cp)(t.s,i.s),l=(0,o.cp)(t.l,i.l),c=(0,o.cp)(t.opacity,i.opacity);return function(e){return t.h=a(e),t.s=s(e),t.l=l(Math.pow(e,n)),t.opacity=c(e),t+""}}return n=+n,i.gamma=t,i}(1)}const a=i(o.Eh);var s=i(o.cp)},1456:(e,t,n)=>{"use strict";function r(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}}n.d(t,{c:()=>r})},6236:(e,t,n)=>{"use strict";n.r(t),n.d(t,{interpolate:()=>r.c,interpolateArray:()=>o.c,interpolateBasis:()=>i.M,interpolateBasisClosed:()=>a.c,interpolateCubehelix:()=>se.c,interpolateCubehelixLong:()=>se.o,interpolateDate:()=>s.c,interpolateDiscrete:()=>l,interpolateHcl:()=>ie,interpolateHclLong:()=>ae,interpolateHsl:()=>L,interpolateHslLong:()=>D,interpolateHue:()=>u,interpolateLab:()=>re,interpolateNumber:()=>g.c,interpolateNumberArray:()=>m.c,interpolateObject:()=>y.c,interpolateRgb:()=>j.cp,interpolateRgbBasis:()=>j.Yf,interpolateRgbBasisClosed:()=>j.Uf,interpolateRound:()=>v.c,interpolateString:()=>b.c,interpolateTransformCss:()=>C,interpolateTransformSvg:()=>_,interpolateZoom:()=>O,piecewise:()=>le,quantize:()=>ce});var r=n(9180),o=n(3680),i=n(5056),a=n(4376),s=n(1456);function l(e){var t=e.length;return function(n){return e[Math.max(0,Math.min(t-1,Math.floor(n*t)))]}}var c=n(5012);function u(e,t){var n=(0,c.Eh)(+e,+t);return function(e){var t=n(e);return t-360*Math.floor(t/360)}}var d,h,p,f,g=n(8408),m=n(5224),y=n(9916),v=n(6928),b=n(636),A=180/Math.PI,x={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function S(e,t,n,r,o,i){var a,s,l;return(a=Math.sqrt(e*e+t*t))&&(e/=a,t/=a),(l=e*n+t*r)&&(n-=e*l,r-=t*l),(s=Math.sqrt(n*n+r*r))&&(n/=s,r/=s,l/=s),e*r180?t+=360:t-e>180&&(e+=360),i.push({i:n.push(o(n)+"rotate(",null,r)-2,x:(0,g.c)(e,t)})):t&&n.push(o(n)+"rotate("+t+r)}(i.rotate,a.rotate,s,l),function(e,t,n,i){e!==t?i.push({i:n.push(o(n)+"skewX(",null,r)-2,x:(0,g.c)(e,t)}):t&&n.push(o(n)+"skewX("+t+r)}(i.skewX,a.skewX,s,l),function(e,t,n,r,i,a){if(e!==n||t!==r){var s=i.push(o(i)+"scale(",null,",",null,")");a.push({i:s-4,x:(0,g.c)(e,n)},{i:s-2,x:(0,g.c)(t,r)})}else 1===n&&1===r||i.push(o(i)+"scale("+n+","+r+")")}(i.scaleX,i.scaleY,a.scaleX,a.scaleY,s,l),i=a=null,function(e){for(var t,n=-1,r=l.length;++nW?Math.pow(e,1/3):e/V+G}function X(e){return e>z?e*e*e:V*(e-G)}function J(e){return 255*(e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)}function Z(e){return(e/=255)<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function $(e){if(e instanceof te)return new te(e.h,e.c,e.l,e.opacity);if(e instanceof K||(e=Q(e)),0===e.a&&0===e.b)return new te(NaN,0{"use strict";function r(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}n.d(t,{c:()=>r})},5224:(e,t,n)=>{"use strict";function r(e,t){t||(t=[]);var n,r=e?Math.min(t.length,e.length):0,o=t.slice();return function(i){for(n=0;nr,g:()=>o})},9916:(e,t,n)=>{"use strict";n.d(t,{c:()=>o});var r=n(9180);function o(e,t){var n,o={},i={};for(n in null!==e&&"object"===typeof e||(e={}),null!==t&&"object"===typeof t||(t={}),t)n in e?o[n]=(0,r.c)(e[n],t[n]):i[n]=t[n];return function(e){for(n in o)i[n]=o[n](e);return i}}},232:(e,t,n)=>{"use strict";n.d(t,{Uf:()=>u,Yf:()=>c,cp:()=>s});var r=n(507),o=n(5056),i=n(4376),a=n(5012);const s=function e(t){var n=(0,a.oR)(t);function o(e,t){var o=n((e=(0,r.uI)(e)).r,(t=(0,r.uI)(t)).r),i=n(e.g,t.g),s=n(e.b,t.b),l=(0,a.cp)(e.opacity,t.opacity);return function(t){return e.r=o(t),e.g=i(t),e.b=s(t),e.opacity=l(t),e+""}}return o.gamma=e,o}(1);function l(e){return function(t){var n,o,i=t.length,a=new Array(i),s=new Array(i),l=new Array(i);for(n=0;n{"use strict";function r(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}n.d(t,{c:()=>r})},636:(e,t,n)=>{"use strict";n.d(t,{c:()=>a});var r=n(8408),o=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,i=new RegExp(o.source,"g");function a(e,t){var n,a,s,l=o.lastIndex=i.lastIndex=0,c=-1,u=[],d=[];for(e+="",t+="";(n=o.exec(e))&&(a=i.exec(t));)(s=a.index)>l&&(s=t.slice(l,s),u[c]?u[c]+=s:u[++c]=s),(n=n[0])===(a=a[0])?u[c]?u[c]+=a:u[++c]=a:(u[++c]=null,d.push({i:c,x:(0,r.c)(n,a)})),l=i.lastIndex;return l{"use strict";n.d(t,{c:()=>h});var r=n(507),o=n(232),i=n(3680),a=n(1456),s=n(8408),l=n(9916),c=n(636),u=n(7808),d=n(5224);function h(e,t){var n,h=typeof t;return null==t||"boolean"===h?(0,u.c)(t):("number"===h?s.c:"string"===h?(n=(0,r.cp)(t))?(t=n,o.cp):c.c:t instanceof r.cp?o.cp:t instanceof Date?a.c:(0,d.g)(t)?d.c:Array.isArray(t)?i.Y:"function"!==typeof t.valueOf&&"function"!==typeof t.toString||isNaN(t)?l.c:s.c)(e,t)}},5600:e=>{"use strict";var t="%[a-f0-9]{2}",n=new RegExp("("+t+")|([^%]+?)","gi"),r=new RegExp("("+t+")+","gi");function o(e,t){try{return[decodeURIComponent(e.join(""))]}catch(i){}if(1===e.length)return e;t=t||1;var n=e.slice(0,t),r=e.slice(t);return Array.prototype.concat.call([],o(n),o(r))}function i(e){try{return decodeURIComponent(e)}catch(i){for(var t=e.match(n)||[],r=1;r{"use strict";var r=n(1260),o=Object.prototype.hasOwnProperty,i=Object.prototype.propertyIsEnumerable;function a(e,t,n){var i=t[n];if(void 0!==i&&null!==i){if(o.call(e,n)&&(void 0===e[n]||null===e[n]))throw new TypeError("Cannot convert undefined or null to object ("+n+")");o.call(e,n)&&r(i)?e[n]=s(Object(e[n]),t[n]):e[n]=i}}function s(e,t){if(e===t)return e;for(var n in t=Object(t))o.call(t,n)&&a(e,t,n);if(Object.getOwnPropertySymbols)for(var r=Object.getOwnPropertySymbols(t),s=0;s{"use strict";e.exports=e=>{if("string"!==typeof e)throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}},272:(e,t,n)=>{var r;!function(){"use strict";var o=!("undefined"===typeof window||!window.document||!window.document.createElement),i={canUseDOM:o,canUseWorkers:"undefined"!==typeof Worker,canUseEventListeners:o&&!(!window.addEventListener&&!window.attachEvent),canUseViewport:o&&!!window.screen};void 0===(r=function(){return i}.call(t,n,t,e))||(e.exports=r)}()},4084:e=>{"use strict";e.exports=function e(t,n){if(t===n)return!0;if(t&&n&&"object"==typeof t&&"object"==typeof n){if(t.constructor!==n.constructor)return!1;var r,o,i;if(Array.isArray(t)){if((r=t.length)!=n.length)return!1;for(o=r;0!==o--;)if(!e(t[o],n[o]))return!1;return!0}if(t.constructor===RegExp)return t.source===n.source&&t.flags===n.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===n.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===n.toString();if((r=(i=Object.keys(t)).length)!==Object.keys(n).length)return!1;for(o=r;0!==o--;)if(!Object.prototype.hasOwnProperty.call(n,i[o]))return!1;for(o=r;0!==o--;){var a=i[o];if(!e(t[a],n[a]))return!1}return!0}return t!==t&&n!==n}},9632:e=>{"use strict";function t(e){return function(){return e}}var n=function(){};n.thatReturns=t,n.thatReturnsFalse=t(!1),n.thatReturnsTrue=t(!0),n.thatReturnsNull=t(null),n.thatReturnsThis=function(){return this},n.thatReturnsArgument=function(e){return e},e.exports=n},3748:e=>{"use strict";var t=function(e){};e.exports=function(e,n){for(var r=arguments.length,o=new Array(r>2?r-2:0),i=2;i{"use strict";var r=n(9632);e.exports=r},8981:e=>{"use strict";e.exports=function(e,t){for(var n={},r=Object.keys(e),o=Array.isArray(t),i=0;i{"use strict";var r=n(3904),o={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},i={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},a={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},s={};function l(e){return r.isMemo(e)?a:s[e.$$typeof]||o}s[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},s[r.Memo]=a;var c=Object.defineProperty,u=Object.getOwnPropertyNames,d=Object.getOwnPropertySymbols,h=Object.getOwnPropertyDescriptor,p=Object.getPrototypeOf,f=Object.prototype;e.exports=function e(t,n,r){if("string"!==typeof n){if(f){var o=p(n);o&&o!==f&&e(t,o,r)}var a=u(n);d&&(a=a.concat(d(n)));for(var s=l(t),g=l(n),m=0;m{"use strict";var n="function"===typeof Symbol&&Symbol.for,r=n?Symbol.for("react.element"):60103,o=n?Symbol.for("react.portal"):60106,i=n?Symbol.for("react.fragment"):60107,a=n?Symbol.for("react.strict_mode"):60108,s=n?Symbol.for("react.profiler"):60114,l=n?Symbol.for("react.provider"):60109,c=n?Symbol.for("react.context"):60110,u=n?Symbol.for("react.async_mode"):60111,d=n?Symbol.for("react.concurrent_mode"):60111,h=n?Symbol.for("react.forward_ref"):60112,p=n?Symbol.for("react.suspense"):60113,f=n?Symbol.for("react.suspense_list"):60120,g=n?Symbol.for("react.memo"):60115,m=n?Symbol.for("react.lazy"):60116,y=n?Symbol.for("react.block"):60121,v=n?Symbol.for("react.fundamental"):60117,b=n?Symbol.for("react.responder"):60118,A=n?Symbol.for("react.scope"):60119;function x(e){if("object"===typeof e&&null!==e){var t=e.$$typeof;switch(t){case r:switch(e=e.type){case u:case d:case i:case s:case a:case p:return e;default:switch(e=e&&e.$$typeof){case c:case h:case m:case g:case l:return e;default:return t}}case o:return t}}}function S(e){return x(e)===d}t.AsyncMode=u,t.ConcurrentMode=d,t.ContextConsumer=c,t.ContextProvider=l,t.Element=r,t.ForwardRef=h,t.Fragment=i,t.Lazy=m,t.Memo=g,t.Portal=o,t.Profiler=s,t.StrictMode=a,t.Suspense=p,t.isAsyncMode=function(e){return S(e)||x(e)===u},t.isConcurrentMode=S,t.isContextConsumer=function(e){return x(e)===c},t.isContextProvider=function(e){return x(e)===l},t.isElement=function(e){return"object"===typeof e&&null!==e&&e.$$typeof===r},t.isForwardRef=function(e){return x(e)===h},t.isFragment=function(e){return x(e)===i},t.isLazy=function(e){return x(e)===m},t.isMemo=function(e){return x(e)===g},t.isPortal=function(e){return x(e)===o},t.isProfiler=function(e){return x(e)===s},t.isStrictMode=function(e){return x(e)===a},t.isSuspense=function(e){return x(e)===p},t.isValidElementType=function(e){return"string"===typeof e||"function"===typeof e||e===i||e===d||e===s||e===a||e===p||e===f||"object"===typeof e&&null!==e&&(e.$$typeof===m||e.$$typeof===g||e.$$typeof===l||e.$$typeof===c||e.$$typeof===h||e.$$typeof===v||e.$$typeof===b||e.$$typeof===A||e.$$typeof===y)},t.typeOf=x},3904:(e,t,n)=>{"use strict";e.exports=n(4744)},2928:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>s});var r=/[A-Z]/g,o=/^ms-/,i={};function a(e){return"-"+e.toLowerCase()}const s=function(e){if(i.hasOwnProperty(e))return i[e];var t=e.replace(r,a);return i[e]=o.test(t)?"-"+t:t}},8699:(e,t,n)=>{"use strict";t.c=function(e){var t=e.prefixMap,n=e.plugins;return function e(s){for(var l in s){var c=s[l];if((0,a.default)(c))s[l]=e(c);else if(Array.isArray(c)){for(var u=[],d=0,h=c.length;d0&&(s[l]=u)}else{var f=(0,o.default)(n,l,c,s,t);f&&(s[l]=f),s=(0,r.default)(t,l,s)}}return s}};var r=s(n(4540)),o=s(n(1348)),i=s(n(9588)),a=s(n(976));function s(e){return e&&e.__esModule?e:{default:e}}},4208:(e,t)=>{"use strict";t.c=function(){return null}},3412:(e,t,n)=>{"use strict";t.c=function(e,t){if("string"===typeof t&&!(0,r.isPrefixedValue)(t)&&-1!==t.indexOf("cross-fade("))return i.map((function(e){return t.replace(o,e+"cross-fade(")}))};var r=n(736),o=/cross-fade\(/g,i=["-webkit-",""]},4464:(e,t)=>{"use strict";t.c=function(e,t){if("cursor"===e&&r.hasOwnProperty(t))return n.map((function(e){return e+t}))};var n=["-webkit-","-moz-",""],r={"zoom-in":!0,"zoom-out":!0,grab:!0,grabbing:!0}},5504:(e,t,n)=>{"use strict";t.c=function(e,t){if("string"===typeof t&&!(0,r.isPrefixedValue)(t)&&-1!==t.indexOf("filter("))return i.map((function(e){return t.replace(o,e+"filter(")}))};var r=n(736),o=/filter\(/g,i=["-webkit-",""]},3080:(e,t,n)=>{"use strict";t.c=function(e,t){if("string"===typeof t&&!(0,i.default)(t)&&t.indexOf("image-set(")>-1)return a.map((function(e){return t.replace(/image-set\(/g,e+"image-set(")}))};var r,o=n(228),i=(r=o)&&r.__esModule?r:{default:r};var a=["-webkit-",""]},4024:(e,t)=>{"use strict";t.c=function(e,t,r){if(Object.prototype.hasOwnProperty.call(n,e))for(var o=n[e],i=0,a=o.length;i{"use strict";t.c=function(e,t){if("position"===e&&"sticky"===t)return["-webkit-sticky","sticky"]}},3015:(e,t)=>{"use strict";t.c=function(e,t){if(r.hasOwnProperty(e)&&o.hasOwnProperty(t))return n.map((function(e){return e+t}))};var n=["-webkit-","-moz-",""],r={maxHeight:!0,maxWidth:!0,width:!0,height:!0,columnWidth:!0,minWidth:!0,minHeight:!0},o={"min-content":!0,"max-content":!0,"fill-available":!0,"fit-content":!0,"contain-floats":!0}},3384:(e,t,n)=>{"use strict";t.c=function(e,t,n,a){if("string"===typeof t&&s.hasOwnProperty(e)){var c=function(e,t){if((0,o.default)(e))return e;for(var n=e.split(/,(?![^()]*(?:\([^()]*\))?\))/g),i=0,a=n.length;i-1&&"order"!==d)for(var h=t[u],p=0,f=h.length;p-1)return u;var d=c.split(/,(?![^()]*(?:\([^()]*\))?\))/g).filter((function(e){return!/-webkit-|-ms-/.test(e)})).join(",");return e.indexOf("Moz")>-1?d:(n["Webkit"+(0,i.default)(e)]=u,n["Moz"+(0,i.default)(e)]=d,c)}};var r=a(n(6232)),o=a(n(228)),i=a(n(4080));function a(e){return e&&e.__esModule?e:{default:e}}var s={transition:!0,transitionProperty:!0,WebkitTransition:!0,WebkitTransitionProperty:!0,MozTransition:!0,MozTransitionProperty:!0},l={Webkit:"-webkit-",Moz:"-moz-",ms:"-ms-"}},9588:(e,t)=>{"use strict";function n(e,t){-1===e.indexOf(t)&&e.push(t)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){if(Array.isArray(t))for(var r=0,o=t.length;r{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return e.charAt(0).toUpperCase()+e.slice(1)}},976:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return e instanceof Object&&!Array.isArray(e)}},4540:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,n){var r=e[t];if(r&&n.hasOwnProperty(t))for(var o=(0,i.default)(t),a=0;a{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,n,r,o){for(var i=0,a=e.length;i{"use strict";e.exports=function(e){var t=typeof e;return null!==e&&("object"===t||"function"===t)}},8276:(e,t,n)=>{"use strict";function r(e){return Array.prototype.slice.call(arguments,1).forEach((function(t){t&&Object.keys(t).forEach((function(n){e[n]=t[n]}))})),e}function o(e){return Object.prototype.toString.call(e)}function i(e){return"[object Function]"===o(e)}function a(e){return e.replace(/[.?*+^$[\]\\(){}|-]/g,"\\$&")}var s={fuzzyLink:!0,fuzzyEmail:!0,fuzzyIP:!1};var l={"http:":{validate:function(e,t,n){var r=e.slice(t);return n.re.http||(n.re.http=new RegExp("^\\/\\/"+n.re.src_auth+n.re.src_host_port_strict+n.re.src_path,"i")),n.re.http.test(r)?r.match(n.re.http)[0].length:0}},"https:":"http:","ftp:":"http:","//":{validate:function(e,t,n){var r=e.slice(t);return n.re.no_http||(n.re.no_http=new RegExp("^"+n.re.src_auth+"(?:localhost|(?:(?:"+n.re.src_domain+")\\.)+"+n.re.src_domain_root+")"+n.re.src_port+n.re.src_host_terminator+n.re.src_path,"i")),n.re.no_http.test(r)?t>=3&&":"===e[t-3]||t>=3&&"/"===e[t-3]?0:r.match(n.re.no_http)[0].length:0}},"mailto:":{validate:function(e,t,n){var r=e.slice(t);return n.re.mailto||(n.re.mailto=new RegExp("^"+n.re.src_email_name+"@"+n.re.src_host_strict,"i")),n.re.mailto.test(r)?r.match(n.re.mailto)[0].length:0}}},c="a[cdefgilmnoqrstuwxz]|b[abdefghijmnorstvwyz]|c[acdfghiklmnoruvwxyz]|d[ejkmoz]|e[cegrstu]|f[ijkmor]|g[abdefghilmnpqrstuwy]|h[kmnrtu]|i[delmnoqrst]|j[emop]|k[eghimnprwyz]|l[abcikrstuvy]|m[acdeghklmnopqrstuvwxyz]|n[acefgilopruz]|om|p[aefghklmnrstwy]|qa|r[eosuw]|s[abcdeghijklmnortuvxyz]|t[cdfghjklmnortvwz]|u[agksyz]|v[aceginu]|w[fs]|y[et]|z[amw]",u="biz|com|edu|gov|net|org|pro|web|xxx|aero|asia|coop|info|museum|name|shop|\u0440\u0444".split("|");function d(e){var t=e.re=n(312)(e.__opts__),r=e.__tlds__.slice();function s(e){return e.replace("%TLDS%",t.src_tlds)}e.onCompile(),e.__tlds_replaced__||r.push(c),r.push(t.src_xn),t.src_tlds=r.join("|"),t.email_fuzzy=RegExp(s(t.tpl_email_fuzzy),"i"),t.link_fuzzy=RegExp(s(t.tpl_link_fuzzy),"i"),t.link_no_ip_fuzzy=RegExp(s(t.tpl_link_no_ip_fuzzy),"i"),t.host_fuzzy_test=RegExp(s(t.tpl_host_fuzzy_test),"i");var l=[];function u(e,t){throw new Error('(LinkifyIt) Invalid schema "'+e+'": '+t)}e.__compiled__={},Object.keys(e.__schemas__).forEach((function(t){var n=e.__schemas__[t];if(null!==n){var r={validate:null,link:null};if(e.__compiled__[t]=r,"[object Object]"===o(n))return!function(e){return"[object RegExp]"===o(e)}(n.validate)?i(n.validate)?r.validate=n.validate:u(t,n):r.validate=function(e){return function(t,n){var r=t.slice(n);return e.test(r)?r.match(e)[0].length:0}}(n.validate),void(i(n.normalize)?r.normalize=n.normalize:n.normalize?u(t,n):r.normalize=function(e,t){t.normalize(e)});!function(e){return"[object String]"===o(e)}(n)?u(t,n):l.push(t)}})),l.forEach((function(t){e.__compiled__[e.__schemas__[t]]&&(e.__compiled__[t].validate=e.__compiled__[e.__schemas__[t]].validate,e.__compiled__[t].normalize=e.__compiled__[e.__schemas__[t]].normalize)})),e.__compiled__[""]={validate:null,normalize:function(e,t){t.normalize(e)}};var d=Object.keys(e.__compiled__).filter((function(t){return t.length>0&&e.__compiled__[t]})).map(a).join("|");e.re.schema_test=RegExp("(^|(?!_)(?:[><\uff5c]|"+t.src_ZPCc+"))("+d+")","i"),e.re.schema_search=RegExp("(^|(?!_)(?:[><\uff5c]|"+t.src_ZPCc+"))("+d+")","ig"),e.re.schema_at_start=RegExp("^"+e.re.schema_search.source,"i"),e.re.pretest=RegExp("("+e.re.schema_test.source+")|("+e.re.host_fuzzy_test.source+")|@","i"),function(e){e.__index__=-1,e.__text_cache__=""}(e)}function h(e,t){var n=e.__index__,r=e.__last_index__,o=e.__text_cache__.slice(n,r);this.schema=e.__schema__.toLowerCase(),this.index=n+t,this.lastIndex=r+t,this.raw=o,this.text=o,this.url=o}function p(e,t){var n=new h(e,t);return e.__compiled__[n.schema].normalize(n,e),n}function f(e,t){if(!(this instanceof f))return new f(e,t);var n;t||(n=e,Object.keys(n||{}).reduce((function(e,t){return e||s.hasOwnProperty(t)}),!1)&&(t=e,e={})),this.__opts__=r({},s,t),this.__index__=-1,this.__last_index__=-1,this.__schema__="",this.__text_cache__="",this.__schemas__=r({},l,e),this.__compiled__={},this.__tlds__=u,this.__tlds_replaced__=!1,this.re={},d(this)}f.prototype.add=function(e,t){return this.__schemas__[e]=t,d(this),this},f.prototype.set=function(e){return this.__opts__=r(this.__opts__,e),this},f.prototype.test=function(e){if(this.__text_cache__=e,this.__index__=-1,!e.length)return!1;var t,n,r,o,i,a,s,l;if(this.re.schema_test.test(e))for((s=this.re.schema_search).lastIndex=0;null!==(t=s.exec(e));)if(o=this.testSchemaAt(e,t[2],s.lastIndex)){this.__schema__=t[2],this.__index__=t.index+t[1].length,this.__last_index__=t.index+t[0].length+o;break}return this.__opts__.fuzzyLink&&this.__compiled__["http:"]&&(l=e.search(this.re.host_fuzzy_test))>=0&&(this.__index__<0||l=0&&null!==(r=e.match(this.re.email_fuzzy))&&(i=r.index+r[1].length,a=r.index+r[0].length,(this.__index__<0||ithis.__last_index__)&&(this.__schema__="mailto:",this.__index__=i,this.__last_index__=a)),this.__index__>=0},f.prototype.pretest=function(e){return this.re.pretest.test(e)},f.prototype.testSchemaAt=function(e,t,n){return this.__compiled__[t.toLowerCase()]?this.__compiled__[t.toLowerCase()].validate(e,n,this):0},f.prototype.match=function(e){var t=0,n=[];this.__index__>=0&&this.__text_cache__===e&&(n.push(p(this,t)),t=this.__last_index__);for(var r=t?e.slice(t):e;this.test(r);)n.push(p(this,t)),r=r.slice(this.__last_index__),t+=this.__last_index__;return n.length?n:null},f.prototype.matchAtStart=function(e){if(this.__text_cache__=e,this.__index__=-1,!e.length)return null;var t=this.re.schema_at_start.exec(e);if(!t)return null;var n=this.testSchemaAt(e,t[2],t[0].length);return n?(this.__schema__=t[2],this.__index__=t.index+t[1].length,this.__last_index__=t.index+t[0].length+n,p(this,0)):null},f.prototype.tlds=function(e,t){return e=Array.isArray(e)?e:[e],t?(this.__tlds__=this.__tlds__.concat(e).sort().filter((function(e,t,n){return e!==n[t-1]})).reverse(),d(this),this):(this.__tlds__=e.slice(),this.__tlds_replaced__=!0,d(this),this)},f.prototype.normalize=function(e){e.schema||(e.url="http://"+e.url),"mailto:"!==e.schema||/^mailto:/i.test(e.url)||(e.url="mailto:"+e.url)},f.prototype.onCompile=function(){},e.exports=f},312:(e,t,n)=>{"use strict";e.exports=function(e){var t={};e=e||{},t.src_Any=n(8892).source,t.src_Cc=n(2014).source,t.src_Z=n(8200).source,t.src_P=n(1760).source,t.src_ZPCc=[t.src_Z,t.src_P,t.src_Cc].join("|"),t.src_ZCc=[t.src_Z,t.src_Cc].join("|");var r="[><\uff5c]";return t.src_pseudo_letter="(?:(?![><\uff5c]|"+t.src_ZPCc+")"+t.src_Any+")",t.src_ip4="(?:(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)",t.src_auth="(?:(?:(?!"+t.src_ZCc+"|[@/\\[\\]()]).)+@)?",t.src_port="(?::(?:6(?:[0-4]\\d{3}|5(?:[0-4]\\d{2}|5(?:[0-2]\\d|3[0-5])))|[1-5]?\\d{1,4}))?",t.src_host_terminator="(?=$|[><\uff5c]|"+t.src_ZPCc+")(?!"+(e["---"]?"-(?!--)|":"-|")+"_|:\\d|\\.-|\\.(?!$|"+t.src_ZPCc+"))",t.src_path="(?:[/?#](?:(?!"+t.src_ZCc+"|"+r+"|[()[\\]{}.,\"'?!\\-;]).|\\[(?:(?!"+t.src_ZCc+"|\\]).)*\\]|\\((?:(?!"+t.src_ZCc+"|[)]).)*\\)|\\{(?:(?!"+t.src_ZCc+'|[}]).)*\\}|\\"(?:(?!'+t.src_ZCc+'|["]).)+\\"|\\\'(?:(?!'+t.src_ZCc+"|[']).)+\\'|\\'(?="+t.src_pseudo_letter+"|[-])|\\.{2,}[a-zA-Z0-9%/&]|\\.(?!"+t.src_ZCc+"|[.]|$)|"+(e["---"]?"\\-(?!--(?:[^-]|$))(?:-*)|":"\\-+|")+",(?!"+t.src_ZCc+"|$)|;(?!"+t.src_ZCc+"|$)|\\!+(?!"+t.src_ZCc+"|[!]|$)|\\?(?!"+t.src_ZCc+"|[?]|$))+|\\/)?",t.src_email_name='[\\-;:&=\\+\\$,\\.a-zA-Z0-9_][\\-;:&=\\+\\$,\\"\\.a-zA-Z0-9_]*',t.src_xn="xn--[a-z0-9\\-]{1,59}",t.src_domain_root="(?:"+t.src_xn+"|"+t.src_pseudo_letter+"{1,63})",t.src_domain="(?:"+t.src_xn+"|(?:"+t.src_pseudo_letter+")|(?:"+t.src_pseudo_letter+"(?:-|"+t.src_pseudo_letter+"){0,61}"+t.src_pseudo_letter+"))",t.src_host="(?:(?:(?:(?:"+t.src_domain+")\\.)*"+t.src_domain+"))",t.tpl_host_fuzzy="(?:"+t.src_ip4+"|(?:(?:(?:"+t.src_domain+")\\.)+(?:%TLDS%)))",t.tpl_host_no_ip_fuzzy="(?:(?:(?:"+t.src_domain+")\\.)+(?:%TLDS%))",t.src_host_strict=t.src_host+t.src_host_terminator,t.tpl_host_fuzzy_strict=t.tpl_host_fuzzy+t.src_host_terminator,t.src_host_port_strict=t.src_host+t.src_port+t.src_host_terminator,t.tpl_host_port_fuzzy_strict=t.tpl_host_fuzzy+t.src_port+t.src_host_terminator,t.tpl_host_port_no_ip_fuzzy_strict=t.tpl_host_no_ip_fuzzy+t.src_port+t.src_host_terminator,t.tpl_host_fuzzy_test="localhost|www\\.|\\.\\d{1,3}\\.|(?:\\.(?:%TLDS%)(?:"+t.src_ZPCc+"|>|$))",t.tpl_email_fuzzy='(^|[><\uff5c]|"|\\(|'+t.src_ZCc+")("+t.src_email_name+"@"+t.tpl_host_fuzzy_strict+")",t.tpl_link_fuzzy="(^|(?![.:/\\-_@])(?:[$+<=>^`|\uff5c]|"+t.src_ZPCc+"))((?![$+<=>^`|\uff5c])"+t.tpl_host_port_fuzzy_strict+t.src_path+")",t.tpl_link_no_ip_fuzzy="(^|(?![.:/\\-_@])(?:[$+<=>^`|\uff5c]|"+t.src_ZPCc+"))((?![$+<=>^`|\uff5c])"+t.tpl_host_port_no_ip_fuzzy_strict+t.src_path+")",t}},8968:e=>{"use strict";var t={};function n(e,r){var o;return"string"!==typeof r&&(r=n.defaultChars),o=function(e){var n,r,o=t[e];if(o)return o;for(o=t[e]=[],n=0;n<128;n++)r=String.fromCharCode(n),o.push(r);for(n=0;n=55296&&l<=57343?"\ufffd\ufffd\ufffd":String.fromCharCode(l),t+=6):240===(248&r)&&t+91114111?c+="\ufffd\ufffd\ufffd\ufffd":(l-=65536,c+=String.fromCharCode(55296+(l>>10),56320+(1023&l))),t+=9):c+="\ufffd";return c}))}n.defaultChars=";/?:@&=+$,#",n.componentChars="",e.exports=n},5108:e=>{"use strict";var t={};function n(e,r,o){var i,a,s,l,c,u="";for("string"!==typeof r&&(o=r,r=n.defaultChars),"undefined"===typeof o&&(o=!0),c=function(e){var n,r,o=t[e];if(o)return o;for(o=t[e]=[],n=0;n<128;n++)r=String.fromCharCode(n),/^[0-9a-z]$/i.test(r)?o.push(r):o.push("%"+("0"+n.toString(16).toUpperCase()).slice(-2));for(n=0;n=55296&&s<=57343){if(s>=55296&&s<=56319&&i+1=56320&&l<=57343){u+=encodeURIComponent(e[i]+e[i+1]),i++;continue}u+="%EF%BF%BD"}else u+=encodeURIComponent(e[i]);return u}n.defaultChars=";/?:@&=+$,-_.!~*'()#",n.componentChars="-_.!~*'()",e.exports=n},3928:e=>{"use strict";e.exports=function(e){var t="";return t+=e.protocol||"",t+=e.slashes?"//":"",t+=e.auth?e.auth+"@":"",e.hostname&&-1!==e.hostname.indexOf(":")?t+="["+e.hostname+"]":t+=e.hostname||"",t+=e.port?":"+e.port:"",t+=e.pathname||"",t+=e.search||"",t+=e.hash||""}},2403:(e,t,n)=>{"use strict";e.exports.encode=n(5108),e.exports.decode=n(8968),e.exports.format=n(3928),e.exports.parse=n(3920)},3920:e=>{"use strict";function t(){this.protocol=null,this.slashes=null,this.auth=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.pathname=null}var n=/^([a-z0-9.+-]+:)/i,r=/:[0-9]*$/,o=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,i=["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r","\n","\t"]),a=["'"].concat(i),s=["%","/","?",";","#"].concat(a),l=["/","?","#"],c=/^[+a-z0-9A-Z_-]{0,63}$/,u=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,d={javascript:!0,"javascript:":!0},h={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0};t.prototype.parse=function(e,t){var r,i,a,p,f,g=e;if(g=g.trim(),!t&&1===e.split("#").length){var m=o.exec(g);if(m)return this.pathname=m[1],m[2]&&(this.search=m[2]),this}var y=n.exec(g);if(y&&(a=(y=y[0]).toLowerCase(),this.protocol=y,g=g.substr(y.length)),(t||y||g.match(/^\/\/[^@\/]+@[^@\/]+/))&&(!(f="//"===g.substr(0,2))||y&&d[y]||(g=g.substr(2),this.slashes=!0)),!d[y]&&(f||y&&!h[y])){var v,b,A=-1;for(r=0;r127?_+="x":_+=C[E];if(!_.match(c)){var k=w.slice(0,r),I=w.slice(r+1),T=C.match(u);T&&(k.push(T[1]),I.unshift(T[2])),I.length&&(g=I.join(".")+g),this.hostname=k.join(".");break}}}}this.hostname.length>255&&(this.hostname=""),S&&(this.hostname=this.hostname.substr(1,this.hostname.length-2))}var O=g.indexOf("#");-1!==O&&(this.hash=g.substr(O),g=g.slice(0,O));var j=g.indexOf("?");return-1!==j&&(this.search=g.substr(j),g=g.slice(0,j)),g&&(this.pathname=g),h[a]&&this.hostname&&!this.pathname&&(this.pathname=""),this},t.prototype.parseHost=function(e){var t=r.exec(e);t&&(":"!==(t=t[0])&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)},e.exports=function(e,n){if(e&&e instanceof t)return e;var r=new t;return r.parse(e,n),r}},5232:(e,t,n)=>{"use strict";n.d(t,{c:()=>i});var r=Number.isNaN||function(e){return"number"===typeof e&&e!==e};function o(e,t){if(e.length!==t.length)return!1;for(var n=0;n{"use strict";function t(e,t){if(null!=e)return e;var n=new Error(void 0!==t?t:"Got unexpected "+e);throw n.framesToPop=1,n}e.exports=t,e.exports.default=t,Object.defineProperty(e.exports,"__esModule",{value:!0})},1532:(e,t,n)=>{"use strict";var r=n(2552);function o(){}function i(){}i.resetWarningCache=o,e.exports=function(){function e(e,t,n,o,i,a){if(a!==r){var s=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw s.name="Invariant Violation",s}}function t(){return e}e.isRequired=e;var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:i,resetWarningCache:o};return n.PropTypes=n,n}},9840:(e,t,n)=>{e.exports=n(1532)()},2552:e=>{"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},2184:(e,t,n)=>{"use strict";const r=n(548),o=n(5600),i=n(9064),a=n(8981),s=Symbol("encodeFragmentIdentifier");function l(e){if("string"!==typeof e||1!==e.length)throw new TypeError("arrayFormatSeparator must be single character string")}function c(e,t){return t.encode?t.strict?r(e):encodeURIComponent(e):e}function u(e,t){return t.decode?o(e):e}function d(e){return Array.isArray(e)?e.sort():"object"===typeof e?d(Object.keys(e)).sort(((e,t)=>Number(e)-Number(t))).map((t=>e[t])):e}function h(e){const t=e.indexOf("#");return-1!==t&&(e=e.slice(0,t)),e}function p(e){const t=(e=h(e)).indexOf("?");return-1===t?"":e.slice(t+1)}function f(e,t){return t.parseNumbers&&!Number.isNaN(Number(e))&&"string"===typeof e&&""!==e.trim()?e=Number(e):!t.parseBooleans||null===e||"true"!==e.toLowerCase()&&"false"!==e.toLowerCase()||(e="true"===e.toLowerCase()),e}function g(e,t){l((t=Object.assign({decode:!0,sort:!0,arrayFormat:"none",arrayFormatSeparator:",",parseNumbers:!1,parseBooleans:!1},t)).arrayFormatSeparator);const n=function(e){let t;switch(e.arrayFormat){case"index":return(e,n,r)=>{t=/\[(\d*)\]$/.exec(e),e=e.replace(/\[\d*\]$/,""),t?(void 0===r[e]&&(r[e]={}),r[e][t[1]]=n):r[e]=n};case"bracket":return(e,n,r)=>{t=/(\[\])$/.exec(e),e=e.replace(/\[\]$/,""),t?void 0!==r[e]?r[e]=[].concat(r[e],n):r[e]=[n]:r[e]=n};case"colon-list-separator":return(e,n,r)=>{t=/(:list)$/.exec(e),e=e.replace(/:list$/,""),t?void 0!==r[e]?r[e]=[].concat(r[e],n):r[e]=[n]:r[e]=n};case"comma":case"separator":return(t,n,r)=>{const o="string"===typeof n&&n.includes(e.arrayFormatSeparator),i="string"===typeof n&&!o&&u(n,e).includes(e.arrayFormatSeparator);n=i?u(n,e):n;const a=o||i?n.split(e.arrayFormatSeparator).map((t=>u(t,e))):null===n?n:u(n,e);r[t]=a};case"bracket-separator":return(t,n,r)=>{const o=/(\[\])$/.test(t);if(t=t.replace(/\[\]$/,""),!o)return void(r[t]=n?u(n,e):n);const i=null===n?[]:n.split(e.arrayFormatSeparator).map((t=>u(t,e)));void 0!==r[t]?r[t]=[].concat(r[t],i):r[t]=i};default:return(e,t,n)=>{void 0!==n[e]?n[e]=[].concat(n[e],t):n[e]=t}}}(t),r=Object.create(null);if("string"!==typeof e)return r;if(!(e=e.trim().replace(/^[?#&]/,"")))return r;for(const o of e.split("&")){if(""===o)continue;let[e,a]=i(t.decode?o.replace(/\+/g," "):o,"=");a=void 0===a?null:["comma","separator","bracket-separator"].includes(t.arrayFormat)?a:u(a,t),n(u(e,t),a,r)}for(const o of Object.keys(r)){const e=r[o];if("object"===typeof e&&null!==e)for(const n of Object.keys(e))e[n]=f(e[n],t);else r[o]=f(e,t)}return!1===t.sort?r:(!0===t.sort?Object.keys(r).sort():Object.keys(r).sort(t.sort)).reduce(((e,t)=>{const n=r[t];return Boolean(n)&&"object"===typeof n&&!Array.isArray(n)?e[t]=d(n):e[t]=n,e}),Object.create(null))}t.extract=p,t.parse=g,t.stringify=(e,t)=>{if(!e)return"";l((t=Object.assign({encode:!0,strict:!0,arrayFormat:"none",arrayFormatSeparator:","},t)).arrayFormatSeparator);const n=n=>{return t.skipNull&&(null===(r=e[n])||void 0===r)||t.skipEmptyString&&""===e[n];var r},r=function(e){switch(e.arrayFormat){case"index":return t=>(n,r)=>{const o=n.length;return void 0===r||e.skipNull&&null===r||e.skipEmptyString&&""===r?n:null===r?[...n,[c(t,e),"[",o,"]"].join("")]:[...n,[c(t,e),"[",c(o,e),"]=",c(r,e)].join("")]};case"bracket":return t=>(n,r)=>void 0===r||e.skipNull&&null===r||e.skipEmptyString&&""===r?n:null===r?[...n,[c(t,e),"[]"].join("")]:[...n,[c(t,e),"[]=",c(r,e)].join("")];case"colon-list-separator":return t=>(n,r)=>void 0===r||e.skipNull&&null===r||e.skipEmptyString&&""===r?n:null===r?[...n,[c(t,e),":list="].join("")]:[...n,[c(t,e),":list=",c(r,e)].join("")];case"comma":case"separator":case"bracket-separator":{const t="bracket-separator"===e.arrayFormat?"[]=":"=";return n=>(r,o)=>void 0===o||e.skipNull&&null===o||e.skipEmptyString&&""===o?r:(o=null===o?"":o,0===r.length?[[c(n,e),t,c(o,e)].join("")]:[[r,c(o,e)].join(e.arrayFormatSeparator)])}default:return t=>(n,r)=>void 0===r||e.skipNull&&null===r||e.skipEmptyString&&""===r?n:null===r?[...n,c(t,e)]:[...n,[c(t,e),"=",c(r,e)].join("")]}}(t),o={};for(const a of Object.keys(e))n(a)||(o[a]=e[a]);const i=Object.keys(o);return!1!==t.sort&&i.sort(t.sort),i.map((n=>{const o=e[n];return void 0===o?"":null===o?c(n,t):Array.isArray(o)?0===o.length&&"bracket-separator"===t.arrayFormat?c(n,t)+"[]":o.reduce(r(n),[]).join("&"):c(n,t)+"="+c(o,t)})).filter((e=>e.length>0)).join("&")},t.parseUrl=(e,t)=>{t=Object.assign({decode:!0},t);const[n,r]=i(e,"#");return Object.assign({url:n.split("?")[0]||"",query:g(p(e),t)},t&&t.parseFragmentIdentifier&&r?{fragmentIdentifier:u(r,t)}:{})},t.stringifyUrl=(e,n)=>{n=Object.assign({encode:!0,strict:!0,[s]:!0},n);const r=h(e.url).split("?")[0]||"",o=t.extract(e.url),i=t.parse(o,{sort:!1}),a=Object.assign(i,e.query);let l=t.stringify(a,n);l&&(l="?".concat(l));let u=function(e){let t="";const n=e.indexOf("#");return-1!==n&&(t=e.slice(n)),t}(e.url);return e.fragmentIdentifier&&(u="#".concat(n[s]?c(e.fragmentIdentifier,n):e.fragmentIdentifier)),"".concat(r).concat(l).concat(u)},t.pick=(e,n,r)=>{r=Object.assign({parseFragmentIdentifier:!0,[s]:!1},r);const{url:o,query:i,fragmentIdentifier:l}=t.parseUrl(e,r);return t.stringifyUrl({url:o,query:a(i,n),fragmentIdentifier:l},r)},t.exclude=(e,n,r)=>{const o=Array.isArray(n)?e=>!n.includes(e):(e,t)=>!n(e,t);return t.pick(e,o,r)}},6144:(e,t,n)=>{"use strict";var r=n(9060),o=n(7724);function i(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n