aquasis-fe-components 1.2.14-a → 1.2.14-b
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -72264,14 +72264,12 @@ const SOe = {
|
|
|
72264
72264
|
}), { updTheme: LOe, updLanguage: EOe } = xOe.actions;
|
|
72265
72265
|
function MOe(e) {
|
|
72266
72266
|
const t = (r) => {
|
|
72267
|
-
const { language: a, theme: o } = r;
|
|
72268
|
-
console.log("🚀 ~ props:", r);
|
|
72269
|
-
const i = Poe();
|
|
72267
|
+
const { language: a, theme: o } = r, i = Poe();
|
|
72270
72268
|
return Et(() => {
|
|
72271
72269
|
i(EOe(a)), Yn.changeLanguage(a);
|
|
72272
|
-
}, [a]), Et(() => {
|
|
72270
|
+
}, [a, r]), Et(() => {
|
|
72273
72271
|
i(LOe(o));
|
|
72274
|
-
}, [o]), /* @__PURE__ */ we.jsx(e, { ...r });
|
|
72272
|
+
}, [o, r]), /* @__PURE__ */ we.jsx(e, { ...r });
|
|
72275
72273
|
};
|
|
72276
72274
|
return Lv((r) => {
|
|
72277
72275
|
var a, o;
|
|
@@ -1072,4 +1072,4 @@ This could lead to inefficient memoization and unnecessary re-renders.
|
|
|
1072
1072
|
Ensure transformation logic is in the result function, and extraction logic is in the input selectors.`,{stack:o})}}},aOe=(e,t,n)=>{const{memoize:r,memoizeOptions:o}=t,{inputSelectorResults:a,inputSelectorResultsCopy:i}=e,c=r(()=>({}),...o);if(!(c.apply(null,a)===c.apply(null,i))){let s;try{throw new Error}catch(d){({stack:s}=d)}console.warn(`An input selector returned a different result when passed same arguments.
|
|
1073
1073
|
This means your output selector will likely run more frequently than intended.
|
|
1074
1074
|
Avoid returning a new reference inside your input selector, e.g.
|
|
1075
|
-
\`createSelector([state => state.todos.map(todo => todo.id)], todoIds => todoIds.length)\``,{arguments:n,firstInputs:a,secondInputs:i,stack:s})}},iOe={inputStabilityCheck:"once",identityFunctionCheck:"once"};function cOe(e,t=`expected a function, instead received ${typeof e}`){if(typeof e!="function")throw new TypeError(t)}function lOe(e,t=`expected an object, instead received ${typeof e}`){if(typeof e!="object")throw new TypeError(t)}function sOe(e,t="expected all items to be functions, instead received the following types: "){if(!e.every(n=>typeof n=="function")){const n=e.map(r=>typeof r=="function"?`function ${r.name||"unnamed"}()`:typeof r).join(", ");throw new TypeError(`${t}[${n}]`)}}var $T=e=>Array.isArray(e)?e:[e];function uOe(e){const t=Array.isArray(e[0])?e[0]:e;return sOe(t,"createSelector expects all input-selectors to be functions, but received the following types: "),t}function PT(e,t){const n=[],{length:r}=e;for(let o=0;o<r;o++)n.push(e[o].apply(null,t));return n}var dOe=(e,t)=>{const{identityFunctionCheck:n,inputStabilityCheck:r}={...iOe,...t};return{identityFunctionCheck:{shouldRun:n==="always"||n==="once"&&e,run:oOe},inputStabilityCheck:{shouldRun:r==="always"||r==="once"&&e,run:aOe}}},fOe=class{constructor(e){this.value=e}deref(){return this.value}},mOe=typeof WeakRef<"u"?WeakRef:fOe,pOe=0,IT=1;function r3(){return{s:pOe,v:void 0,o:null,p:null}}function TT(e,t={}){let n=r3();const{resultEqualityCheck:r}=t;let o,a=0;function i(){var f;let c=n;const{length:l}=arguments;for(let m=0,p=l;m<p;m++){const h=arguments[m];if(typeof h=="function"||typeof h=="object"&&h!==null){let v=c.o;v===null&&(c.o=v=new WeakMap);const g=v.get(h);g===void 0?(c=r3(),v.set(h,c)):c=g}else{let v=c.p;v===null&&(c.p=v=new Map);const g=v.get(h);g===void 0?(c=r3(),v.set(h,c)):c=g}}const s=c;let d;if(c.s===IT)d=c.v;else if(d=e.apply(null,arguments),a++,r){const m=((f=o==null?void 0:o.deref)==null?void 0:f.call(o))??o;m!=null&&r(m,d)&&(d=m,a!==0&&a--),o=typeof d=="object"&&d!==null||typeof d=="function"?new mOe(d):d}return s.s=IT,s.v=d,d}return i.clearCache=()=>{n=r3(),i.resetResultsCount()},i.resultsCount=()=>a,i.resetResultsCount=()=>{a=0},i}function gOe(e,...t){const n=typeof e=="function"?{memoize:e,memoizeOptions:t}:e,r=(...o)=>{let a=0,i=0,c,l={},s=o.pop();typeof s=="object"&&(l=s,s=o.pop()),cOe(s,`createSelector expects an output function after the inputs, but received: [${typeof s}]`);const d={...n,...l},{memoize:f,memoizeOptions:m=[],argsMemoize:p=TT,argsMemoizeOptions:h=[],devModeChecks:v={}}=d,g=$T(m),y=$T(h),b=uOe(o),C=f(function(){return a++,s.apply(null,arguments)},...g);let x=!0;const S=p(function(){i++;const L=PT(b,arguments);if(c=C.apply(null,L),process.env.NODE_ENV!=="production"){const{identityFunctionCheck:w,inputStabilityCheck:M}=dOe(x,v);if(w.shouldRun&&w.run(s,L,c),M.shouldRun){const z=PT(b,arguments);M.run({inputSelectorResults:L,inputSelectorResultsCopy:z},{memoize:f,memoizeOptions:g},arguments)}x&&(x=!1)}return c},...y);return Object.assign(S,{resultFunc:s,memoizedResultFunc:C,dependencies:b,dependencyRecomputations:()=>i,resetDependencyRecomputations:()=>{i=0},lastResult:()=>c,recomputations:()=>a,resetRecomputations:()=>{a=0},memoize:f,argsMemoize:p})};return Object.assign(r,{withTypes:()=>r}),r}var hOe=gOe(TT),vOe=Object.assign((e,t=hOe)=>{lOe(e,`createStructuredSelector expects first argument to be an object where each property is a selector, instead received a ${typeof e}`);const n=Object.keys(e),r=n.map(a=>e[a]);return t(r,(...a)=>a.reduce((i,c,l)=>(i[n[l]]=c,i),{}))},{withTypes:()=>vOe});function RT(e,t){function n(...r){if(t){let o=t(...r);if(!o)throw new Error(process.env.NODE_ENV==="production"?tr(0):"prepareAction did not return an object");return{type:e,payload:o.payload,..."meta"in o&&{meta:o.meta},..."error"in o&&{error:o.error}}}return{type:e,payload:r[0]}}return n.toString=()=>`${e}`,n.type=e,n.match=r=>KNe(r)&&r.type===e,n}function DT(e){return o2(e)?OT(e,()=>{}):e}function AT(e,t,n){if(e.has(t)){let o=e.get(t);return n.update&&(o=n.update(o,t,e),e.set(t,o)),o}if(!n.insert)throw new Error(process.env.NODE_ENV==="production"?tr(10):"No insert provided for key not already in map");const r=n.insert(t,e);return e.set(t,r),r}function _T(e){const t={},n=[];let r;const o={addCase(a,i){if(process.env.NODE_ENV!=="production"){if(n.length>0)throw new Error(process.env.NODE_ENV==="production"?tr(26):"`builder.addCase` should only be called before calling `builder.addMatcher`");if(r)throw new Error(process.env.NODE_ENV==="production"?tr(27):"`builder.addCase` should only be called before calling `builder.addDefaultCase`")}const c=typeof a=="string"?a:a.type;if(!c)throw new Error(process.env.NODE_ENV==="production"?tr(28):"`builder.addCase` cannot be called with an empty action type");if(c in t)throw new Error(process.env.NODE_ENV==="production"?tr(29):`\`builder.addCase\` cannot be called with two reducers for the same action type '${c}'`);return t[c]=i,o},addMatcher(a,i){if(process.env.NODE_ENV!=="production"&&r)throw new Error(process.env.NODE_ENV==="production"?tr(30):"`builder.addMatcher` should only be called before calling `builder.addDefaultCase`");return n.push({matcher:a,reducer:i}),o},addDefaultCase(a){if(process.env.NODE_ENV!=="production"&&r)throw new Error(process.env.NODE_ENV==="production"?tr(31):"`builder.addDefaultCase` can only be called once");return r=a,o}};return e(o),[t,n,r]}function bOe(e){return typeof e=="function"}function yOe(e,t){if(process.env.NODE_ENV!=="production"&&typeof t=="object")throw new Error(process.env.NODE_ENV==="production"?tr(8):"The object notation for `createReducer` has been removed. Please use the 'builder callback' notation instead: https://redux-toolkit.js.org/api/createReducer");let[n,r,o]=_T(t),a;if(bOe(e))a=()=>DT(e());else{const c=DT(e);a=()=>c}function i(c=a(),l){let s=[n[l.type],...r.filter(({matcher:d})=>d(l)).map(({reducer:d})=>d)];return s.filter(d=>!!d).length===0&&(s=[o]),s.reduce((d,f)=>{if(f)if(vo(d)){const p=f(d,l);return p===void 0?d:p}else{if(o2(d))return OT(d,m=>f(m,l));{const m=f(d,l);if(m===void 0){if(d===null)return d;throw Error("A case reducer on a non-draftable value must not return undefined")}return m}}return d},c)}return i.getInitialState=a,i}var COe=Symbol.for("rtk-slice-createasyncthunk");function SOe(e,t){return`${e}/${t}`}function xOe({creators:e}={}){var n;const t=(n=e==null?void 0:e.asyncThunk)==null?void 0:n[COe];return function(o){const{name:a,reducerPath:i=a}=o;if(!a)throw new Error(process.env.NODE_ENV==="production"?tr(11):"`name` is a required option for createSlice");typeof process<"u"&&process.env.NODE_ENV==="development"&&o.initialState===void 0&&console.error("You must provide an `initialState` value that is not `undefined`. You may have misspelled `initialState`");const c=(typeof o.reducers=="function"?o.reducers(wOe()):o.reducers)||{},l=Object.keys(c),s={sliceCaseReducersByName:{},sliceCaseReducersByType:{},actionCreators:{},sliceMatchers:[]},d={addCase(C,x){const S=typeof C=="string"?C:C.type;if(!S)throw new Error(process.env.NODE_ENV==="production"?tr(12):"`context.addCase` cannot be called with an empty action type");if(S in s.sliceCaseReducersByType)throw new Error(process.env.NODE_ENV==="production"?tr(13):"`context.addCase` cannot be called with two reducers for the same action type: "+S);return s.sliceCaseReducersByType[S]=x,d},addMatcher(C,x){return s.sliceMatchers.push({matcher:C,reducer:x}),d},exposeAction(C,x){return s.actionCreators[C]=x,d},exposeCaseReducer(C,x){return s.sliceCaseReducersByName[C]=x,d}};l.forEach(C=>{const x=c[C],S={reducerName:C,type:SOe(a,C),createNotation:typeof o.reducers=="function"};zOe(x)?OOe(S,x,d,t):MOe(S,x,d)});function f(){if(process.env.NODE_ENV!=="production"&&typeof o.extraReducers=="object")throw new Error(process.env.NODE_ENV==="production"?tr(14):"The object notation for `createSlice.extraReducers` has been removed. Please use the 'builder callback' notation instead: https://redux-toolkit.js.org/api/createSlice");const[C={},x=[],S=void 0]=typeof o.extraReducers=="function"?_T(o.extraReducers):[o.extraReducers],E={...C,...s.sliceCaseReducersByType};return yOe(o.initialState,L=>{for(let w in E)L.addCase(w,E[w]);for(let w of s.sliceMatchers)L.addMatcher(w.matcher,w.reducer);for(let w of x)L.addMatcher(w.matcher,w.reducer);S&&L.addDefaultCase(S)})}const m=C=>C,p=new Map;let h;function v(C,x){return h||(h=f()),h(C,x)}function g(){return h||(h=f()),h.getInitialState()}function y(C,x=!1){function S(L){let w=L[C];if(typeof w>"u"){if(x)w=g();else if(process.env.NODE_ENV!=="production")throw new Error(process.env.NODE_ENV==="production"?tr(15):"selectSlice returned undefined for an uninjected slice reducer")}return w}function E(L=m){const w=AT(p,x,{insert:()=>new WeakMap});return AT(w,L,{insert:()=>{const M={};for(const[z,P]of Object.entries(o.selectors??{}))M[z]=EOe(P,L,g,x);return M}})}return{reducerPath:C,getSelectors:E,get selectors(){return E(S)},selectSlice:S}}const b={name:a,reducer:v,actions:s.actionCreators,caseReducers:s.sliceCaseReducersByName,getInitialState:g,...y(i),injectInto(C,{reducerPath:x,...S}={}){const E=x??i;return C.inject({reducerPath:E,reducer:v},S),{...b,...y(E,!0)}}};return b}}function EOe(e,t,n,r){function o(a,...i){let c=t(a);if(typeof c>"u"){if(r)c=n();else if(process.env.NODE_ENV!=="production")throw new Error(process.env.NODE_ENV==="production"?tr(16):"selectState returned undefined for an uninjected slice reducer")}return e(c,...i)}return o.unwrapped=e,o}var LOe=xOe();function wOe(){function e(t,n){return{_reducerDefinitionType:"asyncThunk",payloadCreator:t,...n}}return e.withTypes=()=>e,{reducer(t){return Object.assign({[t.name](...n){return t(...n)}}[t.name],{_reducerDefinitionType:"reducer"})},preparedReducer(t,n){return{_reducerDefinitionType:"reducerWithPrepare",prepare:t,reducer:n}},asyncThunk:e}}function MOe({type:e,reducerName:t,createNotation:n},r,o){let a,i;if("reducer"in r){if(n&&!NOe(r))throw new Error(process.env.NODE_ENV==="production"?tr(17):"Please use the `create.preparedReducer` notation for prepared action creators with the `create` notation.");a=r.reducer,i=r.prepare}else a=r;o.addCase(e,a).exposeCaseReducer(t,a).exposeAction(t,i?RT(e,i):RT(e))}function zOe(e){return e._reducerDefinitionType==="asyncThunk"}function NOe(e){return e._reducerDefinitionType==="reducerWithPrepare"}function OOe({type:e,reducerName:t},n,r,o){if(!o)throw new Error(process.env.NODE_ENV==="production"?tr(18):"Cannot use `create.asyncThunk` in the built-in `createSlice`. Use `buildCreateSlice({ creators: { asyncThunk: asyncThunkCreator } })` to create a customised version of `createSlice`.");const{payloadCreator:a,fulfilled:i,pending:c,rejected:l,settled:s,options:d}=n,f=o(e,a,d);r.exposeAction(t,f),i&&r.addCase(f.fulfilled,i),c&&r.addCase(f.pending,c),l&&r.addCase(f.rejected,l),s&&r.addMatcher(f.settled,s),r.exposeCaseReducer(t,{fulfilled:i||o3,pending:c||o3,rejected:l||o3,settled:s||o3})}function o3(){}function tr(e){return`Minified Redux Toolkit error #${e}; visit https://redux-toolkit.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}const $Oe={theme:$c.Light},POe=LOe({name:"AppState",initialState:$Oe,reducers:{updTheme:(e,{payload:t})=>{e.theme=t},updLanguage:(e,{payload:t})=>{e.language=t}}}),{updTheme:IOe,updLanguage:TOe}=POe.actions;function ROe(e){const t=r=>{const{language:o,theme:a}=r;console.log("🚀 ~ props:",r);const i=Voe();return O.useEffect(()=>{i(TOe(o)),Un.changeLanguage(o)},[o]),O.useEffect(()=>{i(IOe(a))},[a]),Me.jsx(e,{...r})};return z7(r=>{var o,a;return{language:(o=r==null?void 0:r.app)==null?void 0:o.language,theme:(a=r==null?void 0:r.app)==null?void 0:a.theme}})(t)}function wc(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,xo(e,t)}var Mc=function(){function e(){this.listeners=[]}var t=e.prototype;return t.subscribe=function(r){var o=this,a=r||function(){};return this.listeners.push(a),this.onSubscribe(),function(){o.listeners=o.listeners.filter(function(i){return i!==a}),o.onUnsubscribe()}},t.hasListeners=function(){return this.listeners.length>0},t.onSubscribe=function(){},t.onUnsubscribe=function(){},e}(),a3=typeof window>"u";function lr(){}function DOe(e,t){return typeof e=="function"?e(t):e}function V5(e){return typeof e=="number"&&e>=0&&e!==1/0}function i3(e){return Array.isArray(e)?e:[e]}function kT(e,t){return Math.max(e+(t||0)-Date.now(),0)}function c3(e,t,n){return u3(e)?typeof t=="function"?le({},n,{queryKey:e,queryFn:t}):le({},t,{queryKey:e}):e}function P2(e,t,n){return u3(e)?[le({},t,{queryKey:e}),n]:[e||{},t]}function AOe(e,t){if(e===!0&&t===!0||e==null&&t==null)return"all";if(e===!1&&t===!1)return"none";var n=e??!t;return n?"active":"inactive"}function FT(e,t){var n=e.active,r=e.exact,o=e.fetching,a=e.inactive,i=e.predicate,c=e.queryKey,l=e.stale;if(u3(c)){if(r){if(t.queryHash!==W5(c,t.options))return!1}else if(!l3(t.queryKey,c))return!1}var s=AOe(n,a);if(s==="none")return!1;if(s!=="all"){var d=t.isActive();if(s==="active"&&!d||s==="inactive"&&d)return!1}return!(typeof l=="boolean"&&t.isStale()!==l||typeof o=="boolean"&&t.isFetching()!==o||i&&!i(t))}function jT(e,t){var n=e.exact,r=e.fetching,o=e.predicate,a=e.mutationKey;if(u3(a)){if(!t.options.mutationKey)return!1;if(n){if(Co(t.options.mutationKey)!==Co(a))return!1}else if(!l3(t.options.mutationKey,a))return!1}return!(typeof r=="boolean"&&t.state.status==="loading"!==r||o&&!o(t))}function W5(e,t){var n=(t==null?void 0:t.queryKeyHashFn)||Co;return n(e)}function Co(e){var t=i3(e);return _Oe(t)}function _Oe(e){return JSON.stringify(e,function(t,n){return U5(n)?Object.keys(n).sort().reduce(function(r,o){return r[o]=n[o],r},{}):n})}function l3(e,t){return BT(i3(e),i3(t))}function BT(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?!Object.keys(t).some(function(n){return!BT(e[n],t[n])}):!1}function s3(e,t){if(e===t)return e;var n=Array.isArray(e)&&Array.isArray(t);if(n||U5(e)&&U5(t)){for(var r=n?e.length:Object.keys(e).length,o=n?t:Object.keys(t),a=o.length,i=n?[]:{},c=0,l=0;l<a;l++){var s=n?l:o[l];i[s]=s3(e[s],t[s]),i[s]===e[s]&&c++}return r===a&&c===r?e:i}return t}function kOe(e,t){if(e&&!t||t&&!e)return!1;for(var n in e)if(e[n]!==t[n])return!1;return!0}function U5(e){if(!HT(e))return!1;var t=e.constructor;if(typeof t>"u")return!0;var n=t.prototype;return!(!HT(n)||!n.hasOwnProperty("isPrototypeOf"))}function HT(e){return Object.prototype.toString.call(e)==="[object Object]"}function u3(e){return typeof e=="string"||Array.isArray(e)}function FOe(e){return new Promise(function(t){setTimeout(t,e)})}function VT(e){Promise.resolve().then(e).catch(function(t){return setTimeout(function(){throw t})})}function WT(){if(typeof AbortController=="function")return new AbortController}var jOe=function(e){wc(t,e);function t(){var r;return r=e.call(this)||this,r.setup=function(o){var a;if(!a3&&((a=window)!=null&&a.addEventListener)){var i=function(){return o()};return window.addEventListener("visibilitychange",i,!1),window.addEventListener("focus",i,!1),function(){window.removeEventListener("visibilitychange",i),window.removeEventListener("focus",i)}}},r}var n=t.prototype;return n.onSubscribe=function(){this.cleanup||this.setEventListener(this.setup)},n.onUnsubscribe=function(){if(!this.hasListeners()){var o;(o=this.cleanup)==null||o.call(this),this.cleanup=void 0}},n.setEventListener=function(o){var a,i=this;this.setup=o,(a=this.cleanup)==null||a.call(this),this.cleanup=o(function(c){typeof c=="boolean"?i.setFocused(c):i.onFocus()})},n.setFocused=function(o){this.focused=o,o&&this.onFocus()},n.onFocus=function(){this.listeners.forEach(function(o){o()})},n.isFocused=function(){return typeof this.focused=="boolean"?this.focused:typeof document>"u"?!0:[void 0,"visible","prerender"].includes(document.visibilityState)},t}(Mc),zc=new jOe,BOe=function(e){wc(t,e);function t(){var r;return r=e.call(this)||this,r.setup=function(o){var a;if(!a3&&((a=window)!=null&&a.addEventListener)){var i=function(){return o()};return window.addEventListener("online",i,!1),window.addEventListener("offline",i,!1),function(){window.removeEventListener("online",i),window.removeEventListener("offline",i)}}},r}var n=t.prototype;return n.onSubscribe=function(){this.cleanup||this.setEventListener(this.setup)},n.onUnsubscribe=function(){if(!this.hasListeners()){var o;(o=this.cleanup)==null||o.call(this),this.cleanup=void 0}},n.setEventListener=function(o){var a,i=this;this.setup=o,(a=this.cleanup)==null||a.call(this),this.cleanup=o(function(c){typeof c=="boolean"?i.setOnline(c):i.onOnline()})},n.setOnline=function(o){this.online=o,o&&this.onOnline()},n.onOnline=function(){this.listeners.forEach(function(o){o()})},n.isOnline=function(){return typeof this.online=="boolean"?this.online:typeof navigator>"u"||typeof navigator.onLine>"u"?!0:navigator.onLine},t}(Mc),d3=new BOe;function HOe(e){return Math.min(1e3*Math.pow(2,e),3e4)}function f3(e){return typeof(e==null?void 0:e.cancel)=="function"}var UT=function(t){this.revert=t==null?void 0:t.revert,this.silent=t==null?void 0:t.silent};function m3(e){return e instanceof UT}var KT=function(t){var n=this,r=!1,o,a,i,c;this.abort=t.abort,this.cancel=function(m){return o==null?void 0:o(m)},this.cancelRetry=function(){r=!0},this.continueRetry=function(){r=!1},this.continue=function(){return a==null?void 0:a()},this.failureCount=0,this.isPaused=!1,this.isResolved=!1,this.isTransportCancelable=!1,this.promise=new Promise(function(m,p){i=m,c=p});var l=function(p){n.isResolved||(n.isResolved=!0,t.onSuccess==null||t.onSuccess(p),a==null||a(),i(p))},s=function(p){n.isResolved||(n.isResolved=!0,t.onError==null||t.onError(p),a==null||a(),c(p))},d=function(){return new Promise(function(p){a=p,n.isPaused=!0,t.onPause==null||t.onPause()}).then(function(){a=void 0,n.isPaused=!1,t.onContinue==null||t.onContinue()})},f=function m(){if(!n.isResolved){var p;try{p=t.fn()}catch(h){p=Promise.reject(h)}o=function(v){if(!n.isResolved&&(s(new UT(v)),n.abort==null||n.abort(),f3(p)))try{p.cancel()}catch{}},n.isTransportCancelable=f3(p),Promise.resolve(p).then(l).catch(function(h){var v,g;if(!n.isResolved){var y=(v=t.retry)!=null?v:3,b=(g=t.retryDelay)!=null?g:HOe,C=typeof b=="function"?b(n.failureCount,h):b,x=y===!0||typeof y=="number"&&n.failureCount<y||typeof y=="function"&&y(n.failureCount,h);if(r||!x){s(h);return}n.failureCount++,t.onFail==null||t.onFail(n.failureCount,h),FOe(C).then(function(){if(!zc.isFocused()||!d3.isOnline())return d()}).then(function(){r?s(h):m()})}})}};f()},VOe=function(){function e(){this.queue=[],this.transactions=0,this.notifyFn=function(n){n()},this.batchNotifyFn=function(n){n()}}var t=e.prototype;return t.batch=function(r){var o;this.transactions++;try{o=r()}finally{this.transactions--,this.transactions||this.flush()}return o},t.schedule=function(r){var o=this;this.transactions?this.queue.push(r):VT(function(){o.notifyFn(r)})},t.batchCalls=function(r){var o=this;return function(){for(var a=arguments.length,i=new Array(a),c=0;c<a;c++)i[c]=arguments[c];o.schedule(function(){r.apply(void 0,i)})}},t.flush=function(){var r=this,o=this.queue;this.queue=[],o.length&&VT(function(){r.batchNotifyFn(function(){o.forEach(function(a){r.notifyFn(a)})})})},t.setNotifyFunction=function(r){this.notifyFn=r},t.setBatchNotifyFunction=function(r){this.batchNotifyFn=r},e}(),wn=new VOe,qT=console;function p3(){return qT}function WOe(e){qT=e}var UOe=function(){function e(n){this.abortSignalConsumed=!1,this.hadObservers=!1,this.defaultOptions=n.defaultOptions,this.setOptions(n.options),this.observers=[],this.cache=n.cache,this.queryKey=n.queryKey,this.queryHash=n.queryHash,this.initialState=n.state||this.getDefaultState(this.options),this.state=this.initialState,this.meta=n.meta,this.scheduleGc()}var t=e.prototype;return t.setOptions=function(r){var o;this.options=le({},this.defaultOptions,r),this.meta=r==null?void 0:r.meta,this.cacheTime=Math.max(this.cacheTime||0,(o=this.options.cacheTime)!=null?o:5*60*1e3)},t.setDefaultOptions=function(r){this.defaultOptions=r},t.scheduleGc=function(){var r=this;this.clearGcTimeout(),V5(this.cacheTime)&&(this.gcTimeout=setTimeout(function(){r.optionalRemove()},this.cacheTime))},t.clearGcTimeout=function(){this.gcTimeout&&(clearTimeout(this.gcTimeout),this.gcTimeout=void 0)},t.optionalRemove=function(){this.observers.length||(this.state.isFetching?this.hadObservers&&this.scheduleGc():this.cache.remove(this))},t.setData=function(r,o){var a,i,c=this.state.data,l=DOe(r,c);return(a=(i=this.options).isDataEqual)!=null&&a.call(i,c,l)?l=c:this.options.structuralSharing!==!1&&(l=s3(c,l)),this.dispatch({data:l,type:"success",dataUpdatedAt:o==null?void 0:o.updatedAt}),l},t.setState=function(r,o){this.dispatch({type:"setState",state:r,setStateOptions:o})},t.cancel=function(r){var o,a=this.promise;return(o=this.retryer)==null||o.cancel(r),a?a.then(lr).catch(lr):Promise.resolve()},t.destroy=function(){this.clearGcTimeout(),this.cancel({silent:!0})},t.reset=function(){this.destroy(),this.setState(this.initialState)},t.isActive=function(){return this.observers.some(function(r){return r.options.enabled!==!1})},t.isFetching=function(){return this.state.isFetching},t.isStale=function(){return this.state.isInvalidated||!this.state.dataUpdatedAt||this.observers.some(function(r){return r.getCurrentResult().isStale})},t.isStaleByTime=function(r){return r===void 0&&(r=0),this.state.isInvalidated||!this.state.dataUpdatedAt||!kT(this.state.dataUpdatedAt,r)},t.onFocus=function(){var r,o=this.observers.find(function(a){return a.shouldFetchOnWindowFocus()});o&&o.refetch(),(r=this.retryer)==null||r.continue()},t.onOnline=function(){var r,o=this.observers.find(function(a){return a.shouldFetchOnReconnect()});o&&o.refetch(),(r=this.retryer)==null||r.continue()},t.addObserver=function(r){this.observers.indexOf(r)===-1&&(this.observers.push(r),this.hadObservers=!0,this.clearGcTimeout(),this.cache.notify({type:"observerAdded",query:this,observer:r}))},t.removeObserver=function(r){this.observers.indexOf(r)!==-1&&(this.observers=this.observers.filter(function(o){return o!==r}),this.observers.length||(this.retryer&&(this.retryer.isTransportCancelable||this.abortSignalConsumed?this.retryer.cancel({revert:!0}):this.retryer.cancelRetry()),this.cacheTime?this.scheduleGc():this.cache.remove(this)),this.cache.notify({type:"observerRemoved",query:this,observer:r}))},t.getObserversCount=function(){return this.observers.length},t.invalidate=function(){this.state.isInvalidated||this.dispatch({type:"invalidate"})},t.fetch=function(r,o){var a=this,i,c,l;if(this.state.isFetching){if(this.state.dataUpdatedAt&&(o!=null&&o.cancelRefetch))this.cancel({silent:!0});else if(this.promise){var s;return(s=this.retryer)==null||s.continueRetry(),this.promise}}if(r&&this.setOptions(r),!this.options.queryFn){var d=this.observers.find(function(b){return b.options.queryFn});d&&this.setOptions(d.options)}var f=i3(this.queryKey),m=WT(),p={queryKey:f,pageParam:void 0,meta:this.meta};Object.defineProperty(p,"signal",{enumerable:!0,get:function(){if(m)return a.abortSignalConsumed=!0,m.signal}});var h=function(){return a.options.queryFn?(a.abortSignalConsumed=!1,a.options.queryFn(p)):Promise.reject("Missing queryFn")},v={fetchOptions:o,options:this.options,queryKey:f,state:this.state,fetchFn:h,meta:this.meta};if((i=this.options.behavior)!=null&&i.onFetch){var g;(g=this.options.behavior)==null||g.onFetch(v)}if(this.revertState=this.state,!this.state.isFetching||this.state.fetchMeta!==((c=v.fetchOptions)==null?void 0:c.meta)){var y;this.dispatch({type:"fetch",meta:(y=v.fetchOptions)==null?void 0:y.meta})}return this.retryer=new KT({fn:v.fetchFn,abort:m==null||(l=m.abort)==null?void 0:l.bind(m),onSuccess:function(C){a.setData(C),a.cache.config.onSuccess==null||a.cache.config.onSuccess(C,a),a.cacheTime===0&&a.optionalRemove()},onError:function(C){m3(C)&&C.silent||a.dispatch({type:"error",error:C}),m3(C)||(a.cache.config.onError==null||a.cache.config.onError(C,a),p3().error(C)),a.cacheTime===0&&a.optionalRemove()},onFail:function(){a.dispatch({type:"failed"})},onPause:function(){a.dispatch({type:"pause"})},onContinue:function(){a.dispatch({type:"continue"})},retry:v.options.retry,retryDelay:v.options.retryDelay}),this.promise=this.retryer.promise,this.promise},t.dispatch=function(r){var o=this;this.state=this.reducer(this.state,r),wn.batch(function(){o.observers.forEach(function(a){a.onQueryUpdate(r)}),o.cache.notify({query:o,type:"queryUpdated",action:r})})},t.getDefaultState=function(r){var o=typeof r.initialData=="function"?r.initialData():r.initialData,a=typeof r.initialData<"u",i=a?typeof r.initialDataUpdatedAt=="function"?r.initialDataUpdatedAt():r.initialDataUpdatedAt:0,c=typeof o<"u";return{data:o,dataUpdateCount:0,dataUpdatedAt:c?i??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchMeta:null,isFetching:!1,isInvalidated:!1,isPaused:!1,status:c?"success":"idle"}},t.reducer=function(r,o){var a,i;switch(o.type){case"failed":return le({},r,{fetchFailureCount:r.fetchFailureCount+1});case"pause":return le({},r,{isPaused:!0});case"continue":return le({},r,{isPaused:!1});case"fetch":return le({},r,{fetchFailureCount:0,fetchMeta:(a=o.meta)!=null?a:null,isFetching:!0,isPaused:!1},!r.dataUpdatedAt&&{error:null,status:"loading"});case"success":return le({},r,{data:o.data,dataUpdateCount:r.dataUpdateCount+1,dataUpdatedAt:(i=o.dataUpdatedAt)!=null?i:Date.now(),error:null,fetchFailureCount:0,isFetching:!1,isInvalidated:!1,isPaused:!1,status:"success"});case"error":var c=o.error;return m3(c)&&c.revert&&this.revertState?le({},this.revertState):le({},r,{error:c,errorUpdateCount:r.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:r.fetchFailureCount+1,isFetching:!1,isPaused:!1,status:"error"});case"invalidate":return le({},r,{isInvalidated:!0});case"setState":return le({},r,o.state);default:return r}},e}(),KOe=function(e){wc(t,e);function t(r){var o;return o=e.call(this)||this,o.config=r||{},o.queries=[],o.queriesMap={},o}var n=t.prototype;return n.build=function(o,a,i){var c,l=a.queryKey,s=(c=a.queryHash)!=null?c:W5(l,a),d=this.get(s);return d||(d=new UOe({cache:this,queryKey:l,queryHash:s,options:o.defaultQueryOptions(a),state:i,defaultOptions:o.getQueryDefaults(l),meta:a.meta}),this.add(d)),d},n.add=function(o){this.queriesMap[o.queryHash]||(this.queriesMap[o.queryHash]=o,this.queries.push(o),this.notify({type:"queryAdded",query:o}))},n.remove=function(o){var a=this.queriesMap[o.queryHash];a&&(o.destroy(),this.queries=this.queries.filter(function(i){return i!==o}),a===o&&delete this.queriesMap[o.queryHash],this.notify({type:"queryRemoved",query:o}))},n.clear=function(){var o=this;wn.batch(function(){o.queries.forEach(function(a){o.remove(a)})})},n.get=function(o){return this.queriesMap[o]},n.getAll=function(){return this.queries},n.find=function(o,a){var i=P2(o,a),c=i[0];return typeof c.exact>"u"&&(c.exact=!0),this.queries.find(function(l){return FT(c,l)})},n.findAll=function(o,a){var i=P2(o,a),c=i[0];return Object.keys(c).length>0?this.queries.filter(function(l){return FT(c,l)}):this.queries},n.notify=function(o){var a=this;wn.batch(function(){a.listeners.forEach(function(i){i(o)})})},n.onFocus=function(){var o=this;wn.batch(function(){o.queries.forEach(function(a){a.onFocus()})})},n.onOnline=function(){var o=this;wn.batch(function(){o.queries.forEach(function(a){a.onOnline()})})},t}(Mc),qOe=function(){function e(n){this.options=le({},n.defaultOptions,n.options),this.mutationId=n.mutationId,this.mutationCache=n.mutationCache,this.observers=[],this.state=n.state||GOe(),this.meta=n.meta}var t=e.prototype;return t.setState=function(r){this.dispatch({type:"setState",state:r})},t.addObserver=function(r){this.observers.indexOf(r)===-1&&this.observers.push(r)},t.removeObserver=function(r){this.observers=this.observers.filter(function(o){return o!==r})},t.cancel=function(){return this.retryer?(this.retryer.cancel(),this.retryer.promise.then(lr).catch(lr)):Promise.resolve()},t.continue=function(){return this.retryer?(this.retryer.continue(),this.retryer.promise):this.execute()},t.execute=function(){var r=this,o,a=this.state.status==="loading",i=Promise.resolve();return a||(this.dispatch({type:"loading",variables:this.options.variables}),i=i.then(function(){r.mutationCache.config.onMutate==null||r.mutationCache.config.onMutate(r.state.variables,r)}).then(function(){return r.options.onMutate==null?void 0:r.options.onMutate(r.state.variables)}).then(function(c){c!==r.state.context&&r.dispatch({type:"loading",context:c,variables:r.state.variables})})),i.then(function(){return r.executeMutation()}).then(function(c){o=c,r.mutationCache.config.onSuccess==null||r.mutationCache.config.onSuccess(o,r.state.variables,r.state.context,r)}).then(function(){return r.options.onSuccess==null?void 0:r.options.onSuccess(o,r.state.variables,r.state.context)}).then(function(){return r.options.onSettled==null?void 0:r.options.onSettled(o,null,r.state.variables,r.state.context)}).then(function(){return r.dispatch({type:"success",data:o}),o}).catch(function(c){return r.mutationCache.config.onError==null||r.mutationCache.config.onError(c,r.state.variables,r.state.context,r),p3().error(c),Promise.resolve().then(function(){return r.options.onError==null?void 0:r.options.onError(c,r.state.variables,r.state.context)}).then(function(){return r.options.onSettled==null?void 0:r.options.onSettled(void 0,c,r.state.variables,r.state.context)}).then(function(){throw r.dispatch({type:"error",error:c}),c})})},t.executeMutation=function(){var r=this,o;return this.retryer=new KT({fn:function(){return r.options.mutationFn?r.options.mutationFn(r.state.variables):Promise.reject("No mutationFn found")},onFail:function(){r.dispatch({type:"failed"})},onPause:function(){r.dispatch({type:"pause"})},onContinue:function(){r.dispatch({type:"continue"})},retry:(o=this.options.retry)!=null?o:0,retryDelay:this.options.retryDelay}),this.retryer.promise},t.dispatch=function(r){var o=this;this.state=YOe(this.state,r),wn.batch(function(){o.observers.forEach(function(a){a.onMutationUpdate(r)}),o.mutationCache.notify(o)})},e}();function GOe(){return{context:void 0,data:void 0,error:null,failureCount:0,isPaused:!1,status:"idle",variables:void 0}}function YOe(e,t){switch(t.type){case"failed":return le({},e,{failureCount:e.failureCount+1});case"pause":return le({},e,{isPaused:!0});case"continue":return le({},e,{isPaused:!1});case"loading":return le({},e,{context:t.context,data:void 0,error:null,isPaused:!1,status:"loading",variables:t.variables});case"success":return le({},e,{data:t.data,error:null,status:"success",isPaused:!1});case"error":return le({},e,{data:void 0,error:t.error,failureCount:e.failureCount+1,isPaused:!1,status:"error"});case"setState":return le({},e,t.state);default:return e}}var XOe=function(e){wc(t,e);function t(r){var o;return o=e.call(this)||this,o.config=r||{},o.mutations=[],o.mutationId=0,o}var n=t.prototype;return n.build=function(o,a,i){var c=new qOe({mutationCache:this,mutationId:++this.mutationId,options:o.defaultMutationOptions(a),state:i,defaultOptions:a.mutationKey?o.getMutationDefaults(a.mutationKey):void 0,meta:a.meta});return this.add(c),c},n.add=function(o){this.mutations.push(o),this.notify(o)},n.remove=function(o){this.mutations=this.mutations.filter(function(a){return a!==o}),o.cancel(),this.notify(o)},n.clear=function(){var o=this;wn.batch(function(){o.mutations.forEach(function(a){o.remove(a)})})},n.getAll=function(){return this.mutations},n.find=function(o){return typeof o.exact>"u"&&(o.exact=!0),this.mutations.find(function(a){return jT(o,a)})},n.findAll=function(o){return this.mutations.filter(function(a){return jT(o,a)})},n.notify=function(o){var a=this;wn.batch(function(){a.listeners.forEach(function(i){i(o)})})},n.onFocus=function(){this.resumePausedMutations()},n.onOnline=function(){this.resumePausedMutations()},n.resumePausedMutations=function(){var o=this.mutations.filter(function(a){return a.state.isPaused});return wn.batch(function(){return o.reduce(function(a,i){return a.then(function(){return i.continue().catch(lr)})},Promise.resolve())})},t}(Mc);function QOe(){return{onFetch:function(t){t.fetchFn=function(){var n,r,o,a,i,c,l=(n=t.fetchOptions)==null||(r=n.meta)==null?void 0:r.refetchPage,s=(o=t.fetchOptions)==null||(a=o.meta)==null?void 0:a.fetchMore,d=s==null?void 0:s.pageParam,f=(s==null?void 0:s.direction)==="forward",m=(s==null?void 0:s.direction)==="backward",p=((i=t.state.data)==null?void 0:i.pages)||[],h=((c=t.state.data)==null?void 0:c.pageParams)||[],v=WT(),g=v==null?void 0:v.signal,y=h,b=!1,C=t.options.queryFn||function(){return Promise.reject("Missing queryFn")},x=function($,T,R,N){return y=N?[T].concat(y):[].concat(y,[T]),N?[R].concat($):[].concat($,[R])},S=function($,T,R,N){if(b)return Promise.reject("Cancelled");if(typeof R>"u"&&!T&&$.length)return Promise.resolve($);var I={queryKey:t.queryKey,signal:g,pageParam:R,meta:t.meta},k=C(I),_=Promise.resolve(k).then(function(V){return x($,R,V,N)});if(f3(k)){var F=_;F.cancel=k.cancel}return _},E;if(!p.length)E=S([]);else if(f){var L=typeof d<"u",w=L?d:GT(t.options,p);E=S(p,L,w)}else if(m){var M=typeof d<"u",z=M?d:JOe(t.options,p);E=S(p,M,z,!0)}else(function(){y=[];var A=typeof t.options.getNextPageParam>"u",$=l&&p[0]?l(p[0],0,p):!0;E=$?S([],A,h[0]):Promise.resolve(x([],h[0],p[0]));for(var T=function(I){E=E.then(function(k){var _=l&&p[I]?l(p[I],I,p):!0;if(_){var F=A?h[I]:GT(t.options,k);return S(k,A,F)}return Promise.resolve(x(k,h[I],p[I]))})},R=1;R<p.length;R++)T(R)})();var P=E.then(function(A){return{pages:A,pageParams:y}}),D=P;return D.cancel=function(){b=!0,v==null||v.abort(),f3(E)&&E.cancel()},P}}}}function GT(e,t){return e.getNextPageParam==null?void 0:e.getNextPageParam(t[t.length-1],t)}function JOe(e,t){return e.getPreviousPageParam==null?void 0:e.getPreviousPageParam(t[0],t)}var ZOe=function(){function e(n){n===void 0&&(n={}),this.queryCache=n.queryCache||new KOe,this.mutationCache=n.mutationCache||new XOe,this.defaultOptions=n.defaultOptions||{},this.queryDefaults=[],this.mutationDefaults=[]}var t=e.prototype;return t.mount=function(){var r=this;this.unsubscribeFocus=zc.subscribe(function(){zc.isFocused()&&d3.isOnline()&&(r.mutationCache.onFocus(),r.queryCache.onFocus())}),this.unsubscribeOnline=d3.subscribe(function(){zc.isFocused()&&d3.isOnline()&&(r.mutationCache.onOnline(),r.queryCache.onOnline())})},t.unmount=function(){var r,o;(r=this.unsubscribeFocus)==null||r.call(this),(o=this.unsubscribeOnline)==null||o.call(this)},t.isFetching=function(r,o){var a=P2(r,o),i=a[0];return i.fetching=!0,this.queryCache.findAll(i).length},t.isMutating=function(r){return this.mutationCache.findAll(le({},r,{fetching:!0})).length},t.getQueryData=function(r,o){var a;return(a=this.queryCache.find(r,o))==null?void 0:a.state.data},t.getQueriesData=function(r){return this.getQueryCache().findAll(r).map(function(o){var a=o.queryKey,i=o.state,c=i.data;return[a,c]})},t.setQueryData=function(r,o,a){var i=c3(r),c=this.defaultQueryOptions(i);return this.queryCache.build(this,c).setData(o,a)},t.setQueriesData=function(r,o,a){var i=this;return wn.batch(function(){return i.getQueryCache().findAll(r).map(function(c){var l=c.queryKey;return[l,i.setQueryData(l,o,a)]})})},t.getQueryState=function(r,o){var a;return(a=this.queryCache.find(r,o))==null?void 0:a.state},t.removeQueries=function(r,o){var a=P2(r,o),i=a[0],c=this.queryCache;wn.batch(function(){c.findAll(i).forEach(function(l){c.remove(l)})})},t.resetQueries=function(r,o,a){var i=this,c=P2(r,o,a),l=c[0],s=c[1],d=this.queryCache,f=le({},l,{active:!0});return wn.batch(function(){return d.findAll(l).forEach(function(m){m.reset()}),i.refetchQueries(f,s)})},t.cancelQueries=function(r,o,a){var i=this,c=P2(r,o,a),l=c[0],s=c[1],d=s===void 0?{}:s;typeof d.revert>"u"&&(d.revert=!0);var f=wn.batch(function(){return i.queryCache.findAll(l).map(function(m){return m.cancel(d)})});return Promise.all(f).then(lr).catch(lr)},t.invalidateQueries=function(r,o,a){var i,c,l,s=this,d=P2(r,o,a),f=d[0],m=d[1],p=le({},f,{active:(i=(c=f.refetchActive)!=null?c:f.active)!=null?i:!0,inactive:(l=f.refetchInactive)!=null?l:!1});return wn.batch(function(){return s.queryCache.findAll(f).forEach(function(h){h.invalidate()}),s.refetchQueries(p,m)})},t.refetchQueries=function(r,o,a){var i=this,c=P2(r,o,a),l=c[0],s=c[1],d=wn.batch(function(){return i.queryCache.findAll(l).map(function(m){return m.fetch(void 0,le({},s,{meta:{refetchPage:l==null?void 0:l.refetchPage}}))})}),f=Promise.all(d).then(lr);return s!=null&&s.throwOnError||(f=f.catch(lr)),f},t.fetchQuery=function(r,o,a){var i=c3(r,o,a),c=this.defaultQueryOptions(i);typeof c.retry>"u"&&(c.retry=!1);var l=this.queryCache.build(this,c);return l.isStaleByTime(c.staleTime)?l.fetch(c):Promise.resolve(l.state.data)},t.prefetchQuery=function(r,o,a){return this.fetchQuery(r,o,a).then(lr).catch(lr)},t.fetchInfiniteQuery=function(r,o,a){var i=c3(r,o,a);return i.behavior=QOe(),this.fetchQuery(i)},t.prefetchInfiniteQuery=function(r,o,a){return this.fetchInfiniteQuery(r,o,a).then(lr).catch(lr)},t.cancelMutations=function(){var r=this,o=wn.batch(function(){return r.mutationCache.getAll().map(function(a){return a.cancel()})});return Promise.all(o).then(lr).catch(lr)},t.resumePausedMutations=function(){return this.getMutationCache().resumePausedMutations()},t.executeMutation=function(r){return this.mutationCache.build(this,r).execute()},t.getQueryCache=function(){return this.queryCache},t.getMutationCache=function(){return this.mutationCache},t.getDefaultOptions=function(){return this.defaultOptions},t.setDefaultOptions=function(r){this.defaultOptions=r},t.setQueryDefaults=function(r,o){var a=this.queryDefaults.find(function(i){return Co(r)===Co(i.queryKey)});a?a.defaultOptions=o:this.queryDefaults.push({queryKey:r,defaultOptions:o})},t.getQueryDefaults=function(r){var o;return r?(o=this.queryDefaults.find(function(a){return l3(r,a.queryKey)}))==null?void 0:o.defaultOptions:void 0},t.setMutationDefaults=function(r,o){var a=this.mutationDefaults.find(function(i){return Co(r)===Co(i.mutationKey)});a?a.defaultOptions=o:this.mutationDefaults.push({mutationKey:r,defaultOptions:o})},t.getMutationDefaults=function(r){var o;return r?(o=this.mutationDefaults.find(function(a){return l3(r,a.mutationKey)}))==null?void 0:o.defaultOptions:void 0},t.defaultQueryOptions=function(r){if(r!=null&&r._defaulted)return r;var o=le({},this.defaultOptions.queries,this.getQueryDefaults(r==null?void 0:r.queryKey),r,{_defaulted:!0});return!o.queryHash&&o.queryKey&&(o.queryHash=W5(o.queryKey,o)),o},t.defaultQueryObserverOptions=function(r){return this.defaultQueryOptions(r)},t.defaultMutationOptions=function(r){return r!=null&&r._defaulted?r:le({},this.defaultOptions.mutations,this.getMutationDefaults(r==null?void 0:r.mutationKey),r,{_defaulted:!0})},t.clear=function(){this.queryCache.clear(),this.mutationCache.clear()},e}(),e$e=function(e){wc(t,e);function t(r,o){var a;return a=e.call(this)||this,a.client=r,a.options=o,a.trackedProps=[],a.selectError=null,a.bindMethods(),a.setOptions(o),a}var n=t.prototype;return n.bindMethods=function(){this.remove=this.remove.bind(this),this.refetch=this.refetch.bind(this)},n.onSubscribe=function(){this.listeners.length===1&&(this.currentQuery.addObserver(this),YT(this.currentQuery,this.options)&&this.executeFetch(),this.updateTimers())},n.onUnsubscribe=function(){this.listeners.length||this.destroy()},n.shouldFetchOnReconnect=function(){return K5(this.currentQuery,this.options,this.options.refetchOnReconnect)},n.shouldFetchOnWindowFocus=function(){return K5(this.currentQuery,this.options,this.options.refetchOnWindowFocus)},n.destroy=function(){this.listeners=[],this.clearTimers(),this.currentQuery.removeObserver(this)},n.setOptions=function(o,a){var i=this.options,c=this.currentQuery;if(this.options=this.client.defaultQueryObserverOptions(o),typeof this.options.enabled<"u"&&typeof this.options.enabled!="boolean")throw new Error("Expected enabled to be a boolean");this.options.queryKey||(this.options.queryKey=i.queryKey),this.updateQuery();var l=this.hasListeners();l&&XT(this.currentQuery,c,this.options,i)&&this.executeFetch(),this.updateResult(a),l&&(this.currentQuery!==c||this.options.enabled!==i.enabled||this.options.staleTime!==i.staleTime)&&this.updateStaleTimeout();var s=this.computeRefetchInterval();l&&(this.currentQuery!==c||this.options.enabled!==i.enabled||s!==this.currentRefetchInterval)&&this.updateRefetchInterval(s)},n.getOptimisticResult=function(o){var a=this.client.defaultQueryObserverOptions(o),i=this.client.getQueryCache().build(this.client,a);return this.createResult(i,a)},n.getCurrentResult=function(){return this.currentResult},n.trackResult=function(o,a){var i=this,c={},l=function(d){i.trackedProps.includes(d)||i.trackedProps.push(d)};return Object.keys(o).forEach(function(s){Object.defineProperty(c,s,{configurable:!1,enumerable:!0,get:function(){return l(s),o[s]}})}),(a.useErrorBoundary||a.suspense)&&l("error"),c},n.getNextResult=function(o){var a=this;return new Promise(function(i,c){var l=a.subscribe(function(s){s.isFetching||(l(),s.isError&&(o!=null&&o.throwOnError)?c(s.error):i(s))})})},n.getCurrentQuery=function(){return this.currentQuery},n.remove=function(){this.client.getQueryCache().remove(this.currentQuery)},n.refetch=function(o){return this.fetch(le({},o,{meta:{refetchPage:o==null?void 0:o.refetchPage}}))},n.fetchOptimistic=function(o){var a=this,i=this.client.defaultQueryObserverOptions(o),c=this.client.getQueryCache().build(this.client,i);return c.fetch().then(function(){return a.createResult(c,i)})},n.fetch=function(o){var a=this;return this.executeFetch(o).then(function(){return a.updateResult(),a.currentResult})},n.executeFetch=function(o){this.updateQuery();var a=this.currentQuery.fetch(this.options,o);return o!=null&&o.throwOnError||(a=a.catch(lr)),a},n.updateStaleTimeout=function(){var o=this;if(this.clearStaleTimeout(),!(a3||this.currentResult.isStale||!V5(this.options.staleTime))){var a=kT(this.currentResult.dataUpdatedAt,this.options.staleTime),i=a+1;this.staleTimeoutId=setTimeout(function(){o.currentResult.isStale||o.updateResult()},i)}},n.computeRefetchInterval=function(){var o;return typeof this.options.refetchInterval=="function"?this.options.refetchInterval(this.currentResult.data,this.currentQuery):(o=this.options.refetchInterval)!=null?o:!1},n.updateRefetchInterval=function(o){var a=this;this.clearRefetchInterval(),this.currentRefetchInterval=o,!(a3||this.options.enabled===!1||!V5(this.currentRefetchInterval)||this.currentRefetchInterval===0)&&(this.refetchIntervalId=setInterval(function(){(a.options.refetchIntervalInBackground||zc.isFocused())&&a.executeFetch()},this.currentRefetchInterval))},n.updateTimers=function(){this.updateStaleTimeout(),this.updateRefetchInterval(this.computeRefetchInterval())},n.clearTimers=function(){this.clearStaleTimeout(),this.clearRefetchInterval()},n.clearStaleTimeout=function(){this.staleTimeoutId&&(clearTimeout(this.staleTimeoutId),this.staleTimeoutId=void 0)},n.clearRefetchInterval=function(){this.refetchIntervalId&&(clearInterval(this.refetchIntervalId),this.refetchIntervalId=void 0)},n.createResult=function(o,a){var i=this.currentQuery,c=this.options,l=this.currentResult,s=this.currentResultState,d=this.currentResultOptions,f=o!==i,m=f?o.state:this.currentQueryInitialState,p=f?this.currentResult:this.previousQueryResult,h=o.state,v=h.dataUpdatedAt,g=h.error,y=h.errorUpdatedAt,b=h.isFetching,C=h.status,x=!1,S=!1,E;if(a.optimisticResults){var L=this.hasListeners(),w=!L&&YT(o,a),M=L&&XT(o,i,a,c);(w||M)&&(b=!0,v||(C="loading"))}if(a.keepPreviousData&&!h.dataUpdateCount&&(p!=null&&p.isSuccess)&&C!=="error")E=p.data,v=p.dataUpdatedAt,C=p.status,x=!0;else if(a.select&&typeof h.data<"u")if(l&&h.data===(s==null?void 0:s.data)&&a.select===this.selectFn)E=this.selectResult;else try{this.selectFn=a.select,E=a.select(h.data),a.structuralSharing!==!1&&(E=s3(l==null?void 0:l.data,E)),this.selectResult=E,this.selectError=null}catch(D){p3().error(D),this.selectError=D}else E=h.data;if(typeof a.placeholderData<"u"&&typeof E>"u"&&(C==="loading"||C==="idle")){var z;if(l!=null&&l.isPlaceholderData&&a.placeholderData===(d==null?void 0:d.placeholderData))z=l.data;else if(z=typeof a.placeholderData=="function"?a.placeholderData():a.placeholderData,a.select&&typeof z<"u")try{z=a.select(z),a.structuralSharing!==!1&&(z=s3(l==null?void 0:l.data,z)),this.selectError=null}catch(D){p3().error(D),this.selectError=D}typeof z<"u"&&(C="success",E=z,S=!0)}this.selectError&&(g=this.selectError,E=this.selectResult,y=Date.now(),C="error");var P={status:C,isLoading:C==="loading",isSuccess:C==="success",isError:C==="error",isIdle:C==="idle",data:E,dataUpdatedAt:v,error:g,errorUpdatedAt:y,failureCount:h.fetchFailureCount,errorUpdateCount:h.errorUpdateCount,isFetched:h.dataUpdateCount>0||h.errorUpdateCount>0,isFetchedAfterMount:h.dataUpdateCount>m.dataUpdateCount||h.errorUpdateCount>m.errorUpdateCount,isFetching:b,isRefetching:b&&C!=="loading",isLoadingError:C==="error"&&h.dataUpdatedAt===0,isPlaceholderData:S,isPreviousData:x,isRefetchError:C==="error"&&h.dataUpdatedAt!==0,isStale:q5(o,a),refetch:this.refetch,remove:this.remove};return P},n.shouldNotifyListeners=function(o,a){if(!a)return!0;var i=this.options,c=i.notifyOnChangeProps,l=i.notifyOnChangePropsExclusions;if(!c&&!l||c==="tracked"&&!this.trackedProps.length)return!0;var s=c==="tracked"?this.trackedProps:c;return Object.keys(o).some(function(d){var f=d,m=o[f]!==a[f],p=s==null?void 0:s.some(function(v){return v===d}),h=l==null?void 0:l.some(function(v){return v===d});return m&&!h&&(!s||p)})},n.updateResult=function(o){var a=this.currentResult;if(this.currentResult=this.createResult(this.currentQuery,this.options),this.currentResultState=this.currentQuery.state,this.currentResultOptions=this.options,!kOe(this.currentResult,a)){var i={cache:!0};(o==null?void 0:o.listeners)!==!1&&this.shouldNotifyListeners(this.currentResult,a)&&(i.listeners=!0),this.notify(le({},i,o))}},n.updateQuery=function(){var o=this.client.getQueryCache().build(this.client,this.options);if(o!==this.currentQuery){var a=this.currentQuery;this.currentQuery=o,this.currentQueryInitialState=o.state,this.previousQueryResult=this.currentResult,this.hasListeners()&&(a==null||a.removeObserver(this),o.addObserver(this))}},n.onQueryUpdate=function(o){var a={};o.type==="success"?a.onSuccess=!0:o.type==="error"&&!m3(o.error)&&(a.onError=!0),this.updateResult(a),this.hasListeners()&&this.updateTimers()},n.notify=function(o){var a=this;wn.batch(function(){o.onSuccess?(a.options.onSuccess==null||a.options.onSuccess(a.currentResult.data),a.options.onSettled==null||a.options.onSettled(a.currentResult.data,null)):o.onError&&(a.options.onError==null||a.options.onError(a.currentResult.error),a.options.onSettled==null||a.options.onSettled(void 0,a.currentResult.error)),o.listeners&&a.listeners.forEach(function(i){i(a.currentResult)}),o.cache&&a.client.getQueryCache().notify({query:a.currentQuery,type:"observerResultsUpdated"})})},t}(Mc);function t$e(e,t){return t.enabled!==!1&&!e.state.dataUpdatedAt&&!(e.state.status==="error"&&t.retryOnMount===!1)}function YT(e,t){return t$e(e,t)||e.state.dataUpdatedAt>0&&K5(e,t,t.refetchOnMount)}function K5(e,t,n){if(t.enabled!==!1){var r=typeof n=="function"?n(e):n;return r==="always"||r!==!1&&q5(e,t)}return!1}function XT(e,t,n,r){return n.enabled!==!1&&(e!==t||r.enabled===!1)&&(!n.suspense||e.state.status!=="error")&&q5(e,n)}function q5(e,t){return e.isStaleByTime(t.staleTime)}var n$e=Tn.unstable_batchedUpdates;wn.setBatchNotifyFunction(n$e);var r$e=console;WOe(r$e);var QT=O.createContext(void 0),JT=O.createContext(!1);function ZT(e){return e&&typeof window<"u"?(window.ReactQueryClientContext||(window.ReactQueryClientContext=QT),window.ReactQueryClientContext):QT}var o$e=function(){var t=O.useContext(ZT(O.useContext(JT)));if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},eR=function(t){var n=t.client,r=t.contextSharing,o=r===void 0?!1:r,a=t.children;O.useEffect(function(){return n.mount(),function(){n.unmount()}},[n]);var i=ZT(o);return O.createElement(JT.Provider,{value:o},O.createElement(i.Provider,{value:n},a))};function a$e(){var e=!1;return{clearReset:function(){e=!1},reset:function(){e=!0},isReset:function(){return e}}}var i$e=O.createContext(a$e()),c$e=function(){return O.useContext(i$e)};function l$e(e,t,n){return typeof t=="function"?t.apply(void 0,n):typeof t=="boolean"?t:!!e}function s$e(e,t){var n=O.useRef(!1),r=O.useState(0),o=r[1],a=o$e(),i=c$e(),c=a.defaultQueryObserverOptions(e);c.optimisticResults=!0,c.onError&&(c.onError=wn.batchCalls(c.onError)),c.onSuccess&&(c.onSuccess=wn.batchCalls(c.onSuccess)),c.onSettled&&(c.onSettled=wn.batchCalls(c.onSettled)),c.suspense&&(typeof c.staleTime!="number"&&(c.staleTime=1e3),c.cacheTime===0&&(c.cacheTime=1)),(c.suspense||c.useErrorBoundary)&&(i.isReset()||(c.retryOnMount=!1));var l=O.useState(function(){return new t(a,c)}),s=l[0],d=s.getOptimisticResult(c);if(O.useEffect(function(){n.current=!0,i.clearReset();var f=s.subscribe(wn.batchCalls(function(){n.current&&o(function(m){return m+1})}));return s.updateResult(),function(){n.current=!1,f()}},[i,s]),O.useEffect(function(){s.setOptions(c,{listeners:!1})},[c,s]),c.suspense&&d.isLoading)throw s.fetchOptimistic(c).then(function(f){var m=f.data;c.onSuccess==null||c.onSuccess(m),c.onSettled==null||c.onSettled(m,null)}).catch(function(f){i.clearReset(),c.onError==null||c.onError(f),c.onSettled==null||c.onSettled(void 0,f)});if(d.isError&&!i.isReset()&&!d.isFetching&&l$e(c.suspense,c.useErrorBoundary,[d.error,s.getCurrentQuery()]))throw d.error;return c.notifyOnChangeProps==="tracked"&&(d=s.trackResult(d,c)),d}function tR(e,t,n){var r=c3(e,t,n);return s$e(r,e$e)}var Ut=(e=>(e.App="idApp",e.Version="version",e.DeployDate="releaseDate",e.ReleasePages="gaReleasePages",e.Fields="gaReleasePagesContent",e.Title="title",e.Description="description",e.Image="idFile",e.Order="order",e.NoImage="noImage",e))(Ut||{}),G5=(e=>(e.GetApps="GetApps",e.GetReleases="GetReleases",e))(G5||{});const u$e=async()=>{const e=window.globalAuthUrl,{data:t}=await ho.get(`${e}/getApps`);return t},d$e=async e=>{const t=window.globalAuthUrl,{data:n}=await ho.post(`${t}/ListReleases`,e);return n},f$e=async e=>{const t=window.globalAuthUrl,{data:n}=await ho.post(`${t}/MaintainReleases`,e);return n},m$e=async(e,t)=>{const n=window.globalAuthUrl,{data:r}=await ho.post(`${n}/ReadNotification`,{idRelease:e,userId:t});return r},nR=()=>tR([G5.GetApps],async()=>await u$e()),p$e=e=>{const{idApp:t,userId:n,lastDeployed:r}=e;return tR([G5.GetReleases,t,n,r],async()=>await d$e(e),{enabled:!!t})},g$e=({index:e})=>{const{requiredField:t}=Td();return Me.jsx(cn.List,{name:[e,Ut.Fields],children:(n,{remove:r})=>Me.jsxs(Me.Fragment,{children:[Me.jsx(j0,{fieldName:"idReleasePage",hidden:!0}),Me.jsx(p1,{gap:16,vertical:!0,children:n.map(({key:o,name:a,...i})=>Me.jsxs(p1,{gap:6,align:"center",children:[Me.jsxs(p1,{vertical:!0,gap:2,style:{width:"100%"},children:[Me.jsx(cn.Item,{...i,name:[a,Ut.Title],rules:t,noStyle:!0,children:Me.jsx(w1,{placeholder:It("RELEASE-NOTES.FORM.FIELDS.TITLE"),maxLength:500})}),Me.jsx(cn.Item,{...i,name:[a,Ut.Description],rules:t,noStyle:!0,children:Me.jsx(h8,{autoSize:{minRows:2},placeholder:It("RELEASE-NOTES.FORM.FIELDS.DESCRIPTION")})})]}),Me.jsx(cn.Item,{noStyle:!0,children:Me.jsx(mr,{title:It("GENERAL.REMOVE"),children:Me.jsx(mn,{type:"text",icon:Me.jsx(yS,{}),onClick:()=>r(a),disabled:n.length===1})})})]},o))})]})})},h$e=O.forwardRef(({changeSlide:e},t)=>{const[n,r]=O.useState([]),o=cn.useFormInstance(),a=cn.useWatch(Ut.ReleasePages,o),i=s=>({file:d,fileList:f})=>{const m=s[0],p=s[1],h=a[m];r(f),Z2e(d.originFileObj,v=>{o.setFieldValue(Ut.ReleasePages,a.toSpliced(m,1,{...h,[p]:v}))})},c=s=>()=>{var p;const d=a==null?void 0:a[s],m=[...((p=a==null?void 0:a[s])==null?void 0:p[Ut.Fields])??[],{}];o.setFieldValue(Ut.ReleasePages,a.toSpliced(s,1,{...d,[Ut.Fields]:m}))},l=Me.jsx(L1,{justify:"center",align:"middle",children:Me.jsxs(Ms,{direction:"vertical",children:[Me.jsx("p",{className:"ant-upload-drag-icon",children:Me.jsx(_8,{})}),Me.jsx("p",{className:"ant-upload-text",children:It("GENERAL.UPLOAD_LABEL")}),Me.jsx("p",{className:"ant-upload-hint",children:It("GENERAL.JPG_PNG_WARNING")})]})});return Me.jsx(cn.List,{name:Ut.ReleasePages,children:s=>Me.jsxs(Me.Fragment,{children:[Me.jsx(j0,{fieldName:"idRelease",hidden:!0}),Me.jsx(j0,{fieldName:"idReleasePage",hidden:!0}),Me.jsx(t8,{infinite:!1,ref:t,afterChange:e,children:s.map(({key:d,name:f,...m})=>{var v,g;const p=(v=a==null?void 0:a[f])==null?void 0:v[Ut.Image],h=(g=a==null?void 0:a[f])==null?void 0:g[Ut.NoImage];return Me.jsx("div",{children:Me.jsxs(L1,{gutter:[8,16],style:{marginBottom:35},children:[Me.jsx(cr,{span:24,children:Me.jsxs(L1,{gutter:8,children:[Me.jsx(cr,{span:h?24:12,children:Me.jsx(g$e,{index:f})}),!h&&Me.jsx(cr,{span:12,children:Me.jsx(eo,{bordered:!0,styles:{body:{display:"flex",justifyContent:"center",padding:2}},children:Me.jsx(cn.Item,{...m,name:[f,Ut.Image],noStyle:!0,children:Me.jsx(wd,{listType:"picture",className:"release-notes-image",showUploadList:!1,fileList:n,beforeUpload:eoe,onChange:i([f,Ut.Image]),children:p?Me.jsx(Is,{src:p,preview:!1,style:{maxHeight:600}}):l})})})})]})}),Me.jsx(cr,{span:8,children:Me.jsxs(p1,{vertical:!0,children:[Me.jsx(cn.Item,{children:Me.jsx(mn,{type:"dashed",onClick:c(f),icon:Me.jsx(Hu,{}),block:!0,children:It("RELEASE-NOTES.FORM.ADD_NEW_FIELD")})}),Me.jsx(pze,{fieldName:[f,Ut.NoImage],label:It("GENERAL.DO_NOT_USE_IMAGE")})]})})]})},d)})})]})})}),a2="RELEASE-NOTES",v$e=({addBtnLabel:e,addBtnTooltipText:t,release2edit:n,beforeOpenModal:r,beforeCloseModal:o,afterSubmit:a})=>{const[i,c]=O.useState(!1),[l,s]=O.useState(!1),[d,f]=O.useState(0),[m]=cn.useForm(),p=ec(),{getColor:h}=Koe(),v=O.useRef(null),{requiredField:g}=Td(),{data:y}=nR(),b=cn.useWatch(Ut.ReleasePages,m),C=I=>f(I),x=()=>m.resetFields();O.useEffect(()=>{var k;const I=(b==null?void 0:b.length)-1;(k=v.current)==null||k.goTo(I)},[b==null?void 0:b.length]),O.useEffect(()=>(n&&(c(!0),m.setFieldsValue({...n,[Ut.ReleasePages]:n[Ut.ReleasePages].map(I=>({...I,[Ut.Image]:qx(I[Ut.Image])})),[Ut.DeployDate]:Yn(n[Ut.DeployDate])})),()=>{x()}),[n]);const S=()=>{r?new Promise(I=>I(r())).then(()=>c(!0)):c(!0)},E=()=>{o?new Promise(I=>I(o())).then(()=>c(!1)):c(!1)},L=()=>m.setFieldValue(Ut.ReleasePages,[...b,{[Ut.Fields]:[{}]}]),w=()=>m.setFieldValue(Ut.ReleasePages,b.filter((I,k)=>k!==d)),M=I=>{const k={...I,[Ut.DeployDate]:Yn(I[Ut.DeployDate]).format(cD),[Ut.ReleasePages]:I[Ut.ReleasePages].map((_,F)=>({..._,[Ut.Image]:toe(_[Ut.Image]),order:F,[Ut.Fields]:_[Ut.Fields].map((V,j)=>({...V,order:j}))}))};f$e(k).then(()=>{x(),As.success(It("GENERAL.MESSAGES.SUCCESS.ITEM_CREATE",{item:It(`${a2}.TEXT_SINGULAR`)})),a&&a()}).catch(_=>{var V;const F=((V=_.response)==null?void 0:V.data)??[];Fs.error({message:It("GENERAL.ERROR"),description:Me.jsx(T8,{dataSource:F,renderItem:j=>Me.jsx(T8.Item,{children:It(`GENERAL.MESSAGES.ERROR.RELEASE_NOTE.${j.error}`)})})})}).finally(E)},z=()=>!!(b!=null&&b.length)&&d!==0,P=()=>!!(b!=null&&b.length)&&d!==(b==null?void 0:b.length)-1,D=()=>(b==null?void 0:b.length)>1,A=Me.jsxs(p1,{justify:"flex-end",gap:8,children:[z()&&Me.jsx(mn,{type:"dashed",icon:Me.jsx(A1,{icon:q$}),onClick:()=>{var I;return(I=v.current)==null?void 0:I.prev()},children:It("GENERAL.BACK")}),P()&&Me.jsx(mn,{type:"dashed",iconPosition:"end",icon:Me.jsx(A1,{icon:G$}),onClick:()=>{var I;return(I=v.current)==null?void 0:I.next()},children:It("GENERAL.NEXT")}),D()&&Me.jsx(mn,{type:"dashed",danger:!0,icon:Me.jsx(A1,{icon:GN}),onClick:w,children:It(`${a2}.REMOVE_CURRENT_SLIDE`)}),Me.jsx(mn,{type:"dashed",icon:Me.jsx(A1,{icon:LP}),onClick:L,children:It(`${a2}.ADD_NEW_SLIDE`)}),Me.jsx(mn,{type:"primary",icon:Me.jsx(A1,{icon:DN}),onClick:()=>m.submit(),children:It("GENERAL.SAVE")})]}),$=I=>{s(t?I:!1)},T={[Ut.ReleasePages]:[{[Ut.Fields]:[{}]}],[Ut.DeployDate]:Yn()},R=noe(y??[],"appName","id"),N=O.useMemo(()=>It(`${a2}.${n?"UPD_RELEASE_NOTE":"ADD_RELEASE_NOTE"}`),[p]);return Me.jsxs(Me.Fragment,{children:[Me.jsx(mr,{title:t,open:l,onOpenChange:$,children:Me.jsx(mn,{type:"primary",icon:Me.jsx(A1,{icon:Hz}),shape:e?"default":"circle",onClick:S,children:e})}),Me.jsx(Tr,{open:i,title:N,onCancel:E,width:"60%",footer:A,destroyOnClose:!0,children:Me.jsxs(cn,{form:m,layout:"vertical",initialValues:T,onFinish:M,children:[Me.jsx(j0,{fieldName:"idRelease",hidden:!0}),Me.jsxs(L1,{gutter:10,children:[Me.jsx(cr,{span:8,children:Me.jsx(fze,{fieldName:Ut.App,label:It(`${a2}.FORM.FIELDS.APP`),placeholder:It(`${a2}.FORM.FIELDS.APP`,{context:"PLACEHOLDER"}),options:R,rules:g})}),Me.jsx(cr,{span:8,children:Me.jsx(F0,{fieldName:Ut.Version,label:It(`${a2}.FORM.FIELDS.VERSION`),placeholder:"0.0.0",tooltip:It(`${a2}.FORM.FIELDS.VERSION`,{context:"TOOLTIP"}),normalize:I=>I.replace(/\s/,".").replace(/[.]{2}/g,".").replace(/^[^0-9]|[^0-9.\b]/g,""),rules:[...g,()=>({validator(I,k){var V,j;const _=/[^0-9]$/,F=(j=(V=k==null?void 0:k.split("."))==null?void 0:V.filter(Boolean))==null?void 0:j.length;return _.test(k)?Promise.reject(new Error(It("GENERAL.FORM.ERRORS.VERSION"))):F>3||F<3?Promise.reject(new Error(It("GENERAL.FORM.ERRORS.FORMAT"))):Promise.resolve()}})]})}),Me.jsx(cr,{span:8,children:Me.jsx(mze,{fieldName:Ut.DeployDate,label:It(`${a2}.FORM.FIELDS.DEPLOY_DATE`),format:iD,rules:g})}),Me.jsx(cr,{span:24,children:Me.jsx(eo,{styles:{body:{background:h("PrimaryColorBgContainer")}},children:Me.jsx(h$e,{ref:v,changeSlide:C})})})]})]})})]})},{Title:b$e,Text:y$e}=Sa,C$e=()=>{var L,w;const[e,t]=O.useState(!1),[n,r]=O.useState(!1),[o,a]=O.useState(0),i=ec(),c=O.useRef(null),l=xa(k1.AppId),s=xa(k1.UserId),{data:d}=nR(),{data:f}=p$e({idApp:l,lastDeployed:!0,userId:s}),m=f==null?void 0:f[0],p=d==null?void 0:d.find(M=>M.id===l);O.useEffect(()=>{if(f!=null&&f.length){const M=f[0],z=!M.readRelease&&!!M.isDeployed;t(z)}},[f]);const h=()=>{const M=f==null?void 0:f[0];n&&(M!=null&&M.isDeployed)&&m$e(M==null?void 0:M.idRelease,s),t(!1)},v=()=>{var M;return(M=c.current)==null?void 0:M.next()},g=()=>{var M;return(M=c.current)==null?void 0:M.prev()},y=M=>a(M),b=o===0,C=o===(((L=m==null?void 0:m.gaReleasePages)==null?void 0:L.length)??0)-1,x=M=>r(M.target.checked),S=Me.jsxs(p1,{justify:"space-between",align:"center",children:[Me.jsx(Z1,{checked:n,onChange:x,children:It("RELEASE-NOTES.FORM.FIELDS.DO_NOT_SHOW_AGAIN")}),Me.jsxs(p1,{gap:8,children:[!b&&Me.jsx(mn,{onClick:g,children:It("Prev")}),!C&&Me.jsx(mn,{type:"primary",onClick:v,children:It("GENERAL.ACTIONS.NEXT")}),C&&Me.jsx(mn,{type:"primary",onClick:h,children:It("GENERAL.ACTIONS.CLOSE")})]})]}),E=O.useMemo(()=>It("RELEASE-NOTES.WHATS_NEWS",{app:p==null?void 0:p.appName,version:m==null?void 0:m.version}),[i]);return Me.jsx(Tr,{open:e,title:E,onCancel:h,width:"70%",footer:S,children:Me.jsx(t8,{infinite:!1,ref:c,afterChange:y,children:(w=m==null?void 0:m.gaReleasePages)==null?void 0:w.map(({idFile:M,gaReleasePagesContent:z},P)=>Me.jsx("div",{children:Me.jsxs(L1,{gutter:[16,16],style:{marginBottom:35},children:[Me.jsx(cr,{span:M?12:24,children:Me.jsx(p1,{gap:16,vertical:!0,children:z.map(({title:D,description:A},$)=>Me.jsxs(p1,{vertical:!0,children:[Me.jsx(b$e,{level:5,children:D}),Me.jsx(y$e,{style:{opacity:.5},children:A})]},`${P}-${$}`))})}),!!M&&Me.jsx(cr,{span:12,children:Me.jsx(p1,{justify:"center",children:Me.jsx(eo,{bordered:!0,styles:{body:{display:"flex",justifyContent:"center",padding:2}},children:Me.jsx(Is,{src:qx(M),style:{maxHeight:600,borderRadius:8}})})})})]})},P))})})},rR=new ZOe({defaultOptions:{queries:{retry:2}}}),S$e=ROe(({showAddBtn:e,...t})=>e?Me.jsx(Nd,{children:Me.jsx(eR,{client:rR,children:Me.jsx(v$e,{...t})})}):Me.jsx(Nd,{children:Me.jsx(eR,{client:rR,children:Me.jsx(C$e,{})})}));ur.Helpdesk=WNe,ur.ReleaseNote=S$e,Object.defineProperty(ur,Symbol.toStringTag,{value:"Module"})});
|
|
1075
|
+
\`createSelector([state => state.todos.map(todo => todo.id)], todoIds => todoIds.length)\``,{arguments:n,firstInputs:a,secondInputs:i,stack:s})}},iOe={inputStabilityCheck:"once",identityFunctionCheck:"once"};function cOe(e,t=`expected a function, instead received ${typeof e}`){if(typeof e!="function")throw new TypeError(t)}function lOe(e,t=`expected an object, instead received ${typeof e}`){if(typeof e!="object")throw new TypeError(t)}function sOe(e,t="expected all items to be functions, instead received the following types: "){if(!e.every(n=>typeof n=="function")){const n=e.map(r=>typeof r=="function"?`function ${r.name||"unnamed"}()`:typeof r).join(", ");throw new TypeError(`${t}[${n}]`)}}var $T=e=>Array.isArray(e)?e:[e];function uOe(e){const t=Array.isArray(e[0])?e[0]:e;return sOe(t,"createSelector expects all input-selectors to be functions, but received the following types: "),t}function PT(e,t){const n=[],{length:r}=e;for(let o=0;o<r;o++)n.push(e[o].apply(null,t));return n}var dOe=(e,t)=>{const{identityFunctionCheck:n,inputStabilityCheck:r}={...iOe,...t};return{identityFunctionCheck:{shouldRun:n==="always"||n==="once"&&e,run:oOe},inputStabilityCheck:{shouldRun:r==="always"||r==="once"&&e,run:aOe}}},fOe=class{constructor(e){this.value=e}deref(){return this.value}},mOe=typeof WeakRef<"u"?WeakRef:fOe,pOe=0,IT=1;function r3(){return{s:pOe,v:void 0,o:null,p:null}}function TT(e,t={}){let n=r3();const{resultEqualityCheck:r}=t;let o,a=0;function i(){var f;let c=n;const{length:l}=arguments;for(let m=0,p=l;m<p;m++){const h=arguments[m];if(typeof h=="function"||typeof h=="object"&&h!==null){let v=c.o;v===null&&(c.o=v=new WeakMap);const g=v.get(h);g===void 0?(c=r3(),v.set(h,c)):c=g}else{let v=c.p;v===null&&(c.p=v=new Map);const g=v.get(h);g===void 0?(c=r3(),v.set(h,c)):c=g}}const s=c;let d;if(c.s===IT)d=c.v;else if(d=e.apply(null,arguments),a++,r){const m=((f=o==null?void 0:o.deref)==null?void 0:f.call(o))??o;m!=null&&r(m,d)&&(d=m,a!==0&&a--),o=typeof d=="object"&&d!==null||typeof d=="function"?new mOe(d):d}return s.s=IT,s.v=d,d}return i.clearCache=()=>{n=r3(),i.resetResultsCount()},i.resultsCount=()=>a,i.resetResultsCount=()=>{a=0},i}function gOe(e,...t){const n=typeof e=="function"?{memoize:e,memoizeOptions:t}:e,r=(...o)=>{let a=0,i=0,c,l={},s=o.pop();typeof s=="object"&&(l=s,s=o.pop()),cOe(s,`createSelector expects an output function after the inputs, but received: [${typeof s}]`);const d={...n,...l},{memoize:f,memoizeOptions:m=[],argsMemoize:p=TT,argsMemoizeOptions:h=[],devModeChecks:v={}}=d,g=$T(m),y=$T(h),b=uOe(o),C=f(function(){return a++,s.apply(null,arguments)},...g);let x=!0;const S=p(function(){i++;const L=PT(b,arguments);if(c=C.apply(null,L),process.env.NODE_ENV!=="production"){const{identityFunctionCheck:w,inputStabilityCheck:M}=dOe(x,v);if(w.shouldRun&&w.run(s,L,c),M.shouldRun){const z=PT(b,arguments);M.run({inputSelectorResults:L,inputSelectorResultsCopy:z},{memoize:f,memoizeOptions:g},arguments)}x&&(x=!1)}return c},...y);return Object.assign(S,{resultFunc:s,memoizedResultFunc:C,dependencies:b,dependencyRecomputations:()=>i,resetDependencyRecomputations:()=>{i=0},lastResult:()=>c,recomputations:()=>a,resetRecomputations:()=>{a=0},memoize:f,argsMemoize:p})};return Object.assign(r,{withTypes:()=>r}),r}var hOe=gOe(TT),vOe=Object.assign((e,t=hOe)=>{lOe(e,`createStructuredSelector expects first argument to be an object where each property is a selector, instead received a ${typeof e}`);const n=Object.keys(e),r=n.map(a=>e[a]);return t(r,(...a)=>a.reduce((i,c,l)=>(i[n[l]]=c,i),{}))},{withTypes:()=>vOe});function RT(e,t){function n(...r){if(t){let o=t(...r);if(!o)throw new Error(process.env.NODE_ENV==="production"?tr(0):"prepareAction did not return an object");return{type:e,payload:o.payload,..."meta"in o&&{meta:o.meta},..."error"in o&&{error:o.error}}}return{type:e,payload:r[0]}}return n.toString=()=>`${e}`,n.type=e,n.match=r=>KNe(r)&&r.type===e,n}function DT(e){return o2(e)?OT(e,()=>{}):e}function AT(e,t,n){if(e.has(t)){let o=e.get(t);return n.update&&(o=n.update(o,t,e),e.set(t,o)),o}if(!n.insert)throw new Error(process.env.NODE_ENV==="production"?tr(10):"No insert provided for key not already in map");const r=n.insert(t,e);return e.set(t,r),r}function _T(e){const t={},n=[];let r;const o={addCase(a,i){if(process.env.NODE_ENV!=="production"){if(n.length>0)throw new Error(process.env.NODE_ENV==="production"?tr(26):"`builder.addCase` should only be called before calling `builder.addMatcher`");if(r)throw new Error(process.env.NODE_ENV==="production"?tr(27):"`builder.addCase` should only be called before calling `builder.addDefaultCase`")}const c=typeof a=="string"?a:a.type;if(!c)throw new Error(process.env.NODE_ENV==="production"?tr(28):"`builder.addCase` cannot be called with an empty action type");if(c in t)throw new Error(process.env.NODE_ENV==="production"?tr(29):`\`builder.addCase\` cannot be called with two reducers for the same action type '${c}'`);return t[c]=i,o},addMatcher(a,i){if(process.env.NODE_ENV!=="production"&&r)throw new Error(process.env.NODE_ENV==="production"?tr(30):"`builder.addMatcher` should only be called before calling `builder.addDefaultCase`");return n.push({matcher:a,reducer:i}),o},addDefaultCase(a){if(process.env.NODE_ENV!=="production"&&r)throw new Error(process.env.NODE_ENV==="production"?tr(31):"`builder.addDefaultCase` can only be called once");return r=a,o}};return e(o),[t,n,r]}function bOe(e){return typeof e=="function"}function yOe(e,t){if(process.env.NODE_ENV!=="production"&&typeof t=="object")throw new Error(process.env.NODE_ENV==="production"?tr(8):"The object notation for `createReducer` has been removed. Please use the 'builder callback' notation instead: https://redux-toolkit.js.org/api/createReducer");let[n,r,o]=_T(t),a;if(bOe(e))a=()=>DT(e());else{const c=DT(e);a=()=>c}function i(c=a(),l){let s=[n[l.type],...r.filter(({matcher:d})=>d(l)).map(({reducer:d})=>d)];return s.filter(d=>!!d).length===0&&(s=[o]),s.reduce((d,f)=>{if(f)if(vo(d)){const p=f(d,l);return p===void 0?d:p}else{if(o2(d))return OT(d,m=>f(m,l));{const m=f(d,l);if(m===void 0){if(d===null)return d;throw Error("A case reducer on a non-draftable value must not return undefined")}return m}}return d},c)}return i.getInitialState=a,i}var COe=Symbol.for("rtk-slice-createasyncthunk");function SOe(e,t){return`${e}/${t}`}function xOe({creators:e}={}){var n;const t=(n=e==null?void 0:e.asyncThunk)==null?void 0:n[COe];return function(o){const{name:a,reducerPath:i=a}=o;if(!a)throw new Error(process.env.NODE_ENV==="production"?tr(11):"`name` is a required option for createSlice");typeof process<"u"&&process.env.NODE_ENV==="development"&&o.initialState===void 0&&console.error("You must provide an `initialState` value that is not `undefined`. You may have misspelled `initialState`");const c=(typeof o.reducers=="function"?o.reducers(wOe()):o.reducers)||{},l=Object.keys(c),s={sliceCaseReducersByName:{},sliceCaseReducersByType:{},actionCreators:{},sliceMatchers:[]},d={addCase(C,x){const S=typeof C=="string"?C:C.type;if(!S)throw new Error(process.env.NODE_ENV==="production"?tr(12):"`context.addCase` cannot be called with an empty action type");if(S in s.sliceCaseReducersByType)throw new Error(process.env.NODE_ENV==="production"?tr(13):"`context.addCase` cannot be called with two reducers for the same action type: "+S);return s.sliceCaseReducersByType[S]=x,d},addMatcher(C,x){return s.sliceMatchers.push({matcher:C,reducer:x}),d},exposeAction(C,x){return s.actionCreators[C]=x,d},exposeCaseReducer(C,x){return s.sliceCaseReducersByName[C]=x,d}};l.forEach(C=>{const x=c[C],S={reducerName:C,type:SOe(a,C),createNotation:typeof o.reducers=="function"};zOe(x)?OOe(S,x,d,t):MOe(S,x,d)});function f(){if(process.env.NODE_ENV!=="production"&&typeof o.extraReducers=="object")throw new Error(process.env.NODE_ENV==="production"?tr(14):"The object notation for `createSlice.extraReducers` has been removed. Please use the 'builder callback' notation instead: https://redux-toolkit.js.org/api/createSlice");const[C={},x=[],S=void 0]=typeof o.extraReducers=="function"?_T(o.extraReducers):[o.extraReducers],E={...C,...s.sliceCaseReducersByType};return yOe(o.initialState,L=>{for(let w in E)L.addCase(w,E[w]);for(let w of s.sliceMatchers)L.addMatcher(w.matcher,w.reducer);for(let w of x)L.addMatcher(w.matcher,w.reducer);S&&L.addDefaultCase(S)})}const m=C=>C,p=new Map;let h;function v(C,x){return h||(h=f()),h(C,x)}function g(){return h||(h=f()),h.getInitialState()}function y(C,x=!1){function S(L){let w=L[C];if(typeof w>"u"){if(x)w=g();else if(process.env.NODE_ENV!=="production")throw new Error(process.env.NODE_ENV==="production"?tr(15):"selectSlice returned undefined for an uninjected slice reducer")}return w}function E(L=m){const w=AT(p,x,{insert:()=>new WeakMap});return AT(w,L,{insert:()=>{const M={};for(const[z,P]of Object.entries(o.selectors??{}))M[z]=EOe(P,L,g,x);return M}})}return{reducerPath:C,getSelectors:E,get selectors(){return E(S)},selectSlice:S}}const b={name:a,reducer:v,actions:s.actionCreators,caseReducers:s.sliceCaseReducersByName,getInitialState:g,...y(i),injectInto(C,{reducerPath:x,...S}={}){const E=x??i;return C.inject({reducerPath:E,reducer:v},S),{...b,...y(E,!0)}}};return b}}function EOe(e,t,n,r){function o(a,...i){let c=t(a);if(typeof c>"u"){if(r)c=n();else if(process.env.NODE_ENV!=="production")throw new Error(process.env.NODE_ENV==="production"?tr(16):"selectState returned undefined for an uninjected slice reducer")}return e(c,...i)}return o.unwrapped=e,o}var LOe=xOe();function wOe(){function e(t,n){return{_reducerDefinitionType:"asyncThunk",payloadCreator:t,...n}}return e.withTypes=()=>e,{reducer(t){return Object.assign({[t.name](...n){return t(...n)}}[t.name],{_reducerDefinitionType:"reducer"})},preparedReducer(t,n){return{_reducerDefinitionType:"reducerWithPrepare",prepare:t,reducer:n}},asyncThunk:e}}function MOe({type:e,reducerName:t,createNotation:n},r,o){let a,i;if("reducer"in r){if(n&&!NOe(r))throw new Error(process.env.NODE_ENV==="production"?tr(17):"Please use the `create.preparedReducer` notation for prepared action creators with the `create` notation.");a=r.reducer,i=r.prepare}else a=r;o.addCase(e,a).exposeCaseReducer(t,a).exposeAction(t,i?RT(e,i):RT(e))}function zOe(e){return e._reducerDefinitionType==="asyncThunk"}function NOe(e){return e._reducerDefinitionType==="reducerWithPrepare"}function OOe({type:e,reducerName:t},n,r,o){if(!o)throw new Error(process.env.NODE_ENV==="production"?tr(18):"Cannot use `create.asyncThunk` in the built-in `createSlice`. Use `buildCreateSlice({ creators: { asyncThunk: asyncThunkCreator } })` to create a customised version of `createSlice`.");const{payloadCreator:a,fulfilled:i,pending:c,rejected:l,settled:s,options:d}=n,f=o(e,a,d);r.exposeAction(t,f),i&&r.addCase(f.fulfilled,i),c&&r.addCase(f.pending,c),l&&r.addCase(f.rejected,l),s&&r.addMatcher(f.settled,s),r.exposeCaseReducer(t,{fulfilled:i||o3,pending:c||o3,rejected:l||o3,settled:s||o3})}function o3(){}function tr(e){return`Minified Redux Toolkit error #${e}; visit https://redux-toolkit.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}const $Oe={theme:$c.Light},POe=LOe({name:"AppState",initialState:$Oe,reducers:{updTheme:(e,{payload:t})=>{e.theme=t},updLanguage:(e,{payload:t})=>{e.language=t}}}),{updTheme:IOe,updLanguage:TOe}=POe.actions;function ROe(e){const t=r=>{const{language:o,theme:a}=r,i=Voe();return O.useEffect(()=>{i(TOe(o)),Un.changeLanguage(o)},[o,r]),O.useEffect(()=>{i(IOe(a))},[a,r]),Me.jsx(e,{...r})};return z7(r=>{var o,a;return{language:(o=r==null?void 0:r.app)==null?void 0:o.language,theme:(a=r==null?void 0:r.app)==null?void 0:a.theme}})(t)}function wc(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,xo(e,t)}var Mc=function(){function e(){this.listeners=[]}var t=e.prototype;return t.subscribe=function(r){var o=this,a=r||function(){};return this.listeners.push(a),this.onSubscribe(),function(){o.listeners=o.listeners.filter(function(i){return i!==a}),o.onUnsubscribe()}},t.hasListeners=function(){return this.listeners.length>0},t.onSubscribe=function(){},t.onUnsubscribe=function(){},e}(),a3=typeof window>"u";function lr(){}function DOe(e,t){return typeof e=="function"?e(t):e}function V5(e){return typeof e=="number"&&e>=0&&e!==1/0}function i3(e){return Array.isArray(e)?e:[e]}function kT(e,t){return Math.max(e+(t||0)-Date.now(),0)}function c3(e,t,n){return u3(e)?typeof t=="function"?le({},n,{queryKey:e,queryFn:t}):le({},t,{queryKey:e}):e}function P2(e,t,n){return u3(e)?[le({},t,{queryKey:e}),n]:[e||{},t]}function AOe(e,t){if(e===!0&&t===!0||e==null&&t==null)return"all";if(e===!1&&t===!1)return"none";var n=e??!t;return n?"active":"inactive"}function FT(e,t){var n=e.active,r=e.exact,o=e.fetching,a=e.inactive,i=e.predicate,c=e.queryKey,l=e.stale;if(u3(c)){if(r){if(t.queryHash!==W5(c,t.options))return!1}else if(!l3(t.queryKey,c))return!1}var s=AOe(n,a);if(s==="none")return!1;if(s!=="all"){var d=t.isActive();if(s==="active"&&!d||s==="inactive"&&d)return!1}return!(typeof l=="boolean"&&t.isStale()!==l||typeof o=="boolean"&&t.isFetching()!==o||i&&!i(t))}function jT(e,t){var n=e.exact,r=e.fetching,o=e.predicate,a=e.mutationKey;if(u3(a)){if(!t.options.mutationKey)return!1;if(n){if(Co(t.options.mutationKey)!==Co(a))return!1}else if(!l3(t.options.mutationKey,a))return!1}return!(typeof r=="boolean"&&t.state.status==="loading"!==r||o&&!o(t))}function W5(e,t){var n=(t==null?void 0:t.queryKeyHashFn)||Co;return n(e)}function Co(e){var t=i3(e);return _Oe(t)}function _Oe(e){return JSON.stringify(e,function(t,n){return U5(n)?Object.keys(n).sort().reduce(function(r,o){return r[o]=n[o],r},{}):n})}function l3(e,t){return BT(i3(e),i3(t))}function BT(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?!Object.keys(t).some(function(n){return!BT(e[n],t[n])}):!1}function s3(e,t){if(e===t)return e;var n=Array.isArray(e)&&Array.isArray(t);if(n||U5(e)&&U5(t)){for(var r=n?e.length:Object.keys(e).length,o=n?t:Object.keys(t),a=o.length,i=n?[]:{},c=0,l=0;l<a;l++){var s=n?l:o[l];i[s]=s3(e[s],t[s]),i[s]===e[s]&&c++}return r===a&&c===r?e:i}return t}function kOe(e,t){if(e&&!t||t&&!e)return!1;for(var n in e)if(e[n]!==t[n])return!1;return!0}function U5(e){if(!HT(e))return!1;var t=e.constructor;if(typeof t>"u")return!0;var n=t.prototype;return!(!HT(n)||!n.hasOwnProperty("isPrototypeOf"))}function HT(e){return Object.prototype.toString.call(e)==="[object Object]"}function u3(e){return typeof e=="string"||Array.isArray(e)}function FOe(e){return new Promise(function(t){setTimeout(t,e)})}function VT(e){Promise.resolve().then(e).catch(function(t){return setTimeout(function(){throw t})})}function WT(){if(typeof AbortController=="function")return new AbortController}var jOe=function(e){wc(t,e);function t(){var r;return r=e.call(this)||this,r.setup=function(o){var a;if(!a3&&((a=window)!=null&&a.addEventListener)){var i=function(){return o()};return window.addEventListener("visibilitychange",i,!1),window.addEventListener("focus",i,!1),function(){window.removeEventListener("visibilitychange",i),window.removeEventListener("focus",i)}}},r}var n=t.prototype;return n.onSubscribe=function(){this.cleanup||this.setEventListener(this.setup)},n.onUnsubscribe=function(){if(!this.hasListeners()){var o;(o=this.cleanup)==null||o.call(this),this.cleanup=void 0}},n.setEventListener=function(o){var a,i=this;this.setup=o,(a=this.cleanup)==null||a.call(this),this.cleanup=o(function(c){typeof c=="boolean"?i.setFocused(c):i.onFocus()})},n.setFocused=function(o){this.focused=o,o&&this.onFocus()},n.onFocus=function(){this.listeners.forEach(function(o){o()})},n.isFocused=function(){return typeof this.focused=="boolean"?this.focused:typeof document>"u"?!0:[void 0,"visible","prerender"].includes(document.visibilityState)},t}(Mc),zc=new jOe,BOe=function(e){wc(t,e);function t(){var r;return r=e.call(this)||this,r.setup=function(o){var a;if(!a3&&((a=window)!=null&&a.addEventListener)){var i=function(){return o()};return window.addEventListener("online",i,!1),window.addEventListener("offline",i,!1),function(){window.removeEventListener("online",i),window.removeEventListener("offline",i)}}},r}var n=t.prototype;return n.onSubscribe=function(){this.cleanup||this.setEventListener(this.setup)},n.onUnsubscribe=function(){if(!this.hasListeners()){var o;(o=this.cleanup)==null||o.call(this),this.cleanup=void 0}},n.setEventListener=function(o){var a,i=this;this.setup=o,(a=this.cleanup)==null||a.call(this),this.cleanup=o(function(c){typeof c=="boolean"?i.setOnline(c):i.onOnline()})},n.setOnline=function(o){this.online=o,o&&this.onOnline()},n.onOnline=function(){this.listeners.forEach(function(o){o()})},n.isOnline=function(){return typeof this.online=="boolean"?this.online:typeof navigator>"u"||typeof navigator.onLine>"u"?!0:navigator.onLine},t}(Mc),d3=new BOe;function HOe(e){return Math.min(1e3*Math.pow(2,e),3e4)}function f3(e){return typeof(e==null?void 0:e.cancel)=="function"}var UT=function(t){this.revert=t==null?void 0:t.revert,this.silent=t==null?void 0:t.silent};function m3(e){return e instanceof UT}var KT=function(t){var n=this,r=!1,o,a,i,c;this.abort=t.abort,this.cancel=function(m){return o==null?void 0:o(m)},this.cancelRetry=function(){r=!0},this.continueRetry=function(){r=!1},this.continue=function(){return a==null?void 0:a()},this.failureCount=0,this.isPaused=!1,this.isResolved=!1,this.isTransportCancelable=!1,this.promise=new Promise(function(m,p){i=m,c=p});var l=function(p){n.isResolved||(n.isResolved=!0,t.onSuccess==null||t.onSuccess(p),a==null||a(),i(p))},s=function(p){n.isResolved||(n.isResolved=!0,t.onError==null||t.onError(p),a==null||a(),c(p))},d=function(){return new Promise(function(p){a=p,n.isPaused=!0,t.onPause==null||t.onPause()}).then(function(){a=void 0,n.isPaused=!1,t.onContinue==null||t.onContinue()})},f=function m(){if(!n.isResolved){var p;try{p=t.fn()}catch(h){p=Promise.reject(h)}o=function(v){if(!n.isResolved&&(s(new UT(v)),n.abort==null||n.abort(),f3(p)))try{p.cancel()}catch{}},n.isTransportCancelable=f3(p),Promise.resolve(p).then(l).catch(function(h){var v,g;if(!n.isResolved){var y=(v=t.retry)!=null?v:3,b=(g=t.retryDelay)!=null?g:HOe,C=typeof b=="function"?b(n.failureCount,h):b,x=y===!0||typeof y=="number"&&n.failureCount<y||typeof y=="function"&&y(n.failureCount,h);if(r||!x){s(h);return}n.failureCount++,t.onFail==null||t.onFail(n.failureCount,h),FOe(C).then(function(){if(!zc.isFocused()||!d3.isOnline())return d()}).then(function(){r?s(h):m()})}})}};f()},VOe=function(){function e(){this.queue=[],this.transactions=0,this.notifyFn=function(n){n()},this.batchNotifyFn=function(n){n()}}var t=e.prototype;return t.batch=function(r){var o;this.transactions++;try{o=r()}finally{this.transactions--,this.transactions||this.flush()}return o},t.schedule=function(r){var o=this;this.transactions?this.queue.push(r):VT(function(){o.notifyFn(r)})},t.batchCalls=function(r){var o=this;return function(){for(var a=arguments.length,i=new Array(a),c=0;c<a;c++)i[c]=arguments[c];o.schedule(function(){r.apply(void 0,i)})}},t.flush=function(){var r=this,o=this.queue;this.queue=[],o.length&&VT(function(){r.batchNotifyFn(function(){o.forEach(function(a){r.notifyFn(a)})})})},t.setNotifyFunction=function(r){this.notifyFn=r},t.setBatchNotifyFunction=function(r){this.batchNotifyFn=r},e}(),wn=new VOe,qT=console;function p3(){return qT}function WOe(e){qT=e}var UOe=function(){function e(n){this.abortSignalConsumed=!1,this.hadObservers=!1,this.defaultOptions=n.defaultOptions,this.setOptions(n.options),this.observers=[],this.cache=n.cache,this.queryKey=n.queryKey,this.queryHash=n.queryHash,this.initialState=n.state||this.getDefaultState(this.options),this.state=this.initialState,this.meta=n.meta,this.scheduleGc()}var t=e.prototype;return t.setOptions=function(r){var o;this.options=le({},this.defaultOptions,r),this.meta=r==null?void 0:r.meta,this.cacheTime=Math.max(this.cacheTime||0,(o=this.options.cacheTime)!=null?o:5*60*1e3)},t.setDefaultOptions=function(r){this.defaultOptions=r},t.scheduleGc=function(){var r=this;this.clearGcTimeout(),V5(this.cacheTime)&&(this.gcTimeout=setTimeout(function(){r.optionalRemove()},this.cacheTime))},t.clearGcTimeout=function(){this.gcTimeout&&(clearTimeout(this.gcTimeout),this.gcTimeout=void 0)},t.optionalRemove=function(){this.observers.length||(this.state.isFetching?this.hadObservers&&this.scheduleGc():this.cache.remove(this))},t.setData=function(r,o){var a,i,c=this.state.data,l=DOe(r,c);return(a=(i=this.options).isDataEqual)!=null&&a.call(i,c,l)?l=c:this.options.structuralSharing!==!1&&(l=s3(c,l)),this.dispatch({data:l,type:"success",dataUpdatedAt:o==null?void 0:o.updatedAt}),l},t.setState=function(r,o){this.dispatch({type:"setState",state:r,setStateOptions:o})},t.cancel=function(r){var o,a=this.promise;return(o=this.retryer)==null||o.cancel(r),a?a.then(lr).catch(lr):Promise.resolve()},t.destroy=function(){this.clearGcTimeout(),this.cancel({silent:!0})},t.reset=function(){this.destroy(),this.setState(this.initialState)},t.isActive=function(){return this.observers.some(function(r){return r.options.enabled!==!1})},t.isFetching=function(){return this.state.isFetching},t.isStale=function(){return this.state.isInvalidated||!this.state.dataUpdatedAt||this.observers.some(function(r){return r.getCurrentResult().isStale})},t.isStaleByTime=function(r){return r===void 0&&(r=0),this.state.isInvalidated||!this.state.dataUpdatedAt||!kT(this.state.dataUpdatedAt,r)},t.onFocus=function(){var r,o=this.observers.find(function(a){return a.shouldFetchOnWindowFocus()});o&&o.refetch(),(r=this.retryer)==null||r.continue()},t.onOnline=function(){var r,o=this.observers.find(function(a){return a.shouldFetchOnReconnect()});o&&o.refetch(),(r=this.retryer)==null||r.continue()},t.addObserver=function(r){this.observers.indexOf(r)===-1&&(this.observers.push(r),this.hadObservers=!0,this.clearGcTimeout(),this.cache.notify({type:"observerAdded",query:this,observer:r}))},t.removeObserver=function(r){this.observers.indexOf(r)!==-1&&(this.observers=this.observers.filter(function(o){return o!==r}),this.observers.length||(this.retryer&&(this.retryer.isTransportCancelable||this.abortSignalConsumed?this.retryer.cancel({revert:!0}):this.retryer.cancelRetry()),this.cacheTime?this.scheduleGc():this.cache.remove(this)),this.cache.notify({type:"observerRemoved",query:this,observer:r}))},t.getObserversCount=function(){return this.observers.length},t.invalidate=function(){this.state.isInvalidated||this.dispatch({type:"invalidate"})},t.fetch=function(r,o){var a=this,i,c,l;if(this.state.isFetching){if(this.state.dataUpdatedAt&&(o!=null&&o.cancelRefetch))this.cancel({silent:!0});else if(this.promise){var s;return(s=this.retryer)==null||s.continueRetry(),this.promise}}if(r&&this.setOptions(r),!this.options.queryFn){var d=this.observers.find(function(b){return b.options.queryFn});d&&this.setOptions(d.options)}var f=i3(this.queryKey),m=WT(),p={queryKey:f,pageParam:void 0,meta:this.meta};Object.defineProperty(p,"signal",{enumerable:!0,get:function(){if(m)return a.abortSignalConsumed=!0,m.signal}});var h=function(){return a.options.queryFn?(a.abortSignalConsumed=!1,a.options.queryFn(p)):Promise.reject("Missing queryFn")},v={fetchOptions:o,options:this.options,queryKey:f,state:this.state,fetchFn:h,meta:this.meta};if((i=this.options.behavior)!=null&&i.onFetch){var g;(g=this.options.behavior)==null||g.onFetch(v)}if(this.revertState=this.state,!this.state.isFetching||this.state.fetchMeta!==((c=v.fetchOptions)==null?void 0:c.meta)){var y;this.dispatch({type:"fetch",meta:(y=v.fetchOptions)==null?void 0:y.meta})}return this.retryer=new KT({fn:v.fetchFn,abort:m==null||(l=m.abort)==null?void 0:l.bind(m),onSuccess:function(C){a.setData(C),a.cache.config.onSuccess==null||a.cache.config.onSuccess(C,a),a.cacheTime===0&&a.optionalRemove()},onError:function(C){m3(C)&&C.silent||a.dispatch({type:"error",error:C}),m3(C)||(a.cache.config.onError==null||a.cache.config.onError(C,a),p3().error(C)),a.cacheTime===0&&a.optionalRemove()},onFail:function(){a.dispatch({type:"failed"})},onPause:function(){a.dispatch({type:"pause"})},onContinue:function(){a.dispatch({type:"continue"})},retry:v.options.retry,retryDelay:v.options.retryDelay}),this.promise=this.retryer.promise,this.promise},t.dispatch=function(r){var o=this;this.state=this.reducer(this.state,r),wn.batch(function(){o.observers.forEach(function(a){a.onQueryUpdate(r)}),o.cache.notify({query:o,type:"queryUpdated",action:r})})},t.getDefaultState=function(r){var o=typeof r.initialData=="function"?r.initialData():r.initialData,a=typeof r.initialData<"u",i=a?typeof r.initialDataUpdatedAt=="function"?r.initialDataUpdatedAt():r.initialDataUpdatedAt:0,c=typeof o<"u";return{data:o,dataUpdateCount:0,dataUpdatedAt:c?i??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchMeta:null,isFetching:!1,isInvalidated:!1,isPaused:!1,status:c?"success":"idle"}},t.reducer=function(r,o){var a,i;switch(o.type){case"failed":return le({},r,{fetchFailureCount:r.fetchFailureCount+1});case"pause":return le({},r,{isPaused:!0});case"continue":return le({},r,{isPaused:!1});case"fetch":return le({},r,{fetchFailureCount:0,fetchMeta:(a=o.meta)!=null?a:null,isFetching:!0,isPaused:!1},!r.dataUpdatedAt&&{error:null,status:"loading"});case"success":return le({},r,{data:o.data,dataUpdateCount:r.dataUpdateCount+1,dataUpdatedAt:(i=o.dataUpdatedAt)!=null?i:Date.now(),error:null,fetchFailureCount:0,isFetching:!1,isInvalidated:!1,isPaused:!1,status:"success"});case"error":var c=o.error;return m3(c)&&c.revert&&this.revertState?le({},this.revertState):le({},r,{error:c,errorUpdateCount:r.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:r.fetchFailureCount+1,isFetching:!1,isPaused:!1,status:"error"});case"invalidate":return le({},r,{isInvalidated:!0});case"setState":return le({},r,o.state);default:return r}},e}(),KOe=function(e){wc(t,e);function t(r){var o;return o=e.call(this)||this,o.config=r||{},o.queries=[],o.queriesMap={},o}var n=t.prototype;return n.build=function(o,a,i){var c,l=a.queryKey,s=(c=a.queryHash)!=null?c:W5(l,a),d=this.get(s);return d||(d=new UOe({cache:this,queryKey:l,queryHash:s,options:o.defaultQueryOptions(a),state:i,defaultOptions:o.getQueryDefaults(l),meta:a.meta}),this.add(d)),d},n.add=function(o){this.queriesMap[o.queryHash]||(this.queriesMap[o.queryHash]=o,this.queries.push(o),this.notify({type:"queryAdded",query:o}))},n.remove=function(o){var a=this.queriesMap[o.queryHash];a&&(o.destroy(),this.queries=this.queries.filter(function(i){return i!==o}),a===o&&delete this.queriesMap[o.queryHash],this.notify({type:"queryRemoved",query:o}))},n.clear=function(){var o=this;wn.batch(function(){o.queries.forEach(function(a){o.remove(a)})})},n.get=function(o){return this.queriesMap[o]},n.getAll=function(){return this.queries},n.find=function(o,a){var i=P2(o,a),c=i[0];return typeof c.exact>"u"&&(c.exact=!0),this.queries.find(function(l){return FT(c,l)})},n.findAll=function(o,a){var i=P2(o,a),c=i[0];return Object.keys(c).length>0?this.queries.filter(function(l){return FT(c,l)}):this.queries},n.notify=function(o){var a=this;wn.batch(function(){a.listeners.forEach(function(i){i(o)})})},n.onFocus=function(){var o=this;wn.batch(function(){o.queries.forEach(function(a){a.onFocus()})})},n.onOnline=function(){var o=this;wn.batch(function(){o.queries.forEach(function(a){a.onOnline()})})},t}(Mc),qOe=function(){function e(n){this.options=le({},n.defaultOptions,n.options),this.mutationId=n.mutationId,this.mutationCache=n.mutationCache,this.observers=[],this.state=n.state||GOe(),this.meta=n.meta}var t=e.prototype;return t.setState=function(r){this.dispatch({type:"setState",state:r})},t.addObserver=function(r){this.observers.indexOf(r)===-1&&this.observers.push(r)},t.removeObserver=function(r){this.observers=this.observers.filter(function(o){return o!==r})},t.cancel=function(){return this.retryer?(this.retryer.cancel(),this.retryer.promise.then(lr).catch(lr)):Promise.resolve()},t.continue=function(){return this.retryer?(this.retryer.continue(),this.retryer.promise):this.execute()},t.execute=function(){var r=this,o,a=this.state.status==="loading",i=Promise.resolve();return a||(this.dispatch({type:"loading",variables:this.options.variables}),i=i.then(function(){r.mutationCache.config.onMutate==null||r.mutationCache.config.onMutate(r.state.variables,r)}).then(function(){return r.options.onMutate==null?void 0:r.options.onMutate(r.state.variables)}).then(function(c){c!==r.state.context&&r.dispatch({type:"loading",context:c,variables:r.state.variables})})),i.then(function(){return r.executeMutation()}).then(function(c){o=c,r.mutationCache.config.onSuccess==null||r.mutationCache.config.onSuccess(o,r.state.variables,r.state.context,r)}).then(function(){return r.options.onSuccess==null?void 0:r.options.onSuccess(o,r.state.variables,r.state.context)}).then(function(){return r.options.onSettled==null?void 0:r.options.onSettled(o,null,r.state.variables,r.state.context)}).then(function(){return r.dispatch({type:"success",data:o}),o}).catch(function(c){return r.mutationCache.config.onError==null||r.mutationCache.config.onError(c,r.state.variables,r.state.context,r),p3().error(c),Promise.resolve().then(function(){return r.options.onError==null?void 0:r.options.onError(c,r.state.variables,r.state.context)}).then(function(){return r.options.onSettled==null?void 0:r.options.onSettled(void 0,c,r.state.variables,r.state.context)}).then(function(){throw r.dispatch({type:"error",error:c}),c})})},t.executeMutation=function(){var r=this,o;return this.retryer=new KT({fn:function(){return r.options.mutationFn?r.options.mutationFn(r.state.variables):Promise.reject("No mutationFn found")},onFail:function(){r.dispatch({type:"failed"})},onPause:function(){r.dispatch({type:"pause"})},onContinue:function(){r.dispatch({type:"continue"})},retry:(o=this.options.retry)!=null?o:0,retryDelay:this.options.retryDelay}),this.retryer.promise},t.dispatch=function(r){var o=this;this.state=YOe(this.state,r),wn.batch(function(){o.observers.forEach(function(a){a.onMutationUpdate(r)}),o.mutationCache.notify(o)})},e}();function GOe(){return{context:void 0,data:void 0,error:null,failureCount:0,isPaused:!1,status:"idle",variables:void 0}}function YOe(e,t){switch(t.type){case"failed":return le({},e,{failureCount:e.failureCount+1});case"pause":return le({},e,{isPaused:!0});case"continue":return le({},e,{isPaused:!1});case"loading":return le({},e,{context:t.context,data:void 0,error:null,isPaused:!1,status:"loading",variables:t.variables});case"success":return le({},e,{data:t.data,error:null,status:"success",isPaused:!1});case"error":return le({},e,{data:void 0,error:t.error,failureCount:e.failureCount+1,isPaused:!1,status:"error"});case"setState":return le({},e,t.state);default:return e}}var XOe=function(e){wc(t,e);function t(r){var o;return o=e.call(this)||this,o.config=r||{},o.mutations=[],o.mutationId=0,o}var n=t.prototype;return n.build=function(o,a,i){var c=new qOe({mutationCache:this,mutationId:++this.mutationId,options:o.defaultMutationOptions(a),state:i,defaultOptions:a.mutationKey?o.getMutationDefaults(a.mutationKey):void 0,meta:a.meta});return this.add(c),c},n.add=function(o){this.mutations.push(o),this.notify(o)},n.remove=function(o){this.mutations=this.mutations.filter(function(a){return a!==o}),o.cancel(),this.notify(o)},n.clear=function(){var o=this;wn.batch(function(){o.mutations.forEach(function(a){o.remove(a)})})},n.getAll=function(){return this.mutations},n.find=function(o){return typeof o.exact>"u"&&(o.exact=!0),this.mutations.find(function(a){return jT(o,a)})},n.findAll=function(o){return this.mutations.filter(function(a){return jT(o,a)})},n.notify=function(o){var a=this;wn.batch(function(){a.listeners.forEach(function(i){i(o)})})},n.onFocus=function(){this.resumePausedMutations()},n.onOnline=function(){this.resumePausedMutations()},n.resumePausedMutations=function(){var o=this.mutations.filter(function(a){return a.state.isPaused});return wn.batch(function(){return o.reduce(function(a,i){return a.then(function(){return i.continue().catch(lr)})},Promise.resolve())})},t}(Mc);function QOe(){return{onFetch:function(t){t.fetchFn=function(){var n,r,o,a,i,c,l=(n=t.fetchOptions)==null||(r=n.meta)==null?void 0:r.refetchPage,s=(o=t.fetchOptions)==null||(a=o.meta)==null?void 0:a.fetchMore,d=s==null?void 0:s.pageParam,f=(s==null?void 0:s.direction)==="forward",m=(s==null?void 0:s.direction)==="backward",p=((i=t.state.data)==null?void 0:i.pages)||[],h=((c=t.state.data)==null?void 0:c.pageParams)||[],v=WT(),g=v==null?void 0:v.signal,y=h,b=!1,C=t.options.queryFn||function(){return Promise.reject("Missing queryFn")},x=function($,T,R,N){return y=N?[T].concat(y):[].concat(y,[T]),N?[R].concat($):[].concat($,[R])},S=function($,T,R,N){if(b)return Promise.reject("Cancelled");if(typeof R>"u"&&!T&&$.length)return Promise.resolve($);var I={queryKey:t.queryKey,signal:g,pageParam:R,meta:t.meta},k=C(I),_=Promise.resolve(k).then(function(V){return x($,R,V,N)});if(f3(k)){var F=_;F.cancel=k.cancel}return _},E;if(!p.length)E=S([]);else if(f){var L=typeof d<"u",w=L?d:GT(t.options,p);E=S(p,L,w)}else if(m){var M=typeof d<"u",z=M?d:JOe(t.options,p);E=S(p,M,z,!0)}else(function(){y=[];var A=typeof t.options.getNextPageParam>"u",$=l&&p[0]?l(p[0],0,p):!0;E=$?S([],A,h[0]):Promise.resolve(x([],h[0],p[0]));for(var T=function(I){E=E.then(function(k){var _=l&&p[I]?l(p[I],I,p):!0;if(_){var F=A?h[I]:GT(t.options,k);return S(k,A,F)}return Promise.resolve(x(k,h[I],p[I]))})},R=1;R<p.length;R++)T(R)})();var P=E.then(function(A){return{pages:A,pageParams:y}}),D=P;return D.cancel=function(){b=!0,v==null||v.abort(),f3(E)&&E.cancel()},P}}}}function GT(e,t){return e.getNextPageParam==null?void 0:e.getNextPageParam(t[t.length-1],t)}function JOe(e,t){return e.getPreviousPageParam==null?void 0:e.getPreviousPageParam(t[0],t)}var ZOe=function(){function e(n){n===void 0&&(n={}),this.queryCache=n.queryCache||new KOe,this.mutationCache=n.mutationCache||new XOe,this.defaultOptions=n.defaultOptions||{},this.queryDefaults=[],this.mutationDefaults=[]}var t=e.prototype;return t.mount=function(){var r=this;this.unsubscribeFocus=zc.subscribe(function(){zc.isFocused()&&d3.isOnline()&&(r.mutationCache.onFocus(),r.queryCache.onFocus())}),this.unsubscribeOnline=d3.subscribe(function(){zc.isFocused()&&d3.isOnline()&&(r.mutationCache.onOnline(),r.queryCache.onOnline())})},t.unmount=function(){var r,o;(r=this.unsubscribeFocus)==null||r.call(this),(o=this.unsubscribeOnline)==null||o.call(this)},t.isFetching=function(r,o){var a=P2(r,o),i=a[0];return i.fetching=!0,this.queryCache.findAll(i).length},t.isMutating=function(r){return this.mutationCache.findAll(le({},r,{fetching:!0})).length},t.getQueryData=function(r,o){var a;return(a=this.queryCache.find(r,o))==null?void 0:a.state.data},t.getQueriesData=function(r){return this.getQueryCache().findAll(r).map(function(o){var a=o.queryKey,i=o.state,c=i.data;return[a,c]})},t.setQueryData=function(r,o,a){var i=c3(r),c=this.defaultQueryOptions(i);return this.queryCache.build(this,c).setData(o,a)},t.setQueriesData=function(r,o,a){var i=this;return wn.batch(function(){return i.getQueryCache().findAll(r).map(function(c){var l=c.queryKey;return[l,i.setQueryData(l,o,a)]})})},t.getQueryState=function(r,o){var a;return(a=this.queryCache.find(r,o))==null?void 0:a.state},t.removeQueries=function(r,o){var a=P2(r,o),i=a[0],c=this.queryCache;wn.batch(function(){c.findAll(i).forEach(function(l){c.remove(l)})})},t.resetQueries=function(r,o,a){var i=this,c=P2(r,o,a),l=c[0],s=c[1],d=this.queryCache,f=le({},l,{active:!0});return wn.batch(function(){return d.findAll(l).forEach(function(m){m.reset()}),i.refetchQueries(f,s)})},t.cancelQueries=function(r,o,a){var i=this,c=P2(r,o,a),l=c[0],s=c[1],d=s===void 0?{}:s;typeof d.revert>"u"&&(d.revert=!0);var f=wn.batch(function(){return i.queryCache.findAll(l).map(function(m){return m.cancel(d)})});return Promise.all(f).then(lr).catch(lr)},t.invalidateQueries=function(r,o,a){var i,c,l,s=this,d=P2(r,o,a),f=d[0],m=d[1],p=le({},f,{active:(i=(c=f.refetchActive)!=null?c:f.active)!=null?i:!0,inactive:(l=f.refetchInactive)!=null?l:!1});return wn.batch(function(){return s.queryCache.findAll(f).forEach(function(h){h.invalidate()}),s.refetchQueries(p,m)})},t.refetchQueries=function(r,o,a){var i=this,c=P2(r,o,a),l=c[0],s=c[1],d=wn.batch(function(){return i.queryCache.findAll(l).map(function(m){return m.fetch(void 0,le({},s,{meta:{refetchPage:l==null?void 0:l.refetchPage}}))})}),f=Promise.all(d).then(lr);return s!=null&&s.throwOnError||(f=f.catch(lr)),f},t.fetchQuery=function(r,o,a){var i=c3(r,o,a),c=this.defaultQueryOptions(i);typeof c.retry>"u"&&(c.retry=!1);var l=this.queryCache.build(this,c);return l.isStaleByTime(c.staleTime)?l.fetch(c):Promise.resolve(l.state.data)},t.prefetchQuery=function(r,o,a){return this.fetchQuery(r,o,a).then(lr).catch(lr)},t.fetchInfiniteQuery=function(r,o,a){var i=c3(r,o,a);return i.behavior=QOe(),this.fetchQuery(i)},t.prefetchInfiniteQuery=function(r,o,a){return this.fetchInfiniteQuery(r,o,a).then(lr).catch(lr)},t.cancelMutations=function(){var r=this,o=wn.batch(function(){return r.mutationCache.getAll().map(function(a){return a.cancel()})});return Promise.all(o).then(lr).catch(lr)},t.resumePausedMutations=function(){return this.getMutationCache().resumePausedMutations()},t.executeMutation=function(r){return this.mutationCache.build(this,r).execute()},t.getQueryCache=function(){return this.queryCache},t.getMutationCache=function(){return this.mutationCache},t.getDefaultOptions=function(){return this.defaultOptions},t.setDefaultOptions=function(r){this.defaultOptions=r},t.setQueryDefaults=function(r,o){var a=this.queryDefaults.find(function(i){return Co(r)===Co(i.queryKey)});a?a.defaultOptions=o:this.queryDefaults.push({queryKey:r,defaultOptions:o})},t.getQueryDefaults=function(r){var o;return r?(o=this.queryDefaults.find(function(a){return l3(r,a.queryKey)}))==null?void 0:o.defaultOptions:void 0},t.setMutationDefaults=function(r,o){var a=this.mutationDefaults.find(function(i){return Co(r)===Co(i.mutationKey)});a?a.defaultOptions=o:this.mutationDefaults.push({mutationKey:r,defaultOptions:o})},t.getMutationDefaults=function(r){var o;return r?(o=this.mutationDefaults.find(function(a){return l3(r,a.mutationKey)}))==null?void 0:o.defaultOptions:void 0},t.defaultQueryOptions=function(r){if(r!=null&&r._defaulted)return r;var o=le({},this.defaultOptions.queries,this.getQueryDefaults(r==null?void 0:r.queryKey),r,{_defaulted:!0});return!o.queryHash&&o.queryKey&&(o.queryHash=W5(o.queryKey,o)),o},t.defaultQueryObserverOptions=function(r){return this.defaultQueryOptions(r)},t.defaultMutationOptions=function(r){return r!=null&&r._defaulted?r:le({},this.defaultOptions.mutations,this.getMutationDefaults(r==null?void 0:r.mutationKey),r,{_defaulted:!0})},t.clear=function(){this.queryCache.clear(),this.mutationCache.clear()},e}(),e$e=function(e){wc(t,e);function t(r,o){var a;return a=e.call(this)||this,a.client=r,a.options=o,a.trackedProps=[],a.selectError=null,a.bindMethods(),a.setOptions(o),a}var n=t.prototype;return n.bindMethods=function(){this.remove=this.remove.bind(this),this.refetch=this.refetch.bind(this)},n.onSubscribe=function(){this.listeners.length===1&&(this.currentQuery.addObserver(this),YT(this.currentQuery,this.options)&&this.executeFetch(),this.updateTimers())},n.onUnsubscribe=function(){this.listeners.length||this.destroy()},n.shouldFetchOnReconnect=function(){return K5(this.currentQuery,this.options,this.options.refetchOnReconnect)},n.shouldFetchOnWindowFocus=function(){return K5(this.currentQuery,this.options,this.options.refetchOnWindowFocus)},n.destroy=function(){this.listeners=[],this.clearTimers(),this.currentQuery.removeObserver(this)},n.setOptions=function(o,a){var i=this.options,c=this.currentQuery;if(this.options=this.client.defaultQueryObserverOptions(o),typeof this.options.enabled<"u"&&typeof this.options.enabled!="boolean")throw new Error("Expected enabled to be a boolean");this.options.queryKey||(this.options.queryKey=i.queryKey),this.updateQuery();var l=this.hasListeners();l&&XT(this.currentQuery,c,this.options,i)&&this.executeFetch(),this.updateResult(a),l&&(this.currentQuery!==c||this.options.enabled!==i.enabled||this.options.staleTime!==i.staleTime)&&this.updateStaleTimeout();var s=this.computeRefetchInterval();l&&(this.currentQuery!==c||this.options.enabled!==i.enabled||s!==this.currentRefetchInterval)&&this.updateRefetchInterval(s)},n.getOptimisticResult=function(o){var a=this.client.defaultQueryObserverOptions(o),i=this.client.getQueryCache().build(this.client,a);return this.createResult(i,a)},n.getCurrentResult=function(){return this.currentResult},n.trackResult=function(o,a){var i=this,c={},l=function(d){i.trackedProps.includes(d)||i.trackedProps.push(d)};return Object.keys(o).forEach(function(s){Object.defineProperty(c,s,{configurable:!1,enumerable:!0,get:function(){return l(s),o[s]}})}),(a.useErrorBoundary||a.suspense)&&l("error"),c},n.getNextResult=function(o){var a=this;return new Promise(function(i,c){var l=a.subscribe(function(s){s.isFetching||(l(),s.isError&&(o!=null&&o.throwOnError)?c(s.error):i(s))})})},n.getCurrentQuery=function(){return this.currentQuery},n.remove=function(){this.client.getQueryCache().remove(this.currentQuery)},n.refetch=function(o){return this.fetch(le({},o,{meta:{refetchPage:o==null?void 0:o.refetchPage}}))},n.fetchOptimistic=function(o){var a=this,i=this.client.defaultQueryObserverOptions(o),c=this.client.getQueryCache().build(this.client,i);return c.fetch().then(function(){return a.createResult(c,i)})},n.fetch=function(o){var a=this;return this.executeFetch(o).then(function(){return a.updateResult(),a.currentResult})},n.executeFetch=function(o){this.updateQuery();var a=this.currentQuery.fetch(this.options,o);return o!=null&&o.throwOnError||(a=a.catch(lr)),a},n.updateStaleTimeout=function(){var o=this;if(this.clearStaleTimeout(),!(a3||this.currentResult.isStale||!V5(this.options.staleTime))){var a=kT(this.currentResult.dataUpdatedAt,this.options.staleTime),i=a+1;this.staleTimeoutId=setTimeout(function(){o.currentResult.isStale||o.updateResult()},i)}},n.computeRefetchInterval=function(){var o;return typeof this.options.refetchInterval=="function"?this.options.refetchInterval(this.currentResult.data,this.currentQuery):(o=this.options.refetchInterval)!=null?o:!1},n.updateRefetchInterval=function(o){var a=this;this.clearRefetchInterval(),this.currentRefetchInterval=o,!(a3||this.options.enabled===!1||!V5(this.currentRefetchInterval)||this.currentRefetchInterval===0)&&(this.refetchIntervalId=setInterval(function(){(a.options.refetchIntervalInBackground||zc.isFocused())&&a.executeFetch()},this.currentRefetchInterval))},n.updateTimers=function(){this.updateStaleTimeout(),this.updateRefetchInterval(this.computeRefetchInterval())},n.clearTimers=function(){this.clearStaleTimeout(),this.clearRefetchInterval()},n.clearStaleTimeout=function(){this.staleTimeoutId&&(clearTimeout(this.staleTimeoutId),this.staleTimeoutId=void 0)},n.clearRefetchInterval=function(){this.refetchIntervalId&&(clearInterval(this.refetchIntervalId),this.refetchIntervalId=void 0)},n.createResult=function(o,a){var i=this.currentQuery,c=this.options,l=this.currentResult,s=this.currentResultState,d=this.currentResultOptions,f=o!==i,m=f?o.state:this.currentQueryInitialState,p=f?this.currentResult:this.previousQueryResult,h=o.state,v=h.dataUpdatedAt,g=h.error,y=h.errorUpdatedAt,b=h.isFetching,C=h.status,x=!1,S=!1,E;if(a.optimisticResults){var L=this.hasListeners(),w=!L&&YT(o,a),M=L&&XT(o,i,a,c);(w||M)&&(b=!0,v||(C="loading"))}if(a.keepPreviousData&&!h.dataUpdateCount&&(p!=null&&p.isSuccess)&&C!=="error")E=p.data,v=p.dataUpdatedAt,C=p.status,x=!0;else if(a.select&&typeof h.data<"u")if(l&&h.data===(s==null?void 0:s.data)&&a.select===this.selectFn)E=this.selectResult;else try{this.selectFn=a.select,E=a.select(h.data),a.structuralSharing!==!1&&(E=s3(l==null?void 0:l.data,E)),this.selectResult=E,this.selectError=null}catch(D){p3().error(D),this.selectError=D}else E=h.data;if(typeof a.placeholderData<"u"&&typeof E>"u"&&(C==="loading"||C==="idle")){var z;if(l!=null&&l.isPlaceholderData&&a.placeholderData===(d==null?void 0:d.placeholderData))z=l.data;else if(z=typeof a.placeholderData=="function"?a.placeholderData():a.placeholderData,a.select&&typeof z<"u")try{z=a.select(z),a.structuralSharing!==!1&&(z=s3(l==null?void 0:l.data,z)),this.selectError=null}catch(D){p3().error(D),this.selectError=D}typeof z<"u"&&(C="success",E=z,S=!0)}this.selectError&&(g=this.selectError,E=this.selectResult,y=Date.now(),C="error");var P={status:C,isLoading:C==="loading",isSuccess:C==="success",isError:C==="error",isIdle:C==="idle",data:E,dataUpdatedAt:v,error:g,errorUpdatedAt:y,failureCount:h.fetchFailureCount,errorUpdateCount:h.errorUpdateCount,isFetched:h.dataUpdateCount>0||h.errorUpdateCount>0,isFetchedAfterMount:h.dataUpdateCount>m.dataUpdateCount||h.errorUpdateCount>m.errorUpdateCount,isFetching:b,isRefetching:b&&C!=="loading",isLoadingError:C==="error"&&h.dataUpdatedAt===0,isPlaceholderData:S,isPreviousData:x,isRefetchError:C==="error"&&h.dataUpdatedAt!==0,isStale:q5(o,a),refetch:this.refetch,remove:this.remove};return P},n.shouldNotifyListeners=function(o,a){if(!a)return!0;var i=this.options,c=i.notifyOnChangeProps,l=i.notifyOnChangePropsExclusions;if(!c&&!l||c==="tracked"&&!this.trackedProps.length)return!0;var s=c==="tracked"?this.trackedProps:c;return Object.keys(o).some(function(d){var f=d,m=o[f]!==a[f],p=s==null?void 0:s.some(function(v){return v===d}),h=l==null?void 0:l.some(function(v){return v===d});return m&&!h&&(!s||p)})},n.updateResult=function(o){var a=this.currentResult;if(this.currentResult=this.createResult(this.currentQuery,this.options),this.currentResultState=this.currentQuery.state,this.currentResultOptions=this.options,!kOe(this.currentResult,a)){var i={cache:!0};(o==null?void 0:o.listeners)!==!1&&this.shouldNotifyListeners(this.currentResult,a)&&(i.listeners=!0),this.notify(le({},i,o))}},n.updateQuery=function(){var o=this.client.getQueryCache().build(this.client,this.options);if(o!==this.currentQuery){var a=this.currentQuery;this.currentQuery=o,this.currentQueryInitialState=o.state,this.previousQueryResult=this.currentResult,this.hasListeners()&&(a==null||a.removeObserver(this),o.addObserver(this))}},n.onQueryUpdate=function(o){var a={};o.type==="success"?a.onSuccess=!0:o.type==="error"&&!m3(o.error)&&(a.onError=!0),this.updateResult(a),this.hasListeners()&&this.updateTimers()},n.notify=function(o){var a=this;wn.batch(function(){o.onSuccess?(a.options.onSuccess==null||a.options.onSuccess(a.currentResult.data),a.options.onSettled==null||a.options.onSettled(a.currentResult.data,null)):o.onError&&(a.options.onError==null||a.options.onError(a.currentResult.error),a.options.onSettled==null||a.options.onSettled(void 0,a.currentResult.error)),o.listeners&&a.listeners.forEach(function(i){i(a.currentResult)}),o.cache&&a.client.getQueryCache().notify({query:a.currentQuery,type:"observerResultsUpdated"})})},t}(Mc);function t$e(e,t){return t.enabled!==!1&&!e.state.dataUpdatedAt&&!(e.state.status==="error"&&t.retryOnMount===!1)}function YT(e,t){return t$e(e,t)||e.state.dataUpdatedAt>0&&K5(e,t,t.refetchOnMount)}function K5(e,t,n){if(t.enabled!==!1){var r=typeof n=="function"?n(e):n;return r==="always"||r!==!1&&q5(e,t)}return!1}function XT(e,t,n,r){return n.enabled!==!1&&(e!==t||r.enabled===!1)&&(!n.suspense||e.state.status!=="error")&&q5(e,n)}function q5(e,t){return e.isStaleByTime(t.staleTime)}var n$e=Tn.unstable_batchedUpdates;wn.setBatchNotifyFunction(n$e);var r$e=console;WOe(r$e);var QT=O.createContext(void 0),JT=O.createContext(!1);function ZT(e){return e&&typeof window<"u"?(window.ReactQueryClientContext||(window.ReactQueryClientContext=QT),window.ReactQueryClientContext):QT}var o$e=function(){var t=O.useContext(ZT(O.useContext(JT)));if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},eR=function(t){var n=t.client,r=t.contextSharing,o=r===void 0?!1:r,a=t.children;O.useEffect(function(){return n.mount(),function(){n.unmount()}},[n]);var i=ZT(o);return O.createElement(JT.Provider,{value:o},O.createElement(i.Provider,{value:n},a))};function a$e(){var e=!1;return{clearReset:function(){e=!1},reset:function(){e=!0},isReset:function(){return e}}}var i$e=O.createContext(a$e()),c$e=function(){return O.useContext(i$e)};function l$e(e,t,n){return typeof t=="function"?t.apply(void 0,n):typeof t=="boolean"?t:!!e}function s$e(e,t){var n=O.useRef(!1),r=O.useState(0),o=r[1],a=o$e(),i=c$e(),c=a.defaultQueryObserverOptions(e);c.optimisticResults=!0,c.onError&&(c.onError=wn.batchCalls(c.onError)),c.onSuccess&&(c.onSuccess=wn.batchCalls(c.onSuccess)),c.onSettled&&(c.onSettled=wn.batchCalls(c.onSettled)),c.suspense&&(typeof c.staleTime!="number"&&(c.staleTime=1e3),c.cacheTime===0&&(c.cacheTime=1)),(c.suspense||c.useErrorBoundary)&&(i.isReset()||(c.retryOnMount=!1));var l=O.useState(function(){return new t(a,c)}),s=l[0],d=s.getOptimisticResult(c);if(O.useEffect(function(){n.current=!0,i.clearReset();var f=s.subscribe(wn.batchCalls(function(){n.current&&o(function(m){return m+1})}));return s.updateResult(),function(){n.current=!1,f()}},[i,s]),O.useEffect(function(){s.setOptions(c,{listeners:!1})},[c,s]),c.suspense&&d.isLoading)throw s.fetchOptimistic(c).then(function(f){var m=f.data;c.onSuccess==null||c.onSuccess(m),c.onSettled==null||c.onSettled(m,null)}).catch(function(f){i.clearReset(),c.onError==null||c.onError(f),c.onSettled==null||c.onSettled(void 0,f)});if(d.isError&&!i.isReset()&&!d.isFetching&&l$e(c.suspense,c.useErrorBoundary,[d.error,s.getCurrentQuery()]))throw d.error;return c.notifyOnChangeProps==="tracked"&&(d=s.trackResult(d,c)),d}function tR(e,t,n){var r=c3(e,t,n);return s$e(r,e$e)}var Ut=(e=>(e.App="idApp",e.Version="version",e.DeployDate="releaseDate",e.ReleasePages="gaReleasePages",e.Fields="gaReleasePagesContent",e.Title="title",e.Description="description",e.Image="idFile",e.Order="order",e.NoImage="noImage",e))(Ut||{}),G5=(e=>(e.GetApps="GetApps",e.GetReleases="GetReleases",e))(G5||{});const u$e=async()=>{const e=window.globalAuthUrl,{data:t}=await ho.get(`${e}/getApps`);return t},d$e=async e=>{const t=window.globalAuthUrl,{data:n}=await ho.post(`${t}/ListReleases`,e);return n},f$e=async e=>{const t=window.globalAuthUrl,{data:n}=await ho.post(`${t}/MaintainReleases`,e);return n},m$e=async(e,t)=>{const n=window.globalAuthUrl,{data:r}=await ho.post(`${n}/ReadNotification`,{idRelease:e,userId:t});return r},nR=()=>tR([G5.GetApps],async()=>await u$e()),p$e=e=>{const{idApp:t,userId:n,lastDeployed:r}=e;return tR([G5.GetReleases,t,n,r],async()=>await d$e(e),{enabled:!!t})},g$e=({index:e})=>{const{requiredField:t}=Td();return Me.jsx(cn.List,{name:[e,Ut.Fields],children:(n,{remove:r})=>Me.jsxs(Me.Fragment,{children:[Me.jsx(j0,{fieldName:"idReleasePage",hidden:!0}),Me.jsx(p1,{gap:16,vertical:!0,children:n.map(({key:o,name:a,...i})=>Me.jsxs(p1,{gap:6,align:"center",children:[Me.jsxs(p1,{vertical:!0,gap:2,style:{width:"100%"},children:[Me.jsx(cn.Item,{...i,name:[a,Ut.Title],rules:t,noStyle:!0,children:Me.jsx(w1,{placeholder:It("RELEASE-NOTES.FORM.FIELDS.TITLE"),maxLength:500})}),Me.jsx(cn.Item,{...i,name:[a,Ut.Description],rules:t,noStyle:!0,children:Me.jsx(h8,{autoSize:{minRows:2},placeholder:It("RELEASE-NOTES.FORM.FIELDS.DESCRIPTION")})})]}),Me.jsx(cn.Item,{noStyle:!0,children:Me.jsx(mr,{title:It("GENERAL.REMOVE"),children:Me.jsx(mn,{type:"text",icon:Me.jsx(yS,{}),onClick:()=>r(a),disabled:n.length===1})})})]},o))})]})})},h$e=O.forwardRef(({changeSlide:e},t)=>{const[n,r]=O.useState([]),o=cn.useFormInstance(),a=cn.useWatch(Ut.ReleasePages,o),i=s=>({file:d,fileList:f})=>{const m=s[0],p=s[1],h=a[m];r(f),Z2e(d.originFileObj,v=>{o.setFieldValue(Ut.ReleasePages,a.toSpliced(m,1,{...h,[p]:v}))})},c=s=>()=>{var p;const d=a==null?void 0:a[s],m=[...((p=a==null?void 0:a[s])==null?void 0:p[Ut.Fields])??[],{}];o.setFieldValue(Ut.ReleasePages,a.toSpliced(s,1,{...d,[Ut.Fields]:m}))},l=Me.jsx(L1,{justify:"center",align:"middle",children:Me.jsxs(Ms,{direction:"vertical",children:[Me.jsx("p",{className:"ant-upload-drag-icon",children:Me.jsx(_8,{})}),Me.jsx("p",{className:"ant-upload-text",children:It("GENERAL.UPLOAD_LABEL")}),Me.jsx("p",{className:"ant-upload-hint",children:It("GENERAL.JPG_PNG_WARNING")})]})});return Me.jsx(cn.List,{name:Ut.ReleasePages,children:s=>Me.jsxs(Me.Fragment,{children:[Me.jsx(j0,{fieldName:"idRelease",hidden:!0}),Me.jsx(j0,{fieldName:"idReleasePage",hidden:!0}),Me.jsx(t8,{infinite:!1,ref:t,afterChange:e,children:s.map(({key:d,name:f,...m})=>{var v,g;const p=(v=a==null?void 0:a[f])==null?void 0:v[Ut.Image],h=(g=a==null?void 0:a[f])==null?void 0:g[Ut.NoImage];return Me.jsx("div",{children:Me.jsxs(L1,{gutter:[8,16],style:{marginBottom:35},children:[Me.jsx(cr,{span:24,children:Me.jsxs(L1,{gutter:8,children:[Me.jsx(cr,{span:h?24:12,children:Me.jsx(g$e,{index:f})}),!h&&Me.jsx(cr,{span:12,children:Me.jsx(eo,{bordered:!0,styles:{body:{display:"flex",justifyContent:"center",padding:2}},children:Me.jsx(cn.Item,{...m,name:[f,Ut.Image],noStyle:!0,children:Me.jsx(wd,{listType:"picture",className:"release-notes-image",showUploadList:!1,fileList:n,beforeUpload:eoe,onChange:i([f,Ut.Image]),children:p?Me.jsx(Is,{src:p,preview:!1,style:{maxHeight:600}}):l})})})})]})}),Me.jsx(cr,{span:8,children:Me.jsxs(p1,{vertical:!0,children:[Me.jsx(cn.Item,{children:Me.jsx(mn,{type:"dashed",onClick:c(f),icon:Me.jsx(Hu,{}),block:!0,children:It("RELEASE-NOTES.FORM.ADD_NEW_FIELD")})}),Me.jsx(pze,{fieldName:[f,Ut.NoImage],label:It("GENERAL.DO_NOT_USE_IMAGE")})]})})]})},d)})})]})})}),a2="RELEASE-NOTES",v$e=({addBtnLabel:e,addBtnTooltipText:t,release2edit:n,beforeOpenModal:r,beforeCloseModal:o,afterSubmit:a})=>{const[i,c]=O.useState(!1),[l,s]=O.useState(!1),[d,f]=O.useState(0),[m]=cn.useForm(),p=ec(),{getColor:h}=Koe(),v=O.useRef(null),{requiredField:g}=Td(),{data:y}=nR(),b=cn.useWatch(Ut.ReleasePages,m),C=I=>f(I),x=()=>m.resetFields();O.useEffect(()=>{var k;const I=(b==null?void 0:b.length)-1;(k=v.current)==null||k.goTo(I)},[b==null?void 0:b.length]),O.useEffect(()=>(n&&(c(!0),m.setFieldsValue({...n,[Ut.ReleasePages]:n[Ut.ReleasePages].map(I=>({...I,[Ut.Image]:qx(I[Ut.Image])})),[Ut.DeployDate]:Yn(n[Ut.DeployDate])})),()=>{x()}),[n]);const S=()=>{r?new Promise(I=>I(r())).then(()=>c(!0)):c(!0)},E=()=>{o?new Promise(I=>I(o())).then(()=>c(!1)):c(!1)},L=()=>m.setFieldValue(Ut.ReleasePages,[...b,{[Ut.Fields]:[{}]}]),w=()=>m.setFieldValue(Ut.ReleasePages,b.filter((I,k)=>k!==d)),M=I=>{const k={...I,[Ut.DeployDate]:Yn(I[Ut.DeployDate]).format(cD),[Ut.ReleasePages]:I[Ut.ReleasePages].map((_,F)=>({..._,[Ut.Image]:toe(_[Ut.Image]),order:F,[Ut.Fields]:_[Ut.Fields].map((V,j)=>({...V,order:j}))}))};f$e(k).then(()=>{x(),As.success(It("GENERAL.MESSAGES.SUCCESS.ITEM_CREATE",{item:It(`${a2}.TEXT_SINGULAR`)})),a&&a()}).catch(_=>{var V;const F=((V=_.response)==null?void 0:V.data)??[];Fs.error({message:It("GENERAL.ERROR"),description:Me.jsx(T8,{dataSource:F,renderItem:j=>Me.jsx(T8.Item,{children:It(`GENERAL.MESSAGES.ERROR.RELEASE_NOTE.${j.error}`)})})})}).finally(E)},z=()=>!!(b!=null&&b.length)&&d!==0,P=()=>!!(b!=null&&b.length)&&d!==(b==null?void 0:b.length)-1,D=()=>(b==null?void 0:b.length)>1,A=Me.jsxs(p1,{justify:"flex-end",gap:8,children:[z()&&Me.jsx(mn,{type:"dashed",icon:Me.jsx(A1,{icon:q$}),onClick:()=>{var I;return(I=v.current)==null?void 0:I.prev()},children:It("GENERAL.BACK")}),P()&&Me.jsx(mn,{type:"dashed",iconPosition:"end",icon:Me.jsx(A1,{icon:G$}),onClick:()=>{var I;return(I=v.current)==null?void 0:I.next()},children:It("GENERAL.NEXT")}),D()&&Me.jsx(mn,{type:"dashed",danger:!0,icon:Me.jsx(A1,{icon:GN}),onClick:w,children:It(`${a2}.REMOVE_CURRENT_SLIDE`)}),Me.jsx(mn,{type:"dashed",icon:Me.jsx(A1,{icon:LP}),onClick:L,children:It(`${a2}.ADD_NEW_SLIDE`)}),Me.jsx(mn,{type:"primary",icon:Me.jsx(A1,{icon:DN}),onClick:()=>m.submit(),children:It("GENERAL.SAVE")})]}),$=I=>{s(t?I:!1)},T={[Ut.ReleasePages]:[{[Ut.Fields]:[{}]}],[Ut.DeployDate]:Yn()},R=noe(y??[],"appName","id"),N=O.useMemo(()=>It(`${a2}.${n?"UPD_RELEASE_NOTE":"ADD_RELEASE_NOTE"}`),[p]);return Me.jsxs(Me.Fragment,{children:[Me.jsx(mr,{title:t,open:l,onOpenChange:$,children:Me.jsx(mn,{type:"primary",icon:Me.jsx(A1,{icon:Hz}),shape:e?"default":"circle",onClick:S,children:e})}),Me.jsx(Tr,{open:i,title:N,onCancel:E,width:"60%",footer:A,destroyOnClose:!0,children:Me.jsxs(cn,{form:m,layout:"vertical",initialValues:T,onFinish:M,children:[Me.jsx(j0,{fieldName:"idRelease",hidden:!0}),Me.jsxs(L1,{gutter:10,children:[Me.jsx(cr,{span:8,children:Me.jsx(fze,{fieldName:Ut.App,label:It(`${a2}.FORM.FIELDS.APP`),placeholder:It(`${a2}.FORM.FIELDS.APP`,{context:"PLACEHOLDER"}),options:R,rules:g})}),Me.jsx(cr,{span:8,children:Me.jsx(F0,{fieldName:Ut.Version,label:It(`${a2}.FORM.FIELDS.VERSION`),placeholder:"0.0.0",tooltip:It(`${a2}.FORM.FIELDS.VERSION`,{context:"TOOLTIP"}),normalize:I=>I.replace(/\s/,".").replace(/[.]{2}/g,".").replace(/^[^0-9]|[^0-9.\b]/g,""),rules:[...g,()=>({validator(I,k){var V,j;const _=/[^0-9]$/,F=(j=(V=k==null?void 0:k.split("."))==null?void 0:V.filter(Boolean))==null?void 0:j.length;return _.test(k)?Promise.reject(new Error(It("GENERAL.FORM.ERRORS.VERSION"))):F>3||F<3?Promise.reject(new Error(It("GENERAL.FORM.ERRORS.FORMAT"))):Promise.resolve()}})]})}),Me.jsx(cr,{span:8,children:Me.jsx(mze,{fieldName:Ut.DeployDate,label:It(`${a2}.FORM.FIELDS.DEPLOY_DATE`),format:iD,rules:g})}),Me.jsx(cr,{span:24,children:Me.jsx(eo,{styles:{body:{background:h("PrimaryColorBgContainer")}},children:Me.jsx(h$e,{ref:v,changeSlide:C})})})]})]})})]})},{Title:b$e,Text:y$e}=Sa,C$e=()=>{var L,w;const[e,t]=O.useState(!1),[n,r]=O.useState(!1),[o,a]=O.useState(0),i=ec(),c=O.useRef(null),l=xa(k1.AppId),s=xa(k1.UserId),{data:d}=nR(),{data:f}=p$e({idApp:l,lastDeployed:!0,userId:s}),m=f==null?void 0:f[0],p=d==null?void 0:d.find(M=>M.id===l);O.useEffect(()=>{if(f!=null&&f.length){const M=f[0],z=!M.readRelease&&!!M.isDeployed;t(z)}},[f]);const h=()=>{const M=f==null?void 0:f[0];n&&(M!=null&&M.isDeployed)&&m$e(M==null?void 0:M.idRelease,s),t(!1)},v=()=>{var M;return(M=c.current)==null?void 0:M.next()},g=()=>{var M;return(M=c.current)==null?void 0:M.prev()},y=M=>a(M),b=o===0,C=o===(((L=m==null?void 0:m.gaReleasePages)==null?void 0:L.length)??0)-1,x=M=>r(M.target.checked),S=Me.jsxs(p1,{justify:"space-between",align:"center",children:[Me.jsx(Z1,{checked:n,onChange:x,children:It("RELEASE-NOTES.FORM.FIELDS.DO_NOT_SHOW_AGAIN")}),Me.jsxs(p1,{gap:8,children:[!b&&Me.jsx(mn,{onClick:g,children:It("Prev")}),!C&&Me.jsx(mn,{type:"primary",onClick:v,children:It("GENERAL.ACTIONS.NEXT")}),C&&Me.jsx(mn,{type:"primary",onClick:h,children:It("GENERAL.ACTIONS.CLOSE")})]})]}),E=O.useMemo(()=>It("RELEASE-NOTES.WHATS_NEWS",{app:p==null?void 0:p.appName,version:m==null?void 0:m.version}),[i]);return Me.jsx(Tr,{open:e,title:E,onCancel:h,width:"70%",footer:S,children:Me.jsx(t8,{infinite:!1,ref:c,afterChange:y,children:(w=m==null?void 0:m.gaReleasePages)==null?void 0:w.map(({idFile:M,gaReleasePagesContent:z},P)=>Me.jsx("div",{children:Me.jsxs(L1,{gutter:[16,16],style:{marginBottom:35},children:[Me.jsx(cr,{span:M?12:24,children:Me.jsx(p1,{gap:16,vertical:!0,children:z.map(({title:D,description:A},$)=>Me.jsxs(p1,{vertical:!0,children:[Me.jsx(b$e,{level:5,children:D}),Me.jsx(y$e,{style:{opacity:.5},children:A})]},`${P}-${$}`))})}),!!M&&Me.jsx(cr,{span:12,children:Me.jsx(p1,{justify:"center",children:Me.jsx(eo,{bordered:!0,styles:{body:{display:"flex",justifyContent:"center",padding:2}},children:Me.jsx(Is,{src:qx(M),style:{maxHeight:600,borderRadius:8}})})})})]})},P))})})},rR=new ZOe({defaultOptions:{queries:{retry:2}}}),S$e=ROe(({showAddBtn:e,...t})=>e?Me.jsx(Nd,{children:Me.jsx(eR,{client:rR,children:Me.jsx(v$e,{...t})})}):Me.jsx(Nd,{children:Me.jsx(eR,{client:rR,children:Me.jsx(C$e,{})})}));ur.Helpdesk=WNe,ur.ReleaseNote=S$e,Object.defineProperty(ur,Symbol.toStringTag,{value:"Module"})});
|