decap-cms-core 3.5.0 → 3.6.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.
Files changed (141) hide show
  1. package/dist/decap-cms-core.js +10 -10
  2. package/dist/decap-cms-core.js.map +1 -1
  3. package/dist/esm/actions/auth.js +22 -37
  4. package/dist/esm/actions/collections.js +9 -17
  5. package/dist/esm/actions/config.js +58 -74
  6. package/dist/esm/actions/deploys.js +10 -17
  7. package/dist/esm/actions/editorialWorkflow.js +87 -101
  8. package/dist/esm/actions/entries.js +161 -211
  9. package/dist/esm/actions/media.js +31 -46
  10. package/dist/esm/actions/mediaLibrary.js +94 -126
  11. package/dist/esm/actions/notifications.js +5 -13
  12. package/dist/esm/actions/search.js +30 -47
  13. package/dist/esm/actions/status.js +13 -23
  14. package/dist/esm/actions/waitUntil.js +4 -11
  15. package/dist/esm/backend.js +132 -148
  16. package/dist/esm/bootstrap.js +37 -44
  17. package/dist/esm/components/App/App.js +82 -89
  18. package/dist/esm/components/App/Header.js +46 -52
  19. package/dist/esm/components/App/NotFoundPage.js +11 -18
  20. package/dist/esm/components/Collection/Collection.js +55 -63
  21. package/dist/esm/components/Collection/CollectionControls.js +15 -22
  22. package/dist/esm/components/Collection/CollectionSearch.js +35 -42
  23. package/dist/esm/components/Collection/CollectionTop.js +23 -30
  24. package/dist/esm/components/Collection/ControlButton.js +10 -16
  25. package/dist/esm/components/Collection/Entries/Entries.js +24 -31
  26. package/dist/esm/components/Collection/Entries/EntriesCollection.js +60 -63
  27. package/dist/esm/components/Collection/Entries/EntriesSearch.js +26 -33
  28. package/dist/esm/components/Collection/Entries/EntryCard.js +38 -45
  29. package/dist/esm/components/Collection/Entries/EntryListing.js +24 -32
  30. package/dist/esm/components/Collection/FilterControl.js +9 -16
  31. package/dist/esm/components/Collection/GroupControl.js +9 -16
  32. package/dist/esm/components/Collection/NestedCollection.js +56 -64
  33. package/dist/esm/components/Collection/Sidebar.js +36 -43
  34. package/dist/esm/components/Collection/SortControl.js +19 -26
  35. package/dist/esm/components/Collection/ViewStyleControl.js +17 -24
  36. package/dist/esm/components/Editor/Editor.js +100 -108
  37. package/dist/esm/components/Editor/EditorControlPane/EditorControl.js +105 -112
  38. package/dist/esm/components/Editor/EditorControlPane/EditorControlPane.js +68 -62
  39. package/dist/esm/components/Editor/EditorControlPane/Widget.js +87 -73
  40. package/dist/esm/components/Editor/EditorInterface.js +95 -98
  41. package/dist/esm/components/Editor/EditorPreviewPane/EditorPreview.js +13 -21
  42. package/dist/esm/components/Editor/EditorPreviewPane/EditorPreviewContent.js +64 -23
  43. package/dist/esm/components/Editor/EditorPreviewPane/EditorPreviewPane.js +94 -78
  44. package/dist/esm/components/Editor/EditorPreviewPane/PreviewHOC.js +9 -16
  45. package/dist/esm/components/Editor/EditorToolbar.js +133 -140
  46. package/dist/esm/components/Editor/withWorkflow.js +15 -22
  47. package/dist/esm/components/EditorWidgets/Unknown/UnknownControl.js +9 -16
  48. package/dist/esm/components/EditorWidgets/Unknown/UnknownPreview.js +9 -16
  49. package/dist/esm/components/EditorWidgets/index.js +4 -7
  50. package/dist/esm/components/MediaLibrary/EmptyMessage.js +12 -19
  51. package/dist/esm/components/MediaLibrary/MediaLibrary.js +55 -62
  52. package/dist/esm/components/MediaLibrary/MediaLibraryButtons.js +28 -35
  53. package/dist/esm/components/MediaLibrary/MediaLibraryCard.js +36 -43
  54. package/dist/esm/components/MediaLibrary/MediaLibraryCardGrid.js +50 -57
  55. package/dist/esm/components/MediaLibrary/MediaLibraryHeader.js +16 -23
  56. package/dist/esm/components/MediaLibrary/MediaLibraryModal.js +59 -64
  57. package/dist/esm/components/MediaLibrary/MediaLibrarySearch.js +18 -25
  58. package/dist/esm/components/MediaLibrary/MediaLibraryTop.js +39 -46
  59. package/dist/esm/components/UI/DragDrop.js +21 -30
  60. package/dist/esm/components/UI/ErrorBoundary.js +35 -43
  61. package/dist/esm/components/UI/FileUploadButton.js +11 -18
  62. package/dist/esm/components/UI/Modal.js +19 -26
  63. package/dist/esm/components/UI/Notifications.js +21 -28
  64. package/dist/esm/components/UI/SettingsDropdown.js +28 -34
  65. package/dist/esm/components/UI/index.js +6 -60
  66. package/dist/esm/components/Workflow/Workflow.js +52 -61
  67. package/dist/esm/components/Workflow/WorkflowCard.js +45 -51
  68. package/dist/esm/components/Workflow/WorkflowList.js +43 -49
  69. package/dist/esm/constants/collectionTypes.js +2 -8
  70. package/dist/esm/constants/collectionViews.js +2 -8
  71. package/dist/esm/constants/commitProps.js +2 -8
  72. package/dist/esm/constants/configSchema.js +23 -27
  73. package/dist/esm/constants/fieldInference.js +8 -15
  74. package/dist/esm/constants/publishModes.js +6 -11
  75. package/dist/esm/constants/validationErrorTypes.js +1 -7
  76. package/dist/esm/formats/formats.js +32 -41
  77. package/dist/esm/formats/frontmatter.js +18 -30
  78. package/dist/esm/formats/helpers.js +1 -7
  79. package/dist/esm/formats/json.js +1 -7
  80. package/dist/esm/formats/toml.js +11 -18
  81. package/dist/esm/formats/yaml.js +7 -14
  82. package/dist/esm/index.js +5 -12
  83. package/dist/esm/integrations/index.js +8 -16
  84. package/dist/esm/integrations/providers/algolia/implementation.js +14 -22
  85. package/dist/esm/integrations/providers/assetStore/implementation.js +10 -18
  86. package/dist/esm/lib/consoleError.js +1 -7
  87. package/dist/esm/lib/formatters.js +34 -47
  88. package/dist/esm/lib/i18n.js +37 -66
  89. package/dist/esm/lib/phrases.js +4 -11
  90. package/dist/esm/lib/registry.js +40 -75
  91. package/dist/esm/lib/serializeEntryValues.js +11 -18
  92. package/dist/esm/lib/textHelper.js +1 -7
  93. package/dist/esm/lib/urlHelper.js +28 -43
  94. package/dist/esm/mediaLibrary.js +12 -16
  95. package/dist/esm/reducers/auth.js +10 -16
  96. package/dist/esm/reducers/collections.js +70 -102
  97. package/dist/esm/reducers/combinedReducer.js +4 -11
  98. package/dist/esm/reducers/config.js +11 -19
  99. package/dist/esm/reducers/cursors.js +12 -18
  100. package/dist/esm/reducers/deploys.js +8 -15
  101. package/dist/esm/reducers/editorialWorkflow.js +37 -47
  102. package/dist/esm/reducers/entries.js +107 -132
  103. package/dist/esm/reducers/entryDraft.js +64 -72
  104. package/dist/esm/reducers/globalUI.js +5 -11
  105. package/dist/esm/reducers/index.js +43 -64
  106. package/dist/esm/reducers/integrations.js +8 -16
  107. package/dist/esm/reducers/mediaLibrary.js +43 -52
  108. package/dist/esm/reducers/medias.js +11 -18
  109. package/dist/esm/reducers/notifications.js +9 -15
  110. package/dist/esm/reducers/search.js +12 -18
  111. package/dist/esm/reducers/status.js +7 -13
  112. package/dist/esm/redux/index.js +7 -13
  113. package/dist/esm/redux/middleware/waitUntilAction.js +3 -10
  114. package/dist/esm/routing/history.js +7 -15
  115. package/dist/esm/types/diacritics.d.js +0 -1
  116. package/dist/esm/types/global.d.js +1 -5
  117. package/dist/esm/types/immutable.js +1 -5
  118. package/dist/esm/types/redux.js +7 -8
  119. package/dist/esm/types/tomlify-j0.4.d.js +0 -1
  120. package/dist/esm/valueObjects/AssetProxy.js +2 -10
  121. package/dist/esm/valueObjects/EditorComponent.js +5 -12
  122. package/dist/esm/valueObjects/Entry.js +3 -10
  123. package/index.d.ts +1 -0
  124. package/package.json +3 -2
  125. package/src/components/Collection/Entries/EntriesCollection.js +21 -10
  126. package/src/components/Collection/Entries/__tests__/EntriesCollection.spec.js +7 -7
  127. package/src/components/Collection/Entries/__tests__/__snapshots__/EntriesCollection.spec.js.snap +9 -9
  128. package/src/components/Collection/NestedCollection.js +11 -2
  129. package/src/components/Collection/__tests__/NestedCollection.spec.js +3 -0
  130. package/src/components/Collection/__tests__/__snapshots__/NestedCollection.spec.js.snap +68 -0
  131. package/src/components/Editor/EditorControlPane/EditorControl.js +0 -3
  132. package/src/components/Editor/EditorControlPane/EditorControlPane.js +21 -8
  133. package/src/components/Editor/EditorControlPane/Widget.js +22 -1
  134. package/src/components/Editor/EditorInterface.js +6 -1
  135. package/src/components/Editor/EditorPreviewPane/EditorPreviewContent.js +51 -11
  136. package/src/components/Editor/EditorPreviewPane/EditorPreviewPane.js +33 -1
  137. package/src/constants/configSchema.js +1 -0
  138. package/src/types/redux.ts +1 -1
  139. package/dist/esm/actions/editorControl.js +0 -14
  140. package/dist/esm/reducers/editorComponent.js +0 -1
  141. package/dist/esm/reducers/editorControl.js +0 -17
