@tramvai/react-query 2.40.0 → 2.44.2

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.
@@ -1,8 +1,8 @@
1
1
  import type { ActionConditionsParameters, ActionContext, TramvaiAction } from '@tramvai/core';
2
2
  import type { QueryKey as ReactQueryKey, QueryOptions } from '@tanstack/react-query';
3
3
  export declare const QUERY_PARAMETERS = "__query_parameters__";
4
- export declare type ReactQueryKeyOrString = ReactQueryKey | string;
5
- export declare type QueryKey<Options> = ((options: Options) => ReactQueryKeyOrString) | ReactQueryKeyOrString;
4
+ export type ReactQueryKeyOrString = ReactQueryKey | string;
5
+ export type QueryKey<Options> = ((options: Options) => ReactQueryKeyOrString) | ReactQueryKeyOrString;
6
6
  export interface BaseCreateQueryOptions<Options, Deps> {
7
7
  key: QueryKey<Options>;
8
8
  fn: Function;
@@ -8,6 +8,6 @@ export interface CreateInfiniteQueryOptions<Options, PageParam, Result, Deps> ex
8
8
  getNextPageParam?: (lastPage: Result, allPages: Result[]) => PageParam;
9
9
  getPreviousPageParam?: (firstPage: Result, allPages: Result[]) => PageParam;
10
10
  }
11
- export declare type InfiniteQuery<Options, PageParam, Result, Deps> = BaseQuery<Options, CreateInfiniteQueryOptions<Options, PageParam, Result, Deps>, InfiniteQuery<Options, PageParam, Result, Deps>, UseInfiniteQueryOptions<Result, Error>> & {
11
+ export type InfiniteQuery<Options, PageParam, Result, Deps> = BaseQuery<Options, CreateInfiniteQueryOptions<Options, PageParam, Result, Deps>, InfiniteQuery<Options, PageParam, Result, Deps>, UseInfiniteQueryOptions<Result, Error>> & {
12
12
  fetchAction(options?: Options): TramvaiAction<[], Promise<InfiniteData<Result>>, any>;
13
13
  };
@@ -2,7 +2,7 @@ import type { ActionConditionsParameters, ActionContext } from '@tramvai/core';
2
2
  import type { ProvideDepsIterator } from '@tinkoff/dippy';
3
3
  import type { MutationKey as ReactMutationKey, MutationOptions, UseMutationOptions } from '@tanstack/react-query';
4
4
  export declare const MUTATION_PARAMETERS = "__mutations_parameters__";
5
- export declare type MutationKey<Options> = ((options?: Options) => ReactMutationKey) | ReactMutationKey;
5
+ export type MutationKey<Options> = ((options?: Options) => ReactMutationKey) | ReactMutationKey;
6
6
  export interface CreateMutationOptions<Options, Variables, Result, Deps, Key extends MutationKey<Options> = (options?: Options) => ReactMutationKey> {
7
7
  key?: Key;
8
8
  mutationOptions?: UseMutationOptions<Result, any, Variables>;
@@ -6,6 +6,6 @@ export interface CreateQueryOptions<Options, Result, Deps> extends BaseCreateQue
6
6
  queryOptions?: UseQueryOptions<Result, Error>;
7
7
  fn: (options: Options, deps: ProvideDepsIterator<Deps>) => Promise<Result>;
8
8
  }
9
- export declare type Query<Options, Result, Deps> = BaseQuery<Options, CreateQueryOptions<Options, Result, Deps>, Query<Options, Result, Deps>, UseQueryOptions<Result, Error>> & {
9
+ export type Query<Options, Result, Deps> = BaseQuery<Options, CreateQueryOptions<Options, Result, Deps>, Query<Options, Result, Deps>, UseQueryOptions<Result, Error>> & {
10
10
  fetchAction(options?: Options): TramvaiAction<[], Promise<Result>, any>;
11
11
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tramvai/react-query",
3
- "version": "2.40.0",
3
+ "version": "2.44.2",
4
4
  "description": "",
5
5
  "main": "lib/index.js",
6
6
  "typings": "lib/index.d.ts",
@@ -19,10 +19,10 @@
19
19
  },
20
20
  "dependencies": {
21
21
  "@tinkoff/react-hooks": "0.1.4",
22
- "@tramvai/core": "2.40.0",
23
- "@tramvai/module-react-query": "2.40.0",
24
- "@tramvai/state": "2.40.0",
25
- "@tramvai/tokens-common": "2.40.0"
22
+ "@tramvai/core": "2.44.2",
23
+ "@tramvai/module-react-query": "2.44.2",
24
+ "@tramvai/state": "2.44.2",
25
+ "@tramvai/tokens-common": "2.44.2"
26
26
  },
27
27
  "peerDependencies": {
28
28
  "@tinkoff/dippy": "0.8.9",