monday-sdk-js 0.5.3 → 0.5.4
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/package.json +1 -1
- package/types/client-data.interface.ts +20 -0
- package/types/index.d.ts +11 -11
package/package.json
CHANGED
|
@@ -1,10 +1,28 @@
|
|
|
1
1
|
import { AppFeatureContextMap, AppFeatureTypes } from "./client-context.type";
|
|
2
2
|
|
|
3
|
+
export type LocationResponse = Record<string, any> & {
|
|
4
|
+
href: string;
|
|
5
|
+
search: string;
|
|
6
|
+
};
|
|
7
|
+
|
|
8
|
+
export type FilterResponse = Record<string, any> & {
|
|
9
|
+
term: string;
|
|
10
|
+
rules: (Record<string, any> & {
|
|
11
|
+
column_id?: string;
|
|
12
|
+
compare_value?: string[];
|
|
13
|
+
compare_attribute?: string;
|
|
14
|
+
operator?: string;
|
|
15
|
+
})[];
|
|
16
|
+
operator: string | null;
|
|
17
|
+
};
|
|
18
|
+
|
|
3
19
|
type SubscribableEventsResponse<AppFeatureType extends AppFeatureTypes = AppFeatureTypes> = {
|
|
4
20
|
context: AppFeatureContextMap[AppFeatureType];
|
|
5
21
|
settings: Record<string, any>;
|
|
6
22
|
itemIds: number[];
|
|
7
23
|
events: Record<string, any>;
|
|
24
|
+
location: LocationResponse;
|
|
25
|
+
filter: FilterResponse;
|
|
8
26
|
};
|
|
9
27
|
|
|
10
28
|
type SubscribableEvents = keyof SubscribableEventsResponse;
|
|
@@ -54,6 +72,8 @@ export type GetterResponse<AppFeatureType extends AppFeatureTypes = AppFeatureTy
|
|
|
54
72
|
settings: Record<string, any>;
|
|
55
73
|
itemIds: number[];
|
|
56
74
|
sessionToken: string;
|
|
75
|
+
location: LocationResponse;
|
|
76
|
+
filter: FilterResponse;
|
|
57
77
|
};
|
|
58
78
|
export interface ClientData {
|
|
59
79
|
/**
|
package/types/index.d.ts
CHANGED
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
// Original Definitions were contributed by: Josh Parnham <https://github.com/josh->
|
|
2
|
-
import { MondayClientSdk } from
|
|
3
|
-
import { MondayServerSdk } from
|
|
2
|
+
import { MondayClientSdk } from "./client-sdk.interface";
|
|
3
|
+
import { MondayServerSdk } from "./server-sdk.interface";
|
|
4
4
|
|
|
5
5
|
export as namespace mondaySdk;
|
|
6
6
|
|
|
7
7
|
declare function init(
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
8
|
+
config?: Partial<{
|
|
9
|
+
clientId: string;
|
|
10
|
+
apiToken: string;
|
|
11
|
+
apiVersion: string;
|
|
12
|
+
}>
|
|
13
13
|
): MondayClientSdk;
|
|
14
14
|
|
|
15
15
|
declare function init(
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
16
|
+
config?: Partial<{
|
|
17
|
+
token: string;
|
|
18
|
+
apiVersion: string;
|
|
19
|
+
}>
|
|
20
20
|
): MondayServerSdk;
|
|
21
21
|
|
|
22
22
|
export = init;
|