jamespot-front-business 1.1.8 → 1.1.9

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/types.d.ts CHANGED
@@ -1,49 +1,49 @@
1
1
  import * as _reduxjs_toolkit from '@reduxjs/toolkit';
2
- import { EntityState, Action, PayloadAction, Dispatch as Dispatch$1 } from '@reduxjs/toolkit';
2
+ import { EntityState, Action, Dispatch as Dispatch$1, PayloadAction } from '@reduxjs/toolkit';
3
3
  import * as _reduxjs_toolkit_dist_tsHelpers from '@reduxjs/toolkit/dist/tsHelpers';
4
4
  import * as jamespot_user_api from 'jamespot-user-api';
5
- import { Application as Application$1, JamespotUserApi, AudienceAutocomplete, ReservationList, BookableAssetList, AssetReservationConfiguration, widgetRefNames, WidgetWrapperProps, WidgetDefinitionProps, WidgetStateProps, CombinedWidgetContent, WidgetVector, Model as Model$1, JLandMap, JLicenseAvailable, jUserList } from 'jamespot-user-api';
5
+ import { ApplicationType, JamespotUserApi, AudienceAutocomplete, ReservationList, BookableAssetList, AssetReservationConfiguration, BookmarkRawList, JLandMap, JLicenseAvailable, Model as Model$1, jUserList, widgetRefNames, WidgetWrapperProps, WidgetDefinitionProps, WidgetStateProps, CombinedWidgetContent, WidgetVector } from 'jamespot-user-api';
6
6
  import * as redux from 'redux';
7
7
  import { Dispatch } from 'redux';
8
- import * as immer_dist_internal from 'immer/dist/internal';
9
8
  import { MapCreationFront as MapCreationFront$1 } from 'src/types';
10
9
  import { Loading as Loading$1 } from 'src/types/utils';
10
+ import * as immer_dist_internal from 'immer/dist/internal';
11
11
 
12
12
  type ApplicationRootState = {
13
13
  entities: {
14
- applications: EntityState<Application$1>;
14
+ applications: EntityState<ApplicationType>;
15
15
  };
16
16
  };
17
17
  declare const Application: {
18
- slice: _reduxjs_toolkit.Slice<EntityState<Application$1>, {
18
+ slice: _reduxjs_toolkit.Slice<EntityState<ApplicationType>, {
19
19
  addOne: {
20
- <S extends EntityState<Application$1>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S, EntityState<Application$1>, S>, entity: Application$1): S;
21
- <S_1 extends EntityState<Application$1>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_1, EntityState<Application$1>, S_1>, action: {
22
- payload: Application$1;
20
+ <S extends EntityState<ApplicationType>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S, EntityState<ApplicationType>, S>, entity: ApplicationType): S;
21
+ <S_1 extends EntityState<ApplicationType>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_1, EntityState<ApplicationType>, S_1>, action: {
22
+ payload: ApplicationType;
23
23
  type: string;
24
24
  }): S_1;
25
25
  };
26
26
  addMany: {
27
- <S_2 extends EntityState<Application$1>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_2, EntityState<Application$1>, S_2>, entities: readonly Application$1[] | Record<_reduxjs_toolkit.EntityId, Application$1>): S_2;
28
- <S_3 extends EntityState<Application$1>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_3, EntityState<Application$1>, S_3>, entities: {
29
- payload: readonly Application$1[] | Record<_reduxjs_toolkit.EntityId, Application$1>;
27
+ <S_2 extends EntityState<ApplicationType>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_2, EntityState<ApplicationType>, S_2>, entities: readonly ApplicationType[] | Record<_reduxjs_toolkit.EntityId, ApplicationType>): S_2;
28
+ <S_3 extends EntityState<ApplicationType>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_3, EntityState<ApplicationType>, S_3>, entities: {
29
+ payload: readonly ApplicationType[] | Record<_reduxjs_toolkit.EntityId, ApplicationType>;
30
30
  type: string;
31
31
  }): S_3;
32
32
  };
33
33
  setAll: {
34
- <S_4 extends EntityState<Application$1>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_4, EntityState<Application$1>, S_4>, entities: readonly Application$1[] | Record<_reduxjs_toolkit.EntityId, Application$1>): S_4;
35
- <S_5 extends EntityState<Application$1>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_5, EntityState<Application$1>, S_5>, entities: {
36
- payload: readonly Application$1[] | Record<_reduxjs_toolkit.EntityId, Application$1>;
34
+ <S_4 extends EntityState<ApplicationType>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_4, EntityState<ApplicationType>, S_4>, entities: readonly ApplicationType[] | Record<_reduxjs_toolkit.EntityId, ApplicationType>): S_4;
35
+ <S_5 extends EntityState<ApplicationType>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_5, EntityState<ApplicationType>, S_5>, entities: {
36
+ payload: readonly ApplicationType[] | Record<_reduxjs_toolkit.EntityId, ApplicationType>;
37
37
  type: string;
38
38
  }): S_5;
39
39
  };
40
40
  }, "applications">;
