@local-logic/sdks-app 1.0.0-beta.65 → 1.0.0-beta.67
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.
- package/dist/assets/{auto-track-legacy.bcbecbf8.js → auto-track-legacy.f9840683.js} +1 -1
- package/dist/assets/{auto-track.243da627.js → auto-track.f73c34a7.js} +1 -1
- package/dist/assets/{chevron_right-legacy.c94205d1.js → chevron_right-legacy.4a96f715.js} +1 -1
- package/dist/assets/{chevron_right.ed021687.js → chevron_right.427d77f6.js} +1 -1
- package/dist/assets/{index-legacy.8c3f4d82.js → index-legacy.0d90becf.js} +4 -4
- package/dist/assets/{index-legacy.9b2b6e12.js → index-legacy.211144f2.js} +1 -1
- package/dist/assets/{index-legacy.12dc81c1.js → index-legacy.3b49d3a5.js} +1 -1
- package/dist/assets/{index-legacy.3055f688.js → index-legacy.45d65bd6.js} +1 -1
- package/dist/assets/{index-legacy.c489e13e.js → index-legacy.45d7b5c7.js} +1 -1
- package/dist/assets/{index-legacy.0b1c2bb2.js → index-legacy.631596f5.js} +1 -1
- package/dist/assets/{index-legacy.625673e9.js → index-legacy.6ed29dcf.js} +1 -1
- package/dist/assets/{index-legacy.415cee9b.js → index-legacy.b87ca0ca.js} +1 -1
- package/dist/assets/{index-legacy.6eb621a2.js → index-legacy.c10a590c.js} +6 -6
- package/dist/assets/{index.d07e0117.js → index.4b5f7238.js} +1 -1
- package/dist/assets/index.603b7e8b.js +1 -0
- package/dist/assets/{index.78e59a55.js → index.689aa908.js} +204 -204
- package/dist/assets/{index.a829928a.js → index.9c7a418d.js} +1 -1
- package/dist/assets/{index.59c286d1.js → index.aad70e37.js} +1 -1
- package/dist/assets/{index.59699164.js → index.adca6e84.js} +1 -1
- package/dist/assets/{index.3b922ccc.js → index.c9949bba.js} +1 -1
- package/dist/assets/{index.fcbca47f.js → index.e77bdb0c.js} +11 -11
- package/dist/assets/{index.661181da.js → index.fd288973.js} +1 -1
- package/dist/assets/{index.umd-legacy.ea5626e0.js → index.umd-legacy.77e7f5f5.js} +1 -1
- package/dist/assets/{index.umd.6358a889.js → index.umd.3636b63d.js} +1 -1
- package/dist/index.html +2 -2
- package/package.json +3 -3
- package/dist/assets/index.95642d9d.js +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{S as wp,D as eh,E as Tp,G as th,H as ih,J as Ep,K as Sp,
|
|
1
|
+
import{S as wp,D as eh,E as Tp,G as th,H as ih,J as Ep,K as Sp,M as Ip,P as rh,Q as Cp,T as Ks,r as _e,V as Ap,W as Mp,g as zp,j as cl,X as Tc,d as Pp,R as lt,Y as kp,Z as Ei,$ as Dp}from"./index.689aa908.js";class Lp extends wp{constructor(L,B){super(),this.client=L,this.options=B,this.trackedProps=new Set,this.selectError=null,this.bindMethods(),this.setOptions(B)}bindMethods(){this.remove=this.remove.bind(this),this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.length===1&&(this.currentQuery.addObserver(this),nh(this.currentQuery,this.options)&&this.executeFetch(),this.updateTimers())}onUnsubscribe(){this.listeners.length||this.destroy()}shouldFetchOnReconnect(){return vc(this.currentQuery,this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return vc(this.currentQuery,this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=[],this.clearStaleTimeout(),this.clearRefetchInterval(),this.currentQuery.removeObserver(this)}setOptions(L,B){const j=this.options,G=this.currentQuery;if(this.options=this.client.defaultQueryOptions(L),eh(j,this.options)||this.client.getQueryCache().notify({type:"observerOptionsUpdated",query:this.currentQuery,observer:this}),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=j.queryKey),this.updateQuery();const X=this.hasListeners();X&&oh(this.currentQuery,G,this.options,j)&&this.executeFetch(),this.updateResult(B),X&&(this.currentQuery!==G||this.options.enabled!==j.enabled||this.options.staleTime!==j.staleTime)&&this.updateStaleTimeout();const ge=this.computeRefetchInterval();X&&(this.currentQuery!==G||this.options.enabled!==j.enabled||ge!==this.currentRefetchInterval)&&this.updateRefetchInterval(ge)}getOptimisticResult(L){const B=this.client.getQueryCache().build(this.client,L);return this.createResult(B,L)}getCurrentResult(){return this.currentResult}trackResult(L){const B={};return Object.keys(L).forEach(j=>{Object.defineProperty(B,j,{configurable:!1,enumerable:!0,get:()=>(this.trackedProps.add(j),L[j])})}),B}getCurrentQuery(){return this.currentQuery}remove(){this.client.getQueryCache().remove(this.currentQuery)}refetch({refetchPage:L,...B}={}){return this.fetch({...B,meta:{refetchPage:L}})}fetchOptimistic(L){const B=this.client.defaultQueryOptions(L),j=this.client.getQueryCache().build(this.client,B);return j.isFetchingOptimistic=!0,j.fetch().then(()=>this.createResult(j,B))}fetch(L){var B;return this.executeFetch({...L,cancelRefetch:(B=L.cancelRefetch)!=null?B:!0}).then(()=>(this.updateResult(),this.currentResult))}executeFetch(L){this.updateQuery();let B=this.currentQuery.fetch(this.options,L);return L!=null&&L.throwOnError||(B=B.catch(Tp)),B}updateStaleTimeout(){if(this.clearStaleTimeout(),th||this.currentResult.isStale||!ih(this.options.staleTime))return;const B=Ep(this.currentResult.dataUpdatedAt,this.options.staleTime)+1;this.staleTimeoutId=setTimeout(()=>{this.currentResult.isStale||this.updateResult()},B)}computeRefetchInterval(){var L;return typeof this.options.refetchInterval=="function"?this.options.refetchInterval(this.currentResult.data,this.currentQuery):(L=this.options.refetchInterval)!=null?L:!1}updateRefetchInterval(L){this.clearRefetchInterval(),this.currentRefetchInterval=L,!(th||this.options.enabled===!1||!ih(this.currentRefetchInterval)||this.currentRefetchInterval===0)&&(this.refetchIntervalId=setInterval(()=>{(this.options.refetchIntervalInBackground||Sp.isFocused())&&this.executeFetch()},this.currentRefetchInterval))}updateTimers(){this.updateStaleTimeout(),this.updateRefetchInterval(this.computeRefetchInterval())}clearStaleTimeout(){this.staleTimeoutId&&(clearTimeout(this.staleTimeoutId),this.staleTimeoutId=void 0)}clearRefetchInterval(){this.refetchIntervalId&&(clearInterval(this.refetchIntervalId),this.refetchIntervalId=void 0)}createResult(L,B){const j=this.currentQuery,G=this.options,X=this.currentResult,ge=this.currentResultState,l=this.currentResultOptions,ye=L!==j,pe=ye?L.state:this.currentQueryInitialState,Ce=ye?this.currentResult:this.previousQueryResult,{state:we}=L;let{dataUpdatedAt:ne,error:ht,errorUpdatedAt:st,fetchStatus:He,status:_t}=we,Mt=!1,ct=!1,bt;if(B._optimisticResults){const Dt=this.hasListeners(),Fi=!Dt&&nh(L,B),_i=Dt&&oh(L,j,B,G);(Fi||_i)&&(He=Ip(L.options.networkMode)?"fetching":"paused",ne||(_t="loading")),B._optimisticResults==="isRestoring"&&(He="idle")}if(B.keepPreviousData&&!we.dataUpdateCount&&Ce!=null&&Ce.isSuccess&&_t!=="error")bt=Ce.data,ne=Ce.dataUpdatedAt,_t=Ce.status,Mt=!0;else if(B.select&&typeof we.data<"u")if(X&&we.data===(ge==null?void 0:ge.data)&&B.select===this.selectFn)bt=this.selectResult;else try{this.selectFn=B.select,bt=B.select(we.data),bt=rh(X==null?void 0:X.data,bt,B),this.selectResult=bt,this.selectError=null}catch(Dt){this.selectError=Dt}else bt=we.data;if(typeof B.placeholderData<"u"&&typeof bt>"u"&&_t==="loading"){let Dt;if(X!=null&&X.isPlaceholderData&&B.placeholderData===(l==null?void 0:l.placeholderData))Dt=X.data;else if(Dt=typeof B.placeholderData=="function"?B.placeholderData():B.placeholderData,B.select&&typeof Dt<"u")try{Dt=B.select(Dt),Dt=rh(X==null?void 0:X.data,Dt,B),this.selectError=null}catch(Fi){this.selectError=Fi}typeof Dt<"u"&&(_t="success",bt=Dt,ct=!0)}this.selectError&&(ht=this.selectError,bt=this.selectResult,st=Date.now(),_t="error");const Si=He==="fetching";return{status:_t,fetchStatus:He,isLoading:_t==="loading",isSuccess:_t==="success",isError:_t==="error",data:bt,dataUpdatedAt:ne,error:ht,errorUpdatedAt:st,failureCount:we.fetchFailureCount,errorUpdateCount:we.errorUpdateCount,isFetched:we.dataUpdateCount>0||we.errorUpdateCount>0,isFetchedAfterMount:we.dataUpdateCount>pe.dataUpdateCount||we.errorUpdateCount>pe.errorUpdateCount,isFetching:Si,isRefetching:Si&&_t!=="loading",isLoadingError:_t==="error"&&we.dataUpdatedAt===0,isPaused:He==="paused",isPlaceholderData:ct,isPreviousData:Mt,isRefetchError:_t==="error"&&we.dataUpdatedAt!==0,isStale:Ec(L,B),refetch:this.refetch,remove:this.remove}}updateResult(L){const B=this.currentResult,j=this.createResult(this.currentQuery,this.options);if(this.currentResultState=this.currentQuery.state,this.currentResultOptions=this.options,eh(j,B))return;this.currentResult=j;const G={cache:!0},X=()=>{if(!B)return!0;const{notifyOnChangeProps:ge}=this.options;if(ge==="all"||!ge&&!this.trackedProps.size)return!0;const l=new Set(ge!=null?ge:this.trackedProps);return this.options.useErrorBoundary&&l.add("error"),Object.keys(this.currentResult).some(ye=>{const pe=ye;return this.currentResult[pe]!==B[pe]&&l.has(pe)})};(L==null?void 0:L.listeners)!==!1&&X()&&(G.listeners=!0),this.notify({...G,...L})}updateQuery(){const L=this.client.getQueryCache().build(this.client,this.options);if(L===this.currentQuery)return;const B=this.currentQuery;this.currentQuery=L,this.currentQueryInitialState=L.state,this.previousQueryResult=this.currentResult,this.hasListeners()&&(B==null||B.removeObserver(this),L.addObserver(this))}onQueryUpdate(L){const B={};L.type==="success"?B.onSuccess=!L.manual:L.type==="error"&&!Cp(L.error)&&(B.onError=!0),this.updateResult(B),this.hasListeners()&&this.updateTimers()}notify(L){Ks.batch(()=>{if(L.onSuccess){var B,j,G,X;(B=(j=this.options).onSuccess)==null||B.call(j,this.currentResult.data),(G=(X=this.options).onSettled)==null||G.call(X,this.currentResult.data,null)}else if(L.onError){var ge,l,ye,pe;(ge=(l=this.options).onError)==null||ge.call(l,this.currentResult.error),(ye=(pe=this.options).onSettled)==null||ye.call(pe,void 0,this.currentResult.error)}L.listeners&&this.listeners.forEach(Ce=>{Ce(this.currentResult)}),L.cache&&this.client.getQueryCache().notify({query:this.currentQuery,type:"observerResultsUpdated"})})}}function Rp(A,L){return L.enabled!==!1&&!A.state.dataUpdatedAt&&!(A.state.status==="error"&&L.retryOnMount===!1)}function nh(A,L){return Rp(A,L)||A.state.dataUpdatedAt>0&&vc(A,L,L.refetchOnMount)}function vc(A,L,B){if(L.enabled!==!1){const j=typeof B=="function"?B(A):B;return j==="always"||j!==!1&&Ec(A,L)}return!1}function oh(A,L,B,j){return B.enabled!==!1&&(A!==L||j.enabled===!1)&&(!B.suspense||A.state.status!=="error")&&Ec(A,B)}function Ec(A,L){return A.isStaleByTime(L.staleTime)}const ph=_e.exports.createContext(!1),Bp=()=>_e.exports.useContext(ph);ph.Provider;var fh={exports:{}},mh={};/**
|
|
2
2
|
* @license React
|
|
3
3
|
* use-sync-external-store-shim.production.min.js
|
|
4
4
|
*
|