cozy-client 51.6.1 → 52.0.0
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/CozyClient.js +70 -47
- package/dist/CozyClient.spec.js +15 -15
- package/dist/CozyLink.js +9 -8
- package/dist/CozyLink.spec.js +12 -12
- package/dist/StackLink.js +19 -12
- package/dist/WebFlagshipLink.js +4 -4
- package/dist/associations.spec.js +2 -1
- package/dist/index.js +20 -2
- package/dist/index.node.js +20 -2
- package/dist/performances/defaultPerformanceApi.js +15 -0
- package/dist/performances/types.js +26 -0
- package/dist/performances/webPerformanceApi.js +60 -0
- package/dist/store/index.js +49 -24
- package/dist/store/queries.js +34 -11
- package/dist/store/queries.spec.js +2 -1
- package/dist/store.spec.js +4 -1
- package/dist/types.js +1 -0
- package/package.json +3 -3
- package/types/CozyClient.d.ts +8 -1
- package/types/CozyLink.d.ts +2 -1
- package/types/StackLink.d.ts +9 -2
- package/types/index.d.ts +2 -0
- package/types/index.node.d.ts +2 -0
- package/types/performances/defaultPerformanceApi.d.ts +2 -0
- package/types/performances/types.d.ts +25 -0
- package/types/performances/webPerformanceApi.d.ts +2 -0
- package/types/store/index.d.ts +3 -3
- package/types/store/queries.d.ts +2 -1
- package/types/types.d.ts +4 -0
package/types/store/index.d.ts
CHANGED
|
@@ -7,11 +7,11 @@ export class StoreProxy {
|
|
|
7
7
|
getState(): any;
|
|
8
8
|
}
|
|
9
9
|
export default combinedReducer;
|
|
10
|
-
export function createStore(): any;
|
|
11
|
-
declare function combinedReducer(state: {
|
|
10
|
+
export function createStore(performanceApi: any): any;
|
|
11
|
+
declare function combinedReducer(performanceApi: any): (state: {
|
|
12
12
|
documents: {};
|
|
13
13
|
queries: {};
|
|
14
|
-
}, action: any)
|
|
14
|
+
}, action: any) => {
|
|
15
15
|
documents: any;
|
|
16
16
|
queries: Record<string, import("../types").QueryState>;
|
|
17
17
|
};
|
package/types/store/queries.d.ts
CHANGED
|
@@ -39,10 +39,11 @@ export namespace QueryIDGenerator {
|
|
|
39
39
|
}
|
|
40
40
|
import { QueryDefinition } from "../queries/dsl";
|
|
41
41
|
/**
|
|
42
|
+
* @param {import('../performances/types').PerformanceAPI} performanceApi - The performance API that can be used to measure performances
|
|
42
43
|
* @param {import("../types").QueriesStateSlice} state - Redux slice containing all the query states indexed by name
|
|
43
44
|
* @param {object} action - Income redux action
|
|
44
45
|
* @param {import("../types").DocumentsStateSlice} documents - Reference to documents slice
|
|
45
46
|
* @param {boolean} haveDocumentsChanged - Has the document slice changed with current action
|
|
46
47
|
* @returns {import("../types").QueriesStateSlice}
|
|
47
48
|
*/
|
|
48
|
-
declare function queries(state: import("../types").QueriesStateSlice, action: object, documents?: import("../types").DocumentsStateSlice, haveDocumentsChanged?: boolean): import("../types").QueriesStateSlice;
|
|
49
|
+
declare function queries(performanceApi: import('../performances/types').PerformanceAPI, state: import("../types").QueriesStateSlice, action: object, documents?: import("../types").DocumentsStateSlice, haveDocumentsChanged?: boolean): import("../types").QueriesStateSlice;
|
package/types/types.d.ts
CHANGED
|
@@ -553,6 +553,10 @@ export type QueryOptions = {
|
|
|
553
553
|
* - If set to true, the query will be run directly on the current store's state
|
|
554
554
|
*/
|
|
555
555
|
executeFromStore?: boolean;
|
|
556
|
+
/**
|
|
557
|
+
* - If set to true, the query will be executed through StackLink only even if there are other links available
|
|
558
|
+
*/
|
|
559
|
+
forceStack?: boolean;
|
|
556
560
|
};
|
|
557
561
|
export type Query = {
|
|
558
562
|
definition: QueryDefinition;
|