41
41
  actions: {
42
- addOne: _reduxjs_toolkit.ActionCreatorWithPayload<Application$1, "applications/addOne">;
43
- addMany: _reduxjs_toolkit.ActionCreatorWithPayload<readonly Application$1[] | Record<_reduxjs_toolkit.EntityId, Application$1>, "applications/addMany">;
44
- setAll: _reduxjs_toolkit.ActionCreatorWithPayload<readonly Application$1[] | Record<_reduxjs_toolkit.EntityId, Application$1>, "applications/setAll">;
42
+ addOne: _reduxjs_toolkit.ActionCreatorWithPayload<ApplicationType, "applications/addOne">;
43
+ addMany: _reduxjs_toolkit.ActionCreatorWithPayload<readonly ApplicationType[] | Record<_reduxjs_toolkit.EntityId, ApplicationType>, "applications/addMany">;
44
+ setAll: _reduxjs_toolkit.ActionCreatorWithPayload<readonly ApplicationType[] | Record<_reduxjs_toolkit.EntityId, ApplicationType>, "applications/setAll">;
45
45
  };
46
- selectors: _reduxjs_toolkit.EntitySelectors<Application$1, ApplicationRootState>;
46
+ selectors: _reduxjs_toolkit.EntitySelectors<ApplicationType, ApplicationRootState>;
47
47
  };
48
48
 
49
49
  type RootState = Partial<AssetReservationRootState | ApplicationRootState | ModelRootState | ToastRootState | JLandRootState | WidgetsRootState | EditorsRootState>;
@@ -163,224 +163,145 @@ declare const AssetReservation: {
163
163
  };
164
164
  };
165
165
 
