@overmap-ai/core 1.0.56 → 1.0.57-export-overmap-reducer.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/LICENSE +1 -0
- package/README.md +4 -4
- package/dist/constants/ui.d.ts +1 -1
- package/dist/contexts/overmap.d.ts +2 -2
- package/dist/contexts/sdk/globals.d.ts +3 -3
- package/dist/contexts/sdk/sdk.d.ts +2 -2
- package/dist/enums/ui.d.ts +1 -1
- package/dist/forms/builder/constants.d.ts +1 -1
- package/dist/forms/builder/hooks.d.ts +1 -1
- package/dist/overmap-core.js +610 -942
- package/dist/overmap-core.js.map +1 -1
- package/dist/overmap-core.umd.cjs +611 -943
- package/dist/overmap-core.umd.cjs.map +1 -1
- package/dist/sdk/sdk.d.ts +11 -11
- package/dist/sdk/services/AgentService.d.ts +2 -21
- package/dist/sdk/services/AssetAttachmentService.d.ts +10 -0
- package/dist/sdk/services/AssetService.d.ts +11 -0
- package/dist/sdk/services/AssetStageCompletionService.d.ts +16 -0
- package/dist/sdk/services/AssetStageService.d.ts +11 -0
- package/dist/sdk/services/AssetTypeAttachmentService.d.ts +10 -0
- package/dist/sdk/services/AssetTypeService.d.ts +9 -0
- package/dist/sdk/services/UserFormService.d.ts +2 -2
- package/dist/sdk/services/UserFormSubmissionService.d.ts +1 -1
- package/dist/sdk/services/index.d.ts +6 -6
- package/dist/store/index.d.ts +0 -1
- package/dist/store/slices/agentsSlice.d.ts +3 -3
- package/dist/store/slices/assetSlice.d.ts +63 -0
- package/dist/store/slices/assetStageCompletionSlice.d.ts +15 -0
- package/dist/store/slices/assetStageSlice.d.ts +32 -0
- package/dist/store/slices/assetTypeSlice.d.ts +74 -0
- package/dist/store/slices/authSlice.d.ts +3 -3
- package/dist/store/slices/categorySlice.d.ts +9 -9
- package/dist/store/slices/documentSlice.d.ts +12 -13
- package/dist/store/slices/formRevisionSlice.d.ts +7 -7
- package/dist/store/slices/formSlice.d.ts +7 -7
- package/dist/store/slices/formSubmissionSlice.d.ts +2 -2
- package/dist/store/slices/index.d.ts +4 -4
- package/dist/store/slices/issueSlice.d.ts +18 -18
- package/dist/store/slices/mapSlice.d.ts +4 -4
- package/dist/store/slices/organizationAccessSlice.d.ts +3 -3
- package/dist/store/slices/outboxSlice.d.ts +3 -3
- package/dist/store/slices/projectAccessSlice.d.ts +2 -2
- package/dist/store/slices/projectFileSlice.d.ts +7 -7
- package/dist/store/slices/projectSlice.d.ts +8 -8
- package/dist/store/slices/rehydratedSlice.d.ts +2 -2
- package/dist/store/slices/settingsSlice.d.ts +9 -9
- package/dist/store/slices/userSlice.d.ts +4 -4
- package/dist/store/slices/workspaceSlice.d.ts +6 -6
- package/dist/store/store.d.ts +12 -45
- package/dist/typings/models/access.d.ts +1 -0
- package/dist/typings/models/attachments.d.ts +6 -6
- package/dist/typings/models/components.d.ts +11 -7
- package/dist/typings/models/forms.d.ts +3 -3
- package/dist/typings/models/store.d.ts +2 -3
- package/dist/typings/store.d.ts +4 -4
- package/dist/utils/colors.d.ts +1 -1
- package/dist/utils/utils.d.ts +3 -3
- package/package.json +153 -153
- package/dist/sdk/services/ComponentAttachmentService.d.ts +0 -10
- package/dist/sdk/services/ComponentService.d.ts +0 -11
- package/dist/sdk/services/ComponentStageCompletionService.d.ts +0 -17
- package/dist/sdk/services/ComponentStageService.d.ts +0 -11
- package/dist/sdk/services/ComponentTypeAttachmentService.d.ts +0 -10
- package/dist/sdk/services/ComponentTypeService.d.ts +0 -9
- package/dist/store/hooks.d.ts +0 -4
- package/dist/store/slices/ComponentStageCompletionSlice.d.ts +0 -27
- package/dist/store/slices/componentSlice.d.ts +0 -73
- package/dist/store/slices/componentStageSlice.d.ts +0 -42
- package/dist/store/slices/componentTypeSlice.d.ts +0 -75
|
@@ -24,7 +24,7 @@ export declare const formSlice: import("@reduxjs/toolkit").Slice<FormState, {
|
|
|
24
24
|
}, "forms">;
|
|
25
25
|
export declare const setForms: import("@reduxjs/toolkit").ActionCreatorWithPayload<((Pick<import('../../typings/models/workspace').WorkspaceIndexedModel, "index_workspace"> & {
|
|
26
26
|
favorite: boolean;
|
|
27
|
-
|
|
27
|
+
asset_type?: string | undefined;
|
|
28
28
|
issue_type?: string | undefined;
|
|
29
29
|
} & {
|
|
30
30
|
owner_organization: number;
|
|
@@ -36,7 +36,7 @@ export declare const setForms: import("@reduxjs/toolkit").ActionCreatorWithPaylo
|
|
|
36
36
|
submitted_at: string;
|
|
37
37
|
}) | (Pick<import('../../typings/models/workspace').WorkspaceIndexedModel, "index_workspace"> & {
|
|
38
38
|
favorite: boolean;
|
|
39
|
-
|
|
39
|
+
asset_type?: string | undefined;
|
|
40
40
|
issue_type?: string | undefined;
|
|
41
41
|
} & {
|
|
42
42
|
owner_organization: undefined;
|
|
@@ -48,7 +48,7 @@ export declare const setForms: import("@reduxjs/toolkit").ActionCreatorWithPaylo
|
|
|
48
48
|
submitted_at: string;
|
|
49
49
|
}))[], "forms/setForms">, addForm: import("@reduxjs/toolkit").ActionCreatorWithPayload<(Pick<import('../../typings/models/workspace').WorkspaceIndexedModel, "index_workspace"> & {
|
|
50
50
|
favorite: boolean;
|
|
51
|
-
|
|
51
|
+
asset_type?: string | undefined;
|
|
52
52
|
issue_type?: string | undefined;
|
|
53
53
|
} & {
|
|
54
54
|
owner_organization: number;
|
|
@@ -60,7 +60,7 @@ export declare const setForms: import("@reduxjs/toolkit").ActionCreatorWithPaylo
|
|
|
60
60
|
submitted_at: string;
|
|
61
61
|
}) | (Pick<import('../../typings/models/workspace').WorkspaceIndexedModel, "index_workspace"> & {
|
|
62
62
|
favorite: boolean;
|
|
63
|
-
|
|
63
|
+
asset_type?: string | undefined;
|
|
64
64
|
issue_type?: string | undefined;
|
|
65
65
|
} & {
|
|
66
66
|
owner_organization: undefined;
|
|
@@ -72,7 +72,7 @@ export declare const setForms: import("@reduxjs/toolkit").ActionCreatorWithPaylo
|
|
|
72
72
|
submitted_at: string;
|
|
73
73
|
}), "forms/addForm">, addForms: import("@reduxjs/toolkit").ActionCreatorWithPayload<((Pick<import('../../typings/models/workspace').WorkspaceIndexedModel, "index_workspace"> & {
|
|
74
74
|
favorite: boolean;
|
|
75
|
-
|
|
75
|
+
asset_type?: string | undefined;
|
|
76
76
|
issue_type?: string | undefined;
|
|
77
77
|
} & {
|
|
78
78
|
owner_organization: number;
|
|
@@ -84,7 +84,7 @@ export declare const setForms: import("@reduxjs/toolkit").ActionCreatorWithPaylo
|
|
|
84
84
|
submitted_at: string;
|
|
85
85
|
}) | (Pick<import('../../typings/models/workspace').WorkspaceIndexedModel, "index_workspace"> & {
|
|
86
86
|
favorite: boolean;
|
|
87
|
-
|
|
87
|
+
asset_type?: string | undefined;
|
|
88
88
|
issue_type?: string | undefined;
|
|
89
89
|
} & {
|
|
90
90
|
owner_organization: undefined;
|
|
@@ -110,7 +110,7 @@ export type FormSearchArgs = SearchArgs<{
|
|
|
110
110
|
export declare const selectFilteredForms: SelectorWithArgs<FormSearchArgs, CachedUserForm[]>;
|
|
111
111
|
export declare const selectForm: SelectorWithArgs<string, Stored<UserForm>>;
|
|
112
112
|
export declare const selectFormMapping: Selector<Record<Stored<UserForm>["offline_id"], Stored<UserForm>>>;
|
|
113
|
-
export declare const
|
|
113
|
+
export declare const selectFormOfAssetType: SelectorWithArgs<string, Stored<UserForm>>;
|
|
114
114
|
export declare const selectFormOfIssueType: SelectorWithArgs<string, Stored<UserForm>>;
|
|
115
115
|
export declare const selectFormsCount: Selector<number>;
|
|
116
116
|
export declare const selectGeneralFormCount: Selector<number>;
|
|
@@ -42,8 +42,8 @@ export declare const selectFormSubmissionsOfForm: SelectorWithArgs<string, Store
|
|
|
42
42
|
export declare const selectFormSubmissionsByFormRevisions: Selector<Record<string, Stored<UserFormSubmission>[]>>;
|
|
43
43
|
export declare const selectSortedFormSubmissionsOfForm: SelectorWithArgs<string, Stored<UserFormSubmission>[]>;
|
|
44
44
|
export declare const selectFormSubmissionsOfIssue: SelectorWithArgs<string, Stored<UserFormSubmission>[]>;
|
|
45
|
-
export declare const
|
|
46
|
-
export declare const
|
|
45
|
+
export declare const selectFormSubmissionsOfAsset: SelectorWithArgs<string, Stored<UserFormSubmission>[]>;
|
|
46
|
+
export declare const selectFormSubmissionsByAssets: Selector<Record<string, Stored<UserFormSubmission>[]>>;
|
|
47
47
|
export declare const selectFormSubmissionAttachmentsMapping: Selector<FormSubmissionState["attachments"]>;
|
|
48
48
|
export declare const selectAttachmentsOfFormSubmission: SelectorWithArgs<string, Stored<UserFormSubmissionAttachment>[]>;
|
|
49
49
|
export declare const formSubmissionReducer: Reducer<FormSubmissionState>;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
export * from "./authSlice";
|
|
2
2
|
export * from "./categorySlice";
|
|
3
|
-
export * from "./
|
|
4
|
-
export * from "./
|
|
5
|
-
export * from "./
|
|
6
|
-
export * from "./
|
|
3
|
+
export * from "./assetSlice";
|
|
4
|
+
export * from "./assetStageCompletionSlice";
|
|
5
|
+
export * from "./assetStageSlice";
|
|
6
|
+
export * from "./assetTypeSlice";
|
|
7
7
|
export * from "./issueSlice";
|
|
8
8
|
export * from "./issueTypeSlice";
|
|
9
9
|
export * from "./fileSlice";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="@redux-offline/redux-offline" />
|
|
2
2
|
import { PayloadAction, Reducer } from "@reduxjs/toolkit";
|
|
3
|
-
import { Created, Issue, IssueAttachment, IssueComment, IssueUpdate,
|
|
3
|
+
import { Created, Issue, IssueAttachment, IssueComment, IssueUpdate, OvermapRootState, SearchableRecentResult, SearchArgs, SearchResult, Selector, SelectorWithArgs, Stored, Submitted } from "../../typings";
|
|
4
4
|
import { IssueStatus } from "../../enums";
|
|
5
5
|
interface RecentIssueId {
|
|
6
6
|
offlineId: string;
|
|
@@ -108,36 +108,36 @@ export interface IssueFilterArgs {
|
|
|
108
108
|
filterByCategory: boolean;
|
|
109
109
|
filterByWorkspace: boolean;
|
|
110
110
|
}
|
|
111
|
-
export declare const selectIssueMapping: (state:
|
|
112
|
-
export declare const selectRecentIssueIds: (state:
|
|
113
|
-
export declare const selectVisibleUserIds: (state:
|
|
114
|
-
export declare const selectVisibleStatuses: (state:
|
|
111
|
+
export declare const selectIssueMapping: (state: OvermapRootState) => Record<string, Stored<Issue>>;
|
|
112
|
+
export declare const selectRecentIssueIds: (state: OvermapRootState) => RecentIssueId[];
|
|
113
|
+
export declare const selectVisibleUserIds: (state: OvermapRootState) => (number | null)[] | null;
|
|
114
|
+
export declare const selectVisibleStatuses: (state: OvermapRootState) => IssueStatus[];
|
|
115
115
|
export declare const selectIssues: SelectorWithArgs<IssueFilterArgs, Stored<Issue>[]>;
|
|
116
|
-
export declare const selectActiveIssueId: (state:
|
|
117
|
-
export declare const selectIssueAttachmentMapping: (state:
|
|
116
|
+
export declare const selectActiveIssueId: (state: OvermapRootState) => string | null;
|
|
117
|
+
export declare const selectIssueAttachmentMapping: (state: OvermapRootState) => Record<string, Stored<IssueAttachment>>;
|
|
118
118
|
export declare const selectIssueAttachments: Selector<Stored<IssueAttachment>[]>;
|
|
119
119
|
export declare const selectPhotoAttachmentsOfIssue: SelectorWithArgs<string, Stored<IssueAttachment>[]>;
|
|
120
|
-
export declare const selectCommentMapping: (state:
|
|
121
|
-
export declare const selectCommentsOfIssue: (args: string) => (state:
|
|
122
|
-
export declare const selectIssueUpdateMapping: (state:
|
|
123
|
-
export declare const selectIssueUpdatesOfIssue: (args: string) => (state:
|
|
124
|
-
export declare const selectAttachmentsOfIssue: (args: string) => (state:
|
|
120
|
+
export declare const selectCommentMapping: (state: OvermapRootState) => Record<string, Stored<IssueComment>>;
|
|
121
|
+
export declare const selectCommentsOfIssue: (args: string) => (state: OvermapRootState) => Stored<IssueComment>[];
|
|
122
|
+
export declare const selectIssueUpdateMapping: (state: OvermapRootState) => Record<string, Stored<IssueUpdate>>;
|
|
123
|
+
export declare const selectIssueUpdatesOfIssue: (args: string) => (state: OvermapRootState) => Stored<IssueUpdate>[];
|
|
124
|
+
export declare const selectAttachmentsOfIssue: (args: string) => (state: OvermapRootState) => Stored<IssueAttachment>[];
|
|
125
125
|
export declare const selectIssueAttachment: SelectorWithArgs<string, Stored<IssueAttachment>>;
|
|
126
|
-
export declare const selectAttachmentsOfIssueByType: (args: string) => (state:
|
|
126
|
+
export declare const selectAttachmentsOfIssueByType: (args: string) => (state: OvermapRootState) => {
|
|
127
127
|
fileAttachments: Stored<IssueAttachment>[];
|
|
128
128
|
imageAttachments: Stored<IssueAttachment>[];
|
|
129
129
|
};
|
|
130
|
-
export declare const selectFileAttachmentsOfIssue: (args: string) => (state:
|
|
130
|
+
export declare const selectFileAttachmentsOfIssue: (args: string) => (state: OvermapRootState) => Stored<IssueAttachment>[] | undefined;
|
|
131
131
|
export declare const selectIssue: SelectorWithArgs<string, Stored<Issue> | undefined>;
|
|
132
132
|
export declare const selectAllAttachments: ((state: import("redux").EmptyObject & {
|
|
133
133
|
versioning: import('../slices/versioningSlice').VersioningState;
|
|
134
134
|
fileReducer: import('..').FileState;
|
|
135
135
|
authReducer: import('..').AuthState;
|
|
136
136
|
categoryReducer: import("./categorySlice").CategoryState;
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
137
|
+
assetReducer: import('..').AssetState;
|
|
138
|
+
assetStageCompletionReducer: import('..').AssetStageCompletionState;
|
|
139
|
+
assetStageReducer: import('..').AssetStageState;
|
|
140
|
+
assetTypeReducer: import('..').AssetTypeState;
|
|
141
141
|
issueReducer: IssueState;
|
|
142
142
|
issueTypeReducer: import('..').IssueTypeState;
|
|
143
143
|
mapReducer: import('..').MapState;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { PayloadAction, Reducer } from "@reduxjs/toolkit";
|
|
2
2
|
import { MapStyle } from "../../enums";
|
|
3
|
-
import {
|
|
3
|
+
import { OvermapRootState } from "../../typings";
|
|
4
4
|
export interface MapState {
|
|
5
5
|
mapStyle: MapStyle;
|
|
6
6
|
showTooltips: boolean;
|
|
@@ -17,7 +17,7 @@ export declare const mapSlice: import("@reduxjs/toolkit").Slice<MapState, {
|
|
|
17
17
|
}) => void;
|
|
18
18
|
}, "map">;
|
|
19
19
|
export declare const setMapStyle: import("@reduxjs/toolkit").ActionCreatorWithPayload<MapStyle, "map/setMapStyle">, setShowTooltips: import("@reduxjs/toolkit").ActionCreatorWithPayload<boolean, "map/setShowTooltips">, setCenterMapToProject: import("@reduxjs/toolkit").ActionCreatorWithPayload<boolean, "map/setCenterMapToProject">;
|
|
20
|
-
export declare const selectMapStyle: (state:
|
|
21
|
-
export declare const selectShowTooltips: (state:
|
|
22
|
-
export declare const selectCenterMapToProject: (state:
|
|
20
|
+
export declare const selectMapStyle: (state: OvermapRootState) => MapStyle;
|
|
21
|
+
export declare const selectShowTooltips: (state: OvermapRootState) => boolean;
|
|
22
|
+
export declare const selectCenterMapToProject: (state: OvermapRootState) => boolean;
|
|
23
23
|
export declare const mapReducer: Reducer<MapState>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Reducer } from "@reduxjs/toolkit";
|
|
2
|
-
import {
|
|
2
|
+
import { OvermapRootState, Selector, SelectorWithArgs } from '../../typings';
|
|
3
3
|
import { OfflineIdMapping, OrganizationAccess, User } from '../../typings/models';
|
|
4
4
|
export interface OrganizationAccessState {
|
|
5
5
|
organizationAccesses: OfflineIdMapping<OrganizationAccess>;
|
|
@@ -16,9 +16,9 @@ export declare const organizationAccessSlice: import("@reduxjs/toolkit").Slice<O
|
|
|
16
16
|
}) => void;
|
|
17
17
|
}, "organizationAccess">;
|
|
18
18
|
export declare const setOrganizationAccesses: import("@reduxjs/toolkit").ActionCreatorWithPayload<OrganizationAccess[], "organizationAccess/setOrganizationAccesses">, updateOrganizationAccess: import("@reduxjs/toolkit").ActionCreatorWithPayload<OrganizationAccess, "organizationAccess/updateOrganizationAccess">, removeOrganizationAccess: import("@reduxjs/toolkit").ActionCreatorWithPayload<OrganizationAccess, "organizationAccess/removeOrganizationAccess">;
|
|
19
|
-
export declare const selectOrganizationAccesses: (state:
|
|
19
|
+
export declare const selectOrganizationAccesses: (state: OvermapRootState) => OfflineIdMapping<OrganizationAccess>;
|
|
20
20
|
export declare const selectOrganizationAccess: SelectorWithArgs<string, OrganizationAccess>;
|
|
21
21
|
export declare const selectActiveOrganizationAccess: Selector<OrganizationAccess | null>;
|
|
22
22
|
export declare const selectOrganizationAccessForUser: SelectorWithArgs<User, OrganizationAccess | undefined>;
|
|
23
|
-
export declare const selectOrganizationAccessUserMapping: (state:
|
|
23
|
+
export declare const selectOrganizationAccessUserMapping: (state: OvermapRootState) => Record<number, OrganizationAccess>;
|
|
24
24
|
export declare const organizationAccessReducer: Reducer<OrganizationAccessState>;
|
|
@@ -2,7 +2,7 @@ import { PayloadAction, Reducer } from "@reduxjs/toolkit";
|
|
|
2
2
|
import type { FullOfflineAction } from "../store";
|
|
3
3
|
import type { RequestDetails } from "../../sdk";
|
|
4
4
|
import { SDKRequest } from "../../sdk";
|
|
5
|
-
import {
|
|
5
|
+
import { OvermapRootState } from "../../typings";
|
|
6
6
|
export declare const createOfflineAction: (request: SDKRequest, baseUrl: string) => FullOfflineAction;
|
|
7
7
|
export interface OutboxState {
|
|
8
8
|
/** A list of requests marked for deletion. Once the offline slice encounters one of these, */
|
|
@@ -27,8 +27,8 @@ export declare const outboxSlice: import("@reduxjs/toolkit").Slice<OutboxState,
|
|
|
27
27
|
markAsDeleted(state: import("immer/dist/internal.js").WritableDraft<OutboxState>, action: PayloadAction<string>): void;
|
|
28
28
|
_setLatestRetryTime: (state: import("immer/dist/internal.js").WritableDraft<OutboxState>, action: PayloadAction<number>) => void;
|
|
29
29
|
}, "outbox">;
|
|
30
|
-
export declare const selectDeletedRequests: (state:
|
|
31
|
-
export declare const selectLatestRetryTime: (state:
|
|
30
|
+
export declare const selectDeletedRequests: (state: OvermapRootState) => string[];
|
|
31
|
+
export declare const selectLatestRetryTime: (state: OvermapRootState) => number;
|
|
32
32
|
export declare const enqueueRequest: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[payload: Omit<RequestDetails, "uuid"> & {
|
|
33
33
|
uuid?: string | undefined;
|
|
34
34
|
} & {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Reducer } from "@reduxjs/toolkit";
|
|
2
|
-
import { ProjectAccess,
|
|
2
|
+
import { ProjectAccess, OvermapRootState, Selector, SelectorWithArgs, User } from "../../typings";
|
|
3
3
|
export interface ProjectAccessState {
|
|
4
4
|
projectAccesses: Record<string, ProjectAccess>;
|
|
5
5
|
}
|
|
@@ -18,7 +18,7 @@ export declare const projectAccessSlice: import("@reduxjs/toolkit").Slice<Projec
|
|
|
18
18
|
}) => void;
|
|
19
19
|
}, "projectAccess">;
|
|
20
20
|
export declare const setProjectAccesses: import("@reduxjs/toolkit").ActionCreatorWithPayload<ProjectAccess[], "projectAccess/setProjectAccesses">, updateProjectAccess: import("@reduxjs/toolkit").ActionCreatorWithPayload<ProjectAccess, "projectAccess/updateProjectAccess">, removeProjectAccess: import("@reduxjs/toolkit").ActionCreatorWithPayload<ProjectAccess, "projectAccess/removeProjectAccess">, removeProjectAccessesOfProject: import("@reduxjs/toolkit").ActionCreatorWithPayload<number, "projectAccess/removeProjectAccessesOfProject">;
|
|
21
|
-
export declare const selectProjectAccesses: (state:
|
|
21
|
+
export declare const selectProjectAccesses: (state: OvermapRootState) => Record<string, ProjectAccess>;
|
|
22
22
|
export declare const selectProjectAccess: SelectorWithArgs<string, ProjectAccess>;
|
|
23
23
|
export declare const selectActiveProjectAccess: Selector<ProjectAccess | null>;
|
|
24
24
|
export declare const selectProjectAccessForUser: SelectorWithArgs<User, ProjectAccess | undefined>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/// <reference types="@redux-offline/redux-offline" />
|
|
2
2
|
import { Reducer } from "@reduxjs/toolkit";
|
|
3
3
|
import L from "leaflet";
|
|
4
|
-
import { ProjectFile,
|
|
4
|
+
import { ProjectFile, OvermapRootState, Selector } from "../../typings";
|
|
5
5
|
export interface ProjectFileState {
|
|
6
6
|
projectFiles: Record<string, ProjectFile>;
|
|
7
7
|
activeProjectFileId: string | null;
|
|
@@ -46,18 +46,18 @@ export declare const addOrReplaceProjectFiles: import("@reduxjs/toolkit").Action
|
|
|
46
46
|
fileId: string;
|
|
47
47
|
visible: boolean;
|
|
48
48
|
}, "projectFiles/setProjectFileVisible">, setIsImportingProjectFile: import("@reduxjs/toolkit").ActionCreatorWithPayload<boolean, "projectFiles/setIsImportingProjectFile">, setActiveProjectFileId: import("@reduxjs/toolkit").ActionCreatorWithPayload<string | null, "projectFiles/setActiveProjectFileId">, saveActiveProjectFileBounds: import("@reduxjs/toolkit").ActionCreatorWithPayload<[L.LatLngTuple, L.LatLngTuple], "projectFiles/saveActiveProjectFileBounds">, removeProjectFile: import("@reduxjs/toolkit").ActionCreatorWithPayload<string, "projectFiles/removeProjectFile">, removeProjectFilesOfProject: import("@reduxjs/toolkit").ActionCreatorWithPayload<number, "projectFiles/removeProjectFilesOfProject">, resetProjectFileObjectUrls: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"projectFiles/resetProjectFileObjectUrls">;
|
|
49
|
-
export declare const selectEnabledProjectFiles: (state:
|
|
49
|
+
export declare const selectEnabledProjectFiles: (state: OvermapRootState) => Record<string, boolean | undefined>;
|
|
50
50
|
export declare const selectProjectFileVisibility: Selector<Record<string, boolean>>;
|
|
51
|
-
export declare const selectEnabledProjectFileMapping: (state:
|
|
51
|
+
export declare const selectEnabledProjectFileMapping: (state: OvermapRootState) => Record<string, ProjectFile>;
|
|
52
52
|
export declare const selectProjectFiles: ((state: import("redux").EmptyObject & {
|
|
53
53
|
versioning: import('../slices/versioningSlice').VersioningState;
|
|
54
54
|
fileReducer: import('..').FileState;
|
|
55
55
|
authReducer: import('..').AuthState;
|
|
56
56
|
categoryReducer: import('..').CategoryState;
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
57
|
+
assetReducer: import('..').AssetState;
|
|
58
|
+
assetStageCompletionReducer: import('..').AssetStageCompletionState;
|
|
59
|
+
assetStageReducer: import('..').AssetStageState;
|
|
60
|
+
assetTypeReducer: import('..').AssetTypeState;
|
|
61
61
|
issueReducer: import('..').IssueState;
|
|
62
62
|
issueTypeReducer: import('..').IssueTypeState;
|
|
63
63
|
mapReducer: import('..').MapState;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Reducer } from "@reduxjs/toolkit";
|
|
2
|
-
import { Project, ProjectAttachment, ProjectType,
|
|
2
|
+
import { Project, ProjectAttachment, ProjectType, OvermapRootState, Selector, SelectorWithArgs, Stored, User } from "../../typings";
|
|
3
3
|
export interface ProjectState {
|
|
4
4
|
projects: Record<number, Project>;
|
|
5
5
|
activeProjectId: number | null;
|
|
@@ -71,21 +71,21 @@ export declare const projectSlice: import("@reduxjs/toolkit").Slice<ProjectState
|
|
|
71
71
|
}, "projects">;
|
|
72
72
|
export declare const setProjects: import("@reduxjs/toolkit").ActionCreatorWithPayload<Project[], "projects/setProjects">, updateOrCreateProject: import("@reduxjs/toolkit").ActionCreatorWithPayload<Project, "projects/updateOrCreateProject">, addOrReplaceProjects: import("@reduxjs/toolkit").ActionCreatorWithPayload<Project[], "projects/updateOrCreateProjects">, setActiveProjectId: import("@reduxjs/toolkit").ActionCreatorWithPayload<number | null, "projects/setActiveProjectId">, setCreateProjectType: import("@reduxjs/toolkit").ActionCreatorWithPayload<ProjectType, "projects/setCreateProjectType">, deleteProject: import("@reduxjs/toolkit").ActionCreatorWithPayload<Project, "projects/deleteProject">, acceptProjectInvite: import("@reduxjs/toolkit").ActionCreatorWithPayload<number, "projects/acceptProjectInvite">, addActiveProjectIssuesCount: import("@reduxjs/toolkit").ActionCreatorWithPayload<number, "projects/addActiveProjectIssuesCount">, addActiveProjectFormSubmissionsCount: import("@reduxjs/toolkit").ActionCreatorWithPayload<number, "projects/addActiveProjectFormSubmissionsCount">, setProjectAttachment: import("@reduxjs/toolkit").ActionCreatorWithPayload<Stored<ProjectAttachment>, "projects/setProjectAttachment">, setProjectAttachments: import("@reduxjs/toolkit").ActionCreatorWithPayload<Stored<ProjectAttachment>[], "projects/setProjectAttachments">, addProjectAttachment: import("@reduxjs/toolkit").ActionCreatorWithPayload<import('../../typings/models/issues').Submitted<ProjectAttachment>, "projects/addProjectAttachment">, addProjectAttachments: import("@reduxjs/toolkit").ActionCreatorWithPayload<import('../../typings/models/issues').Submitted<ProjectAttachment>[], "projects/addProjectAttachments">, updateProjectAttachment: import("@reduxjs/toolkit").ActionCreatorWithPayload<import('../../typings/models/issues').Submitted<ProjectAttachment>, "projects/updateProjectAttachment">, updateProjectAttachments: import("@reduxjs/toolkit").ActionCreatorWithPayload<import('../../typings/models/issues').Submitted<ProjectAttachment>[], "projects/updateProjectAttachments">, removeProjectAttachment: import("@reduxjs/toolkit").ActionCreatorWithPayload<string, "projects/removeProjectAttachment">, removeProjectAttachments: import("@reduxjs/toolkit").ActionCreatorWithPayload<string[], "projects/removeProjectAttachments">;
|
|
73
73
|
export declare const selectProjects: Selector<Record<number, Project>>;
|
|
74
|
-
export declare const selectActiveProjectId: (state:
|
|
75
|
-
export declare const selectActiveProject: (state:
|
|
76
|
-
export declare const selectRecentProjects: (state:
|
|
74
|
+
export declare const selectActiveProjectId: (state: OvermapRootState) => number | null;
|
|
75
|
+
export declare const selectActiveProject: (state: OvermapRootState) => Project | null;
|
|
76
|
+
export declare const selectRecentProjects: (state: OvermapRootState) => number[];
|
|
77
77
|
export declare const selectSortedProjects: Selector<Project[]>;
|
|
78
|
-
export declare const selectCreateProjectType: (state:
|
|
78
|
+
export declare const selectCreateProjectType: (state: OvermapRootState) => ProjectType;
|
|
79
79
|
export declare const projectReducer: Reducer<ProjectState>;
|
|
80
80
|
export declare const selectProjectUsersIds: Selector<number[]>;
|
|
81
81
|
export declare const selectProjectUsersAsMapping: Selector<Record<number, User>>;
|
|
82
82
|
export declare const selectProjectsWithAccess: Selector<Project[]>;
|
|
83
83
|
export declare const selectSortedProjectUsers: Selector<User[]>;
|
|
84
|
-
export declare const selectProjectAttachmentMapping: (state:
|
|
84
|
+
export declare const selectProjectAttachmentMapping: (state: OvermapRootState) => Record<string, Stored<ProjectAttachment>>;
|
|
85
85
|
export declare const selectAllProjectAttachments: Selector<Stored<ProjectAttachment>[]>;
|
|
86
86
|
export declare const selectProjectAttachment: SelectorWithArgs<string, ProjectAttachment>;
|
|
87
|
-
export declare const selectAttachmentsOfProject: (args: number) => (state:
|
|
88
|
-
export declare const selectAttachmentsOfProjectByType: (args: number) => (state:
|
|
87
|
+
export declare const selectAttachmentsOfProject: (args: number) => (state: OvermapRootState) => Stored<ProjectAttachment>[];
|
|
88
|
+
export declare const selectAttachmentsOfProjectByType: (args: number) => (state: OvermapRootState) => {
|
|
89
89
|
fileAttachments: Stored<ProjectAttachment>[];
|
|
90
90
|
imageAttachments: Stored<ProjectAttachment>[];
|
|
91
91
|
};
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { PayloadAction, Reducer } from "@reduxjs/toolkit";
|
|
2
|
-
import {
|
|
2
|
+
import { OvermapRootState } from "../../typings";
|
|
3
3
|
export interface RehydratedState {
|
|
4
4
|
isRehydrated: boolean;
|
|
5
5
|
}
|
|
6
6
|
export declare const rehydratedSlice: import("@reduxjs/toolkit").Slice<RehydratedState, {
|
|
7
7
|
setRehydrated: (state: import("immer/dist/internal.js").WritableDraft<RehydratedState>, action: PayloadAction<boolean>) => void;
|
|
8
8
|
}, "rehydrated">;
|
|
9
|
-
export declare const selectRehydrated: (state:
|
|
9
|
+
export declare const selectRehydrated: (state: OvermapRootState) => boolean;
|
|
10
10
|
export declare const rehydratedReducer: Reducer<RehydratedState>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { PayloadAction, Reducer } from "@reduxjs/toolkit";
|
|
2
|
-
import { Appearance,
|
|
2
|
+
import { Appearance, OvermapRootState } from "../../typings";
|
|
3
3
|
export interface SettingState {
|
|
4
4
|
useIssueTemplate: boolean;
|
|
5
5
|
placementMode: boolean;
|
|
@@ -21,12 +21,12 @@ export declare const settingSlice: import("@reduxjs/toolkit").Slice<SettingState
|
|
|
21
21
|
setIsLoading: (state: import("immer/dist/internal.js").WritableDraft<SettingState>, action: PayloadAction<boolean>) => void;
|
|
22
22
|
}, "settings">;
|
|
23
23
|
export declare const setEnableDuplicateIssues: import("@reduxjs/toolkit").ActionCreatorWithPayload<boolean, "settings/setEnableDuplicateIssues">, setEnablePlacementMode: import("@reduxjs/toolkit").ActionCreatorWithPayload<boolean, "settings/setEnablePlacementMode">, setSectionExpanded: import("@reduxjs/toolkit").ActionCreatorWithPayload<Record<string, boolean>, "settings/setSectionExpanded">, setEnableClustering: import("@reduxjs/toolkit").ActionCreatorWithPayload<boolean, "settings/setEnableClustering">, setAppearance: import("@reduxjs/toolkit").ActionCreatorWithPayload<"light" | "dark", "settings/setAppearance">, setIsFetchingInitialData: import("@reduxjs/toolkit").ActionCreatorWithPayload<boolean, "settings/setIsFetchingInitialData">, setIsLoading: import("@reduxjs/toolkit").ActionCreatorWithPayload<boolean, "settings/setIsLoading">;
|
|
24
|
-
export declare const selectEnablePlacementMode: (state:
|
|
25
|
-
export declare const selectEnableDuplicateIssues: (state:
|
|
26
|
-
export declare const selectEnableSvgLayout: (state:
|
|
27
|
-
export declare const selectExpandedSections: (state:
|
|
28
|
-
export declare const selectEnableClustering: (state:
|
|
29
|
-
export declare const selectAppearance: (state:
|
|
24
|
+
export declare const selectEnablePlacementMode: (state: OvermapRootState) => boolean;
|
|
25
|
+
export declare const selectEnableDuplicateIssues: (state: OvermapRootState) => boolean;
|
|
26
|
+
export declare const selectEnableSvgLayout: (state: OvermapRootState) => boolean;
|
|
27
|
+
export declare const selectExpandedSections: (state: OvermapRootState) => Record<string, boolean>;
|
|
28
|
+
export declare const selectEnableClustering: (state: OvermapRootState) => boolean;
|
|
29
|
+
export declare const selectAppearance: (state: OvermapRootState) => ("inherit" | "light" | "dark") | undefined;
|
|
30
30
|
export declare const settingReducer: Reducer<SettingState>;
|
|
31
|
-
export declare const selectIsFetchingInitialData: (state:
|
|
32
|
-
export declare const selectIsLoading: (state:
|
|
31
|
+
export declare const selectIsFetchingInitialData: (state: OvermapRootState) => boolean;
|
|
32
|
+
export declare const selectIsLoading: (state: OvermapRootState) => boolean;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Reducer } from "@reduxjs/toolkit";
|
|
2
|
-
import {
|
|
2
|
+
import { OvermapRootState, SelectorWithArgs, User } from "../../typings";
|
|
3
3
|
export interface UserState {
|
|
4
4
|
currentUser: User;
|
|
5
5
|
users: Record<number, User>;
|
|
@@ -37,8 +37,8 @@ export declare const setCurrentUser: import("@reduxjs/toolkit").ActionCreatorWit
|
|
|
37
37
|
file?: string | undefined;
|
|
38
38
|
file_sha1?: string | undefined;
|
|
39
39
|
}, "users/setProfilePicture">, setUsers: import("@reduxjs/toolkit").ActionCreatorWithPayload<User[], "users/setUsers">, addUsers: import("@reduxjs/toolkit").ActionCreatorWithPayload<User[], "users/addUsers">, addFavouriteProjectId: import("@reduxjs/toolkit").ActionCreatorWithPayload<number, "users/addFavouriteProjectId">, removeFavouriteProjectId: import("@reduxjs/toolkit").ActionCreatorWithPayload<number, "users/removeFavouriteProjectId">, setTourStep: import("@reduxjs/toolkit").ActionCreatorWithPayload<number, "users/setTourStep">, removeUser: import("@reduxjs/toolkit").ActionCreatorWithPayload<number, "users/removeUser">;
|
|
40
|
-
export declare const selectCurrentUser: (state:
|
|
40
|
+
export declare const selectCurrentUser: (state: OvermapRootState) => User;
|
|
41
41
|
export declare const selectUser: SelectorWithArgs<number | null, User | undefined>;
|
|
42
|
-
export declare const selectUsersAsMapping: (state:
|
|
43
|
-
export declare const selectFavouriteProjects: (state:
|
|
42
|
+
export declare const selectUsersAsMapping: (state: OvermapRootState) => Record<number, User>;
|
|
43
|
+
export declare const selectFavouriteProjects: (state: OvermapRootState) => number[];
|
|
44
44
|
export declare const userReducer: Reducer<UserState>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="@redux-offline/redux-offline" />
|
|
2
2
|
import { Reducer } from "@reduxjs/toolkit";
|
|
3
|
-
import {
|
|
3
|
+
import { OvermapRootState, Selector, Workspace } from "../../typings";
|
|
4
4
|
export interface WorkspaceState {
|
|
5
5
|
workspaces: Record<string, Workspace>;
|
|
6
6
|
activeWorkspaceId: string | null;
|
|
@@ -32,10 +32,10 @@ export declare const selectWorkspaces: ((state: import("redux").EmptyObject & {
|
|
|
32
32
|
fileReducer: import('..').FileState;
|
|
33
33
|
authReducer: import('..').AuthState;
|
|
34
34
|
categoryReducer: import('..').CategoryState;
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
35
|
+
assetReducer: import('..').AssetState;
|
|
36
|
+
assetStageCompletionReducer: import('..').AssetStageCompletionState;
|
|
37
|
+
assetStageReducer: import('..').AssetStageState;
|
|
38
|
+
assetTypeReducer: import('..').AssetTypeState;
|
|
39
39
|
issueReducer: import('..').IssueState;
|
|
40
40
|
issueTypeReducer: import('..').IssueTypeState;
|
|
41
41
|
mapReducer: import('..').MapState;
|
|
@@ -65,7 +65,7 @@ export declare const selectWorkspaces: ((state: import("redux").EmptyObject & {
|
|
|
65
65
|
clearCache: () => void;
|
|
66
66
|
};
|
|
67
67
|
export declare const selectMainWorkspace: Selector<Workspace | undefined>;
|
|
68
|
-
export declare const selectWorkspace: (args: string) => (state:
|
|
68
|
+
export declare const selectWorkspace: (args: string) => (state: OvermapRootState) => Workspace | undefined;
|
|
69
69
|
export declare const selectActiveWorkspaceId: Selector<string | null>;
|
|
70
70
|
export declare const selectActiveWorkspace: Selector<Workspace | null | undefined>;
|
|
71
71
|
export declare const selectPermittedWorkspaceIds: Selector<Set<string>>;
|
package/dist/store/store.d.ts
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
/// <reference types="@redux-offline/redux-offline" />
|
|
2
2
|
import { AnyAction, Reducer } from "redux";
|
|
3
|
-
import { Config, OfflineAction, OfflineMetadata
|
|
3
|
+
import { Config, OfflineAction, OfflineMetadata } from "@redux-offline/redux-offline/lib/types";
|
|
4
4
|
import request from "superagent";
|
|
5
5
|
import { type OfflineMetaEffect, OutboxCoordinator, type OvermapSDK, RequestDetails } from "../sdk";
|
|
6
|
-
import { AgentsState, AuthState, CategoryState,
|
|
6
|
+
import { AgentsState, AuthState, CategoryState, AssetStageCompletionState, AssetStageState, AssetState, AssetTypeState, DocumentState, EmailDomainState, FileState, FormRevisionState, FormState, FormSubmissionState, IssueState, IssueTypeState, LicenseState, MapState, OrganizationAccessState, OrganizationState, OutboxState, ProjectAccessState, ProjectFileState, ProjectState, RehydratedState, SettingState, UserState, WorkspaceState, TeamState } from "./slices";
|
|
7
7
|
import { VersioningState } from "./slices/versioningSlice";
|
|
8
|
-
import {
|
|
8
|
+
import { OvermapRootState } from "../typings";
|
|
9
9
|
export declare const overmapReducers: {
|
|
10
10
|
versioning: Reducer<VersioningState>;
|
|
11
11
|
fileReducer: Reducer<FileState>;
|
|
12
12
|
authReducer: Reducer<AuthState>;
|
|
13
13
|
categoryReducer: Reducer<CategoryState>;
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
14
|
+
assetReducer: Reducer<AssetState>;
|
|
15
|
+
assetStageCompletionReducer: Reducer<AssetStageCompletionState>;
|
|
16
|
+
assetStageReducer: Reducer<AssetStageState>;
|
|
17
|
+
assetTypeReducer: Reducer<AssetTypeState>;
|
|
18
18
|
issueReducer: Reducer<IssueState>;
|
|
19
19
|
issueTypeReducer: Reducer<IssueTypeState>;
|
|
20
20
|
mapReducer: Reducer<MapState>;
|
|
@@ -42,10 +42,10 @@ export declare const overmapReducer: Reducer<import("redux").CombinedState<{
|
|
|
42
42
|
fileReducer: FileState;
|
|
43
43
|
authReducer: AuthState;
|
|
44
44
|
categoryReducer: CategoryState;
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
45
|
+
assetReducer: AssetState;
|
|
46
|
+
assetStageCompletionReducer: AssetStageCompletionState;
|
|
47
|
+
assetStageReducer: AssetStageState;
|
|
48
|
+
assetTypeReducer: AssetTypeState;
|
|
49
49
|
issueReducer: IssueState;
|
|
50
50
|
issueTypeReducer: IssueTypeState;
|
|
51
51
|
mapReducer: MapState;
|
|
@@ -69,7 +69,7 @@ export declare const overmapReducer: Reducer<import("redux").CombinedState<{
|
|
|
69
69
|
agentsReducer: AgentsState;
|
|
70
70
|
}>, AnyAction>;
|
|
71
71
|
export declare const resetStore = "RESET";
|
|
72
|
-
export declare const
|
|
72
|
+
export declare const overmapRootReducer: Reducer<OvermapRootState>;
|
|
73
73
|
export interface FullOfflineMetadata extends OfflineMetadata {
|
|
74
74
|
effect: OfflineMetaEffect;
|
|
75
75
|
}
|
|
@@ -87,38 +87,5 @@ export declare const dequeue: Config["queue"]["dequeue"];
|
|
|
87
87
|
* Add to your store's `enhancers` array.
|
|
88
88
|
*/
|
|
89
89
|
export declare const overmapEnhancer: (...args: any[]) => unknown;
|
|
90
|
-
export declare const defaultStore: import("@reduxjs/toolkit/dist/configureStore").ToolkitStore<import("redux").EmptyObject & {
|
|
91
|
-
versioning: VersioningState;
|
|
92
|
-
fileReducer: FileState;
|
|
93
|
-
authReducer: AuthState;
|
|
94
|
-
categoryReducer: CategoryState;
|
|
95
|
-
componentReducer: ComponentState;
|
|
96
|
-
componentStageCompletionReducer: ComponentStageCompletionState;
|
|
97
|
-
componentStageReducer: ComponentStageState;
|
|
98
|
-
componentTypeReducer: ComponentTypeState;
|
|
99
|
-
issueReducer: IssueState;
|
|
100
|
-
issueTypeReducer: IssueTypeState;
|
|
101
|
-
mapReducer: MapState;
|
|
102
|
-
organizationReducer: OrganizationState;
|
|
103
|
-
outboxReducer: OutboxState;
|
|
104
|
-
projectReducer: ProjectState;
|
|
105
|
-
projectAccessReducer: ProjectAccessState;
|
|
106
|
-
organizationAccessReducer: OrganizationAccessState;
|
|
107
|
-
projectFileReducer: ProjectFileState;
|
|
108
|
-
rehydratedReducer: RehydratedState;
|
|
109
|
-
settingReducer: SettingState;
|
|
110
|
-
formReducer: FormState;
|
|
111
|
-
userReducer: UserState;
|
|
112
|
-
formRevisionReducer: FormRevisionState;
|
|
113
|
-
formSubmissionReducer: FormSubmissionState;
|
|
114
|
-
workspaceReducer: WorkspaceState;
|
|
115
|
-
emailDomainsReducer: EmailDomainState;
|
|
116
|
-
licenseReducer: LicenseState;
|
|
117
|
-
documentsReducer: DocumentState;
|
|
118
|
-
teamReducer: TeamState;
|
|
119
|
-
agentsReducer: AgentsState;
|
|
120
|
-
} & {
|
|
121
|
-
offline: OfflineState;
|
|
122
|
-
}, AnyAction, import("@reduxjs/toolkit").MiddlewareArray<[import("@reduxjs/toolkit").ThunkMiddleware<RootState, AnyAction>]>>;
|
|
123
90
|
export declare function performRequest(action: FullOfflineAction, client: OvermapSDK): Promise<request.Response>;
|
|
124
91
|
export declare function discard(reason: unknown, action: FullOfflineAction, retries?: number): boolean;
|
|
@@ -10,11 +10,11 @@ export interface Attachment extends OfflineModel, FileWithNameModel, CreatedByMo
|
|
|
10
10
|
export interface IssueAttachment extends Attachment {
|
|
11
11
|
issue: string;
|
|
12
12
|
}
|
|
13
|
-
export interface
|
|
14
|
-
|
|
13
|
+
export interface AssetAttachment extends Attachment {
|
|
14
|
+
asset: string;
|
|
15
15
|
}
|
|
16
|
-
export interface
|
|
17
|
-
|
|
16
|
+
export interface AssetTypeAttachment extends Attachment {
|
|
17
|
+
asset_type: string;
|
|
18
18
|
}
|
|
19
19
|
export interface ProjectAttachment extends Attachment {
|
|
20
20
|
project: Project["id"];
|
|
@@ -24,8 +24,8 @@ export interface DocumentAttachment extends Attachment {
|
|
|
24
24
|
}
|
|
25
25
|
export declare enum AttachmentModel {
|
|
26
26
|
Issue = "issue",
|
|
27
|
-
|
|
28
|
-
|
|
27
|
+
Asset = "asset",
|
|
28
|
+
AssetType = "asset_type",
|
|
29
29
|
Project = "project",
|
|
30
30
|
Document = "document"
|
|
31
31
|
}
|
|
@@ -1,21 +1,25 @@
|
|
|
1
|
-
import { IconModel, OfflineModel } from "./base";
|
|
1
|
+
import { IconModel, Model, OfflineModel } from "./base";
|
|
2
2
|
import { Marker } from "./geo";
|
|
3
|
-
export interface
|
|
3
|
+
export interface Asset extends OfflineModel {
|
|
4
4
|
marker: Marker | null;
|
|
5
|
-
|
|
5
|
+
asset_type: string;
|
|
6
6
|
created_at?: string;
|
|
7
7
|
label: string | null;
|
|
8
8
|
}
|
|
9
|
-
export interface
|
|
9
|
+
export interface AssetType extends OfflineModel, IconModel {
|
|
10
10
|
name?: string;
|
|
11
11
|
description?: string;
|
|
12
12
|
}
|
|
13
|
-
export interface
|
|
14
|
-
|
|
13
|
+
export interface AssetStage extends OfflineModel {
|
|
14
|
+
asset_type: string;
|
|
15
15
|
name: string;
|
|
16
16
|
description?: string;
|
|
17
17
|
priority: number;
|
|
18
18
|
user_form?: string;
|
|
19
19
|
}
|
|
20
|
-
export type
|
|
20
|
+
export type AssetStagePayload = Omit<AssetStage, "asset_type">;
|
|
21
|
+
export interface AssetStageCompletion extends Model {
|
|
22
|
+
asset: string;
|
|
23
|
+
stage: string;
|
|
24
|
+
}
|
|
21
25
|
export type CompletedStagesMapping = Record<string, Record<string, string>>;
|
|
@@ -4,7 +4,7 @@ import { FileWithNameModel } from '../files';
|
|
|
4
4
|
import { WorkspaceIndexedModel } from "./workspace";
|
|
5
5
|
export type UserForm = Pick<WorkspaceIndexedModel, "index_workspace"> & {
|
|
6
6
|
favorite: boolean;
|
|
7
|
-
|
|
7
|
+
asset_type?: string;
|
|
8
8
|
issue_type?: string;
|
|
9
9
|
} & ({
|
|
10
10
|
owner_organization: number;
|
|
@@ -37,8 +37,8 @@ export interface UserFormSubmission extends OfflineModel, SubmittedAtModel, Crea
|
|
|
37
37
|
form_revision: string;
|
|
38
38
|
values: Record<string, FieldValue>;
|
|
39
39
|
issue?: string;
|
|
40
|
-
|
|
41
|
-
|
|
40
|
+
asset?: string;
|
|
41
|
+
asset_stage?: string;
|
|
42
42
|
}
|
|
43
43
|
export interface UserFormSubmissionAttachment extends OfflineModel, FileWithNameModel {
|
|
44
44
|
submission: string;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
/// <reference types="@redux-offline/redux-offline" />
|
|
2
2
|
import { OfflineState } from "@redux-offline/redux-offline/lib/types";
|
|
3
|
-
import {
|
|
4
|
-
export type
|
|
5
|
-
export type RootState = ReturnType<typeof overmapReducer> & {
|
|
3
|
+
import { overmapReducer } from "../../store";
|
|
4
|
+
export type OvermapRootState = ReturnType<typeof overmapReducer> & {
|
|
6
5
|
offline: OfflineState;
|
|
7
6
|
};
|
package/dist/typings/store.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export type SelectorWithArgs<TArgs, TRet> = (args: TArgs) => (state:
|
|
3
|
-
export type Selector<TRet> = (state:
|
|
4
|
-
export type Migrator = (state: Partial<
|
|
1
|
+
import { OvermapRootState } from "./models";
|
|
2
|
+
export type SelectorWithArgs<TArgs, TRet> = (args: TArgs) => (state: OvermapRootState) => TRet | undefined;
|
|
3
|
+
export type Selector<TRet> = (state: OvermapRootState) => TRet;
|
|
4
|
+
export type Migrator = (state: Partial<OvermapRootState>) => Partial<OvermapRootState>;
|
|
5
5
|
export type Manifest = Record<number, Migrator>;
|