Files
dailygrubs_console_build/build/static/js/8097.6c505857.chunk.js

1 line
12 KiB
JavaScript

"use strict";(self.webpackChunkmantis_material_react=self.webpackChunkmantis_material_react||[]).push([[8097],{18948:function(t,e,i){i.d(e,{z:function(){return q}});var n,s,r,a,o,u,h,l,c,d,f,Z,p,v,y,b,w,k,R,g,O,C,S,m=i(1413),W=i(36459),U=i(15671),M=i(43144),E=i(97326),F=i(60136),L=i(27277),A=i(40101),P=i(72346),Q=i(43889),T=i(86033),D=i(13092),_=i(66587),I=i(28127),j=i(3847),x=i(27542),B=i(31854),q=(n=new WeakMap,s=new WeakMap,r=new WeakMap,a=new WeakMap,o=new WeakMap,u=new WeakMap,h=new WeakMap,l=new WeakMap,c=new WeakMap,d=new WeakMap,f=new WeakMap,Z=new WeakMap,p=new WeakMap,v=new WeakMap,y=new WeakSet,b=new WeakSet,w=new WeakSet,k=new WeakSet,R=new WeakSet,g=new WeakSet,O=new WeakSet,C=new WeakSet,S=new WeakSet,function(t){(0,F.Z)(i,t);var e=(0,L.Z)(i);function i(t,m){var W;return(0,U.Z)(this,i),W=e.call(this),(0,A.Z)((0,E.Z)(W),S),(0,A.Z)((0,E.Z)(W),C),(0,A.Z)((0,E.Z)(W),O),(0,A.Z)((0,E.Z)(W),g),(0,A.Z)((0,E.Z)(W),R),(0,A.Z)((0,E.Z)(W),k),(0,A.Z)((0,E.Z)(W),w),(0,A.Z)((0,E.Z)(W),b),(0,A.Z)((0,E.Z)(W),y),(0,P.Z)((0,E.Z)(W),n,{writable:!0,value:void 0}),(0,P.Z)((0,E.Z)(W),s,{writable:!0,value:void 0}),(0,P.Z)((0,E.Z)(W),r,{writable:!0,value:void 0}),(0,P.Z)((0,E.Z)(W),a,{writable:!0,value:void 0}),(0,P.Z)((0,E.Z)(W),o,{writable:!0,value:void 0}),(0,P.Z)((0,E.Z)(W),u,{writable:!0,value:void 0}),(0,P.Z)((0,E.Z)(W),h,{writable:!0,value:void 0}),(0,P.Z)((0,E.Z)(W),l,{writable:!0,value:void 0}),(0,P.Z)((0,E.Z)(W),c,{writable:!0,value:void 0}),(0,P.Z)((0,E.Z)(W),d,{writable:!0,value:void 0}),(0,P.Z)((0,E.Z)(W),f,{writable:!0,value:void 0}),(0,P.Z)((0,E.Z)(W),Z,{writable:!0,value:void 0}),(0,P.Z)((0,E.Z)(W),p,{writable:!0,value:void 0}),(0,P.Z)((0,E.Z)(W),v,{writable:!0,value:new Set}),W.options=m,(0,D.Z)((0,E.Z)(W),n,t),(0,D.Z)((0,E.Z)(W),h,null),W.bindMethods(),W.setOptions(m),W}return(0,M.Z)(i,[{key:"bindMethods",value:function(){this.refetch=this.refetch.bind(this)}},{key:"onSubscribe",value:function(){1===this.listeners.size&&((0,T.Z)(this,s).addObserver(this),Y((0,T.Z)(this,s),this.options)?(0,Q.Z)(this,y,N).call(this):this.updateResult(),(0,Q.Z)(this,R,z).call(this))}},{key:"onUnsubscribe",value:function(){this.hasListeners()||this.destroy()}},{key:"shouldFetchOnReconnect",value:function(){return tt((0,T.Z)(this,s),this.options,this.options.refetchOnReconnect)}},{key:"shouldFetchOnWindowFocus",value:function(){return tt((0,T.Z)(this,s),this.options,this.options.refetchOnWindowFocus)}},{key:"destroy",value:function(){this.listeners=new Set,(0,Q.Z)(this,g,H).call(this),(0,Q.Z)(this,O,$).call(this),(0,T.Z)(this,s).removeObserver(this)}},{key:"setOptions",value:function(t,e){var i=this.options,r=(0,T.Z)(this,s);if(this.options=(0,T.Z)(this,n).defaultQueryOptions(t),"undefined"!==typeof this.options.enabled&&"boolean"!==typeof this.options.enabled)throw new Error("Expected enabled to be a boolean");(0,Q.Z)(this,C,G).call(this),(0,_.VS)(this.options,i)||(0,T.Z)(this,n).getQueryCache().notify({type:"observerOptionsUpdated",query:(0,T.Z)(this,s),observer:this});var a=this.hasListeners();a&&et((0,T.Z)(this,s),r,this.options,i)&&(0,Q.Z)(this,y,N).call(this),this.updateResult(e),!a||(0,T.Z)(this,s)===r&&this.options.enabled===i.enabled&&this.options.staleTime===i.staleTime||(0,Q.Z)(this,b,V).call(this);var o=(0,Q.Z)(this,w,J).call(this);!a||(0,T.Z)(this,s)===r&&this.options.enabled===i.enabled&&o===(0,T.Z)(this,p)||(0,Q.Z)(this,k,K).call(this,o)}},{key:"getOptimisticResult",value:function(t){var e=(0,T.Z)(this,n).getQueryCache().build((0,T.Z)(this,n),t),i=this.createResult(e,t);return function(t,e){if(!(0,_.VS)(t.getCurrentResult(),e))return!0;return!1}(this,i)&&((0,D.Z)(this,a,i),(0,D.Z)(this,u,this.options),(0,D.Z)(this,o,(0,T.Z)(this,s).state)),i}},{key:"getCurrentResult",value:function(){return(0,T.Z)(this,a)}},{key:"trackResult",value:function(t){var e=this,i={};return Object.keys(t).forEach((function(n){Object.defineProperty(i,n,{configurable:!1,enumerable:!0,get:function(){return(0,T.Z)(e,v).add(n),t[n]}})})),i}},{key:"getCurrentQuery",value:function(){return(0,T.Z)(this,s)}},{key:"refetch",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=Object.assign({},((0,W.Z)(t),t));return this.fetch((0,m.Z)({},e))}},{key:"fetchOptimistic",value:function(t){var e=this,i=(0,T.Z)(this,n).defaultQueryOptions(t),s=(0,T.Z)(this,n).getQueryCache().build((0,T.Z)(this,n),i);return s.isFetchingOptimistic=!0,s.fetch().then((function(){return e.createResult(s,i)}))}},{key:"fetch",value:function(t){var e,i=this;return(0,Q.Z)(this,y,N).call(this,(0,m.Z)((0,m.Z)({},t),{},{cancelRefetch:null===(e=t.cancelRefetch)||void 0===e||e})).then((function(){return i.updateResult(),(0,T.Z)(i,a)}))}},{key:"createResult",value:function(t,e){var i,n=(0,T.Z)(this,s),f=this.options,Z=(0,T.Z)(this,a),p=(0,T.Z)(this,o),v=(0,T.Z)(this,u),y=t!==n?t.state:(0,T.Z)(this,r),b=t.state,w=b.error,k=b.errorUpdatedAt,R=b.fetchStatus,g=b.status,O=!1;if(e._optimisticResults){var C=this.hasListeners(),S=!C&&Y(t,e),m=C&&et(t,n,e,f);(S||m)&&(R=(0,B.Kw)(t.options.networkMode)?"fetching":"paused",b.dataUpdatedAt||(g="pending")),"isRestoring"===e._optimisticResults&&(R="idle")}if(e.select&&"undefined"!==typeof b.data)if(Z&&b.data===(null===p||void 0===p?void 0:p.data)&&e.select===(0,T.Z)(this,l))i=(0,T.Z)(this,c);else try{(0,D.Z)(this,l,e.select),i=e.select(b.data),i=(0,_.oE)(null===Z||void 0===Z?void 0:Z.data,i,e),(0,D.Z)(this,c,i),(0,D.Z)(this,h,null)}catch(A){(0,D.Z)(this,h,A)}else i=b.data;if("undefined"!==typeof e.placeholderData&&"undefined"===typeof i&&"pending"===g){var W,U;if(null!==Z&&void 0!==Z&&Z.isPlaceholderData&&e.placeholderData===(null===v||void 0===v?void 0:v.placeholderData))W=Z.data;else if(W="function"===typeof e.placeholderData?e.placeholderData(null===(U=(0,T.Z)(this,d))||void 0===U?void 0:U.state.data,(0,T.Z)(this,d)):e.placeholderData,e.select&&"undefined"!==typeof W)try{W=e.select(W),(0,D.Z)(this,h,null)}catch(A){(0,D.Z)(this,h,A)}"undefined"!==typeof W&&(g="success",i=(0,_.oE)(null===Z||void 0===Z?void 0:Z.data,W,e),O=!0)}(0,T.Z)(this,h)&&(w=(0,T.Z)(this,h),i=(0,T.Z)(this,c),k=Date.now(),g="error");var M="fetching"===R,E="pending"===g,F="error"===g,L=E&&M;return{status:g,fetchStatus:R,isPending:E,isSuccess:"success"===g,isError:F,isInitialLoading:L,isLoading:L,data:i,dataUpdatedAt:b.dataUpdatedAt,error:w,errorUpdatedAt:k,failureCount:b.fetchFailureCount,failureReason:b.fetchFailureReason,errorUpdateCount:b.errorUpdateCount,isFetched:b.dataUpdateCount>0||b.errorUpdateCount>0,isFetchedAfterMount:b.dataUpdateCount>y.dataUpdateCount||b.errorUpdateCount>y.errorUpdateCount,isFetching:M,isRefetching:M&&!E,isLoadingError:F&&0===b.dataUpdatedAt,isPaused:"paused"===R,isPlaceholderData:O,isRefetchError:F&&0!==b.dataUpdatedAt,isStale:it(t,e),refetch:this.refetch}}},{key:"updateResult",value:function(t){var e=this,i=(0,T.Z)(this,a),n=this.createResult((0,T.Z)(this,s),this.options);if((0,D.Z)(this,o,(0,T.Z)(this,s).state),(0,D.Z)(this,u,this.options),void 0!==(0,T.Z)(this,o).data&&(0,D.Z)(this,d,(0,T.Z)(this,s)),!(0,_.VS)(n,i)){(0,D.Z)(this,a,n);var r={};!1!==(null===t||void 0===t?void 0:t.listeners)&&function(){if(!i)return!0;var t=e.options.notifyOnChangeProps,n="function"===typeof t?t():t;if("all"===n||!n&&!(0,T.Z)(e,v).size)return!0;var s=new Set(null!==n&&void 0!==n?n:(0,T.Z)(e,v));return e.options.throwOnError&&s.add("error"),Object.keys((0,T.Z)(e,a)).some((function(t){var n=t;return(0,T.Z)(e,a)[n]!==i[n]&&s.has(n)}))}()&&(r.listeners=!0),(0,Q.Z)(this,S,X).call(this,(0,m.Z)((0,m.Z)({},r),t))}}},{key:"onQueryUpdate",value:function(){this.updateResult(),this.hasListeners()&&(0,Q.Z)(this,R,z).call(this)}}]),i}(x.l));function N(t){(0,Q.Z)(this,C,G).call(this);var e=(0,T.Z)(this,s).fetch(this.options,t);return null!==t&&void 0!==t&&t.throwOnError||(e=e.catch(_.ZT)),e}function V(){var t=this;if((0,Q.Z)(this,g,H).call(this),!_.sk&&!(0,T.Z)(this,a).isStale&&(0,_.PN)(this.options.staleTime)){var e=(0,_.Kp)((0,T.Z)(this,a).dataUpdatedAt,this.options.staleTime)+1;(0,D.Z)(this,f,setTimeout((function(){(0,T.Z)(t,a).isStale||t.updateResult()}),e))}}function J(){var t;return null!==(t="function"===typeof this.options.refetchInterval?this.options.refetchInterval((0,T.Z)(this,s)):this.options.refetchInterval)&&void 0!==t&&t}function K(t){var e=this;(0,Q.Z)(this,O,$).call(this),(0,D.Z)(this,p,t),!_.sk&&!1!==this.options.enabled&&(0,_.PN)((0,T.Z)(this,p))&&0!==(0,T.Z)(this,p)&&(0,D.Z)(this,Z,setInterval((function(){(e.options.refetchIntervalInBackground||j.j.isFocused())&&(0,Q.Z)(e,y,N).call(e)}),(0,T.Z)(this,p)))}function z(){(0,Q.Z)(this,b,V).call(this),(0,Q.Z)(this,k,K).call(this,(0,Q.Z)(this,w,J).call(this))}function H(){(0,T.Z)(this,f)&&(clearTimeout((0,T.Z)(this,f)),(0,D.Z)(this,f,void 0))}function $(){(0,T.Z)(this,Z)&&(clearInterval((0,T.Z)(this,Z)),(0,D.Z)(this,Z,void 0))}function G(){var t=(0,T.Z)(this,n).getQueryCache().build((0,T.Z)(this,n),this.options);if(t!==(0,T.Z)(this,s)){var e=(0,T.Z)(this,s);(0,D.Z)(this,s,t),(0,D.Z)(this,r,t.state),this.hasListeners()&&(null===e||void 0===e||e.removeObserver(this),t.addObserver(this))}}function X(t){var e=this;I.V.batch((function(){t.listeners&&e.listeners.forEach((function(t){t((0,T.Z)(e,a))})),(0,T.Z)(e,n).getQueryCache().notify({query:(0,T.Z)(e,s),type:"observerResultsUpdated"})}))}function Y(t,e){return function(t,e){return!1!==e.enabled&&!t.state.dataUpdatedAt&&!("error"===t.state.status&&!1===e.retryOnMount)}(t,e)||t.state.dataUpdatedAt>0&&tt(t,e,e.refetchOnMount)}function tt(t,e,i){if(!1!==e.enabled){var n="function"===typeof i?i(t):i;return"always"===n||!1!==n&&it(t,e)}return!1}function et(t,e,i,n){return!1!==i.enabled&&(t!==e||!1===n.enabled)&&(!i.suspense||"error"!==t.state.status)&&it(t,i)}function it(t,e){return t.isStaleByTime(e.staleTime)}},70048:function(t,e,i){i.d(e,{_:function(){return a}});var n=i(47313);i(46417);function s(){var t=!1;return{clearReset:function(){t=!1},reset:function(){t=!0},isReset:function(){return t}}}var r=n.createContext(s()),a=function(){return n.useContext(r)}},27958:function(t,e,i){i.d(e,{JN:function(){return a},KJ:function(){return o},pf:function(){return r}});var n=i(47313),s=i(24772),r=function(t,e){(t.suspense||t.throwOnError)&&(e.isReset()||(t.retryOnMount=!1))},a=function(t){n.useEffect((function(){t.clearReset()}),[t])},o=function(t){var e=t.result,i=t.errorResetBoundary,n=t.throwOnError,r=t.query;return e.isError&&!i.isReset()&&!e.isFetching&&r&&(0,s.L)(n,[e.error,r])}},36055:function(t,e,i){i.d(e,{S:function(){return r}});var n=i(47313),s=n.createContext(!1),r=function(){return n.useContext(s)};s.Provider},56526:function(t,e,i){i.d(e,{Fb:function(){return n},SB:function(){return r},Z$:function(){return s},j8:function(){return a}});var n=function(t){t.suspense&&"number"!==typeof t.staleTime&&(t.staleTime=1e3)},s=function(t,e){return t.isLoading&&t.isFetching&&!e},r=function(t,e){return(null===t||void 0===t?void 0:t.suspense)&&e.isPending},a=function(t,e,i){return e.fetchOptimistic(t).catch((function(){i.clearReset()}))}},51695:function(t,e,i){i.d(e,{r:function(){return c}});var n=i(29439),s=i(47313),r=i(28127),a=i(70048),o=i(67109),u=i(36055),h=i(27958),l=i(56526);function c(t,e,i){var c=(0,o.NL)(i),d=(0,u.S)(),f=(0,a._)(),Z=c.defaultQueryOptions(t);Z._optimisticResults=d?"isRestoring":"optimistic",(0,l.Fb)(Z),(0,h.pf)(Z,f),(0,h.JN)(f);var p=s.useState((function(){return new e(c,Z)})),v=(0,n.Z)(p,1)[0],y=v.getOptimisticResult(Z);if(s.useSyncExternalStore(s.useCallback((function(t){var e=d?function(){}:v.subscribe(r.V.batchCalls(t));return v.updateResult(),e}),[v,d]),(function(){return v.getCurrentResult()}),(function(){return v.getCurrentResult()})),s.useEffect((function(){v.setOptions(Z,{listeners:!1})}),[Z,v]),(0,l.SB)(Z,y))throw(0,l.j8)(Z,v,f);if((0,h.KJ)({result:y,errorResetBoundary:f,throwOnError:Z.throwOnError,query:c.getQueryCache().get(Z.queryHash)}))throw y.error;return Z.notifyOnChangeProps?y:v.trackResult(y)}},24772:function(t,e,i){i.d(e,{L:function(){return s}});var n=i(93433);function s(t,e){return"function"===typeof t?t.apply(void 0,(0,n.Z)(e)):!!t}}}]);