@konfuzio/document-validation-ui 0.1.53-dev.0 → 0.1.53-dev.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@konfuzio/document-validation-ui",
3
- "version": "0.1.53-dev.0",
3
+ "version": "0.1.53-dev.1",
4
4
  "repository": "git://github.com:konfuzio-ai/document-validation-ui.git",
5
5
  "main": "dist/app.js",
6
6
  "scripts": {
@@ -1078,17 +1078,19 @@ const actions = {
1078
1078
  const { labels, annotations, annotationSets } =
1079
1079
  getters.processAnnotationSets(fetchedDocument.annotation_sets);
1080
1080
 
1081
+ // reset pages to avoid displaying old pages while new ones are loading
1082
+ commit("SET_PAGES", []);
1083
+
1081
1084
  // load first page
1082
- // if (fetchedDocument.pages.length > 0) {
1083
- // dispatch("fetchDocumentPage", initialPage);
1084
- // }
1085
+ if (fetchedDocument.pages.length > 0) {
1086
+ dispatch("fetchDocumentPage", initialPage);
1087
+ }
1085
1088
 
1086
1089
  // set information on the store
1087
1090
  commit("SET_ANNOTATION_SETS", annotationSets);
1088
1091
  commit("SET_ANNOTATIONS", annotations);
1089
1092
  commit("SET_LABELS", labels);
1090
1093
  commit("SET_SELECTED_DOCUMENT", fetchedDocument);
1091
- commit("SET_PAGES", fetchedDocument.pages);
1092
1094
 
1093
1095
  // project
1094
1096
  if (fetchedDocument.project) {