166
- declare function widgetFactory<T>(name: typeof widgetRefNames[number], widgetWrapperExtraParams: T): WidgetWrapperProps;
167
-
168
- declare function uniqid(): string;
169
-
170
- declare const WIDGET_ARTICLE_TITLE = "widget-article-title";
171
- declare const WIDGET_ARTICLE_TEXT = "widget-article-text";
172
- declare const WIDGET_ARTICLE_IMAGE = "widget-article-image";
173
- declare const WIDGET_ARTICLE_BUTTON = "widget-article-button";
174
- declare const WIDGET_ARTICLE_GALLERY = "widget-article-gallery";
175
- declare const WIDGET_ARTICLE_ATTACHMENT = "widget-article-attachment";
176
-
177
- declare const WIDGETS_WIDGET_ARTICLE_TITLE: typeof WIDGET_ARTICLE_TITLE;
178
- declare const WIDGETS_WIDGET_ARTICLE_TEXT: typeof WIDGET_ARTICLE_TEXT;
179
- declare const WIDGETS_WIDGET_ARTICLE_IMAGE: typeof WIDGET_ARTICLE_IMAGE;
180
- declare const WIDGETS_WIDGET_ARTICLE_BUTTON: typeof WIDGET_ARTICLE_BUTTON;
181
- declare const WIDGETS_WIDGET_ARTICLE_GALLERY: typeof WIDGET_ARTICLE_GALLERY;
182
- declare const WIDGETS_WIDGET_ARTICLE_ATTACHMENT: typeof WIDGET_ARTICLE_ATTACHMENT;
183
- declare namespace WIDGETS {
184
- export {
185
- WIDGETS_WIDGET_ARTICLE_TITLE as WIDGET_ARTICLE_TITLE,
186
- WIDGETS_WIDGET_ARTICLE_TEXT as WIDGET_ARTICLE_TEXT,
187
- WIDGETS_WIDGET_ARTICLE_IMAGE as WIDGET_ARTICLE_IMAGE,
188
- WIDGETS_WIDGET_ARTICLE_BUTTON as WIDGET_ARTICLE_BUTTON,
189
- WIDGETS_WIDGET_ARTICLE_GALLERY as WIDGET_ARTICLE_GALLERY,
190
- WIDGETS_WIDGET_ARTICLE_ATTACHMENT as WIDGET_ARTICLE_ATTACHMENT,
191
- };
166
+ type bookmarkEditState = Loading & {
167
+ bookmark: BookmarkRawList | undefined;
168
+ status: 'success' | 'error' | undefined;
169
+ };
170
+ interface bookmarkEditRootState {
171
+ bookmarkEdit: bookmarkEditState;
192
172
  }
193
173
 
194
- declare function widgetDefinition(name: typeof widgetRefNames[number] | undefined): WidgetDefinitionProps;
195
-
196
- declare const MODE_EDIT = "edit";
197
- declare const MODE_VIEW = "view";
198
- type WidgetModalProps = {
199
- title?: string;
200
- view?: any;
201
- };
202
- type WidgetsRootState = {
203
- widgets: WidgetsState;
204
- };
205
- type WidgetsState = {
206
- token?: string | undefined;
207
- ids: Record<string, WidgetWrapperProps>;
208
- states: Record<string, WidgetStateProps>;
209
- modal: WidgetModalProps | undefined;
210
- };
211
- declare const Widget: {
212
- const: typeof WIDGETS;
213
- factory: typeof widgetFactory;
214
- definition: typeof widgetDefinition;
215
- utils: {
216
- uniqid: typeof uniqid;
217
- };
218
- slice: _reduxjs_toolkit.Slice<WidgetsState, {
219
- registerWidget: (state: immer_dist_internal.WritableDraft<WidgetsState>, action: PayloadAction<{
220
- uniqid: string;
221
- widget: WidgetWrapperProps;
222
- }>) => void;
223
- updateWidget: (state: immer_dist_internal.WritableDraft<WidgetsState>, action: PayloadAction<{
224
- uniqid: string;
225
- content: CombinedWidgetContent;
226
- }>) => void;
227
- flushWidget: (state: immer_dist_internal.WritableDraft<WidgetsState>, action: PayloadAction<{
228
- uniqid: string;
229
- }>) => void;
230
- updateWidgetWrapper: (state: immer_dist_internal.WritableDraft<WidgetsState>, action: PayloadAction<{
231
- uniqid: string;
232
- title: string;
233
- position?: WidgetVector;
234
- }>) => void;
235
- setToken: (state: immer_dist_internal.WritableDraft<WidgetsState>, action: PayloadAction<{
236
- token: string;
237
- }>) => void;
238
- setState: (state: immer_dist_internal.WritableDraft<WidgetsState>, action: PayloadAction<{
239
- uniqid: string;
240
- } & WidgetStateProps>) => void;
241
- setAllStates: (state: immer_dist_internal.WritableDraft<WidgetsState>, action: PayloadAction<WidgetStateProps>) => void;
242
- registerModal: (state: immer_dist_internal.WritableDraft<WidgetsState>, action: PayloadAction<WidgetModalProps>) => void;
243
- flushModal: (state: immer_dist_internal.WritableDraft<WidgetsState>) => void;
244
- }, "widgets">;
245
- selectors: {
246
- selectToken: (state: WidgetsRootState) => string | undefined;
247
- selectWidgets: (state: WidgetsRootState) => Record<string, WidgetWrapperProps<jamespot_user_api.WidgetTypes>>;
248
- selectWidget: (state: WidgetsRootState, uniqid: string) => WidgetWrapperProps<jamespot_user_api.WidgetTypes> | undefined;
249
- selectWidgetState: (state: WidgetsRootState, uniqid: string) => WidgetStateProps | undefined;
250
- selectWidgetContent: (state: WidgetsRootState, uniqid: string) => CombinedWidgetContent | undefined;
251
- selectModal: (state: WidgetsRootState) => WidgetModalProps | undefined;
174
+ type bookmarkListState = Loading & {
175
+ bookmarks: BookmarkRawList[];
176
+ nbResults: number;
177
+ status: 'success' | 'error' | undefined;
178
+ isInitialized: boolean;
179
+ add: Record<string, Loading & {
180
+ status: 'success' | 'error' | undefined;
181
+ id?: number;
182
+ }>;
183
+ move: Loading & {
184
+ status: 'success' | 'error' | undefined;
252
185
  };
186
+ delete: Record<string, Loading & {
187
+ status: 'success' | 'error' | undefined;
188
+ }>;
253
189
  };
190
+ interface bookmarkListRootState {
191
+ bookmarkList: bookmarkListState;
192
+ }
254
193
 
255
- type EditorProps = {
256
- uniqid: string;
257
- name: typeof widgetRefNames[number];
258
- position: 'left' | 'right';
259
- popup?: boolean;
260
- view?: any;
261
- };
262
- type EditorsState = {
263
- editors: EditorProps[];
264
- };
265
- type EditorsRootState = {
266
- editors: EditorsState;
267
- };
268
- declare const WidgetEditor: {
269
- slice: _reduxjs_toolkit.Slice<EditorsState, {
270
- registerEditor: (state: immer_dist_internal.WritableDraft<EditorsState>, action: PayloadAction<{
271
- uniqid: string;
272
- name: (typeof widgetRefNames)[number];
273
- }>) => void;
274
- registerEditorPopup: (state: immer_dist_internal.WritableDraft<EditorsState>, action: PayloadAction<{
275
- uniqid: string;
276
- view: any;
277
- }>) => void;
278
- flushEditorPopup: (state: immer_dist_internal.WritableDraft<EditorsState>, action: PayloadAction<{
279
- uniqid: string;
280
- }>) => void;
281
- setEditorPosition: (state: immer_dist_internal.WritableDraft<EditorsState>, action: PayloadAction<{
282
- uniqid: string;
283
- position: 'left' | 'right';
284
- }>) => void;
285
- updateEditor: (state: immer_dist_internal.WritableDraft<EditorsState>, action: PayloadAction<{
286
- uniqid: string;
287
- content: Record<string, unknown>;
288
- }>) => void;
289
- flushEditor: (state: immer_dist_internal.WritableDraft<EditorsState>, action: PayloadAction<{
290
- uniqid: string;
291
- }>) => void;
292
- }, "editors">;
293
- selectors: {
294
- selectEditors: (state: EditorsRootState) => EditorProps[];
295
- selectEditor: (state: EditorsRootState, uniqid: string) => EditorProps | undefined;
296
- };
194
+ type BookmarkRootState = {
195
+ bookmark: bookmarkListRootState & bookmarkEditRootState;
297
196
  };
298
-
299
- type ModelRootState = {
300
- entities: {
301
- models: EntityState<Model$1>;
197
+ declare const Bookmark: {
198
+ slice: {
199
+ name: "bookmark";
200
+ reducer: redux.Reducer<redux.CombinedState<{
201
+ bookmarkList: bookmarkListState;
202
+ bookmarkEdit: bookmarkEditState;
203
+ }>, redux.AnyAction>;
302
204
  };
303
- };
304
- declare const Model: {
305
- slice: _reduxjs_toolkit.Slice<EntityState<Model$1<string>>, {
306
- addOne: {
307
- <S extends EntityState<Model$1<string>>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S, EntityState<Model$1<string>>, S>, entity: Model$1<string>): S;
308
- <S_1 extends EntityState<Model$1<string>>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_1, EntityState<Model$1<string>>, S_1>, action: {
309
- payload: Model$1<string>;
310
- type: string;
311
- }): S_1;
312
- };
313
- addMany: {
314
- <S_2 extends EntityState<Model$1<string>>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_2, EntityState<Model$1<string>>, S_2>, entities: readonly Model$1<string>[] | Record<_reduxjs_toolkit.EntityId, Model$1<string>>): S_2;
315
- <S_3 extends EntityState<Model$1<string>>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_3, EntityState<Model$1<string>>, S_3>, entities: {
316
- payload: readonly Model$1<string>[] | Record<_reduxjs_toolkit.EntityId, Model$1<string>>;
317
- type: string;
318
- }): S_3;
319
- };
320
- setAll: {
321
- <S_4 extends EntityState<Model$1<string>>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_4, EntityState<Model$1<string>>, S_4>, entities: readonly Model$1<string>[] | Record<_reduxjs_toolkit.EntityId, Model$1<string>>): S_4;
322
- <S_5 extends EntityState<Model$1<string>>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_5, EntityState<Model$1<string>>, S_5>, entities: {
323
- payload: readonly Model$1<string>[] | Record<_reduxjs_toolkit.EntityId, Model$1<string>>;
324
- type: string;
325
- }): S_5;
326
- };
327
- }, "models">;
328
205
  actions: {
329
- addOne: _reduxjs_toolkit.ActionCreatorWithPayload<Model$1<string>, "models/addOne">;
330
- addMany: _reduxjs_toolkit.ActionCreatorWithPayload<readonly Model$1<string>[] | Record<_reduxjs_toolkit.EntityId, Model$1<string>>, "models/addMany">;
331
- setAll: _reduxjs_toolkit.ActionCreatorWithPayload<readonly Model$1<string>[] | Record<_reduxjs_toolkit.EntityId, Model$1<string>>, "models/setAll">;
206
+ resetAddBookmarkStatus: _reduxjs_toolkit.ActionCreatorWithPayload<string, "bookmarkList/resetAddBookmarkStatus">;
207
+ resetMoveBookmarkStatus: _reduxjs_toolkit.ActionCreatorWithoutPayload<"bookmarkList/resetMoveBookmarkStatus">;
208
+ resetDeleteBookmarkStatus: _reduxjs_toolkit.ActionCreatorWithPayload<string, "bookmarkList/resetDeleteBookmarkStatus">;
209
+ addBookmarkRT: _reduxjs_toolkit.ActionCreatorWithPayload<jamespot_user_api.BookmarkRawList<jamespot_user_api.jObjectLittle>, "bookmarkList/addBookmarkRT">;
210
+ deleteBookmarkRT: _reduxjs_toolkit.ActionCreatorWithPayload<jamespot_user_api.BookmarkRawList<jamespot_user_api.jObjectLittle>, "bookmarkList/deleteBookmarkRT">;
211
+ updateBookmarkRT: _reduxjs_toolkit.ActionCreatorWithPayload<jamespot_user_api.BookmarkRawList<jamespot_user_api.jObjectLittle>, "bookmarkList/updateBookmarkRT">;
212
+ setEditBookmark: _reduxjs_toolkit.ActionCreatorWithPayload<jamespot_user_api.BookmarkRawList<jamespot_user_api.jObjectLittle>, "bookmarkEdit/setEditBookmark">;
213
+ unsetEditBookmark: _reduxjs_toolkit.ActionCreatorWithoutPayload<"bookmarkEdit/unsetEditBookmark">;
214
+ resetStatus: _reduxjs_toolkit.ActionCreatorWithoutPayload<"bookmarkEdit/resetStatus">;
215
+ fetchBookmark: _reduxjs_toolkit.AsyncThunk<jamespot_user_api.ApiPagingResults<jamespot_user_api.BookmarkRawList<jamespot_user_api.jObjectLittle>, string[]>, void, {
216
+ dispatch: any;
217
+ state: RootState & BookmarkRootState;
218
+ extra: {
219
+ jApi: jamespot_user_api.JamespotUserApi;
220
+ };
221
+ rejectValue: {
222
+ error: number;
223
+ errorMsg: string;
224
+ };
225
+ serializedErrorType?: unknown;
226
+ pendingMeta?: unknown;
227
+ fulfilledMeta?: unknown;
228
+ rejectedMeta?: unknown;
229
+ }>;
230
+ addBookmark: _reduxjs_toolkit.AsyncThunk<jamespot_user_api.ApiWrapper<jamespot_user_api.BookmarkRawList<jamespot_user_api.jObjectLittle> | jamespot_user_api.BookmarkList<jamespot_user_api.jObjectLittle>, jamespot_user_api.BaseMessagesOne> | jamespot_user_api.ApiWrapper<jamespot_user_api.BookmarkRawList<jamespot_user_api.jObjectLittle>, string[]>, (jamespot_user_api.BookmarkCustom | jamespot_user_api.BookmarkLink) & {
231
+ requestId?: string | undefined;
232
+ }, {
233
+ dispatch: any;
234
+ state: RootState & BookmarkRootState;
235
+ extra: {
236
+ jApi: jamespot_user_api.JamespotUserApi;
237
+ };
238
+ rejectValue: {
239
+ error: number;
240
+ errorMsg: string;
241
+ };
242
+ serializedErrorType?: unknown;
243
+ pendingMeta?: unknown;
244
+ fulfilledMeta?: unknown;
245
+ rejectedMeta?: unknown;
246
+ }>;
247
+ moveBookmark: _reduxjs_toolkit.AsyncThunk<void, {
248
+ bookmark: Pick<jamespot_user_api.BookmarkRawList<jamespot_user_api.jObjectLittle>, "id">;
249
+ bookmarkReference: Pick<jamespot_user_api.BookmarkRawList<jamespot_user_api.jObjectLittle>, "id">;
250
+ position: "after" | "before";
251
+ }, {
252
+ dispatch: any;
253
+ state: RootState & BookmarkRootState;
254
+ extra: {
255
+ jApi: jamespot_user_api.JamespotUserApi;
256
+ };
257
+ rejectValue: {
258
+ error: number;
259
+ errorMsg: string;
260
+ };
261
+ serializedErrorType?: unknown;
262
+ pendingMeta?: unknown;
263
+ fulfilledMeta?: unknown;
264
+ rejectedMeta?: unknown;
265
+ }>;
266
+ deleteBookmark: _reduxjs_toolkit.AsyncThunk<void, Pick<jamespot_user_api.BookmarkRawList<jamespot_user_api.jObjectLittle>, "id"> & {
267
+ requestId?: string | undefined;
268
+ }, {
269
+ dispatch: any;
270
+ state: RootState & BookmarkRootState;
271
+ extra: {
272
+ jApi: jamespot_user_api.JamespotUserApi;
273
+ };
274
+ rejectValue: {
275
+ error: number;
276
+ errorMsg: string;
277
+ };
278
+ serializedErrorType?: unknown;
279
+ pendingMeta?: unknown;
280
+ fulfilledMeta?: unknown;
281
+ rejectedMeta?: unknown;
282
+ }>;
283
+ editBookmark: _reduxjs_toolkit.AsyncThunk<void, Partial<jamespot_user_api.BookmarkRawList<jamespot_user_api.jObjectLittle>>, {
284
+ dispatch: any;
285
+ state: RootState & BookmarkRootState;
286
+ extra: {
287
+ jApi: jamespot_user_api.JamespotUserApi;
288
+ };
289
+ rejectValue: {
290
+ error: number;
291
+ errorMsg: string;
292
+ };
293
+ serializedErrorType?: unknown;
294
+ pendingMeta?: unknown;
295
+ fulfilledMeta?: unknown;
296
+ rejectedMeta?: unknown;
297
+ }>;
332
298
  };
333
- selectors: _reduxjs_toolkit.EntitySelectors<Model$1<string>, ModelRootState>;
334
- };
335
-
336
- type ToastType = 'success' | 'warning' | 'error';
337
- type ToastRootState = {
338
- toasts: EntityState<ToastEntity>;
339
- };
340
- type ToastEntity = {
341
- id: string;
342
- label: string;
343
- description?: string;
344
- timeout: number;
345
- type: ToastType;
346
- };
347
- declare const actions: {
348
- addMessage: ({ id, ...toast }: Toast, type?: ToastType, timeout?: number) => (dispatch: Dispatch$1) => string;
349
- success: (toast: Toast, timeout?: number) => (dispatch: Dispatch$1) => string;
350
- warning: (toast: Toast, timeout?: number) => (dispatch: Dispatch$1) => string;
351
- error: (toast: Toast, timeout?: number) => (dispatch: Dispatch$1) => string;
352
- };
353
- type Toast = {
354
- id?: string;
355
- label: string;
356
- description?: string;
357
- };
358
- declare const Toast: {
359
- slice: _reduxjs_toolkit.Slice<EntityState<ToastEntity>, {
360
- addOne: {
361
- <S extends EntityState<ToastEntity>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S, EntityState<ToastEntity>, S>, entity: ToastEntity): S;
362
- <S_1 extends EntityState<ToastEntity>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_1, EntityState<ToastEntity>, S_1>, action: {
363
- payload: ToastEntity;
364
- type: string;
365
- }): S_1;
366
- };
367
- removeOne: {
368
- <S_2 extends EntityState<ToastEntity>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_2, EntityState<ToastEntity>, S_2>, key: _reduxjs_toolkit.EntityId): S_2;
369
- <S_3 extends EntityState<ToastEntity>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_3, EntityState<ToastEntity>, S_3>, key: {
370
- payload: _reduxjs_toolkit.EntityId;
371
- type: string;
372
- }): S_3;
373
- };
374
- }, "toasts">;
375
- actions: {
376
- addOne: _reduxjs_toolkit.ActionCreatorWithPayload<ToastEntity, "toasts/addOne">;
377
- removeOne: _reduxjs_toolkit.ActionCreatorWithPayload<_reduxjs_toolkit.EntityId, "toasts/removeOne">;
378
- addMessage: ({ id, ...toast }: Toast, type?: ToastType, timeout?: number) => (dispatch: Dispatch$1) => string;
379
- success: (toast: Toast, timeout?: number) => (dispatch: Dispatch$1) => string;
380
- warning: (toast: Toast, timeout?: number) => (dispatch: Dispatch$1) => string;
381
- error: (toast: Toast, timeout?: number) => (dispatch: Dispatch$1) => string;
299
+ selectors: {
300
+ bookmarkList: (state: BookmarkRootState) => bookmarkListState;
301
+ bookmarkListIsInitialized: (state: BookmarkRootState) => boolean;
302
+ bookmarkEditBookmark: (state: BookmarkRootState) => jamespot_user_api.BookmarkRawList<jamespot_user_api.jObjectLittle> | undefined;
382
303
  };
383
- selectors: _reduxjs_toolkit.EntitySelectors<ToastEntity, ToastRootState>;
304
+ getRTHandlers: (dispatch: redux.Dispatch<any>) => (jamespot_user_api.RTMessageHandler<"BOOKMARKS"> | jamespot_user_api.RTMessageHandler<"CUSTOM-ACTION">)[];
384
305
  };
