@beinformed/react 1.0.0-beta.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/CHANGELOG.md +12 -0
- package/LICENSE.md +1 -0
- package/dist/ErrorBoundaryFallback-D6YQem9P.d.cts +13 -0
- package/dist/ErrorBoundaryFallback-D6YQem9P.d.ts +13 -0
- package/dist/beforeRenderHooks-CNvsMmi8.d.cts +18 -0
- package/dist/beforeRenderHooks-Gb0tcmCY.d.ts +18 -0
- package/dist/chunk-347XDLN7.js +1 -0
- package/dist/chunk-347XDLN7.js.map +1 -0
- package/dist/chunk-3OP2KQ56.js +2 -0
- package/dist/chunk-3OP2KQ56.js.map +1 -0
- package/dist/chunk-4AC7YQ5Q.js +2 -0
- package/dist/chunk-4AC7YQ5Q.js.map +1 -0
- package/dist/chunk-6E5DAS6G.js +1 -0
- package/dist/chunk-6E5DAS6G.js.map +1 -0
- package/dist/chunk-6KRECIRI.js +2 -0
- package/dist/chunk-6KRECIRI.js.map +1 -0
- package/dist/chunk-A4USB53Q.js +2 -0
- package/dist/chunk-A4USB53Q.js.map +1 -0
- package/dist/chunk-AMFWIR2R.js +2 -0
- package/dist/chunk-AMFWIR2R.js.map +1 -0
- package/dist/chunk-B7PQLTVC.js +2 -0
- package/dist/chunk-B7PQLTVC.js.map +1 -0
- package/dist/chunk-DI7VM62A.js +2 -0
- package/dist/chunk-DI7VM62A.js.map +1 -0
- package/dist/chunk-FW4363Y4.js +2 -0
- package/dist/chunk-FW4363Y4.js.map +1 -0
- package/dist/chunk-HDOILTJ2.js +2 -0
- package/dist/chunk-HDOILTJ2.js.map +1 -0
- package/dist/chunk-JYAETKRB.js +2 -0
- package/dist/chunk-JYAETKRB.js.map +1 -0
- package/dist/chunk-K3DTH6XN.js +2 -0
- package/dist/chunk-K3DTH6XN.js.map +1 -0
- package/dist/chunk-KNEDBCHP.js +2 -0
- package/dist/chunk-KNEDBCHP.js.map +1 -0
- package/dist/chunk-MT7D3AJU.js +12 -0
- package/dist/chunk-MT7D3AJU.js.map +1 -0
- package/dist/chunk-RKGGCIUD.js +2 -0
- package/dist/chunk-RKGGCIUD.js.map +1 -0
- package/dist/chunk-UZIZDEU6.js +2 -0
- package/dist/chunk-UZIZDEU6.js.map +1 -0
- package/dist/chunk-VFLYA5WJ.js +2 -0
- package/dist/chunk-VFLYA5WJ.js.map +1 -0
- package/dist/chunk-VG3QU524.js +22 -0
- package/dist/chunk-VG3QU524.js.map +1 -0
- package/dist/chunk-WBPDMDW4.js +2 -0
- package/dist/chunk-WBPDMDW4.js.map +1 -0
- package/dist/chunk-X2C7CKOK.js +2 -0
- package/dist/chunk-X2C7CKOK.js.map +1 -0
- package/dist/chunk-X3N2NQVZ.js +2 -0
- package/dist/chunk-X3N2NQVZ.js.map +1 -0
- package/dist/chunk-Y7ESITVO.js +2 -0
- package/dist/chunk-Y7ESITVO.js.map +1 -0
- package/dist/chunk-YG7XDCNV.js +2 -0
- package/dist/chunk-YG7XDCNV.js.map +1 -0
- package/dist/chunk-YJNJVQFW.js +2 -0
- package/dist/chunk-YJNJVQFW.js.map +1 -0
- package/dist/chunk-Z2Y3OPVI.js +2 -0
- package/dist/chunk-Z2Y3OPVI.js.map +1 -0
- package/dist/client/index.cjs +12 -0
- package/dist/client/index.cjs.map +1 -0
- package/dist/client/index.d.cts +84 -0
- package/dist/client/index.d.ts +84 -0
- package/dist/client/index.js +2 -0
- package/dist/client/index.js.map +1 -0
- package/dist/components/index.cjs +12 -0
- package/dist/components/index.cjs.map +1 -0
- package/dist/components/index.d.cts +28 -0
- package/dist/components/index.d.ts +28 -0
- package/dist/components/index.js +2 -0
- package/dist/components/index.js.map +1 -0
- package/dist/hooks/index.cjs +2 -0
- package/dist/hooks/index.cjs.map +1 -0
- package/dist/hooks/index.d.cts +353 -0
- package/dist/hooks/index.d.ts +353 -0
- package/dist/hooks/index.js +2 -0
- package/dist/hooks/index.js.map +1 -0
- package/dist/i18n/index.cjs +2 -0
- package/dist/i18n/index.cjs.map +1 -0
- package/dist/i18n/index.d.cts +26 -0
- package/dist/i18n/index.d.ts +26 -0
- package/dist/i18n/index.js +2 -0
- package/dist/i18n/index.js.map +1 -0
- package/dist/index.cjs +32 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +27 -0
- package/dist/index.d.ts +27 -0
- package/dist/index.js +2 -0
- package/dist/index.js.map +1 -0
- package/dist/redux/index.cjs +2 -0
- package/dist/redux/index.cjs.map +1 -0
- package/dist/redux/index.d.cts +458 -0
- package/dist/redux/index.d.ts +458 -0
- package/dist/redux/index.js +2 -0
- package/dist/redux/index.js.map +1 -0
- package/dist/server/index.cjs +22 -0
- package/dist/server/index.cjs.map +1 -0
- package/dist/server/index.d.cts +78 -0
- package/dist/server/index.d.ts +78 -0
- package/dist/server/index.js +2 -0
- package/dist/server/index.js.map +1 -0
- package/dist/styled-components.d-CrkOxzv5.d.cts +346 -0
- package/dist/styled-components.d-CrkOxzv5.d.ts +346 -0
- package/dist/theme/index.cjs +2 -0
- package/dist/theme/index.cjs.map +1 -0
- package/dist/theme/index.d.cts +112 -0
- package/dist/theme/index.d.ts +112 -0
- package/dist/theme/index.js +2 -0
- package/dist/theme/index.js.map +1 -0
- package/dist/types-CGXygEPz.d.cts +8 -0
- package/dist/types-CGXygEPz.d.ts +8 -0
- package/dist/useForm-CG_DMYfZ.d.cts +178 -0
- package/dist/useForm-DW-a5mcV.d.ts +178 -0
- package/dist/utils/index.cjs +2 -0
- package/dist/utils/index.cjs.map +1 -0
- package/dist/utils/index.d.cts +6 -0
- package/dist/utils/index.d.ts +6 -0
- package/dist/utils/index.js +2 -0
- package/dist/utils/index.js.map +1 -0
- package/package.json +125 -0
|
@@ -0,0 +1,458 @@
|
|
|
1
|
+
import * as _reduxjs_toolkit from '@reduxjs/toolkit';
|
|
2
|
+
import { Middleware } from '@reduxjs/toolkit';
|
|
3
|
+
import { S as ShowNotificationArguments, $ as RootState, a0 as BEIDispatch, V as RouterLocation, C as FetchModelResult, F as FetchModelPayload, b as Locales, R as PreferenceValue, W as RouterState, P as PreferencesState, y as ModularUIState, I as I18nState, A as AuthState, E as ErrorState, o as ModalsState, v as ModelCatalogState, N as NotificationState, T as ProgressIndicatorState } from '../styled-components.d-CrkOxzv5.cjs';
|
|
4
|
+
export { _ as BEIStore, n as ModalState, B as ModelEntry, D as NOTIFICATION_TYPES, g as authReducer, q as closeModal, H as dismissNotification, i as errorReducer, m as i18nReducer, X as locationChange, l as loginSuccess, e as logoutSuccess, t as modalsReducer, x as modelCatalogReducer, z as modularUIReducer, J as notificationReducer, Q as preferencesReducer, U as progressIndicatorReducer, j as receiveLocale, r as resetAuthErrors, Y as routerReducer, f as saveChangePassword, h as saveError, s as sendAuthenticationError, k as setLocales, K as setPreference, O as setPreferences, Z as setupStore, p as showModal, G as showNotification, w as updateEntryDate, u as updateLocale } from '../styled-components.d-CrkOxzv5.cjs';
|
|
5
|
+
import * as _beinformed_ui_models from '@beinformed/ui/models';
|
|
6
|
+
import { FormModel, ErrorResponse, ApplicationModel, FormObjectModel, AttributeModel, ModularUIModel, Href } from '@beinformed/ui/models';
|
|
7
|
+
import * as redux from 'redux';
|
|
8
|
+
import { LocationState, History } from 'history';
|
|
9
|
+
export { a as BeforeRenderHook, B as BeforeRenderHookProps, h as handleBeforeRenderHooks } from '../beforeRenderHooks-CNvsMmi8.cjs';
|
|
10
|
+
import { U as UpdateFormOptions } from '../useForm-CG_DMYfZ.cjs';
|
|
11
|
+
import * as react_redux from 'react-redux';
|
|
12
|
+
import { ISO_DATE } from '@beinformed/ui/types';
|
|
13
|
+
import { ModularUIRequestOptions } from '@beinformed/ui/utils';
|
|
14
|
+
import 'immer';
|
|
15
|
+
import '@beinformed/ui/settings';
|
|
16
|
+
import 'styled-components';
|
|
17
|
+
import '../types-CGXygEPz.cjs';
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* Show form notification
|
|
21
|
+
*/
|
|
22
|
+
declare const showFormNotification: _reduxjs_toolkit.AsyncThunk<{
|
|
23
|
+
payload: undefined;
|
|
24
|
+
type: "FINISH_PROGRESS";
|
|
25
|
+
}, FormModel, {
|
|
26
|
+
state?: unknown;
|
|
27
|
+
dispatch?: _reduxjs_toolkit.ThunkDispatch<unknown, unknown, redux.UnknownAction>;
|
|
28
|
+
extra?: unknown;
|
|
29
|
+
rejectValue?: unknown;
|
|
30
|
+
serializedErrorType?: unknown;
|
|
31
|
+
pendingMeta?: unknown;
|
|
32
|
+
fulfilledMeta?: unknown;
|
|
33
|
+
rejectedMeta?: unknown;
|
|
34
|
+
}>;
|
|
35
|
+
/**
|
|
36
|
+
* Show error notification
|
|
37
|
+
*/
|
|
38
|
+
declare const showXHRErrorNotification: (error: ErrorResponse) => _reduxjs_toolkit.AsyncThunkAction<void, ShowNotificationArguments, {
|
|
39
|
+
state?: unknown;
|
|
40
|
+
dispatch?: _reduxjs_toolkit.ThunkDispatch<unknown, unknown, redux.UnknownAction>;
|
|
41
|
+
extra?: unknown;
|
|
42
|
+
rejectValue?: unknown;
|
|
43
|
+
serializedErrorType?: unknown;
|
|
44
|
+
pendingMeta?: unknown;
|
|
45
|
+
fulfilledMeta?: unknown;
|
|
46
|
+
rejectedMeta?: unknown;
|
|
47
|
+
}>;
|
|
48
|
+
|
|
49
|
+
/**
|
|
50
|
+
* Retrieve entrydate for the model catalog
|
|
51
|
+
*/
|
|
52
|
+
declare const getEntryDate: (state: RootState) => ISO_DATE;
|
|
53
|
+
|
|
54
|
+
declare const reloadApplication: _reduxjs_toolkit.AsyncThunk<void, void, {
|
|
55
|
+
dispatch: BEIDispatch;
|
|
56
|
+
state: RootState;
|
|
57
|
+
extra: unknown;
|
|
58
|
+
rejectValue?: unknown;
|
|
59
|
+
serializedErrorType?: unknown;
|
|
60
|
+
pendingMeta?: unknown;
|
|
61
|
+
fulfilledMeta?: unknown;
|
|
62
|
+
rejectedMeta?: unknown;
|
|
63
|
+
}>;
|
|
64
|
+
|
|
65
|
+
/**
|
|
66
|
+
* Get the application model, which is the model with selfhref '/'
|
|
67
|
+
*/
|
|
68
|
+
declare const getApplication: (state: RootState) => ApplicationModel | undefined;
|
|
69
|
+
|
|
70
|
+
declare const loginFailed: (errorMessage: string) => {
|
|
71
|
+
payload: string;
|
|
72
|
+
type: "AUTHENTICATION_ERROR";
|
|
73
|
+
};
|
|
74
|
+
declare const changePassword: _reduxjs_toolkit.AsyncThunk<{
|
|
75
|
+
payload: {
|
|
76
|
+
location: string | RouterLocation;
|
|
77
|
+
state: LocationState;
|
|
78
|
+
};
|
|
79
|
+
type: string;
|
|
80
|
+
}, void, {
|
|
81
|
+
state: RootState;
|
|
82
|
+
dispatch?: _reduxjs_toolkit.ThunkDispatch<unknown, unknown, redux.UnknownAction> | undefined;
|
|
83
|
+
extra?: unknown;
|
|
84
|
+
rejectValue?: unknown;
|
|
85
|
+
serializedErrorType?: unknown;
|
|
86
|
+
pendingMeta?: unknown;
|
|
87
|
+
fulfilledMeta?: unknown;
|
|
88
|
+
rejectedMeta?: unknown;
|
|
89
|
+
}>;
|
|
90
|
+
declare const login: _reduxjs_toolkit.AsyncThunk<void, {
|
|
91
|
+
username: string;
|
|
92
|
+
password: string;
|
|
93
|
+
}, {
|
|
94
|
+
state: RootState;
|
|
95
|
+
dispatch: BEIDispatch;
|
|
96
|
+
extra?: unknown;
|
|
97
|
+
rejectValue?: unknown;
|
|
98
|
+
serializedErrorType?: unknown;
|
|
99
|
+
pendingMeta?: unknown;
|
|
100
|
+
fulfilledMeta?: unknown;
|
|
101
|
+
rejectedMeta?: unknown;
|
|
102
|
+
}>;
|
|
103
|
+
|
|
104
|
+
declare const logout: _reduxjs_toolkit.AsyncThunk<void, void, {
|
|
105
|
+
dispatch: BEIDispatch;
|
|
106
|
+
state?: unknown;
|
|
107
|
+
extra?: unknown;
|
|
108
|
+
rejectValue?: unknown;
|
|
109
|
+
serializedErrorType?: unknown;
|
|
110
|
+
pendingMeta?: unknown;
|
|
111
|
+
fulfilledMeta?: unknown;
|
|
112
|
+
rejectedMeta?: unknown;
|
|
113
|
+
}>;
|
|
114
|
+
|
|
115
|
+
declare const handleUnauthorized: _reduxjs_toolkit.AsyncThunk<void, ErrorResponse, {
|
|
116
|
+
state: RootState;
|
|
117
|
+
dispatch: BEIDispatch;
|
|
118
|
+
extra?: unknown;
|
|
119
|
+
rejectValue?: unknown;
|
|
120
|
+
serializedErrorType?: unknown;
|
|
121
|
+
pendingMeta?: unknown;
|
|
122
|
+
fulfilledMeta?: unknown;
|
|
123
|
+
rejectedMeta?: unknown;
|
|
124
|
+
}>;
|
|
125
|
+
|
|
126
|
+
declare const getDataFromServer: () => Record<string, unknown>;
|
|
127
|
+
|
|
128
|
+
declare const updateFormAttribute: _reduxjs_toolkit.AsyncThunk<void, {
|
|
129
|
+
form: FormModel;
|
|
130
|
+
formObject: FormObjectModel;
|
|
131
|
+
attribute: AttributeModel;
|
|
132
|
+
inputvalue: string;
|
|
133
|
+
options?: UpdateFormOptions;
|
|
134
|
+
}, {
|
|
135
|
+
dispatch: BEIDispatch;
|
|
136
|
+
state?: unknown;
|
|
137
|
+
extra?: unknown;
|
|
138
|
+
rejectValue?: unknown;
|
|
139
|
+
serializedErrorType?: unknown;
|
|
140
|
+
pendingMeta?: unknown;
|
|
141
|
+
fulfilledMeta?: unknown;
|
|
142
|
+
rejectedMeta?: unknown;
|
|
143
|
+
}>;
|
|
144
|
+
|
|
145
|
+
/**
|
|
146
|
+
* POSSIBLE AUTOSAVE STATUSSES
|
|
147
|
+
* @type {{START: string, FINISHED: string}}
|
|
148
|
+
*/
|
|
149
|
+
declare enum AUTOSAVE_STATUS {
|
|
150
|
+
START = 0,
|
|
151
|
+
FINISHED = 1
|
|
152
|
+
}
|
|
153
|
+
declare const autosaveFormObject: (form: FormModel) => (dispatch: BEIDispatch) => void | undefined;
|
|
154
|
+
|
|
155
|
+
declare const autosubmitFormObject: (form: FormModel, attribute: AttributeModel, forceUpdate?: boolean) => _reduxjs_toolkit.AsyncThunkAction<FetchModelResult, FetchModelPayload, {
|
|
156
|
+
dispatch: BEIDispatch;
|
|
157
|
+
state: RootState;
|
|
158
|
+
rejectValue: _beinformed_ui_models.ErrorResponse;
|
|
159
|
+
extra?: unknown;
|
|
160
|
+
serializedErrorType?: unknown;
|
|
161
|
+
pendingMeta?: unknown;
|
|
162
|
+
fulfilledMeta?: unknown;
|
|
163
|
+
rejectedMeta?: unknown;
|
|
164
|
+
}> | null;
|
|
165
|
+
|
|
166
|
+
declare const autoupdateFormObject: (form: FormModel, attribute: AttributeModel) => _reduxjs_toolkit.AsyncThunkAction<FetchModelResult, FetchModelPayload, {
|
|
167
|
+
dispatch: BEIDispatch;
|
|
168
|
+
state: RootState;
|
|
169
|
+
rejectValue: _beinformed_ui_models.ErrorResponse;
|
|
170
|
+
extra?: unknown;
|
|
171
|
+
serializedErrorType?: unknown;
|
|
172
|
+
pendingMeta?: unknown;
|
|
173
|
+
fulfilledMeta?: unknown;
|
|
174
|
+
rejectedMeta?: unknown;
|
|
175
|
+
}> | null;
|
|
176
|
+
|
|
177
|
+
declare const previousObject: (form: FormModel) => {
|
|
178
|
+
payload: _beinformed_ui_models.ModularUIModel;
|
|
179
|
+
type: "MODULARUI/UPDATE_FORM";
|
|
180
|
+
};
|
|
181
|
+
declare const cancelForm: _reduxjs_toolkit.AsyncThunk<{
|
|
182
|
+
payload: undefined;
|
|
183
|
+
type: string;
|
|
184
|
+
}, FormModel, {
|
|
185
|
+
dispatch: BEIDispatch;
|
|
186
|
+
state: RootState;
|
|
187
|
+
extra?: unknown;
|
|
188
|
+
rejectValue?: unknown;
|
|
189
|
+
serializedErrorType?: unknown;
|
|
190
|
+
pendingMeta?: unknown;
|
|
191
|
+
fulfilledMeta?: unknown;
|
|
192
|
+
rejectedMeta?: unknown;
|
|
193
|
+
}>;
|
|
194
|
+
|
|
195
|
+
declare const addRepeatableAttributeSet: (form: FormModel) => {
|
|
196
|
+
payload: _beinformed_ui_models.ModularUIModel;
|
|
197
|
+
type: "MODULARUI/UPDATE_FORM";
|
|
198
|
+
};
|
|
199
|
+
declare const cancelRepeatableAttributeSet: (form: FormModel, formObject: FormObjectModel) => {
|
|
200
|
+
payload: _beinformed_ui_models.ModularUIModel;
|
|
201
|
+
type: "MODULARUI/UPDATE_FORM";
|
|
202
|
+
};
|
|
203
|
+
declare const removeRepeatableAttributeSet: (form: FormModel, formObject: FormObjectModel) => {
|
|
204
|
+
payload: _beinformed_ui_models.ModularUIModel;
|
|
205
|
+
type: "MODULARUI/UPDATE_FORM";
|
|
206
|
+
};
|
|
207
|
+
|
|
208
|
+
declare const validateFormObject: (form: FormModel) => (dispatch: BEIDispatch) => void;
|
|
209
|
+
|
|
210
|
+
/**
|
|
211
|
+
* Retrieve the locale from state
|
|
212
|
+
*/
|
|
213
|
+
declare const getLocale: (state: RootState) => string;
|
|
214
|
+
/**
|
|
215
|
+
* Retrieve all available locales in the store
|
|
216
|
+
*/
|
|
217
|
+
declare const getLocales: (state: RootState) => Locales;
|
|
218
|
+
|
|
219
|
+
declare enum MODULARUI_STATUS {
|
|
220
|
+
IDLE = "IDLE",
|
|
221
|
+
LOADING = "LOADING",
|
|
222
|
+
FINISHED = "FINISHED",
|
|
223
|
+
ERROR = "ERROR"
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
declare const fetchModel: _reduxjs_toolkit.AsyncThunk<FetchModelResult, FetchModelPayload, {
|
|
227
|
+
dispatch: BEIDispatch;
|
|
228
|
+
state: RootState;
|
|
229
|
+
rejectValue: ErrorResponse;
|
|
230
|
+
extra?: unknown;
|
|
231
|
+
serializedErrorType?: unknown;
|
|
232
|
+
pendingMeta?: unknown;
|
|
233
|
+
fulfilledMeta?: unknown;
|
|
234
|
+
rejectedMeta?: unknown;
|
|
235
|
+
}>;
|
|
236
|
+
|
|
237
|
+
declare const updateErrorStatus: _reduxjs_toolkit.ActionCreatorWithPreparedPayload<[key: string, error: ErrorResponse], {
|
|
238
|
+
key: string;
|
|
239
|
+
error: ErrorResponse;
|
|
240
|
+
}, "MODULARUI/ERROR_STATUS", never, never>;
|
|
241
|
+
declare const setModel: _reduxjs_toolkit.ActionCreatorWithPreparedPayload<[key: string, model: ModularUIModel], {
|
|
242
|
+
key: string;
|
|
243
|
+
model: ModularUIModel;
|
|
244
|
+
}, "MODULARUI/SET", never, never>;
|
|
245
|
+
declare const initModels: _reduxjs_toolkit.ActionCreatorWithPreparedPayload<[models: {
|
|
246
|
+
key: string;
|
|
247
|
+
model: ModularUIModel;
|
|
248
|
+
}[]], {
|
|
249
|
+
key: string;
|
|
250
|
+
model: ModularUIModel;
|
|
251
|
+
}[], "MODULARUI/INIT", never, never>;
|
|
252
|
+
declare const updateModel: _reduxjs_toolkit.ActionCreatorWithPreparedPayload<[model: ModularUIModel], ModularUIModel, "MODULARUI/UPDATE", never, never>;
|
|
253
|
+
declare const updateForm: _reduxjs_toolkit.ActionCreatorWithPreparedPayload<[model: ModularUIModel], ModularUIModel, "MODULARUI/UPDATE_FORM", never, never>;
|
|
254
|
+
declare const removeModelByKey: _reduxjs_toolkit.ActionCreatorWithPreparedPayload<[key: string], string, "MODULARUI/REMOVE_KEY", never, never>;
|
|
255
|
+
/**
|
|
256
|
+
* Removes all models except the application model from the modular ui reducer
|
|
257
|
+
*/
|
|
258
|
+
declare const resetModularUI: _reduxjs_toolkit.ActionCreatorWithoutPayload<"MODULARUI/RESET">;
|
|
259
|
+
|
|
260
|
+
declare const reloadModel: (model: ModularUIModel, options?: ModularUIRequestOptions) => _reduxjs_toolkit.AsyncThunkAction<FetchModelResult, FetchModelPayload, {
|
|
261
|
+
dispatch: BEIDispatch;
|
|
262
|
+
state: RootState;
|
|
263
|
+
rejectValue: _beinformed_ui_models.ErrorResponse;
|
|
264
|
+
extra?: unknown;
|
|
265
|
+
serializedErrorType?: unknown;
|
|
266
|
+
pendingMeta?: unknown;
|
|
267
|
+
fulfilledMeta?: unknown;
|
|
268
|
+
rejectedMeta?: unknown;
|
|
269
|
+
}>;
|
|
270
|
+
|
|
271
|
+
/**
|
|
272
|
+
* Retrieve the preferred language for this request, falls back to the browser language or english
|
|
273
|
+
*/
|
|
274
|
+
declare const getRequestLocale: (optionLocale: string | undefined, currentStateLocale: string) => string;
|
|
275
|
+
|
|
276
|
+
declare const setServerPreference: (propertyName: string, defaultValue: PreferenceValue, type?: string) => {
|
|
277
|
+
payload: {
|
|
278
|
+
key: string;
|
|
279
|
+
value: PreferenceValue;
|
|
280
|
+
};
|
|
281
|
+
type: "SET_PREFERENCE";
|
|
282
|
+
};
|
|
283
|
+
declare const setThemePreference: (configTheme: string) => {
|
|
284
|
+
payload: {
|
|
285
|
+
key: string;
|
|
286
|
+
value: PreferenceValue;
|
|
287
|
+
};
|
|
288
|
+
type: "SET_PREFERENCE";
|
|
289
|
+
};
|
|
290
|
+
/**
|
|
291
|
+
* Make modular-ui-content-in-data preference available client side
|
|
292
|
+
*/
|
|
293
|
+
declare const setAllContentInDataSetting: (state?: RootState) => {
|
|
294
|
+
payload: {
|
|
295
|
+
key: string;
|
|
296
|
+
value: PreferenceValue;
|
|
297
|
+
};
|
|
298
|
+
type: "SET_PREFERENCE";
|
|
299
|
+
};
|
|
300
|
+
/**
|
|
301
|
+
* Retrieve settings for date time conversion
|
|
302
|
+
*/
|
|
303
|
+
declare const setDateTimeSettings: (state?: RootState) => {
|
|
304
|
+
payload: {
|
|
305
|
+
key: string;
|
|
306
|
+
value: PreferenceValue;
|
|
307
|
+
};
|
|
308
|
+
type: "SET_PREFERENCE";
|
|
309
|
+
};
|
|
310
|
+
/**
|
|
311
|
+
* Retrieves login settings from runtime preferences and sets them as setting in the preference reducer
|
|
312
|
+
*/
|
|
313
|
+
declare const setLoginPreferences: (state?: RootState) => {
|
|
314
|
+
payload: {
|
|
315
|
+
[x: string]: PreferenceValue;
|
|
316
|
+
};
|
|
317
|
+
type: "SET_PREFERENCES";
|
|
318
|
+
};
|
|
319
|
+
|
|
320
|
+
/**
|
|
321
|
+
* Returns a singleton instance of the browser history.
|
|
322
|
+
* Creates the instance on the first call.
|
|
323
|
+
* This pattern is suitable for client-side applications.
|
|
324
|
+
*/
|
|
325
|
+
declare function getBrowserHistory(): History;
|
|
326
|
+
|
|
327
|
+
declare const push: _reduxjs_toolkit.ActionCreatorWithPreparedPayload<[location: string | RouterLocation, state?: unknown], {
|
|
328
|
+
location: string | RouterLocation;
|
|
329
|
+
state: unknown;
|
|
330
|
+
}, "ROUTER/PUSH", never, never>;
|
|
331
|
+
declare const replace: _reduxjs_toolkit.ActionCreatorWithPreparedPayload<[location: string | RouterLocation, state?: unknown], {
|
|
332
|
+
location: string | RouterLocation;
|
|
333
|
+
state: unknown;
|
|
334
|
+
}, "ROUTER/REPLACE", never, never>;
|
|
335
|
+
declare const go: _reduxjs_toolkit.ActionCreatorWithPreparedPayload<[delta: number], {
|
|
336
|
+
delta: number;
|
|
337
|
+
}, "ROUTER/GO", never, never>;
|
|
338
|
+
declare const goBack: _reduxjs_toolkit.ActionCreatorWithoutPayload<"ROUTER/GOBACK">;
|
|
339
|
+
declare const goForward: _reduxjs_toolkit.ActionCreatorWithoutPayload<"ROUTER/GOFORWARD">;
|
|
340
|
+
|
|
341
|
+
declare const routerMiddleware: (history: History) => Middleware<{}, RootState>;
|
|
342
|
+
|
|
343
|
+
declare const useBEIDispatch: react_redux.UseDispatch<_reduxjs_toolkit.ThunkDispatch<{
|
|
344
|
+
router: RouterState;
|
|
345
|
+
preferences: PreferencesState;
|
|
346
|
+
modularui: ModularUIState;
|
|
347
|
+
i18n: I18nState;
|
|
348
|
+
auth: AuthState;
|
|
349
|
+
error: ErrorState;
|
|
350
|
+
modals: ModalsState;
|
|
351
|
+
modelcatalog: ModelCatalogState;
|
|
352
|
+
notification: NotificationState;
|
|
353
|
+
progressindicator: ProgressIndicatorState;
|
|
354
|
+
}, undefined, redux.UnknownAction> & redux.Dispatch<redux.UnknownAction>>;
|
|
355
|
+
declare const useBEISelector: react_redux.UseSelector<{
|
|
356
|
+
router: RouterState;
|
|
357
|
+
preferences: PreferencesState;
|
|
358
|
+
modularui: ModularUIState;
|
|
359
|
+
i18n: I18nState;
|
|
360
|
+
auth: AuthState;
|
|
361
|
+
error: ErrorState;
|
|
362
|
+
modals: ModalsState;
|
|
363
|
+
modelcatalog: ModelCatalogState;
|
|
364
|
+
notification: NotificationState;
|
|
365
|
+
progressindicator: ProgressIndicatorState;
|
|
366
|
+
}>;
|
|
367
|
+
declare const useBEIStore: react_redux.UseStore<_reduxjs_toolkit.EnhancedStore<{
|
|
368
|
+
router: RouterState;
|
|
369
|
+
preferences: PreferencesState;
|
|
370
|
+
modularui: ModularUIState;
|
|
371
|
+
i18n: I18nState;
|
|
372
|
+
auth: AuthState;
|
|
373
|
+
error: ErrorState;
|
|
374
|
+
modals: ModalsState;
|
|
375
|
+
modelcatalog: ModelCatalogState;
|
|
376
|
+
notification: NotificationState;
|
|
377
|
+
progressindicator: ProgressIndicatorState;
|
|
378
|
+
}, redux.UnknownAction, _reduxjs_toolkit.Tuple<[redux.StoreEnhancer<{
|
|
379
|
+
dispatch: _reduxjs_toolkit.ThunkDispatch<{
|
|
380
|
+
router: RouterState;
|
|
381
|
+
preferences: PreferencesState;
|
|
382
|
+
modularui: ModularUIState;
|
|
383
|
+
i18n: I18nState;
|
|
384
|
+
auth: AuthState;
|
|
385
|
+
error: ErrorState;
|
|
386
|
+
modals: ModalsState;
|
|
387
|
+
modelcatalog: ModelCatalogState;
|
|
388
|
+
notification: NotificationState;
|
|
389
|
+
progressindicator: ProgressIndicatorState;
|
|
390
|
+
}, undefined, redux.UnknownAction>;
|
|
391
|
+
}>, redux.StoreEnhancer]>>>;
|
|
392
|
+
|
|
393
|
+
declare const noAction: _reduxjs_toolkit.ActionCreatorWithoutPayload<"NO_ACTION">;
|
|
394
|
+
|
|
395
|
+
declare const getFirstModelByInstance: <T extends new (...args: unknown[]) => unknown>(state: RootState, instance: T) => InstanceType<T> | undefined;
|
|
396
|
+
/**
|
|
397
|
+
* Returns all model keys found in the store, restrict on href
|
|
398
|
+
*/
|
|
399
|
+
declare const allKeysByHref: (state: RootState, href: Href | string) => string[];
|
|
400
|
+
|
|
401
|
+
type DefaultHandler = typeof defaultErrorResponseHandler;
|
|
402
|
+
declare const defaultErrorResponseHandler: (error: ErrorResponse) => (dispatch: BEIDispatch) => {
|
|
403
|
+
payload: undefined;
|
|
404
|
+
type: "CHANGE_PASSWORD";
|
|
405
|
+
} | {
|
|
406
|
+
payload: ErrorResponse;
|
|
407
|
+
type: "SAVE_ERROR";
|
|
408
|
+
} | (Promise<_reduxjs_toolkit.PayloadAction<void, string, {
|
|
409
|
+
arg: ShowNotificationArguments;
|
|
410
|
+
requestId: string;
|
|
411
|
+
requestStatus: "fulfilled";
|
|
412
|
+
}, never> | _reduxjs_toolkit.PayloadAction<unknown, string, {
|
|
413
|
+
arg: ShowNotificationArguments;
|
|
414
|
+
requestId: string;
|
|
415
|
+
requestStatus: "rejected";
|
|
416
|
+
aborted: boolean;
|
|
417
|
+
condition: boolean;
|
|
418
|
+
} & ({
|
|
419
|
+
rejectedWithValue: true;
|
|
420
|
+
} | ({
|
|
421
|
+
rejectedWithValue: false;
|
|
422
|
+
} & {})), _reduxjs_toolkit.SerializedError>> & {
|
|
423
|
+
__linterBrands: "SafePromise";
|
|
424
|
+
} & {
|
|
425
|
+
abort: (reason?: string) => void;
|
|
426
|
+
requestId: string;
|
|
427
|
+
arg: ShowNotificationArguments;
|
|
428
|
+
unwrap: () => Promise<void>;
|
|
429
|
+
}) | {
|
|
430
|
+
payload: undefined;
|
|
431
|
+
type: "NO_ACTION";
|
|
432
|
+
} | (Promise<_reduxjs_toolkit.PayloadAction<void, string, {
|
|
433
|
+
arg: ErrorResponse;
|
|
434
|
+
requestId: string;
|
|
435
|
+
requestStatus: "fulfilled";
|
|
436
|
+
}, never> | _reduxjs_toolkit.PayloadAction<unknown, string, {
|
|
437
|
+
arg: ErrorResponse;
|
|
438
|
+
requestId: string;
|
|
439
|
+
requestStatus: "rejected";
|
|
440
|
+
aborted: boolean;
|
|
441
|
+
condition: boolean;
|
|
442
|
+
} & ({
|
|
443
|
+
rejectedWithValue: true;
|
|
444
|
+
} | ({
|
|
445
|
+
rejectedWithValue: false;
|
|
446
|
+
} & {})), _reduxjs_toolkit.SerializedError>> & {
|
|
447
|
+
__linterBrands: "SafePromise";
|
|
448
|
+
} & {
|
|
449
|
+
abort: (reason?: string) => void;
|
|
450
|
+
requestId: string;
|
|
451
|
+
arg: ErrorResponse;
|
|
452
|
+
unwrap: () => Promise<void>;
|
|
453
|
+
}) | undefined;
|
|
454
|
+
type CustomErrorResponseHandler = (error: ErrorResponse, defaultHandler: DefaultHandler) => (dispatch: BEIDispatch) => void;
|
|
455
|
+
declare const setCustomErrorResponseHandler: (handler: CustomErrorResponseHandler) => void;
|
|
456
|
+
declare const handleError: (error: unknown) => (dispatch: BEIDispatch) => void;
|
|
457
|
+
|
|
458
|
+
export { AUTOSAVE_STATUS, AuthState, BEIDispatch, ErrorState, FetchModelPayload, FetchModelResult, I18nState, MODULARUI_STATUS, ModalsState, ModelCatalogState, ModularUIState, NotificationState, PreferenceValue, PreferencesState, ProgressIndicatorState, RootState, RouterLocation, RouterState, ShowNotificationArguments, addRepeatableAttributeSet, allKeysByHref, autosaveFormObject, autosubmitFormObject, autoupdateFormObject, cancelForm, cancelRepeatableAttributeSet, changePassword, fetchModel, getApplication, getBrowserHistory, getDataFromServer, getEntryDate, getFirstModelByInstance, getLocale, getLocales, getRequestLocale, go, goBack, goForward, handleError, handleUnauthorized, initModels, login, loginFailed, logout, noAction, previousObject, push, reloadApplication, reloadModel, removeModelByKey, removeRepeatableAttributeSet, replace, resetModularUI, routerMiddleware, setAllContentInDataSetting, setCustomErrorResponseHandler, setDateTimeSettings, setLoginPreferences, setModel, setServerPreference, setThemePreference, showFormNotification, showXHRErrorNotification, updateErrorStatus, updateForm, updateFormAttribute, updateModel, useBEIDispatch, useBEISelector, useBEIStore, validateFormObject };
|