@@ -1,41 +1,24 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.SEARCH_ENTRIES_SUCCESS = exports.SEARCH_ENTRIES_REQUEST = exports.SEARCH_ENTRIES_FAILURE = exports.SEARCH_CLEAR = exports.QUERY_SUCCESS = exports.QUERY_REQUEST = exports.QUERY_FAILURE = exports.CLEAR_REQUESTS = void 0;
7
- exports.clearRequests = clearRequests;
8
- exports.clearSearch = clearSearch;
9
- exports.query = query;
10
- exports.queryFailure = queryFailure;
11
- exports.querySuccess = querySuccess;
12
- exports.querying = querying;
13
- exports.searchEntries = searchEntries;
14
- exports.searchFailure = searchFailure;
15
- exports.searchSuccess = searchSuccess;
16
- exports.searchingEntries = searchingEntries;
17
- var _isEqual2 = _interopRequireDefault(require("lodash/isEqual"));
18
- var _backend = require("../backend");
19
- var _integrations = require("../integrations");
20
- var _reducers = require("../reducers");
21
- function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
1
+ import _isEqual from "lodash/isEqual";
2
+ import { currentBackend } from '../backend';
3
+ import { getIntegrationProvider } from '../integrations';
4
+ import { selectIntegration } from '../reducers';
22
5
  /*
23
6
  * Constant Declarations
24
7
  */