385
306
 
386
307
  type MapCreateState = Loading$1 & {
@@ -543,6 +464,93 @@ declare const jland: {
543
464
  };
544
465
  };
545
466
 
467
+ type ModelRootState = {
468
+ entities: {
469
+ models: EntityState<Model$1>;
470
+ };
471
+ };
472
+ declare const Model: {
473
+ slice: _reduxjs_toolkit.Slice<EntityState<Model$1<string>>, {
474
+ addOne: {
475
+ <S extends EntityState<Model$1<string>>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S, EntityState<Model$1<string>>, S>, entity: Model$1<string>): S;
476
+ <S_1 extends EntityState<Model$1<string>>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_1, EntityState<Model$1<string>>, S_1>, action: {
477
+ payload: Model$1<string>;
478
+ type: string;
479
+ }): S_1;
480
+ };
481
+ addMany: {
482
+ <S_2 extends EntityState<Model$1<string>>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_2, EntityState<Model$1<string>>, S_2>, entities: readonly Model$1<string>[] | Record<_reduxjs_toolkit.EntityId, Model$1<string>>): S_2;
483
+ <S_3 extends EntityState<Model$1<string>>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_3, EntityState<Model$1<string>>, S_3>, entities: {
484
+ payload: readonly Model$1<string>[] | Record<_reduxjs_toolkit.EntityId, Model$1<string>>;
485
+ type: string;
486
+ }): S_3;
487
+ };
488
+ setAll: {
489
+ <S_4 extends EntityState<Model$1<string>>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_4, EntityState<Model$1<string>>, S_4>, entities: readonly Model$1<string>[] | Record<_reduxjs_toolkit.EntityId, Model$1<string>>): S_4;
490
+ <S_5 extends EntityState<Model$1<string>>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_5, EntityState<Model$1<string>>, S_5>, entities: {
491
+ payload: readonly Model$1<string>[] | Record<_reduxjs_toolkit.EntityId, Model$1<string>>;
492
+ type: string;
493
+ }): S_5;
494
+ };
495
+ }, "models">;
496
+ actions: {
497
+ addOne: _reduxjs_toolkit.ActionCreatorWithPayload<Model$1<string>, "models/addOne">;
498
+ addMany: _reduxjs_toolkit.ActionCreatorWithPayload<readonly Model$1<string>[] | Record<_reduxjs_toolkit.EntityId, Model$1<string>>, "models/addMany">;
499
+ setAll: _reduxjs_toolkit.ActionCreatorWithPayload<readonly Model$1<string>[] | Record<_reduxjs_toolkit.EntityId, Model$1<string>>, "models/setAll">;
500
+ };
501
+ selectors: _reduxjs_toolkit.EntitySelectors<Model$1<string>, ModelRootState>;
502
+ };
503
+
504
+ type ToastType = 'success' | 'warning' | 'error';
505
+ type ToastRootState = {
506
+ toasts: EntityState<ToastEntity>;
507
+ };
508
+ type ToastEntity = {
509
+ id: string;
510
+ label: string;
511
+ description?: string;
512
+ timeout: number;
513
+ type: ToastType;
514
+ };
515
+ declare const actions: {
516
+ addMessage: ({ id, ...toast }: Toast, type?: ToastType, timeout?: number) => (dispatch: Dispatch$1) => string;
517
+ success: (toast: Toast, timeout?: number) => (dispatch: Dispatch$1) => string;
518
+ warning: (toast: Toast, timeout?: number) => (dispatch: Dispatch$1) => string;
519
+ error: (toast: Toast, timeout?: number) => (dispatch: Dispatch$1) => string;
520
+ };
521
+ type Toast = {
522
+ id?: string;
523
+ label: string;
524
+ description?: string;
525
+ };
526
+ declare const Toast: {
527
+ slice: _reduxjs_toolkit.Slice<EntityState<ToastEntity>, {
528
+ addOne: {
529
+ <S extends EntityState<ToastEntity>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S, EntityState<ToastEntity>, S>, entity: ToastEntity): S;
530
+ <S_1 extends EntityState<ToastEntity>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_1, EntityState<ToastEntity>, S_1>, action: {
531
+ payload: ToastEntity;
532
+ type: string;
533
+ }): S_1;
534
+ };
535
+ removeOne: {
536
+ <S_2 extends EntityState<ToastEntity>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_2, EntityState<ToastEntity>, S_2>, key: _reduxjs_toolkit.EntityId): S_2;
537
+ <S_3 extends EntityState<ToastEntity>>(state: _reduxjs_toolkit_dist_tsHelpers.IsAny<S_3, EntityState<ToastEntity>, S_3>, key: {
538
+ payload: _reduxjs_toolkit.EntityId;
539
+ type: string;
540
+ }): S_3;
541
+ };
542
+ }, "toasts">;
543
+ actions: {
544
+ addOne: _reduxjs_toolkit.ActionCreatorWithPayload<ToastEntity, "toasts/addOne">;
545
+ removeOne: _reduxjs_toolkit.ActionCreatorWithPayload<_reduxjs_toolkit.EntityId, "toasts/removeOne">;
546
+ addMessage: ({ id, ...toast }: Toast, type?: ToastType, timeout?: number) => (dispatch: Dispatch$1) => string;
547
+ success: (toast: Toast, timeout?: number) => (dispatch: Dispatch$1) => string;
548
+ warning: (toast: Toast, timeout?: number) => (dispatch: Dispatch$1) => string;
549
+ error: (toast: Toast, timeout?: number) => (dispatch: Dispatch$1) => string;
550
+ };
551
+ selectors: _reduxjs_toolkit.EntitySelectors<ToastEntity, ToastRootState>;
552
+ };
553
+
546
554
  type UserCurrentRootState = {
547
555
  userCurrent: jUserList;
548
556
  };
