"use strict";(self.webpackChunkcentreon=self.webpackChunkcentreon||[]).push([["110"],{73277:function(e,t,r){r.r(t),r.d(t,{Provider:()=>u.Kq,atom:()=>n.eU,createStore:()=>n.y$,getDefaultStore:()=>n.zp,useAtom:()=>u.fp,useAtomValue:()=>u.md,useSetAtom:()=>u.Xr,useStore:()=>u.Pj});var n=r(20158),u=r(91460)},91460:function(e,t,r){r.d(t,{Kq:()=>s,Pj:()=>l,Xr:()=>v,fp:()=>h,md:()=>p});var n=r(9697),u=r(20158);let o=(0,n.createContext)(void 0),l=e=>{let t=(0,n.useContext)(o);return(null==e?void 0:e.store)||t||(0,u.zp)()},s=({children:e,store:t})=>{let r=(0,n.useRef)(void 0);return t||r.current||(r.current=(0,u.y$)()),(0,n.createElement)(o.Provider,{value:t||r.current},e)},a=e=>"function"==typeof(null==e?void 0:e.then),i=e=>{e.status="pending",e.then(t=>{e.status="fulfilled",e.value=t},t=>{e.status="rejected",e.reason=t})},c=n.use||(e=>{if("pending"===e.status)throw e;if("fulfilled"===e.status)return e.value;if("rejected"===e.status)throw e.reason;throw i(e),e}),f=new WeakMap,d=e=>{let t=f.get(e);return t||(t=new Promise((r,n)=>{let u=e,o=e=>t=>{u===e&&r(t)},l=e=>t=>{u===e&&n(t)},s=e=>{"onCancel"in e&&"function"==typeof e.onCancel&&e.onCancel(n=>{if(n===e)throw Error("[Bug] p is not updated even after cancelation");a(n)?(f.set(n,t),u=n,n.then(o(n),l(n)),s(n)):r(n)})};e.then(o(e),l(e)),s(e)}),f.set(e,t)),t};function p(e,t){let r=l(t),[[u,o,s],f]=(0,n.useReducer)(t=>{let n=r.get(e);return Object.is(t[0],n)&&t[1]===r&&t[2]===e?t:[n,r,e]},void 0,()=>[r.get(e),r,e]),p=u;(o!==r||s!==e)&&(f(),p=r.get(e));let v=null==t?void 0:t.delay;return((0,n.useEffect)(()=>{let t=r.sub(e,()=>{if("number"==typeof v){let t=r.get(e);a(t)&&i(d(t)),setTimeout(f,v);return}f()});return f(),t},[r,e,v]),(0,n.useDebugValue)(p),a(p))?c(d(p)):p}function v(e,t){let r=l(t);return(0,n.useCallback)((...t)=>{if(!("write"in e))throw Error("not writable atom");return r.set(e,...t)},[r,e])}function h(e,t){return[p(e,t),v(e,t)]}}}]);
//# sourceMappingURL=110.e87405376aa2937e.8c08a6d557df2775.d9c6ad45f12e48bd.js.map