@powerhousedao/reactor-browser 6.0.0-dev.101 → 6.0.0-dev.103

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.
@@ -59711,29 +59711,19 @@ var TimeoutManager = class {
59711
59711
  #provider = defaultTimeoutProvider;
59712
59712
  #providerCalled = false;
59713
59713
  setTimeoutProvider(provider) {
59714
- if (true) {
59715
- if (this.#providerCalled && provider !== this.#provider) {
59716
- console.error(`[timeoutManager]: Switching provider after calls to previous provider might result in unexpected behavior.`, { previous: this.#provider, provider });
59717
- }
59718
- }
59714
+ if (false) {}
59719
59715
  this.#provider = provider;
59720
- if (true) {
59721
- this.#providerCalled = false;
59722
- }
59716
+ if (false) {}
59723
59717
  }
59724
59718
  setTimeout(callback, delay) {
59725
- if (true) {
59726
- this.#providerCalled = true;
59727
- }
59719
+ if (false) {}
59728
59720
  return this.#provider.setTimeout(callback, delay);
59729
59721
  }
59730
59722
  clearTimeout(timeoutId) {
59731
59723
  this.#provider.clearTimeout(timeoutId);
59732
59724
  }
59733
59725
  setInterval(callback, delay) {
59734
- if (true) {
59735
- this.#providerCalled = true;
59736
- }
59726
+ if (false) {}
59737
59727
  return this.#provider.setInterval(callback, delay);
59738
59728
  }
59739
59729
  clearInterval(intervalId) {
@@ -59928,14 +59918,7 @@ function replaceData(prevData, data, options) {
59928
59918
  if (typeof options.structuralSharing === "function") {
59929
59919
  return options.structuralSharing(prevData, data);
59930
59920
  } else if (options.structuralSharing !== false) {
59931
- if (true) {
59932
- try {
59933
- return replaceEqualDeep(prevData, data);
59934
- } catch (error) {
59935
- console.error(`Structural sharing requires data to be JSON serializable. To fix this, turn off structuralSharing or return JSON-serializable data from your queryFn. [${options.queryHash}]: ${error}`);
59936
- throw error;
59937
- }
59938
- }
59921
+ if (false) {}
59939
59922
  return replaceEqualDeep(prevData, data);
59940
59923
  }
59941
59924
  return data;
@@ -59950,11 +59933,7 @@ function addToStart(items, item, max = 0) {
59950
59933
  }
59951
59934
  var skipToken = /* @__PURE__ */ Symbol();
59952
59935
  function ensureQueryFn(options, fetchOptions) {
59953
- if (true) {
59954
- if (options.queryFn === skipToken) {
59955
- console.error(`Attempted to invoke queryFn when set to skipToken. This is likely a configuration error. Query hash: '${options.queryHash}'`);
59956
- }
59957
- }
59936
+ if (false) {}
59958
59937
  if (!options.queryFn && fetchOptions?.initialPromise) {
59959
59938
  return () => fetchOptions.initialPromise;
59960
59939
  }
@@ -60514,11 +60493,7 @@ var Query = class extends Removable {
60514
60493
  this.setOptions(observer.options);
60515
60494
  }
60516
60495
  }
60517
- if (true) {
60518
- if (!Array.isArray(this.options.queryKey)) {
60519
- console.error(`As of v4, queryKey needs to be an Array. If you are using a string like 'repoData', please change it to an Array, e.g. ['repoData']`);
60520
- }
60521
- }
60496
+ if (false) {}
60522
60497
  const abortController = new AbortController;
60523
60498
  const addSignalProperty = (object) => {
60524
60499
  Object.defineProperty(object, "signal", {
@@ -60594,9 +60569,7 @@ var Query = class extends Removable {
60594
60569
  try {
60595
60570
  const data = await this.#retryer.start();
60596
60571
  if (data === undefined) {
60597
- if (true) {
60598
- console.error(`Query data cannot be undefined. Please make sure to return a value other than undefined from your query function. Affected query key: ${this.queryHash}`);
60599
- }
60572
+ if (false) {}
60600
60573
  throw new Error(`${this.queryHash} data is undefined`);
60601
60574
  }
60602
60575
  this.setData(data);
@@ -62135,22 +62108,14 @@ var fetchOptimistic = (defaultedOptions, observer, errorResetBoundary) => observ
62135
62108
  // ../../node_modules/.pnpm/@tanstack+react-query@5.90.21_react@19.2.4/node_modules/@tanstack/react-query/build/modern/useBaseQuery.js
62136
62109
  "use client";
62137
62110
  function useBaseQuery(options, Observer, queryClient) {
62138
- if (true) {
62139
- if (typeof options !== "object" || Array.isArray(options)) {
62140
- throw new Error('Bad argument type. Starting with v5, only the "Object" form is allowed when calling query related functions. Please use the error stack to find the culprit call. More info here: https://tanstack.com/query/latest/docs/react/guides/migrating-to-v5#supports-a-single-signature-one-object');
62141
- }
62142
- }
62111
+ if (false) {}
62143
62112
  const isRestoring = useIsRestoring();
62144
62113
  const errorResetBoundary = useQueryErrorResetBoundary();
62145
62114
  const client = useQueryClient(queryClient);
62146
62115
  const defaultedOptions = client.defaultQueryOptions(options);
62147
62116
  client.getDefaultOptions().queries?._experimental_beforeQuery?.(defaultedOptions);
62148
62117
  const query = client.getQueryCache().get(defaultedOptions.queryHash);
62149
- if (true) {
62150
- if (!defaultedOptions.queryFn) {
62151
- console.error(`[${defaultedOptions.queryHash}]: No queryFn was passed as an option, and no default queryFn was found. The queryFn parameter is only optional when using a default queryFn. More info here: https://tanstack.com/query/latest/docs/framework/react/guides/default-query-function`);
62152
- }
62153
- }
62118
+ if (false) {}
62154
62119
  defaultedOptions._optimisticResults = isRestoring ? "isRestoring" : "optimistic";
62155
62120
  ensureSuspenseTimers(defaultedOptions);
62156
62121
  ensurePreventErrorBoundaryRetry(defaultedOptions, errorResetBoundary, query);
@@ -62198,11 +62163,7 @@ function useQuery(options, queryClient) {
62198
62163
  // ../../node_modules/.pnpm/@tanstack+react-query@5.90.21_react@19.2.4/node_modules/@tanstack/react-query/build/modern/useSuspenseQuery.js
62199
62164
  "use client";
62200
62165
  function useSuspenseQuery(options, queryClient) {
62201
- if (true) {
62202
- if (options.queryFn === skipToken) {
62203
- console.error("skipToken is not allowed for useSuspenseQuery");
62204
- }
62205
- }
62166
+ if (false) {}
62206
62167
  return useBaseQuery({
62207
62168
  ...options,
62208
62169
  enabled: true,
@@ -62257,7 +62218,7 @@ function clearGlobal(namespace) {
62257
62218
  }
62258
62219
 
62259
62220
  // src/analytics/context.tsx
62260
- import { jsxDEV } from "react/jsx-dev-runtime";
62221
+ import { jsx as jsx3, jsxs } from "react/jsx-runtime";
62261
62222
  var logger = childLogger(["reactor-browser", "analytics", "provider"]);
62262
62223
  var defaultQueryClient = new QueryClient;
62263
62224
  var analyticsOptionsKey = ["analytics", "options"];
@@ -62367,15 +62328,15 @@ function AnalyticsProvider({
62367
62328
  queryClient = defaultQueryClient,
62368
62329
  ...props
62369
62330
  }) {
62370
- return /* @__PURE__ */ jsxDEV(QueryClientProvider, {
62331
+ return /* @__PURE__ */ jsxs(QueryClientProvider, {
62371
62332
  client: queryClient,
62372
62333
  children: [
62373
- /* @__PURE__ */ jsxDEV(CreateAnalyticsStore, {
62334
+ /* @__PURE__ */ jsx3(CreateAnalyticsStore, {
62374
62335
  ...props
62375
- }, undefined, false, undefined, this),
62336
+ }),
62376
62337
  children
62377
62338
  ]
62378
- }, undefined, true, undefined, this);
62339
+ });
62379
62340
  }
62380
62341
  function useAnalyticsEngine() {
62381
62342
  return useSuspenseQuery({