@@ -564,4 +572,137 @@ declare const UserCurrent: {
564
572
  };
565
573
  };
566
574
 
567
- export { Application, ApplicationRootState, AssetReservation, AssetReservationRootState, EditorProps, EditorsRootState, EditorsState, JLandMapFront, JLandRootState, JLandState, MODE_EDIT, MODE_VIEW, MapCreationFront, Model, ModelRootState, ReservationForm, RootDispatch, RootState, ThunkApiConfig, Toast, ToastRootState, UserCurrent, UserCurrentRootState, Widget, WidgetEditor, WidgetModalProps, WidgetsRootState, WidgetsState, actions, jland, slice };
575
+ declare function widgetFactory<T>(name: typeof widgetRefNames[number], widgetWrapperExtraParams: T): WidgetWrapperProps;
576
+
577
+ declare function uniqid(): string;
578
+
579
+ declare const WIDGET_ARTICLE_TITLE = "widget-article-title";
580
+ declare const WIDGET_ARTICLE_TEXT = "widget-article-text";
581
+ declare const WIDGET_ARTICLE_IMAGE = "widget-article-image";
582
+ declare const WIDGET_ARTICLE_BUTTON = "widget-article-button";
583
+ declare const WIDGET_ARTICLE_GALLERY = "widget-article-gallery";
584
+ declare const WIDGET_ARTICLE_ATTACHMENT = "widget-article-attachment";
585
+
586
+ declare const WIDGETS_WIDGET_ARTICLE_TITLE: typeof WIDGET_ARTICLE_TITLE;
587
+ declare const WIDGETS_WIDGET_ARTICLE_TEXT: typeof WIDGET_ARTICLE_TEXT;
588
+ declare const WIDGETS_WIDGET_ARTICLE_IMAGE: typeof WIDGET_ARTICLE_IMAGE;
589
+ declare const WIDGETS_WIDGET_ARTICLE_BUTTON: typeof WIDGET_ARTICLE_BUTTON;
590
+ declare const WIDGETS_WIDGET_ARTICLE_GALLERY: typeof WIDGET_ARTICLE_GALLERY;
591
+ declare const WIDGETS_WIDGET_ARTICLE_ATTACHMENT: typeof WIDGET_ARTICLE_ATTACHMENT;
592
+ declare namespace WIDGETS {
593
+ export {
594
+ WIDGETS_WIDGET_ARTICLE_TITLE as WIDGET_ARTICLE_TITLE,
595
+ WIDGETS_WIDGET_ARTICLE_TEXT as WIDGET_ARTICLE_TEXT,
596
+ WIDGETS_WIDGET_ARTICLE_IMAGE as WIDGET_ARTICLE_IMAGE,
597
+ WIDGETS_WIDGET_ARTICLE_BUTTON as WIDGET_ARTICLE_BUTTON,
598
+ WIDGETS_WIDGET_ARTICLE_GALLERY as WIDGET_ARTICLE_GALLERY,
599
+ WIDGETS_WIDGET_ARTICLE_ATTACHMENT as WIDGET_ARTICLE_ATTACHMENT,
600
+ };
601
+ }
602
+
603
+ declare function widgetDefinition(name: typeof widgetRefNames[number] | undefined): WidgetDefinitionProps;
604
+
605
+ declare const MODE_EDIT = "edit";
606
+ declare const MODE_VIEW = "view";
607
+ type WidgetModalProps = {
608
+ title?: string;
609
+ view?: any;
610
+ };
611
+ type WidgetsRootState = {
612
+ widgets: WidgetsState;
613
+ };
614
+ type WidgetsState = {
615
+ token?: string | undefined;
616
+ ids: Record<string, WidgetWrapperProps>;
617
+ states: Record<string, WidgetStateProps>;
618
+ modal: WidgetModalProps | undefined;
619
+ };
620
+ declare const Widget: {
621
+ const: typeof WIDGETS;
622
+ factory: typeof widgetFactory;
623
+ definition: typeof widgetDefinition;
624
+ utils: {
625
+ uniqid: typeof uniqid;
626
+ };
627
+ slice: _reduxjs_toolkit.Slice<WidgetsState, {
628
+ registerWidget: (state: immer_dist_internal.WritableDraft<WidgetsState>, action: PayloadAction<{
629
+ uniqid: string;
630
+ widget: WidgetWrapperProps;
631
+ }>) => void;
632
+ updateWidget: (state: immer_dist_internal.WritableDraft<WidgetsState>, action: PayloadAction<{
633
+ uniqid: string;
634
+ content: CombinedWidgetContent;
635
+ }>) => void;
636
+ flushWidget: (state: immer_dist_internal.WritableDraft<WidgetsState>, action: PayloadAction<{
637
+ uniqid: string;
638
+ }>) => void;
639
+ updateWidgetWrapper: (state: immer_dist_internal.WritableDraft<WidgetsState>, action: PayloadAction<{
640
+ uniqid: string;
641
+ title: string;
642
+ position?: WidgetVector;
643
+ }>) => void;
644
+ setToken: (state: immer_dist_internal.WritableDraft<WidgetsState>, action: PayloadAction<{
645
+ token: string;
646
+ }>) => void;
647
+ setState: (state: immer_dist_internal.WritableDraft<WidgetsState>, action: PayloadAction<{
648
+ uniqid: string;
649
+ } & WidgetStateProps>) => void;
650
+ setAllStates: (state: immer_dist_internal.WritableDraft<WidgetsState>, action: PayloadAction<WidgetStateProps>) => void;
651
+ registerModal: (state: immer_dist_internal.WritableDraft<WidgetsState>, action: PayloadAction<WidgetModalProps>) => void;
652
+ flushModal: (state: immer_dist_internal.WritableDraft<WidgetsState>) => void;
653
+ }, "widgets">;
654
+ selectors: {
655
+ selectToken: (state: WidgetsRootState) => string | undefined;
656
+ selectWidgets: (state: WidgetsRootState) => Record<string, WidgetWrapperProps<jamespot_user_api.WidgetTypes>>;
657
+ selectWidget: (state: WidgetsRootState, uniqid: string) => WidgetWrapperProps<jamespot_user_api.WidgetTypes> | undefined;
658
+ selectWidgetState: (state: WidgetsRootState, uniqid: string) => WidgetStateProps | undefined;
659
+ selectWidgetContent: (state: WidgetsRootState, uniqid: string) => CombinedWidgetContent | undefined;
660
+ selectModal: (state: WidgetsRootState) => WidgetModalProps | undefined;
661
+ };
662
+ };
663
+
664
+ type EditorProps = {
665
+ uniqid: string;
666
+ name: typeof widgetRefNames[number];
667
+ position: 'left' | 'right';
668
+ popup?: boolean;
669
+ view?: any;
670
+ };
671
+ type EditorsState = {
672
+ editors: EditorProps[];
673
+ };
674
+ type EditorsRootState = {
675
+ editors: EditorsState;
676
+ };
677
+ declare const WidgetEditor: {
678
+ slice: _reduxjs_toolkit.Slice<EditorsState, {
679
+ registerEditor: (state: immer_dist_internal.WritableDraft<EditorsState>, action: PayloadAction<{
680
+ uniqid: string;
681
+ name: (typeof widgetRefNames)[number];
682
+ }>) => void;
683
+ registerEditorPopup: (state: immer_dist_internal.WritableDraft<EditorsState>, action: PayloadAction<{
684
+ uniqid: string;
685
+ view: any;
686
+ }>) => void;
687
+ flushEditorPopup: (state: immer_dist_internal.WritableDraft<EditorsState>, action: PayloadAction<{
688
+ uniqid: string;
689
+ }>) => void;
690
+ setEditorPosition: (state: immer_dist_internal.WritableDraft<EditorsState>, action: PayloadAction<{
691
+ uniqid: string;
692
+ position: 'left' | 'right';
693
+ }>) => void;
694
+ updateEditor: (state: immer_dist_internal.WritableDraft<EditorsState>, action: PayloadAction<{
695
+ uniqid: string;
696
+ content: Record<string, unknown>;
697
+ }>) => void;
698
+ flushEditor: (state: immer_dist_internal.WritableDraft<EditorsState>, action: PayloadAction<{
699
+ uniqid: string;
700
+ }>) => void;
701
+ }, "editors">;
702
+ selectors: {
703
+ selectEditors: (state: EditorsRootState) => EditorProps[];
704
+ selectEditor: (state: EditorsRootState, uniqid: string) => EditorProps | undefined;
705
+ };
706
+ };
707
+
708
+ export { Application, ApplicationRootState, AssetReservation, AssetReservationRootState, Bookmark, BookmarkRootState, EditorProps, EditorsRootState, EditorsState, JLandMapFront, JLandRootState, JLandState, MODE_EDIT, MODE_VIEW, MapCreationFront, Model, ModelRootState, ReservationForm, RootDispatch, RootState, ThunkApiConfig, Toast, ToastRootState, UserCurrent, UserCurrentRootState, Widget, WidgetEditor, WidgetModalProps, WidgetsRootState, WidgetsState, actions, jland, slice };