@overmap-ai/core 1.0.60 → 1.0.61
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/overmap-core.js +25 -21
- package/dist/overmap-core.js.map +1 -1
- package/dist/overmap-core.umd.cjs +25 -21
- package/dist/overmap-core.umd.cjs.map +1 -1
- package/dist/store/slices/formSlice.d.ts +2 -2
- package/dist/store/slices/formSubmissionSlice.d.ts +13 -9
- package/dist/store/slices/licenseSlice.d.ts +2 -2
- package/dist/store/slices/projectAccessSlice.d.ts +2 -2
- package/dist/store/slices/teamSlice.d.ts +2 -2
- package/package.json +1 -1
package/dist/overmap-core.js
CHANGED
|
@@ -1768,12 +1768,12 @@ const licenseSlice = createSlice({
|
|
|
1768
1768
|
initialState: initialState$n,
|
|
1769
1769
|
extraReducers: (builder) => builder.addCase("RESET", (state) => Object.assign(state, initialState$n)),
|
|
1770
1770
|
reducers: {
|
|
1771
|
-
|
|
1771
|
+
initializeLicences: licenseAdapter.initialize,
|
|
1772
1772
|
addLicenses: licenseAdapter.addMany,
|
|
1773
1773
|
updateLicense: licenseAdapter.updateOne
|
|
1774
1774
|
}
|
|
1775
1775
|
});
|
|
1776
|
-
const {
|
|
1776
|
+
const { initializeLicences, addLicenses, updateLicense } = licenseSlice.actions;
|
|
1777
1777
|
const selectLicenses = (state) => {
|
|
1778
1778
|
return state.licenseReducer.instances;
|
|
1779
1779
|
};
|
|
@@ -1798,13 +1798,13 @@ const projectAccessSlice = createSlice({
|
|
|
1798
1798
|
initialState: initialState$m,
|
|
1799
1799
|
extraReducers: (builder) => builder.addCase("RESET", (state) => Object.assign(state, initialState$m)),
|
|
1800
1800
|
reducers: {
|
|
1801
|
-
|
|
1801
|
+
initializeProjectAccesses: projectAccessAdapter.initialize,
|
|
1802
1802
|
updateProjectAccess: projectAccessAdapter.updateOne,
|
|
1803
1803
|
deleteProjectAccess: projectAccessAdapter.deleteOne,
|
|
1804
1804
|
deleteProjectAccesses: projectAccessAdapter.deleteMany
|
|
1805
1805
|
}
|
|
1806
1806
|
});
|
|
1807
|
-
const {
|
|
1807
|
+
const { initializeProjectAccesses, updateProjectAccess, deleteProjectAccess, deleteProjectAccesses } = projectAccessSlice.actions;
|
|
1808
1808
|
const selectProjectAccessMapping = (state) => {
|
|
1809
1809
|
return state.projectAccessReducer.instances;
|
|
1810
1810
|
};
|
|
@@ -2395,7 +2395,7 @@ const formSlice = createSlice({
|
|
|
2395
2395
|
initialState: initialState$d,
|
|
2396
2396
|
extraReducers: (builder) => builder.addCase("RESET", (state) => Object.assign(state, initialState$d)),
|
|
2397
2397
|
reducers: {
|
|
2398
|
-
|
|
2398
|
+
initializeForms: formAdapter.initialize,
|
|
2399
2399
|
setForm: formAdapter.setOne,
|
|
2400
2400
|
addForm: formAdapter.addOne,
|
|
2401
2401
|
addForms: formAdapter.addMany,
|
|
@@ -2403,7 +2403,7 @@ const formSlice = createSlice({
|
|
|
2403
2403
|
deleteForm: formAdapter.deleteOne
|
|
2404
2404
|
}
|
|
2405
2405
|
});
|
|
2406
|
-
const {
|
|
2406
|
+
const { initializeForms, setForm, addForm, addForms, updateForm, deleteForm } = formSlice.actions;
|
|
2407
2407
|
const selectFormsMapping = (state) => {
|
|
2408
2408
|
return state.formReducer.instances;
|
|
2409
2409
|
};
|
|
@@ -2479,6 +2479,7 @@ const formSubmissionSlice = createSlice({
|
|
|
2479
2479
|
initialState: initialState$c,
|
|
2480
2480
|
extraReducers: (builder) => builder.addCase("RESET", (state) => Object.assign(state, initialState$c)),
|
|
2481
2481
|
reducers: {
|
|
2482
|
+
initializeFormSubmissions: submissionAdapter.initialize,
|
|
2482
2483
|
setFormSubmission: submissionAdapter.setOne,
|
|
2483
2484
|
setFormSubmissions: submissionAdapter.setMany,
|
|
2484
2485
|
addFormSubmission: submissionAdapter.addOne,
|
|
@@ -2490,6 +2491,7 @@ const formSubmissionSlice = createSlice({
|
|
|
2490
2491
|
}
|
|
2491
2492
|
});
|
|
2492
2493
|
const {
|
|
2494
|
+
initializeFormSubmissions,
|
|
2493
2495
|
setFormSubmission,
|
|
2494
2496
|
setFormSubmissions,
|
|
2495
2497
|
addFormSubmission,
|
|
@@ -2976,13 +2978,13 @@ const teamSlice = createSlice({
|
|
|
2976
2978
|
extraReducers: (builder) => builder.addCase("RESET", (state) => Object.assign(state, initialState$6)),
|
|
2977
2979
|
reducers: {
|
|
2978
2980
|
setTeam: teamAdapter.setOne,
|
|
2979
|
-
|
|
2981
|
+
initializeTeams: teamAdapter.initialize,
|
|
2980
2982
|
addTeam: teamAdapter.addOne,
|
|
2981
2983
|
updateTeam: teamAdapter.updateOne,
|
|
2982
2984
|
deleteTeam: teamAdapter.deleteOne
|
|
2983
2985
|
}
|
|
2984
2986
|
});
|
|
2985
|
-
const { setTeam,
|
|
2987
|
+
const { setTeam, initializeTeams, addTeam, updateTeam, deleteTeam } = teamSlice.actions;
|
|
2986
2988
|
const selectTeamsMapping = (state) => state.teamReducer.instances;
|
|
2987
2989
|
const selectTeams = createSelector([selectTeamsMapping], (teams) => {
|
|
2988
2990
|
return Object.values(teams);
|
|
@@ -5138,7 +5140,7 @@ class ProjectAccessService extends BaseApiService {
|
|
|
5138
5140
|
async refreshStore(projectId) {
|
|
5139
5141
|
const promise = this.fetchAll(projectId);
|
|
5140
5142
|
const result = await promise;
|
|
5141
|
-
this.dispatch(
|
|
5143
|
+
this.dispatch(initializeProjectAccesses(result));
|
|
5142
5144
|
}
|
|
5143
5145
|
}
|
|
5144
5146
|
class ProjectFileService extends BaseApiService {
|
|
@@ -5150,6 +5152,7 @@ class ProjectFileService extends BaseApiService {
|
|
|
5150
5152
|
blockers: [],
|
|
5151
5153
|
blocks: []
|
|
5152
5154
|
});
|
|
5155
|
+
this.dispatch(addOrReplaceProjectFiles([]));
|
|
5153
5156
|
this.dispatch(addOrReplaceProjectFiles(result));
|
|
5154
5157
|
}
|
|
5155
5158
|
async saveExisting(file) {
|
|
@@ -5303,7 +5306,7 @@ class ProjectService extends BaseApiService {
|
|
|
5303
5306
|
return result;
|
|
5304
5307
|
}
|
|
5305
5308
|
async update(project) {
|
|
5306
|
-
if (!project.bounds
|
|
5309
|
+
if (!project.bounds && !project.canvas_bounds) {
|
|
5307
5310
|
throw new Error("Project must either have bounds or canvas_bounds set");
|
|
5308
5311
|
}
|
|
5309
5312
|
this.dispatch(updateOrCreateProject(project));
|
|
@@ -5350,7 +5353,7 @@ class ProjectService extends BaseApiService {
|
|
|
5350
5353
|
this.dispatch({ type: "rehydrated/setRehydrated", payload: true });
|
|
5351
5354
|
} catch (e) {
|
|
5352
5355
|
this.dispatch(setProjects(Object.values(projects)));
|
|
5353
|
-
this.dispatch(
|
|
5356
|
+
this.dispatch(initializeProjectAccesses(Object.values(projectAccesses)));
|
|
5354
5357
|
this.dispatch(addOrReplaceProjectFiles(filesToDelete));
|
|
5355
5358
|
this.dispatch(setProjectAttachments(attachmentsOfProject));
|
|
5356
5359
|
this.dispatch({ type: "rehydrated/setRehydrated", payload: true });
|
|
@@ -5718,9 +5721,9 @@ class FormService extends BaseApiService {
|
|
|
5718
5721
|
revisions.push(revision);
|
|
5719
5722
|
for (const attachment of issueTypeFormsResult.attachments)
|
|
5720
5723
|
attachments.push(attachment);
|
|
5721
|
-
this.dispatch(
|
|
5724
|
+
this.dispatch(initializeForms(forms));
|
|
5722
5725
|
this.dispatch(initializeFormRevisions(revisions));
|
|
5723
|
-
this.dispatch(
|
|
5726
|
+
this.dispatch(initializeFormRevisionAttachments(attachments));
|
|
5724
5727
|
}
|
|
5725
5728
|
}
|
|
5726
5729
|
const isArrayOfFiles = (value) => {
|
|
@@ -5983,7 +5986,7 @@ class FormSubmissionService extends BaseUploadService {
|
|
|
5983
5986
|
blockers: [],
|
|
5984
5987
|
blocks: []
|
|
5985
5988
|
});
|
|
5986
|
-
this.dispatch(
|
|
5989
|
+
this.dispatch(initializeFormSubmissions(submissions));
|
|
5987
5990
|
const attachments = await this.enqueueRequest({
|
|
5988
5991
|
description: "Fetch form attachments",
|
|
5989
5992
|
method: HttpMethod.GET,
|
|
@@ -5991,7 +5994,7 @@ class FormSubmissionService extends BaseUploadService {
|
|
|
5991
5994
|
blockers: [],
|
|
5992
5995
|
blocks: []
|
|
5993
5996
|
});
|
|
5994
|
-
this.dispatch(
|
|
5997
|
+
this.dispatch(initializeFormSubmissionAttachments(attachments));
|
|
5995
5998
|
}
|
|
5996
5999
|
}
|
|
5997
6000
|
class WorkspaceService extends BaseApiService {
|
|
@@ -6533,7 +6536,7 @@ class LicenseService extends BaseApiService {
|
|
|
6533
6536
|
for (const license of projectLicences) {
|
|
6534
6537
|
licencesRecord[license.offline_id] = license;
|
|
6535
6538
|
}
|
|
6536
|
-
this.dispatch(
|
|
6539
|
+
this.dispatch(initializeLicences(Object.values(licencesRecord)));
|
|
6537
6540
|
}
|
|
6538
6541
|
}
|
|
6539
6542
|
class DocumentService extends BaseApiService {
|
|
@@ -6927,7 +6930,7 @@ class TeamService extends BaseApiService {
|
|
|
6927
6930
|
blockers: [],
|
|
6928
6931
|
blocks: []
|
|
6929
6932
|
});
|
|
6930
|
-
this.dispatch(
|
|
6933
|
+
this.dispatch(initializeTeams(result));
|
|
6931
6934
|
}
|
|
6932
6935
|
}
|
|
6933
6936
|
class UserService extends BaseApiService {
|
|
@@ -7364,14 +7367,19 @@ export {
|
|
|
7364
7367
|
initializeFormRevisionAttachments,
|
|
7365
7368
|
initializeFormRevisions,
|
|
7366
7369
|
initializeFormSubmissionAttachments,
|
|
7370
|
+
initializeFormSubmissions,
|
|
7371
|
+
initializeForms,
|
|
7367
7372
|
initializeGeoImages,
|
|
7368
7373
|
initializeIssueAttachments,
|
|
7369
7374
|
initializeIssueTypes,
|
|
7370
7375
|
initializeIssueUpdates,
|
|
7371
7376
|
initializeIssues,
|
|
7377
|
+
initializeLicences,
|
|
7372
7378
|
initializeOrganizationAccesses,
|
|
7379
|
+
initializeProjectAccesses,
|
|
7373
7380
|
initializeProjectAttachments,
|
|
7374
7381
|
initializeStages,
|
|
7382
|
+
initializeTeams,
|
|
7375
7383
|
initializeWorkspaces,
|
|
7376
7384
|
isToday,
|
|
7377
7385
|
issueAttachmentReducer,
|
|
@@ -7627,7 +7635,6 @@ export {
|
|
|
7627
7635
|
setFormSubmissionAttachment,
|
|
7628
7636
|
setFormSubmissionAttachments,
|
|
7629
7637
|
setFormSubmissions,
|
|
7630
|
-
setForms,
|
|
7631
7638
|
setGeoImage,
|
|
7632
7639
|
setGeoImages,
|
|
7633
7640
|
setIsFetchingInitialData,
|
|
@@ -7638,11 +7645,9 @@ export {
|
|
|
7638
7645
|
setIssueComments,
|
|
7639
7646
|
setIssueType,
|
|
7640
7647
|
setIssueUpdate,
|
|
7641
|
-
setLicenses,
|
|
7642
7648
|
setLoggedIn,
|
|
7643
7649
|
setOrganizations,
|
|
7644
7650
|
setProfilePicture,
|
|
7645
|
-
setProjectAccesses,
|
|
7646
7651
|
setProjectAttachment,
|
|
7647
7652
|
setProjectAttachments,
|
|
7648
7653
|
setProjects,
|
|
@@ -7650,7 +7655,6 @@ export {
|
|
|
7650
7655
|
setStage,
|
|
7651
7656
|
setStageCompletions,
|
|
7652
7657
|
setTeam,
|
|
7653
|
-
setTeams,
|
|
7654
7658
|
setTokens,
|
|
7655
7659
|
setTourStep,
|
|
7656
7660
|
setUploadUrl,
|