25
- const SEARCH_ENTRIES_REQUEST = exports.SEARCH_ENTRIES_REQUEST = 'SEARCH_ENTRIES_REQUEST';
26
- const SEARCH_ENTRIES_SUCCESS = exports.SEARCH_ENTRIES_SUCCESS = 'SEARCH_ENTRIES_SUCCESS';
27
- const SEARCH_ENTRIES_FAILURE = exports.SEARCH_ENTRIES_FAILURE = 'SEARCH_ENTRIES_FAILURE';
28
- const QUERY_REQUEST = exports.QUERY_REQUEST = 'QUERY_REQUEST';
29
- const QUERY_SUCCESS = exports.QUERY_SUCCESS = 'QUERY_SUCCESS';
30
- const QUERY_FAILURE = exports.QUERY_FAILURE = 'QUERY_FAILURE';
31
- const SEARCH_CLEAR = exports.SEARCH_CLEAR = 'SEARCH_CLEAR';
32
- const CLEAR_REQUESTS = exports.CLEAR_REQUESTS = 'CLEAR_REQUESTS';
8
+ export const SEARCH_ENTRIES_REQUEST = 'SEARCH_ENTRIES_REQUEST';
9
+ export const SEARCH_ENTRIES_SUCCESS = 'SEARCH_ENTRIES_SUCCESS';
10
+ export const SEARCH_ENTRIES_FAILURE = 'SEARCH_ENTRIES_FAILURE';
11
+ export const QUERY_REQUEST = 'QUERY_REQUEST';
12
+ export const QUERY_SUCCESS = 'QUERY_SUCCESS';
13
+ export const QUERY_FAILURE = 'QUERY_FAILURE';
14
+ export const SEARCH_CLEAR = 'SEARCH_CLEAR';
15
+ export const CLEAR_REQUESTS = 'CLEAR_REQUESTS';
33
16
 
