@overmap-ai/core 1.0.60-model-adapter.0 → 1.0.60-sdk-refactor.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/enums/index.d.ts +0 -1
- package/dist/forms/builder/FormBuilder.d.ts +1 -0
- package/dist/forms/fields/BaseField/hooks.d.ts +11 -11
- package/dist/forms/fields/BaseField/layouts.d.ts +3 -2
- package/dist/forms/fields/typings.d.ts +3 -3
- package/dist/forms/index.d.ts +1 -0
- package/dist/forms/provider.d.ts +5 -0
- package/dist/forms/renderer/index.d.ts +0 -3
- package/dist/forms/utils.d.ts +0 -2
- package/dist/index.d.ts +0 -1
- package/dist/overmap-core.js +17955 -15482
- package/dist/overmap-core.js.map +1 -1
- package/dist/overmap-core.umd.cjs +17889 -15417
- package/dist/overmap-core.umd.cjs.map +1 -1
- package/dist/sdk/base.d.ts +22 -0
- package/dist/sdk/globals.d.ts +7 -0
- package/dist/sdk/index.d.ts +1 -0
- package/dist/sdk/sdk.d.ts +3 -51
- package/dist/sdk/services/AgentService.d.ts +2 -2
- package/dist/sdk/services/AssetAttachmentService.d.ts +3 -3
- package/dist/sdk/services/AssetService.d.ts +3 -3
- package/dist/sdk/services/AssetStageCompletionService.d.ts +3 -3
- package/dist/sdk/services/AssetStageService.d.ts +2 -2
- package/dist/sdk/services/AssetTypeAttachmentService.d.ts +3 -3
- package/dist/sdk/services/AssetTypeService.d.ts +3 -3
- package/dist/sdk/services/AuthService.d.ts +1 -1
- package/dist/sdk/services/BaseApiService.d.ts +15 -4
- package/dist/sdk/services/BaseAttachmentService.d.ts +4 -4
- package/dist/sdk/services/CategoryService.d.ts +3 -3
- package/dist/sdk/services/DocumentAttachmentService.d.ts +3 -3
- package/dist/sdk/services/DocumentService.d.ts +3 -3
- package/dist/sdk/services/EmailDomainsService.d.ts +2 -2
- package/dist/sdk/services/EmailVerificationService.d.ts +3 -3
- package/dist/sdk/services/FileService.d.ts +1 -0
- package/dist/sdk/services/IssueAttachmentService.d.ts +3 -3
- package/dist/sdk/services/IssueCommentService.d.ts +3 -3
- package/dist/sdk/services/IssueService.d.ts +3 -3
- package/dist/sdk/services/IssueTypeService.d.ts +3 -3
- package/dist/sdk/services/IssueUpdateService.d.ts +2 -1
- package/dist/sdk/services/LicenseService.d.ts +2 -2
- package/dist/sdk/services/OrganizationAccessService.d.ts +2 -2
- package/dist/sdk/services/OrganizationService.d.ts +2 -2
- package/dist/sdk/services/ProjectAccessService.d.ts +2 -2
- package/dist/sdk/services/ProjectAttachmentService.d.ts +3 -3
- package/dist/sdk/services/ProjectFileService.d.ts +2 -1
- package/dist/sdk/services/ProjectService.d.ts +2 -2
- package/dist/sdk/services/TeamService.d.ts +3 -3
- package/dist/sdk/services/UserFormService.d.ts +3 -3
- package/dist/sdk/services/UserFormSubmissionService.d.ts +3 -3
- package/dist/sdk/services/WorkspaceService.d.ts +2 -1
- package/dist/sdk/services/index.d.ts +0 -1
- package/dist/sdk/typings.d.ts +4 -1
- package/dist/store/index.d.ts +0 -1
- package/dist/store/slices/agentsSlice.d.ts +4 -4
- package/dist/store/slices/assetAttachmentSlice.d.ts +6 -6
- package/dist/store/slices/assetSlice.d.ts +8 -8
- package/dist/store/slices/assetStageCompletionSlice.d.ts +3 -3
- package/dist/store/slices/assetStageSlice.d.ts +9 -9
- package/dist/store/slices/assetTypeAttachmentSlice.d.ts +6 -6
- package/dist/store/slices/assetTypeSlice.d.ts +7 -7
- package/dist/store/slices/authSlice.d.ts +3 -3
- package/dist/store/slices/categorySlice.d.ts +8 -50
- package/dist/store/slices/documentAttachmentSlice.d.ts +6 -6
- package/dist/store/slices/documentSlice.d.ts +6 -48
- package/dist/store/slices/emailDomainsSlice.d.ts +4 -4
- package/dist/store/slices/fileSlice.d.ts +2 -2
- package/dist/store/slices/formRevisionAttachmentSlice.d.ts +3 -3
- package/dist/store/slices/formRevisionSlice.d.ts +8 -50
- package/dist/store/slices/formSlice.d.ts +8 -8
- package/dist/store/slices/formSubmissionAttachmentSlice.d.ts +3 -3
- package/dist/store/slices/formSubmissionSlice.d.ts +12 -12
- package/dist/store/slices/index.d.ts +0 -1
- package/dist/store/slices/issueAttachmentSlice.d.ts +6 -6
- package/dist/store/slices/issueCommentSlice.d.ts +3 -3
- package/dist/store/slices/issueSlice.d.ts +10 -10
- package/dist/store/slices/issueTypeSlice.d.ts +7 -7
- package/dist/store/slices/issueUpdateSlice.d.ts +3 -3
- package/dist/store/slices/licenseSlice.d.ts +7 -7
- package/dist/store/slices/organizationAccessSlice.d.ts +6 -6
- package/dist/store/slices/organizationSlice.d.ts +13 -13
- package/dist/store/slices/outboxSlice.d.ts +3 -3
- package/dist/store/slices/projectAccessSlice.d.ts +7 -7
- package/dist/store/slices/projectAttachmentSlice.d.ts +6 -6
- package/dist/store/slices/projectFileSlice.d.ts +7 -49
- package/dist/store/slices/projectSlice.d.ts +10 -10
- package/dist/store/slices/rehydratedSlice.d.ts +3 -2
- package/dist/store/slices/settingsSlice.d.ts +3 -24
- package/dist/store/slices/teamSlice.d.ts +6 -6
- package/dist/store/slices/userSlice.d.ts +5 -5
- package/dist/store/slices/workspaceSlice.d.ts +8 -50
- package/dist/store/store.d.ts +8 -90
- package/dist/style.css +0 -18
- package/dist/typings/models/store.d.ts +43 -4
- package/dist/typings/store.d.ts +6 -4
- package/dist/utils/file.d.ts +0 -6
- package/dist/utils/utils.d.ts +3 -3
- package/package.json +5 -3
- package/dist/contexts/hooks.d.ts +0 -2
- package/dist/contexts/index.d.ts +0 -3
- package/dist/contexts/overmap.d.ts +0 -12
- package/dist/contexts/sdk/globals.d.ts +0 -4
- package/dist/contexts/sdk/hooks.d.ts +0 -4
- package/dist/contexts/sdk/index.d.ts +0 -2
- package/dist/contexts/sdk/sdk.d.ts +0 -15
- package/dist/enums/map.d.ts +0 -6
- package/dist/forms/renderer/FormBrowser/FormBrowser.d.ts +0 -11
- package/dist/forms/renderer/FormSubmissionBrowser/FormSubmissionBrowser.d.ts +0 -28
- package/dist/forms/renderer/FormSubmissionViewer/FormSubmissionViewer.d.ts +0 -17
- package/dist/sdk/services/MainService.d.ts +0 -16
- package/dist/store/hooks.d.ts +0 -4
- package/dist/store/slices/mapSlice.d.ts +0 -23
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { AuthService, FileService } from "./services";
|
|
2
|
+
import { ToolkitStore } from "@reduxjs/toolkit/dist/configureStore";
|
|
3
|
+
import { SDKRequest } from "./typings";
|
|
4
|
+
import { BaseState } from "../typings";
|
|
5
|
+
export declare class BaseSDK<TState extends BaseState> {
|
|
6
|
+
readonly store: ToolkitStore<TState>;
|
|
7
|
+
constructor(store: ToolkitStore<TState>);
|
|
8
|
+
/**
|
|
9
|
+
* Enqueues an API request to the offline outbox.
|
|
10
|
+
* @param requestDetails An SDKRequest object containing the details of the request.
|
|
11
|
+
* @param host The base URL of the API to send the request to.
|
|
12
|
+
* @protected
|
|
13
|
+
*/
|
|
14
|
+
enqueueRequest<TResult>(requestDetails: SDKRequest, host: string): Promise<TResult>;
|
|
15
|
+
/**
|
|
16
|
+
* Enqueues an API request to the Redux Offline outbox
|
|
17
|
+
* @protected
|
|
18
|
+
*/
|
|
19
|
+
private _enqueueRequest;
|
|
20
|
+
files: FileService;
|
|
21
|
+
auth: AuthService;
|
|
22
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { ToolkitStore } from "@reduxjs/toolkit/dist/configureStore";
|
|
2
|
+
import { BaseState } from "../typings";
|
|
3
|
+
import { BaseSDK } from "./base";
|
|
4
|
+
export declare function setClientStore<TState extends BaseState>(store: ToolkitStore<TState>): void;
|
|
5
|
+
export declare function getClientStore(): ToolkitStore<BaseState> | undefined;
|
|
6
|
+
export declare function setClientSDK<TState extends BaseState>(sdkCtor: BaseSDK<TState>): void;
|
|
7
|
+
export declare function getClientSDK(): BaseSDK<BaseState> | undefined;
|
package/dist/sdk/index.d.ts
CHANGED
package/dist/sdk/sdk.d.ts
CHANGED
|
@@ -1,52 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { OvermapSDKConstructor } from "./index";
|
|
2
2
|
import { ToolkitStore } from "@reduxjs/toolkit/dist/configureStore";
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
export declare class OvermapSDK {
|
|
6
|
-
readonly API_URL: string;
|
|
7
|
-
readonly store: ToolkitStore<RootState>;
|
|
8
|
-
constructor(apiUrl: string, store: ToolkitStore<RootState>);
|
|
9
|
-
/**
|
|
10
|
-
* Enqueues an API request to the offline outbox.
|
|
11
|
-
* @param requestDetails An SDKRequest object containing the details of the request.
|
|
12
|
-
* @protected
|
|
13
|
-
*/
|
|
14
|
-
enqueueRequest<TResult>(requestDetails: SDKRequest): Promise<TResult>;
|
|
15
|
-
/**
|
|
16
|
-
* Enqueues an API request to the Redux Offline outbox
|
|
17
|
-
* @protected
|
|
18
|
-
*/
|
|
19
|
-
private _enqueueRequest;
|
|
20
|
-
agent: AgentService;
|
|
21
|
-
files: FileService;
|
|
22
|
-
auth: AuthService;
|
|
23
|
-
categories: CategoryService;
|
|
24
|
-
projectAccesses: ProjectAccessService;
|
|
25
|
-
organizations: OrganizationService;
|
|
26
|
-
organizationAccess: OrganizationAccessService;
|
|
27
|
-
issues: IssueService;
|
|
28
|
-
issueTypes: IssueTypeService;
|
|
29
|
-
issueComments: IssueCommentService;
|
|
30
|
-
issueUpdates: IssueUpdateService;
|
|
31
|
-
issueAttachments: IssueAttachmentService;
|
|
32
|
-
workspaces: WorkspaceService;
|
|
33
|
-
main: MainService;
|
|
34
|
-
assets: AssetService;
|
|
35
|
-
assetAttachments: AssetAttachmentService;
|
|
36
|
-
assetTypes: AssetTypeService;
|
|
37
|
-
assetTypeAttachments: AssetTypeAttachmentService;
|
|
38
|
-
assetStages: AssetStageService;
|
|
39
|
-
assetStageCompletions: AssetStageCompletionService;
|
|
40
|
-
userForms: UserFormService;
|
|
41
|
-
userFormSubmissions: UserFormSubmissionService;
|
|
42
|
-
projects: ProjectService;
|
|
43
|
-
projectFiles: ProjectFileService;
|
|
44
|
-
projectAttachments: ProjectAttachmentService;
|
|
45
|
-
emailVerification: EmailVerificationService;
|
|
46
|
-
emailDomains: EmailDomainsService;
|
|
47
|
-
licenses: LicenseService;
|
|
48
|
-
documents: DocumentService;
|
|
49
|
-
teams: TeamService;
|
|
50
|
-
documentAttachments: DocumentAttachmentService;
|
|
51
|
-
}
|
|
52
|
-
export declare const makeClient: (apiUrl: string, store: ToolkitStore<RootState>) => OvermapSDK;
|
|
3
|
+
import { BaseState } from "../typings";
|
|
4
|
+
export declare const initSDK: <TState extends BaseState>(store: ToolkitStore<TState>, sdk: OvermapSDKConstructor<TState>) => import('./base').BaseSDK<TState>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import { AgentUserConversation, OvermapRootState } from "../../typings";
|
|
1
2
|
import { BaseApiService } from "./BaseApiService";
|
|
2
|
-
|
|
3
|
-
export declare class AgentService extends BaseApiService {
|
|
3
|
+
export declare abstract class AgentService<TState extends OvermapRootState> extends BaseApiService<TState> {
|
|
4
4
|
startConversation(prompt: string): Promise<AgentUserConversation>;
|
|
5
5
|
/**
|
|
6
6
|
* Prompt the agent with a message.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { BaseAttachmentService } from "./BaseAttachmentService";
|
|
2
|
-
import { AttachmentModel, AssetAttachment, Stored } from "../../typings";
|
|
2
|
+
import { AttachmentModel, AssetAttachment, Stored, OvermapRootState } from "../../typings";
|
|
3
3
|
import { OptimisticMultipleModelResult } from "../typings";
|
|
4
|
-
export declare class AssetAttachmentService extends BaseAttachmentService<string, AssetAttachment> {
|
|
4
|
+
export declare abstract class AssetAttachmentService<TState extends OvermapRootState> extends BaseAttachmentService<TState, string, AssetAttachment> {
|
|
5
5
|
attachmentModel: AttachmentModel;
|
|
6
6
|
initializeAttachments: import("@reduxjs/toolkit").ActionCreatorWithPayload<Stored<AssetAttachment>[], "assetAttachments/initializeAssetAttachments">;
|
|
7
7
|
addAttachments: import("@reduxjs/toolkit").ActionCreatorWithPayload<Stored<AssetAttachment>[], "assetAttachments/addAssetAttachments">;
|
|
@@ -9,7 +9,7 @@ export declare class AssetAttachmentService extends BaseAttachmentService<string
|
|
|
9
9
|
removeAttachments: import("@reduxjs/toolkit").ActionCreatorWithPayload<string[], "assetAttachments/deleteAssetAttachments">;
|
|
10
10
|
removeAttachment: import("@reduxjs/toolkit").ActionCreatorWithPayload<string, "assetAttachments/deleteAssetAttachment">;
|
|
11
11
|
setAttachment: import("@reduxjs/toolkit").ActionCreatorWithPayload<Stored<AssetAttachment>, "assetAttachments/setAssetAttachment">;
|
|
12
|
-
selectAttachment: import('../../typings/store').
|
|
12
|
+
selectAttachment: import('../../typings/store').OvermapSelectorWithArgs<string, Stored<AssetAttachment>>;
|
|
13
13
|
private buildOfflineAttachment;
|
|
14
14
|
attachFilesToAsset(files: File[], assetId: string): Promise<OptimisticMultipleModelResult<AssetAttachment>>;
|
|
15
15
|
deleteAssetAttachment(attachmentId: string): Promise<void>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { Asset, Created, Payload } from "../../typings";
|
|
1
|
+
import { Asset, Created, Payload, OvermapRootState } from "../../typings";
|
|
3
2
|
import { OptimisticModelResult } from "../typings";
|
|
4
|
-
|
|
3
|
+
import { BaseApiService } from "./BaseApiService";
|
|
4
|
+
export declare abstract class AssetService<TState extends OvermapRootState> extends BaseApiService<TState> {
|
|
5
5
|
add(asset: Payload<Asset>, workspaceId: string): OptimisticModelResult<Asset>;
|
|
6
6
|
update(asset: Asset, workspaceId: string): OptimisticModelResult<Asset>;
|
|
7
7
|
remove(assetId: string): Promise<undefined>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { BaseApiService } from "./BaseApiService";
|
|
2
1
|
import { OptimisticModelResult } from "../typings";
|
|
3
|
-
import { AssetStageCompletion, Payload } from "../../typings";
|
|
4
|
-
|
|
2
|
+
import { AssetStageCompletion, OvermapRootState, Payload } from "../../typings";
|
|
3
|
+
import { BaseApiService } from "./BaseApiService";
|
|
4
|
+
export declare abstract class AssetStageCompletionService<TState extends OvermapRootState> extends BaseApiService<TState> {
|
|
5
5
|
add(assetId: string, stageId: string): OptimisticModelResult<AssetStageCompletion>;
|
|
6
6
|
refreshStore(): Promise<void>;
|
|
7
7
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import { AssetStage, AssetStagePayload, OvermapRootState, Payload } from "../../typings";
|
|
1
2
|
import { BaseApiService } from "./BaseApiService";
|
|
2
|
-
|
|
3
|
-
export declare class AssetStageService extends BaseApiService {
|
|
3
|
+
export declare abstract class AssetStageService<TState extends OvermapRootState> extends BaseApiService<TState> {
|
|
4
4
|
bulkCreateStages(stagesToSubmit: Payload<AssetStagePayload>[], assetTypeId: string, workspaceId: string): Promise<AssetStage[]>;
|
|
5
5
|
bulkUpdateStages(stagesToUpdate: AssetStage[], assetTypeId: string): Promise<AssetStage[]>;
|
|
6
6
|
bulkDelete(idsToDelete: string[]): Promise<undefined>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { BaseAttachmentService } from "./BaseAttachmentService";
|
|
2
|
-
import { AttachmentModel, AssetTypeAttachment, Stored } from "../../typings";
|
|
2
|
+
import { AttachmentModel, AssetTypeAttachment, Stored, OvermapRootState } from "../../typings";
|
|
3
3
|
import { OptimisticMultipleModelResult } from "../typings";
|
|
4
|
-
export declare class AssetTypeAttachmentService extends BaseAttachmentService<string, AssetTypeAttachment> {
|
|
4
|
+
export declare abstract class AssetTypeAttachmentService<TState extends OvermapRootState> extends BaseAttachmentService<TState, string, AssetTypeAttachment> {
|
|
5
5
|
attachmentModel: AttachmentModel;
|
|
6
6
|
initializeAttachments: import("@reduxjs/toolkit").ActionCreatorWithPayload<Stored<AssetTypeAttachment>[], "assetTypeAttachments/initializeAssetTypeAttachments">;
|
|
7
7
|
addAttachments: import("@reduxjs/toolkit").ActionCreatorWithPayload<Stored<AssetTypeAttachment>[], "assetTypeAttachments/addAssetTypeAttachments">;
|
|
@@ -9,7 +9,7 @@ export declare class AssetTypeAttachmentService extends BaseAttachmentService<st
|
|
|
9
9
|
removeAttachments: import("@reduxjs/toolkit").ActionCreatorWithPayload<string[], "assetTypeAttachments/deleteAssetTypeAttachments">;
|
|
10
10
|
removeAttachment: import("@reduxjs/toolkit").ActionCreatorWithPayload<string, "assetTypeAttachments/deleteAssetTypeAttachment">;
|
|
11
11
|
setAttachment: import("@reduxjs/toolkit").ActionCreatorWithPayload<Stored<AssetTypeAttachment>, "assetTypeAttachments/setAssetTypeAttachment">;
|
|
12
|
-
selectAttachment: import('../../typings/store').
|
|
12
|
+
selectAttachment: import('../../typings/store').OvermapSelectorWithArgs<string, Stored<AssetTypeAttachment>>;
|
|
13
13
|
private buildOfflineAttachment;
|
|
14
14
|
attachFilesToAssetType(files: File[], assetTypeId: string): Promise<OptimisticMultipleModelResult<AssetTypeAttachment>>;
|
|
15
15
|
deleteAssetTypeAttachment(attachmentId: string): Promise<void>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { AssetType, Payload } from "../../typings";
|
|
1
|
+
import { AssetType, OvermapRootState, Payload } from "../../typings";
|
|
3
2
|
import { OptimisticModelResult } from "../typings";
|
|
4
|
-
|
|
3
|
+
import { BaseApiService } from "./BaseApiService";
|
|
4
|
+
export declare abstract class AssetTypeService<TState extends OvermapRootState> extends BaseApiService<TState> {
|
|
5
5
|
add(assetType: Payload<AssetType>): OptimisticModelResult<AssetType>;
|
|
6
6
|
update(assetType: AssetType): Promise<undefined>;
|
|
7
7
|
delete(assetTypeId: string): Promise<undefined>;
|
|
@@ -4,6 +4,7 @@ import { RegistrationPayload, RegistrationReturn } from "../../typings";
|
|
|
4
4
|
* Handles login, logout and renewing tokens
|
|
5
5
|
*/
|
|
6
6
|
export declare class AuthService extends BaseApiService {
|
|
7
|
+
host: string;
|
|
7
8
|
private _getAccessToken;
|
|
8
9
|
private _getRefreshToken;
|
|
9
10
|
/**
|
|
@@ -49,6 +50,5 @@ export declare class AuthService extends BaseApiService {
|
|
|
49
50
|
replaceProfilePicture(file: File): Promise<undefined>;
|
|
50
51
|
addFavouriteProjectId(projectId: number): Promise<undefined>;
|
|
51
52
|
removeFavouriteProjectId(projectId: number): Promise<undefined>;
|
|
52
|
-
setTourStep(stepIndex: number): Promise<undefined>;
|
|
53
53
|
joinApplication(projectInviteId: string, verification_code: string, username: string, password: string): Promise<undefined>;
|
|
54
54
|
}
|
|
@@ -1,8 +1,19 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { AnyAction } from "@reduxjs/toolkit";
|
|
2
|
+
import type { BaseSDK } from "../base";
|
|
3
|
+
import { BaseState } from "../../typings";
|
|
4
|
+
import { SDKRequest } from "../typings";
|
|
2
5
|
/**
|
|
3
6
|
* Abstract base class for building a service that can enqueue API requests
|
|
4
7
|
*/
|
|
5
|
-
export declare abstract class BaseApiService {
|
|
6
|
-
protected readonly client:
|
|
7
|
-
|
|
8
|
+
export declare abstract class BaseApiService<TStore extends BaseState = BaseState> {
|
|
9
|
+
protected readonly client: BaseSDK<TStore>;
|
|
10
|
+
abstract readonly host: string;
|
|
11
|
+
constructor(sdk: BaseSDK<TStore>);
|
|
12
|
+
/**
|
|
13
|
+
* Enqueues an API request to the offline outbox.
|
|
14
|
+
* @param requestDetails An SDKRequest object containing the details of the request.
|
|
15
|
+
* @protected
|
|
16
|
+
*/
|
|
17
|
+
protected enqueueRequest<TResult>(requestDetails: SDKRequest): Promise<TResult>;
|
|
18
|
+
protected dispatch(action: AnyAction): void;
|
|
8
19
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ActionCreatorWithPayload } from "@reduxjs/toolkit";
|
|
2
|
-
import { BaseApiService } from "./BaseApiService";
|
|
3
2
|
import { OptimisticMultipleModelResult } from "../typings";
|
|
4
|
-
import { Attachment, AttachmentModel,
|
|
3
|
+
import { Attachment, AttachmentModel, OvermapRootState, OvermapSelectorWithArgs, Stored, Submitted } from "../../typings";
|
|
4
|
+
import { BaseApiService } from "./BaseApiService";
|
|
5
5
|
export interface BuildOfflineAttachmentData<TModelId> {
|
|
6
6
|
file: File;
|
|
7
7
|
sha1: string;
|
|
@@ -10,7 +10,7 @@ export interface BuildOfflineAttachmentData<TModelId> {
|
|
|
10
10
|
description?: string;
|
|
11
11
|
modelId: TModelId;
|
|
12
12
|
}
|
|
13
|
-
export declare abstract class BaseAttachmentService<TModelId extends string | number, TAttachment extends Attachment> extends BaseApiService {
|
|
13
|
+
export declare abstract class BaseAttachmentService<TState extends OvermapRootState, TModelId extends string | number, TAttachment extends Attachment> extends BaseApiService<TState> {
|
|
14
14
|
abstract readonly attachmentModel: AttachmentModel;
|
|
15
15
|
abstract readonly initializeAttachments: ActionCreatorWithPayload<Submitted<TAttachment>[]>;
|
|
16
16
|
abstract readonly addAttachments: ActionCreatorWithPayload<Submitted<TAttachment>[]>;
|
|
@@ -18,7 +18,7 @@ export declare abstract class BaseAttachmentService<TModelId extends string | nu
|
|
|
18
18
|
abstract readonly removeAttachments: ActionCreatorWithPayload<string[]>;
|
|
19
19
|
abstract readonly setAttachment: ActionCreatorWithPayload<Stored<TAttachment>>;
|
|
20
20
|
abstract readonly removeAttachment: ActionCreatorWithPayload<string>;
|
|
21
|
-
abstract readonly selectAttachment:
|
|
21
|
+
abstract readonly selectAttachment: OvermapSelectorWithArgs<string, Stored<TAttachment>>;
|
|
22
22
|
private getNumberOfAttachmentsWithSha1;
|
|
23
23
|
private processPresignedUrls;
|
|
24
24
|
protected attachFiles(files: File[], modelId: TModelId, buildOfflineAttachment: (data: BuildOfflineAttachmentData<TModelId>) => Stored<TAttachment>): Promise<OptimisticMultipleModelResult<TAttachment>>;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { Category, Offline, Payload } from "../../typings";
|
|
1
|
+
import { Category, Offline, OvermapRootState, Payload } from "../../typings";
|
|
3
2
|
import { OptimisticModelResult } from "../typings";
|
|
3
|
+
import { BaseApiService } from "./BaseApiService";
|
|
4
4
|
/**
|
|
5
5
|
* Handles the creation of Category Service
|
|
6
6
|
* TODO: Support editing and deleting categories
|
|
7
7
|
*/
|
|
8
|
-
export declare class CategoryService extends BaseApiService {
|
|
8
|
+
export declare abstract class CategoryService<TState extends OvermapRootState> extends BaseApiService<TState> {
|
|
9
9
|
add(category: Omit<Payload<Category>, "workspace">, workspaceId: string): OptimisticModelResult<Category>;
|
|
10
10
|
update(category: Offline<Partial<Category>>, workspaceId: string): OptimisticModelResult<Category>;
|
|
11
11
|
remove(category: Category, workspaceId: string): Promise<undefined>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { BaseAttachmentService } from "./BaseAttachmentService";
|
|
2
|
-
import { AttachmentModel, DocumentAttachment, Stored } from "../../typings";
|
|
2
|
+
import { AttachmentModel, DocumentAttachment, OvermapRootState, Stored } from "../../typings";
|
|
3
3
|
import { OptimisticMultipleModelResult } from "../typings";
|
|
4
|
-
export declare class DocumentAttachmentService extends BaseAttachmentService<string, DocumentAttachment> {
|
|
4
|
+
export declare abstract class DocumentAttachmentService<TState extends OvermapRootState> extends BaseAttachmentService<TState, string, DocumentAttachment> {
|
|
5
5
|
attachmentModel: AttachmentModel;
|
|
6
6
|
initializeAttachments: import("@reduxjs/toolkit").ActionCreatorWithPayload<Stored<DocumentAttachment>[], "documentAttachments/initializeDocumentAttachments">;
|
|
7
7
|
addAttachments: import("@reduxjs/toolkit").ActionCreatorWithPayload<Stored<DocumentAttachment>[], "documentAttachments/addDocumentAttachments">;
|
|
@@ -9,7 +9,7 @@ export declare class DocumentAttachmentService extends BaseAttachmentService<str
|
|
|
9
9
|
removeAttachments: import("@reduxjs/toolkit").ActionCreatorWithPayload<string[], "documentAttachments/deleteDocumentAttachments">;
|
|
10
10
|
removeAttachment: import("@reduxjs/toolkit").ActionCreatorWithPayload<string, "documentAttachments/deleteDocumentAttachment">;
|
|
11
11
|
setAttachment: import("@reduxjs/toolkit").ActionCreatorWithPayload<Stored<DocumentAttachment>, "documentAttachments/setDocumentAttachment">;
|
|
12
|
-
selectAttachment: import('../../typings/store').
|
|
12
|
+
selectAttachment: import('../../typings/store').OvermapSelectorWithArgs<string, Stored<DocumentAttachment>>;
|
|
13
13
|
private buildOfflineAttachment;
|
|
14
14
|
attachFilesToDocument(files: File[], documentId: string): Promise<OptimisticMultipleModelResult<DocumentAttachment>>;
|
|
15
15
|
deleteDocumentAttachment(attachmentId: string): Promise<void>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { Document, DocumentPayload, MovePosition, Submitted } from "../../typings";
|
|
1
|
+
import { Document, DocumentPayload, MovePosition, OvermapRootState, Submitted } from "../../typings";
|
|
3
2
|
import { OptimisticModelResult } from "../typings";
|
|
4
|
-
|
|
3
|
+
import { BaseApiService } from "./BaseApiService";
|
|
4
|
+
export declare abstract class DocumentService<TState extends OvermapRootState> extends BaseApiService<TState> {
|
|
5
5
|
add(document: DocumentPayload): OptimisticModelResult<Document>;
|
|
6
6
|
update(document: Submitted<Partial<Document>>): OptimisticModelResult<Document>;
|
|
7
7
|
move(documentId: string, targetDocumentId: string | null, position: MovePosition): Promise<Document[]>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import { EmailDomain, OvermapRootState } from "../../typings";
|
|
1
2
|
import { BaseApiService } from "./BaseApiService";
|
|
2
|
-
|
|
3
|
-
export declare class EmailDomainsService extends BaseApiService {
|
|
3
|
+
export declare abstract class EmailDomainsService<TState extends OvermapRootState> extends BaseApiService<TState> {
|
|
4
4
|
add(orgId: number, email: string): Promise<undefined>;
|
|
5
5
|
remove(emailDomain: EmailDomain): Promise<undefined>;
|
|
6
6
|
refreshStore(): Promise<undefined>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { BaseApiService } from "
|
|
2
|
-
import { EmailVerificationPayload, EmailVerificationReturn, VerificationCode } from "../../typings";
|
|
3
|
-
export declare class EmailVerificationService extends BaseApiService {
|
|
1
|
+
import { BaseApiService } from "../../sdk";
|
|
2
|
+
import { EmailVerificationPayload, EmailVerificationReturn, OvermapRootState, VerificationCode } from "../../typings";
|
|
3
|
+
export declare abstract class EmailVerificationService<TState extends OvermapRootState> extends BaseApiService<TState> {
|
|
4
4
|
getVerificationCode(verificationCode: string): Promise<VerificationCode>;
|
|
5
5
|
validateVerificationCode(verificationCode: string, payload?: EmailVerificationPayload | undefined): Promise<EmailVerificationReturn>;
|
|
6
6
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { BaseAttachmentService } from "./BaseAttachmentService";
|
|
2
2
|
import { OptimisticMultipleModelResult } from "../typings";
|
|
3
|
-
import { AttachmentModel, IssueAttachment, Stored } from "../../typings";
|
|
4
|
-
export declare class IssueAttachmentService extends BaseAttachmentService<string, IssueAttachment> {
|
|
3
|
+
import { AttachmentModel, IssueAttachment, OvermapRootState, Stored } from "../../typings";
|
|
4
|
+
export declare abstract class IssueAttachmentService<TState extends OvermapRootState> extends BaseAttachmentService<TState, string, IssueAttachment> {
|
|
5
5
|
attachmentModel: AttachmentModel;
|
|
6
6
|
initializeAttachments: import("@reduxjs/toolkit").ActionCreatorWithPayload<Stored<IssueAttachment>[], "issueAttachments/initializeIssueAttachments">;
|
|
7
7
|
addAttachments: import("@reduxjs/toolkit").ActionCreatorWithPayload<Stored<IssueAttachment>[], "issueAttachments/addIssueAttachments">;
|
|
@@ -9,7 +9,7 @@ export declare class IssueAttachmentService extends BaseAttachmentService<string
|
|
|
9
9
|
removeAttachments: import("@reduxjs/toolkit").ActionCreatorWithPayload<string[], "issueAttachments/deleteIssueAttachments">;
|
|
10
10
|
removeAttachment: import("@reduxjs/toolkit").ActionCreatorWithPayload<string, "issueAttachments/deleteIssueAttachment">;
|
|
11
11
|
setAttachment: import("@reduxjs/toolkit").ActionCreatorWithPayload<Stored<IssueAttachment>, "issueAttachments/setIssueAttachment">;
|
|
12
|
-
selectAttachment: import('../../typings/store').
|
|
12
|
+
selectAttachment: import('../../typings/store').OvermapSelectorWithArgs<string, Stored<IssueAttachment>>;
|
|
13
13
|
private buildOfflineAttachment;
|
|
14
14
|
attachFilesToIssue(files: File[], issueId: string): Promise<OptimisticMultipleModelResult<IssueAttachment>>;
|
|
15
15
|
deleteIssueAttachment(attachmentId: string): Promise<void>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { IssueComment, Payload, Submitted } from "../../typings";
|
|
1
|
+
import { IssueComment, OvermapRootState, Payload, Submitted } from "../../typings";
|
|
3
2
|
import { OptimisticModelResult } from "../typings";
|
|
4
|
-
|
|
3
|
+
import { BaseApiService } from "./BaseApiService";
|
|
4
|
+
export declare abstract class IssueCommentService<TState extends OvermapRootState> extends BaseApiService<TState> {
|
|
5
5
|
add(comment: Omit<Payload<IssueComment>, "author" | "submitted_at">): OptimisticModelResult<IssueComment>;
|
|
6
6
|
update(comment: Submitted<IssueComment>): OptimisticModelResult<IssueComment>;
|
|
7
7
|
remove(offline_id: string): Promise<undefined>;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { BaseApiService } from "./BaseApiService";
|
|
2
1
|
import { OptimisticModelResult } from "../typings";
|
|
3
|
-
import { Issue, IssueType, Submitted } from "../../typings";
|
|
2
|
+
import { Issue, IssueType, OvermapRootState, Submitted } from "../../typings";
|
|
3
|
+
import { BaseApiService } from "./BaseApiService";
|
|
4
4
|
/**
|
|
5
5
|
* Handles CRUD operations on issues
|
|
6
6
|
*/
|
|
7
|
-
export declare class IssueService extends BaseApiService {
|
|
7
|
+
export declare abstract class IssueService<TState extends OvermapRootState> extends BaseApiService<TState> {
|
|
8
8
|
add(issue: Issue, issueType?: IssueType["offline_id"] | null): OptimisticModelResult<Issue>;
|
|
9
9
|
update(issue: Submitted<Partial<Issue>>): OptimisticModelResult<Issue>;
|
|
10
10
|
remove(id: string): Promise<undefined>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { BaseApiService } from "./BaseApiService";
|
|
2
1
|
import { OptimisticModelResult } from "../typings";
|
|
3
|
-
import { IssueType, IssueTypePayload, Offline } from "../../typings";
|
|
4
|
-
|
|
2
|
+
import { IssueType, IssueTypePayload, Offline, OvermapRootState } from "../../typings";
|
|
3
|
+
import { BaseApiService } from "./BaseApiService";
|
|
4
|
+
export declare abstract class IssueTypeService<TState extends OvermapRootState> extends BaseApiService<TState> {
|
|
5
5
|
add(payload: IssueTypePayload): OptimisticModelResult<IssueType>;
|
|
6
6
|
update(issueTypeFields: Offline<Partial<IssueType>>): OptimisticModelResult<IssueType>;
|
|
7
7
|
delete(issueTypeId: string): Promise<void>;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
+
import { OvermapRootState } from "../../typings";
|
|
1
2
|
import { BaseApiService } from "./BaseApiService";
|
|
2
|
-
export declare class IssueUpdateService extends BaseApiService {
|
|
3
|
+
export declare abstract class IssueUpdateService<TState extends OvermapRootState> extends BaseApiService<TState> {
|
|
3
4
|
refreshStore(): Promise<void>;
|
|
4
5
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import { License, OvermapRootState, Project, Transaction } from "../../typings";
|
|
1
2
|
import { BaseApiService } from "./BaseApiService";
|
|
2
|
-
|
|
3
|
-
export declare class LicenseService extends BaseApiService {
|
|
3
|
+
export declare abstract class LicenseService<TState extends OvermapRootState> extends BaseApiService<TState> {
|
|
4
4
|
fetchLicensesForOrganization(organizationId: number, showLoading?: boolean): Promise<License[]>;
|
|
5
5
|
getLicense(license: License): Promise<License>;
|
|
6
6
|
pauseLicense(license: License): Promise<License>;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
+
import { OrganizationAccess, OvermapRootState } from "../../typings";
|
|
1
2
|
import { BaseApiService } from "./BaseApiService";
|
|
2
|
-
import { OrganizationAccess } from "../../typings";
|
|
3
3
|
/**
|
|
4
4
|
* Handles the creation of OrganizationAccess Service
|
|
5
5
|
*/
|
|
6
|
-
export declare class OrganizationAccessService extends BaseApiService {
|
|
6
|
+
export declare abstract class OrganizationAccessService<TState extends OvermapRootState> extends BaseApiService<TState> {
|
|
7
7
|
update(organizationAccess: OrganizationAccess): Promise<OrganizationAccess>;
|
|
8
8
|
remove(organizationAccess: OrganizationAccess): Promise<undefined>;
|
|
9
9
|
refreshStore(): Promise<void>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { InitialOrganizationData, Organization } from "../../typings";
|
|
1
|
+
import { InitialOrganizationData, Organization, OvermapRootState } from "../../typings";
|
|
2
2
|
import { BaseApiService } from "./BaseApiService";
|
|
3
|
-
export declare class OrganizationService extends BaseApiService {
|
|
3
|
+
export declare abstract class OrganizationService<TState extends OvermapRootState> extends BaseApiService<TState> {
|
|
4
4
|
fetchInitialOrganizationData(organizationId: number, showLoading: boolean): Promise<InitialOrganizationData>;
|
|
5
5
|
_processInitialOrganizationData(data: InitialOrganizationData, showLoading: boolean): void;
|
|
6
6
|
create(name: string): Promise<Organization>;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
+
import { OvermapRootState, ProjectAccess } from "../../typings";
|
|
1
2
|
import { BaseApiService } from "./BaseApiService";
|
|
2
|
-
import { ProjectAccess } from "../../typings";
|
|
3
3
|
/**
|
|
4
4
|
* Handles the creation of ProjectAccess Service
|
|
5
5
|
*/
|
|
6
|
-
export declare class ProjectAccessService extends BaseApiService {
|
|
6
|
+
export declare abstract class ProjectAccessService<TState extends OvermapRootState> extends BaseApiService<TState> {
|
|
7
7
|
fetchAll(projectId: number): Promise<ProjectAccess[]>;
|
|
8
8
|
update(projectAccess: ProjectAccess): Promise<ProjectAccess>;
|
|
9
9
|
remove(projectAccess: ProjectAccess): Promise<undefined>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { BaseAttachmentService } from "./BaseAttachmentService";
|
|
2
|
-
import { AttachmentModel, ProjectAttachment, Stored } from "../../typings";
|
|
2
|
+
import { AttachmentModel, OvermapRootState, ProjectAttachment, Stored } from "../../typings";
|
|
3
3
|
import { OptimisticMultipleModelResult } from "../typings";
|
|
4
|
-
export declare class ProjectAttachmentService extends BaseAttachmentService<number, ProjectAttachment> {
|
|
4
|
+
export declare abstract class ProjectAttachmentService<TState extends OvermapRootState> extends BaseAttachmentService<TState, number, ProjectAttachment> {
|
|
5
5
|
attachmentModel: AttachmentModel;
|
|
6
6
|
initializeAttachments: import("@reduxjs/toolkit").ActionCreatorWithPayload<Stored<ProjectAttachment>[], "projectAttachments/initializeProjectAttachments">;
|
|
7
7
|
addAttachments: import("@reduxjs/toolkit").ActionCreatorWithPayload<Stored<ProjectAttachment>[], "projectAttachments/addProjectAttachments">;
|
|
@@ -9,7 +9,7 @@ export declare class ProjectAttachmentService extends BaseAttachmentService<numb
|
|
|
9
9
|
removeAttachments: import("@reduxjs/toolkit").ActionCreatorWithPayload<string[], "projectAttachments/deleteProjectAttachments">;
|
|
10
10
|
removeAttachment: import("@reduxjs/toolkit").ActionCreatorWithPayload<string, "projectAttachments/deleteProjectAttachment">;
|
|
11
11
|
setAttachment: import("@reduxjs/toolkit").ActionCreatorWithPayload<Stored<ProjectAttachment>, "projectAttachments/setProjectAttachment">;
|
|
12
|
-
selectAttachment: import('../../typings/store').
|
|
12
|
+
selectAttachment: import('../../typings/store').OvermapSelectorWithArgs<string, ProjectAttachment>;
|
|
13
13
|
private buildOfflineAttachment;
|
|
14
14
|
attachFilesToProject(files: File[], projectId: number): Promise<OptimisticMultipleModelResult<ProjectAttachment>>;
|
|
15
15
|
deleteProjectAttachment(attachmentId: string): Promise<void>;
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import { ProjectFile } from '../../typings/models/projects';
|
|
2
2
|
import { OptimisticGenericResult } from "../typings";
|
|
3
|
+
import { OvermapRootState } from "../../typings";
|
|
3
4
|
import { BaseApiService } from "./BaseApiService";
|
|
4
5
|
/**
|
|
5
6
|
* Handles creation and caching of ProjectFiles
|
|
6
7
|
*/
|
|
7
|
-
export declare class ProjectFileService extends BaseApiService {
|
|
8
|
+
export declare abstract class ProjectFileService<TState extends OvermapRootState> extends BaseApiService<TState> {
|
|
8
9
|
refreshStore(): Promise<void>;
|
|
9
10
|
saveExisting(file: ProjectFile): Promise<ProjectFile>;
|
|
10
11
|
saveActive(): OptimisticGenericResult<ProjectFile>;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { Project } from '../../typings/models/projects';
|
|
2
|
+
import { OvermapRootState, Payload } from "../../typings";
|
|
2
3
|
import { BaseApiService } from "./BaseApiService";
|
|
3
|
-
import { Payload } from "../../typings";
|
|
4
4
|
interface JoinProjectResponse {
|
|
5
5
|
username: string;
|
|
6
6
|
}
|
|
7
|
-
export declare class ProjectService extends BaseApiService {
|
|
7
|
+
export declare abstract class ProjectService<TState extends OvermapRootState> extends BaseApiService<TState> {
|
|
8
8
|
/**
|
|
9
9
|
* Creates a new project. Due to the nature of project creation,
|
|
10
10
|
* @param project A Payload<Project> object containing project attributes.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { Stored, Team, TeamPayload, User } from "../../typings";
|
|
1
|
+
import { OvermapRootState, Stored, Team, TeamPayload, User } from "../../typings";
|
|
3
2
|
import { OptimisticModelResult } from "../typings";
|
|
4
|
-
|
|
3
|
+
import { BaseApiService } from "./BaseApiService";
|
|
4
|
+
export declare abstract class TeamService<TState extends OvermapRootState> extends BaseApiService<TState> {
|
|
5
5
|
add(teamPayload: TeamPayload): OptimisticModelResult<Team>;
|
|
6
6
|
update(team: Stored<Team>): OptimisticModelResult<Team>;
|
|
7
7
|
delete(teamId: string): Promise<undefined>;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { UserForm, UserFormRevision, UserFormRevisionPayload } from '../../typings/models/forms';
|
|
2
2
|
import { OptimisticModelResult } from "../typings";
|
|
3
|
-
import {
|
|
4
|
-
import { Created, Submitted } from "../../typings";
|
|
3
|
+
import { Created, Submitted, OvermapRootState } from "../../typings";
|
|
5
4
|
import { ISerializedField } from "../../forms";
|
|
6
|
-
|
|
5
|
+
import { BaseApiService } from "./BaseApiService";
|
|
6
|
+
export declare abstract class UserFormService<TState extends OvermapRootState> extends BaseApiService<TState> {
|
|
7
7
|
private getAttachImagePromises;
|
|
8
8
|
private add;
|
|
9
9
|
addForOrganization(organizationId: number, initialRevision: UserFormRevisionPayload): Promise<[Submitted<UserForm>, Submitted<UserFormRevision<ISerializedField>>, Promise<Created<UserFormRevision<ISerializedField>>>, Promise<Created<UserFormRevision<ISerializedField>>>]>;
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import { Offline } from '../../typings/models/base';
|
|
2
|
-
import { BaseApiService } from "./BaseApiService";
|
|
3
2
|
import { UserFormSubmission, UserFormSubmissionAttachment, UserFormSubmissionPayload } from '../../typings/models/forms';
|
|
4
3
|
import { OptimisticModelResult } from "../typings";
|
|
5
4
|
import { FieldValue } from '../../forms';
|
|
6
|
-
import { Created, Stored } from "../../typings";
|
|
5
|
+
import { Created, OvermapRootState, Stored } from "../../typings";
|
|
7
6
|
import { GetS3UrlSuccessResponse } from "./FileService";
|
|
7
|
+
import { BaseApiService } from "./BaseApiService";
|
|
8
8
|
interface BulkAddRequestReturnValue {
|
|
9
9
|
submissions: Created<UserFormSubmission>[];
|
|
10
10
|
attachments: Created<UserFormSubmissionAttachment>[];
|
|
11
11
|
presigned_urls: Record<string, GetS3UrlSuccessResponse>;
|
|
12
12
|
}
|
|
13
|
-
export declare class UserFormSubmissionService extends BaseApiService {
|
|
13
|
+
export declare abstract class UserFormSubmissionService<TState extends OvermapRootState> extends BaseApiService<TState> {
|
|
14
14
|
private getAttachFilesPromises;
|
|
15
15
|
add(payload: Offline<UserFormSubmissionPayload>): OptimisticModelResult<UserFormSubmission>;
|
|
16
16
|
bulkAdd(args: {
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { Payload } from '../../typings/models/base';
|
|
2
2
|
import { Workspace } from '../../typings/models/workspace';
|
|
3
3
|
import { OptimisticModelResult } from "../typings";
|
|
4
|
+
import { OvermapRootState } from "../../typings";
|
|
4
5
|
import { BaseApiService } from "./BaseApiService";
|
|
5
|
-
export declare class WorkspaceService extends BaseApiService {
|
|
6
|
+
export declare abstract class WorkspaceService<TState extends OvermapRootState> extends BaseApiService<TState> {
|
|
6
7
|
add(workspace: Payload<Workspace>): OptimisticModelResult<Workspace>;
|
|
7
8
|
update(workspace: Workspace): OptimisticModelResult<Workspace>;
|
|
8
9
|
delete(workspaceId: string): Promise<undefined>;
|
|
@@ -12,7 +12,6 @@ export * from "./IssueUpdateService";
|
|
|
12
12
|
export * from "./IssueAttachmentService";
|
|
13
13
|
export * from "./IssueService";
|
|
14
14
|
export * from "./IssueTypeService";
|
|
15
|
-
export * from "./MainService";
|
|
16
15
|
export * from "./ProjectAccessService";
|
|
17
16
|
export * from "./ProjectFileService";
|
|
18
17
|
export * from "./ProjectAttachmentService";
|
package/dist/sdk/typings.d.ts
CHANGED
|
@@ -1,8 +1,11 @@
|
|
|
1
1
|
import request from "superagent";
|
|
2
|
+
import { ToolkitStore } from "@reduxjs/toolkit/dist/configureStore";
|
|
2
3
|
import { HttpMethod } from "../enums";
|
|
3
|
-
import { Created, Model, Stored, Submitted } from "../typings";
|
|
4
|
+
import { BaseState, Created, Model, Stored, Submitted } from "../typings";
|
|
4
5
|
import { DeferredPromise } from "../utils/async/DeferredPromise";
|
|
5
6
|
import { GetS3UrlResponse } from "./services";
|
|
7
|
+
import { BaseSDK } from "./base";
|
|
8
|
+
export type OvermapSDKConstructor<TState extends BaseState> = new (store: ToolkitStore<TState>) => BaseSDK<TState>;
|
|
6
9
|
export interface TokenPair {
|
|
7
10
|
accessToken: string;
|
|
8
11
|
refreshToken: string;
|
package/dist/store/index.d.ts
CHANGED