34
17
  /*
35
18
  * Simple Action Creators (Internal)
36
19
  * We still need to export them for tests
37
20
  */
38
- function searchingEntries(searchTerm, searchCollections, page) {
21
+ export function searchingEntries(searchTerm, searchCollections, page) {
39
22
  return {
40
23
  type: SEARCH_ENTRIES_REQUEST,
41
24
  payload: {
@@ -45,7 +28,7 @@ function searchingEntries(searchTerm, searchCollections, page) {
45
28
  }
46
29
  };
47
30
  }
48
- function searchSuccess(entries, page) {
31
+ export function searchSuccess(entries, page) {
49
32
  return {
50
33
  type: SEARCH_ENTRIES_SUCCESS,
51
34
  payload: {
@@ -54,7 +37,7 @@ function searchSuccess(entries, page) {
54
37
  }
55
38
  };
56
39
  }
57
- function searchFailure(error) {
40
+ export function searchFailure(error) {
58
41
  return {
59
42
  type: SEARCH_ENTRIES_FAILURE,
60
43
  payload: {
@@ -62,7 +45,7 @@ function searchFailure(error) {
62
45
  }
63
46
  };
64
47
  }
65
- function querying(searchTerm, request) {
48
+ export function querying(searchTerm, request) {
66
49
  return {
67
50
  type: QUERY_REQUEST,
68
51
  payload: {
@@ -71,7 +54,7 @@ function querying(searchTerm, request) {
71
54
  }
72
55
  };
73
56
  }
74
- function querySuccess(namespace, hits) {
57
+ export function querySuccess(namespace, hits) {
75
58
  return {
76
59
  type: QUERY_SUCCESS,
77
60
  payload: {
@@ -80,7 +63,7 @@ function querySuccess(namespace, hits) {
80
63
  }
81
64
  };
82
65
  }
83
- function queryFailure(error) {
66
+ export function queryFailure(error) {
84
67
  return {
85
68
  type: QUERY_FAILURE,
86
69
  payload: {
@@ -93,12 +76,12 @@ function queryFailure(error) {
93
76
  * Exported simple Action Creators
94
77
  */
95
78
 
96
- function clearSearch() {
79
+ export function clearSearch() {
97
80
  return {
98
81
  type: SEARCH_CLEAR
99
82
  };
100
83
  }
101
- function clearRequests() {
84
+ export function clearRequests() {
102
85
  return {
103
86
  type: CLEAR_REQUESTS
104
87
  };
@@ -109,25 +92,25 @@ function clearRequests() {
109
92
  */
110
93
 
111
94
  // SearchEntries will search for complete entries in all collections.
112
- function searchEntries(searchTerm, searchCollections, page = 0) {
95
+ export function searchEntries(searchTerm, searchCollections, page = 0) {
113
96
  return async (dispatch, getState) => {
114
97
  const state = getState();
115
98
  const {
116
99
  search
117
100
  } = state;
118
- const backend = (0, _backend.currentBackend)(state.config);
101
+ const backend = currentBackend(state.config);
119
102
  const allCollections = searchCollections || state.collections.keySeq().toArray();
120
- const collections = allCollections.filter(collection => (0, _reducers.selectIntegration)(state, collection, 'search'));
121
- const integration = (0, _reducers.selectIntegration)(state, collections[0], 'search');
103
+ const collections = allCollections.filter(collection => selectIntegration(state, collection, 'search'));
104
+ const integration = selectIntegration(state, collections[0], 'search');
122
105
 
123
106
  // avoid duplicate searches
124
- if (search.isFetching && search.term === searchTerm && (0, _isEqual2.default)(allCollections, search.collections) && (
107
+ if (search.isFetching && search.term === searchTerm && _isEqual(allCollections, search.collections) && (
125
108
  // if an integration doesn't exist, 'page' is not used
126
109
  search.page === page || !integration)) {
127
110
  return;
128
111
  }
129
112
  dispatch(searchingEntries(searchTerm, allCollections, page));
130
- const searchPromise = integration ? (0, _integrations.getIntegrationProvider)(state.integrations, backend.getToken, integration).search(collections, searchTerm, page) : backend.search(state.collections.filter((_, key) => allCollections.indexOf(key) !== -1).valueSeq().toArray(), searchTerm);
113
+ const searchPromise = integration ? getIntegrationProvider(state.integrations, backend.getToken, integration).search(collections, searchTerm, page) : backend.search(state.collections.filter((_, key) => allCollections.indexOf(key) !== -1).valueSeq().toArray(), searchTerm);
131
114
  try {
132
115
  const response = await searchPromise;
133
116
  return dispatch(searchSuccess(response.entries, response.pagination));
@@ -139,18 +122,18 @@ function searchEntries(searchTerm, searchCollections, page = 0) {
139
122
 
140
123
  // Instead of searching for complete entries, query will search for specific fields
141
124
  // in specific collections and return raw data (no entries).
142
- function query(namespace, collectionName, searchFields, searchTerm, file, limit) {
125
+ export function query(namespace, collectionName, searchFields, searchTerm, file, limit) {
143
126
  return async (dispatch, getState) => {
144
127
  const state = getState();
145
- const backend = (0, _backend.currentBackend)(state.config);
146
- const integration = (0, _reducers.selectIntegration)(state, collectionName, 'search');
128
+ const backend = currentBackend(state.config);
129
+ const integration = selectIntegration(state, collectionName, 'search');
147
130
  const collection = state.collections.find(collection => collection.get('name') === collectionName);
148
131
  dispatch(clearRequests());
149
132
  const queryIdentifier = `${collectionName}-${searchFields.join()}-${searchTerm}-${file}-${limit}`;
150
133
  const queuedQueryPromise = state.search.requests.find(({
151
134
  id
152
135
  }) => id == queryIdentifier);
153
- const queryPromise = queuedQueryPromise ? queuedQueryPromise.queryResponse : integration ? (0, _integrations.getIntegrationProvider)(state.integrations, backend.getToken, integration).searchBy(searchFields.map(f => `data.${f}`), collectionName, searchTerm) : backend.query(collection, searchFields, searchTerm, file, limit);
136
+ const queryPromise = queuedQueryPromise ? queuedQueryPromise.queryResponse : integration ? getIntegrationProvider(state.integrations, backend.getToken, integration).searchBy(searchFields.map(f => `data.${f}`), collectionName, searchTerm) : backend.query(collection, searchFields, searchTerm, file, limit);
154
137
  dispatch(querying(searchTerm, queuedQueryPromise ? undefined : {
155
138
  id: queryIdentifier,
156
139
  expires: new Date(new Date().getTime() + 10 * 1000),
@@ -1,24 +1,14 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.STATUS_SUCCESS = exports.STATUS_REQUEST = exports.STATUS_FAILURE = void 0;
7
- exports.checkBackendStatus = checkBackendStatus;
8
- exports.statusFailure = statusFailure;
9
- exports.statusRequest = statusRequest;
10
- exports.statusSuccess = statusSuccess;
11
- var _backend = require("../backend");
12
- var _notifications = require("./notifications");
13
- const STATUS_REQUEST = exports.STATUS_REQUEST = 'STATUS_REQUEST';
14
- const STATUS_SUCCESS = exports.STATUS_SUCCESS = 'STATUS_SUCCESS';
15
- const STATUS_FAILURE = exports.STATUS_FAILURE = 'STATUS_FAILURE';
16
- function statusRequest() {
1
+ import { currentBackend } from '../backend';
2
+ import { addNotification, dismissNotification } from './notifications';
3
+ export const STATUS_REQUEST = 'STATUS_REQUEST';
4
+ export const STATUS_SUCCESS = 'STATUS_SUCCESS';
5
+ export const STATUS_FAILURE = 'STATUS_FAILURE';
6
+ export function statusRequest() {
17
7
  return {
18
8
  type: STATUS_REQUEST
19
9
  };
20
10
  }
21
- function statusSuccess(status) {
11
+ export function statusSuccess(status) {
22
12
  return {
23
13
  type: STATUS_SUCCESS,
24
14
  payload: {
@@ -26,7 +16,7 @@ function statusSuccess(status) {
26
16
  }
27
17
  };
28
18
  }
29
- function statusFailure(error) {
19
+ export function statusFailure(error) {
30
20
  return {
31
21
  type: STATUS_FAILURE,
32
22
  payload: {
@@ -34,7 +24,7 @@ function statusFailure(error) {
34
24
  }
35
25
  };
36
26
  }
37
- function checkBackendStatus() {
27
+ export function checkBackendStatus() {
38
28
  return async (dispatch, getState) => {
39
29
  try {
40
30
  const state = getState();
@@ -42,7 +32,7 @@ function checkBackendStatus() {
42
32
  return;
43
33
  }
44
34
  dispatch(statusRequest());
45
- const backend = (0, _backend.currentBackend)(state.config);
35
+ const backend = currentBackend(state.config);
46
36
  const status = await backend.status();
47
37
  const backendDownKey = 'ui.toast.onBackendDown';
48
38
  const previousBackendDownNotifications = state.notifications.notifications.filter(n => {
@@ -51,7 +41,7 @@ function checkBackendStatus() {
51
41
  });
52
42
  if (status.api.status === false) {
53
43
  if (previousBackendDownNotifications.length === 0) {
54
- dispatch((0, _notifications.addNotification)({
44
+ dispatch(addNotification({
55
45
  message: {
56
46
  details: status.api.statusPage,
57
47
  key: 'ui.toast.onBackendDown'
@@ -63,7 +53,7 @@ function checkBackendStatus() {
63
53
  } else if (status.api.status === true && previousBackendDownNotifications.length > 0) {
64
54
  // If backend is up, clear all the danger messages
65
55
  previousBackendDownNotifications.forEach(notification => {
66
- dispatch((0, _notifications.dismissNotification)(notification.id));
56
+ dispatch(dismissNotification(notification.id));
67
57
  });
68
58
  }
69
59
  const authError = status.auth.status === false;
@@ -74,7 +64,7 @@ function checkBackendStatus() {
74
64
  return typeof n.message != 'string' && ((_n$message2 = n.message) === null || _n$message2 === void 0 ? void 0 : _n$message2.key) === key;
75
65
  });
76
66
  if (!existingNotification) {
77
- dispatch((0, _notifications.addNotification)({
67
+ dispatch(addNotification({
78
68
  message: {
79
69
  key: 'ui.toast.onLoggedOut'
80
70
  },
@@ -1,22 +1,15 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.waitUntil = waitUntil;
7
- exports.waitUntilWithTimeout = waitUntilWithTimeout;
8
- var _waitUntilAction = require("../redux/middleware/waitUntilAction");
9
- function waitUntil({
1
+ import { WAIT_UNTIL_ACTION } from '../redux/middleware/waitUntilAction';
2
+ export function waitUntil({
10
3
  predicate,
11
4
  run
12
5
  }) {
13
6
  return {
14
- type: _waitUntilAction.WAIT_UNTIL_ACTION,
7
+ type: WAIT_UNTIL_ACTION,
15
8
  predicate,
16
9
  run
17
10
  };
18
11
  }
19
- async function waitUntilWithTimeout(dispatch, waitActionArgs, timeout = 30000) {
12
+ export async function waitUntilWithTimeout(dispatch, waitActionArgs, timeout = 30000) {
20
13
  let waitDone = false;
21
14
  const waitPromise = new Promise(resolve => {
22
15
  dispatch(waitUntil(waitActionArgs(resolve)));