@nizza/core 0.3.2-beta.0 → 0.4.0-alpha.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/dist/environments/environment.d.ts +1 -0
- package/dist/index.cjs +12 -11
- package/dist/index.mjs +4310 -2178
- package/dist/lib/accounts/core/services/AccountService.d.ts +1 -1
- package/dist/lib/accounts/hooks/useAccount.d.ts +2 -2
- package/dist/lib/constants/i18n.d.ts +5 -0
- package/dist/lib/constants/index.d.ts +1 -0
- package/dist/lib/i18n/buildTranslations.d.ts +2 -0
- package/dist/lib/i18n/index.d.ts +2 -0
- package/dist/lib/i18n/init.d.ts +1 -0
- package/dist/lib/index.d.ts +1 -0
- package/dist/lib/types/api-graphql-types.d.ts +265 -0
- package/dist/lib/types/api.d.ts +1 -0
- package/dist/lib/types/i18n.d.ts +3 -0
- package/dist/lib/types/index.d.ts +1 -0
- package/dist/lib/types/nizza/chat.d.ts +28 -0
- package/dist/lib/types/nizza/index.d.ts +1 -0
- package/dist/lib/types/utils.d.ts +1 -1
- package/dist/lib/utils/customFetch.d.ts +6 -1
- package/dist/lib/utils/downloadFile.d.ts +6 -0
- package/dist/lib/utils/helpers.d.ts +19 -2
- package/dist/lib/utils/index.d.ts +2 -0
- package/dist/lib/utils/logger.d.ts +28 -0
- package/dist/package.json +1 -1
- package/package.json +1 -1
|
@@ -2,5 +2,5 @@ import { AccountRepository } from '../domain';
|
|
|
2
2
|
export declare class AccountService {
|
|
3
3
|
private accountRepository;
|
|
4
4
|
constructor(accountRepository: AccountRepository);
|
|
5
|
-
get(name: string): Promise<import("
|
|
5
|
+
get(name: string): Promise<import("../domain").NizzaAccount>;
|
|
6
6
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
export declare const useAccount: () => {
|
|
2
|
-
findQuery: import("@tanstack/react-query").UseQueryResult<import("
|
|
3
|
-
account: import("
|
|
2
|
+
findQuery: import("@tanstack/react-query").UseQueryResult<import("../core").NizzaAccount, unknown>;
|
|
3
|
+
account: import("../core").NizzaAccount | null;
|
|
4
4
|
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const i18n: Promise<import("i18next").TFunction>;
|
package/dist/lib/index.d.ts
CHANGED
|
@@ -26,6 +26,54 @@ export type ActionSnackVideoSuccess = {
|
|
|
26
26
|
__typename?: 'ActionSnackVideoSuccess';
|
|
27
27
|
message: Scalars['String'];
|
|
28
28
|
};
|
|
29
|
+
export type ChatMessage = {
|
|
30
|
+
__typename?: 'ChatMessage';
|
|
31
|
+
account: Scalars['String'];
|
|
32
|
+
connectionId?: Maybe<Scalars['String']>;
|
|
33
|
+
data: Scalars['String'];
|
|
34
|
+
email?: Maybe<Scalars['String']>;
|
|
35
|
+
id: Scalars['String'];
|
|
36
|
+
idEvent: Scalars['String'];
|
|
37
|
+
isAdmin?: Maybe<Scalars['Boolean']>;
|
|
38
|
+
sendDate?: Maybe<Scalars['String']>;
|
|
39
|
+
sessionId?: Maybe<Scalars['String']>;
|
|
40
|
+
type?: Maybe<Scalars['String']>;
|
|
41
|
+
username?: Maybe<Scalars['String']>;
|
|
42
|
+
};
|
|
43
|
+
export type ChatMessageArray = {
|
|
44
|
+
__typename?: 'ChatMessageArray';
|
|
45
|
+
data?: Maybe<Array<ChatMessage>>;
|
|
46
|
+
duration?: Maybe<Scalars['String']>;
|
|
47
|
+
isArray?: Maybe<Scalars['Boolean']>;
|
|
48
|
+
method?: Maybe<Scalars['String']>;
|
|
49
|
+
path?: Maybe<Scalars['String']>;
|
|
50
|
+
};
|
|
51
|
+
export type ChatRoom = {
|
|
52
|
+
__typename?: 'ChatRoom';
|
|
53
|
+
id: Scalars['String'];
|
|
54
|
+
};
|
|
55
|
+
export type ChatRoomData = {
|
|
56
|
+
__typename?: 'ChatRoomData';
|
|
57
|
+
data?: Maybe<ChatRoom>;
|
|
58
|
+
duration?: Maybe<Scalars['String']>;
|
|
59
|
+
isArray?: Maybe<Scalars['Boolean']>;
|
|
60
|
+
method?: Maybe<Scalars['String']>;
|
|
61
|
+
path?: Maybe<Scalars['String']>;
|
|
62
|
+
};
|
|
63
|
+
export type ChatRoomToken = {
|
|
64
|
+
__typename?: 'ChatRoomToken';
|
|
65
|
+
sessionExpirationTime: Scalars['String'];
|
|
66
|
+
token: Scalars['String'];
|
|
67
|
+
tokenExpirationTime: Scalars['String'];
|
|
68
|
+
};
|
|
69
|
+
export type ChatRoomTokenData = {
|
|
70
|
+
__typename?: 'ChatRoomTokenData';
|
|
71
|
+
data?: Maybe<ChatRoomToken>;
|
|
72
|
+
duration?: Maybe<Scalars['String']>;
|
|
73
|
+
isArray?: Maybe<Scalars['Boolean']>;
|
|
74
|
+
method?: Maybe<Scalars['String']>;
|
|
75
|
+
path?: Maybe<Scalars['String']>;
|
|
76
|
+
};
|
|
29
77
|
export type Clip = {
|
|
30
78
|
endTime: Scalars['String'];
|
|
31
79
|
name: Scalars['String'];
|
|
@@ -63,6 +111,11 @@ export type CollectionSuccessArray = {
|
|
|
63
111
|
method?: Maybe<Scalars['String']>;
|
|
64
112
|
path?: Maybe<Scalars['String']>;
|
|
65
113
|
};
|
|
114
|
+
export type CreateChatRoomInput = {
|
|
115
|
+
account: Scalars['String'];
|
|
116
|
+
idEvent: Scalars['String'];
|
|
117
|
+
};
|
|
118
|
+
export type CreateChatRoomResult = ChatRoomData | ErrorGeneral;
|
|
66
119
|
export type CreateCollectionInput = {
|
|
67
120
|
account: Scalars['String'];
|
|
68
121
|
description?: InputMaybe<Scalars['String']>;
|
|
@@ -114,6 +167,22 @@ export type CustomPlayerSuccessArray = {
|
|
|
114
167
|
method?: Maybe<Scalars['String']>;
|
|
115
168
|
path?: Maybe<Scalars['String']>;
|
|
116
169
|
};
|
|
170
|
+
export type DeleteChatInput = {
|
|
171
|
+
account: Scalars['String'];
|
|
172
|
+
id: Scalars['String'];
|
|
173
|
+
idEvent: Scalars['String'];
|
|
174
|
+
sendDate: Scalars['String'];
|
|
175
|
+
username: Scalars['String'];
|
|
176
|
+
};
|
|
177
|
+
export type DeleteChatMessageResult = DeleteChatMessageSuccess | ErrorGeneral;
|
|
178
|
+
export type DeleteChatMessageSuccess = {
|
|
179
|
+
__typename?: 'DeleteChatMessageSuccess';
|
|
180
|
+
message: Scalars['String'];
|
|
181
|
+
};
|
|
182
|
+
export type DeleteSnackVideoInput = {
|
|
183
|
+
account: Scalars['String'];
|
|
184
|
+
id: Scalars['String'];
|
|
185
|
+
};
|
|
117
186
|
export type Error = {
|
|
118
187
|
message: Scalars['String'];
|
|
119
188
|
statusCode: Scalars['String'];
|
|
@@ -162,6 +231,17 @@ export type FindManySnackVideoInput = {
|
|
|
162
231
|
ids: Array<Scalars['String']>;
|
|
163
232
|
};
|
|
164
233
|
export type FindManySnackVideoResult = ErrorGeneral | SnackVideoArray;
|
|
234
|
+
export type GetAllChatMessageInput = {
|
|
235
|
+
account: Scalars['String'];
|
|
236
|
+
idEvent: Scalars['String'];
|
|
237
|
+
};
|
|
238
|
+
export type GetAllChatMessageResult = ChatMessageArray | ErrorGeneral;
|
|
239
|
+
export type GetChatRoomInput = {
|
|
240
|
+
account: Scalars['String'];
|
|
241
|
+
idEvent: Scalars['String'];
|
|
242
|
+
userName: Scalars['String'];
|
|
243
|
+
};
|
|
244
|
+
export type GetChatRoomTokenResult = ChatRoomTokenData | ErrorGeneral;
|
|
165
245
|
export type LiveStreamingEvent = {
|
|
166
246
|
__typename?: 'LiveStreamingEvent';
|
|
167
247
|
account: Scalars['String'];
|
|
@@ -169,7 +249,9 @@ export type LiveStreamingEvent = {
|
|
|
169
249
|
eventName: Scalars['String'];
|
|
170
250
|
id: Scalars['String'];
|
|
171
251
|
recordVideoPath?: Maybe<Scalars['String']>;
|
|
252
|
+
recordVideoPathMp4?: Maybe<Scalars['String']>;
|
|
172
253
|
status: EventStatus;
|
|
254
|
+
thumbnails?: Maybe<Array<Scalars['String']>>;
|
|
173
255
|
thumbnailsPath?: Maybe<Scalars['String']>;
|
|
174
256
|
};
|
|
175
257
|
export type ManageCollectionProductInInput = {
|
|
@@ -185,12 +267,19 @@ export declare enum Methods {
|
|
|
185
267
|
export type Mutation = {
|
|
186
268
|
__typename?: 'Mutation';
|
|
187
269
|
appendProductsSnackVideo: RelateEntitySnackVideo;
|
|
270
|
+
createChatRoom: CreateChatRoomResult;
|
|
188
271
|
createCollection: CollectionResult;
|
|
189
272
|
createSnackVideos: CreateSnackVideoResult;
|
|
190
273
|
deleteAllCustomPlayer: CustomPlayerResult;
|
|
274
|
+
deleteChatMessage: DeleteChatMessageResult;
|
|
275
|
+
deleteChatRoom: CreateChatRoomResult;
|
|
191
276
|
deleteCollection: CollectionResult;
|
|
192
277
|
deleteRelationshipSnackVideo: RelateEntitySnackVideo;
|
|
278
|
+
deleteSnackVideo: RelateEntitySnackVideo;
|
|
193
279
|
manageCollectionProduct: CollectionResult;
|
|
280
|
+
pinChatMessage: PinChatMessageResult;
|
|
281
|
+
runVideoAnalyzer: RunVideoAnalyzerResult;
|
|
282
|
+
saveChatMessage: SaveChatMessageResult;
|
|
194
283
|
updateCollection: CollectionResult;
|
|
195
284
|
updateCustomPlayer: CustomPlayerResult;
|
|
196
285
|
updateProgressSnackVideo: UpdateProgressSnackVideosResult;
|
|
@@ -198,6 +287,9 @@ export type Mutation = {
|
|
|
198
287
|
export type MutationAppendProductsSnackVideoArgs = {
|
|
199
288
|
data: RelateToProductsSnackVideoInput;
|
|
200
289
|
};
|
|
290
|
+
export type MutationCreateChatRoomArgs = {
|
|
291
|
+
data: CreateChatRoomInput;
|
|
292
|
+
};
|
|
201
293
|
export type MutationCreateCollectionArgs = {
|
|
202
294
|
data: CreateCollectionInput;
|
|
203
295
|
};
|
|
@@ -207,15 +299,33 @@ export type MutationCreateSnackVideosArgs = {
|
|
|
207
299
|
export type MutationDeleteAllCustomPlayerArgs = {
|
|
208
300
|
data: CustomPlayerInputAccount;
|
|
209
301
|
};
|
|
302
|
+
export type MutationDeleteChatMessageArgs = {
|
|
303
|
+
data: DeleteChatInput;
|
|
304
|
+
};
|
|
305
|
+
export type MutationDeleteChatRoomArgs = {
|
|
306
|
+
data: CreateChatRoomInput;
|
|
307
|
+
};
|
|
210
308
|
export type MutationDeleteCollectionArgs = {
|
|
211
309
|
data: QueryInput;
|
|
212
310
|
};
|
|
213
311
|
export type MutationDeleteRelationshipSnackVideoArgs = {
|
|
214
312
|
data: SnackVideoRelationshipKeys;
|
|
215
313
|
};
|
|
314
|
+
export type MutationDeleteSnackVideoArgs = {
|
|
315
|
+
data: DeleteSnackVideoInput;
|
|
316
|
+
};
|
|
216
317
|
export type MutationManageCollectionProductArgs = {
|
|
217
318
|
data: ManageCollectionProductInInput;
|
|
218
319
|
};
|
|
320
|
+
export type MutationPinChatMessageArgs = {
|
|
321
|
+
data: PinChatInput;
|
|
322
|
+
};
|
|
323
|
+
export type MutationRunVideoAnalyzerArgs = {
|
|
324
|
+
data: RunVideoAnalyzerInput;
|
|
325
|
+
};
|
|
326
|
+
export type MutationSaveChatMessageArgs = {
|
|
327
|
+
data: SaveChatInput;
|
|
328
|
+
};
|
|
219
329
|
export type MutationUpdateCollectionArgs = {
|
|
220
330
|
data: UpdateCollectionInput;
|
|
221
331
|
};
|
|
@@ -225,6 +335,19 @@ export type MutationUpdateCustomPlayerArgs = {
|
|
|
225
335
|
export type MutationUpdateProgressSnackVideoArgs = {
|
|
226
336
|
data: UpdateProgressSnackVideosInput;
|
|
227
337
|
};
|
|
338
|
+
export type PinChatInput = {
|
|
339
|
+
account: Scalars['String'];
|
|
340
|
+
data: Scalars['String'];
|
|
341
|
+
idEvent: Scalars['String'];
|
|
342
|
+
pin: Scalars['Boolean'];
|
|
343
|
+
sessionId: Scalars['String'];
|
|
344
|
+
username: Scalars['String'];
|
|
345
|
+
};
|
|
346
|
+
export type PinChatMessageResult = ErrorGeneral | PinChatMessageSuccess;
|
|
347
|
+
export type PinChatMessageSuccess = {
|
|
348
|
+
__typename?: 'PinChatMessageSuccess';
|
|
349
|
+
message: Scalars['String'];
|
|
350
|
+
};
|
|
228
351
|
export type Product = {
|
|
229
352
|
__typename?: 'Product';
|
|
230
353
|
account: Scalars['String'];
|
|
@@ -243,9 +366,11 @@ export type Query = {
|
|
|
243
366
|
findCollection: CollectionResult;
|
|
244
367
|
findEvent: FindEventResult;
|
|
245
368
|
findManySnackVideos: FindManySnackVideoResult;
|
|
369
|
+
getAllChatMessage: GetAllChatMessageResult;
|
|
246
370
|
getAllCollection: CollectionResultArray;
|
|
247
371
|
getAllCustomPlayer: CustomPlayerResultArray;
|
|
248
372
|
getAllSnackVideos: SnackVideoGetAll;
|
|
373
|
+
getChatRoomToken: GetChatRoomTokenResult;
|
|
249
374
|
getRelationshipSnackVideos: RelationshipSnackVideoArrayResponse;
|
|
250
375
|
searchCollection: CollectionResultArray;
|
|
251
376
|
searchEvent: SearchEventResult;
|
|
@@ -263,6 +388,9 @@ export type QueryFindEventArgs = {
|
|
|
263
388
|
export type QueryFindManySnackVideosArgs = {
|
|
264
389
|
data: FindManySnackVideoInput;
|
|
265
390
|
};
|
|
391
|
+
export type QueryGetAllChatMessageArgs = {
|
|
392
|
+
data: GetAllChatMessageInput;
|
|
393
|
+
};
|
|
266
394
|
export type QueryGetAllCollectionArgs = {
|
|
267
395
|
data: QueryInput;
|
|
268
396
|
};
|
|
@@ -272,6 +400,9 @@ export type QueryGetAllCustomPlayerArgs = {
|
|
|
272
400
|
export type QueryGetAllSnackVideosArgs = {
|
|
273
401
|
data: QueryInput;
|
|
274
402
|
};
|
|
403
|
+
export type QueryGetChatRoomTokenArgs = {
|
|
404
|
+
data: GetChatRoomInput;
|
|
405
|
+
};
|
|
275
406
|
export type QueryGetRelationshipSnackVideosArgs = {
|
|
276
407
|
data: SnackVideoRelationshipInput;
|
|
277
408
|
};
|
|
@@ -288,6 +419,7 @@ export type QueryInput = {
|
|
|
288
419
|
account: Scalars['String'];
|
|
289
420
|
cursor?: InputMaybe<Scalars['JSON']>;
|
|
290
421
|
id?: InputMaybe<Scalars['String']>;
|
|
422
|
+
includeTotal?: InputMaybe<Scalars['Boolean']>;
|
|
291
423
|
limit?: InputMaybe<Scalars['Float']>;
|
|
292
424
|
page?: InputMaybe<Scalars['Float']>;
|
|
293
425
|
search?: InputMaybe<Scalars['String']>;
|
|
@@ -320,10 +452,38 @@ export type RelationshipSnackVideoArray = {
|
|
|
320
452
|
path?: Maybe<Scalars['String']>;
|
|
321
453
|
};
|
|
322
454
|
export type RelationshipSnackVideoArrayResponse = ErrorGeneral | RelationshipSnackVideoArray;
|
|
455
|
+
export type RunVideoAnalyzerInput = {
|
|
456
|
+
account: Scalars['String'];
|
|
457
|
+
idEvent: Scalars['String'];
|
|
458
|
+
};
|
|
459
|
+
export type RunVideoAnalyzerMessageSuccess = {
|
|
460
|
+
__typename?: 'RunVideoAnalyzerMessageSuccess';
|
|
461
|
+
message: Scalars['String'];
|
|
462
|
+
};
|
|
463
|
+
export type RunVideoAnalyzerResult = ErrorGeneral | RunVideoAnalyzerMessageSuccess;
|
|
464
|
+
export type SaveChatInput = {
|
|
465
|
+
account: Scalars['String'];
|
|
466
|
+
connectionId: Scalars['String'];
|
|
467
|
+
data: Scalars['String'];
|
|
468
|
+
email: Scalars['String'];
|
|
469
|
+
id: Scalars['String'];
|
|
470
|
+
idEvent: Scalars['String'];
|
|
471
|
+
isAdmin?: InputMaybe<Scalars['Boolean']>;
|
|
472
|
+
sendDate: Scalars['String'];
|
|
473
|
+
sessionId: Scalars['String'];
|
|
474
|
+
type: Scalars['String'];
|
|
475
|
+
username: Scalars['String'];
|
|
476
|
+
};
|
|
477
|
+
export type SaveChatMessageResult = ErrorGeneral | SaveChatMessageSuccess;
|
|
478
|
+
export type SaveChatMessageSuccess = {
|
|
479
|
+
__typename?: 'SaveChatMessageSuccess';
|
|
480
|
+
message: Scalars['String'];
|
|
481
|
+
};
|
|
323
482
|
export type SearchEventInput = {
|
|
324
483
|
account: Scalars['String'];
|
|
325
484
|
cursor?: InputMaybe<Scalars['JSON']>;
|
|
326
485
|
id?: InputMaybe<Scalars['String']>;
|
|
486
|
+
includeTotal?: InputMaybe<Scalars['Boolean']>;
|
|
327
487
|
limit?: InputMaybe<Scalars['Float']>;
|
|
328
488
|
page?: InputMaybe<Scalars['Float']>;
|
|
329
489
|
search: Scalars['String'];
|
|
@@ -334,6 +494,7 @@ export type SearchInput = {
|
|
|
334
494
|
account: Scalars['String'];
|
|
335
495
|
cursor?: InputMaybe<Scalars['JSON']>;
|
|
336
496
|
id?: InputMaybe<Scalars['String']>;
|
|
497
|
+
includeTotal?: InputMaybe<Scalars['Boolean']>;
|
|
337
498
|
limit?: InputMaybe<Scalars['Float']>;
|
|
338
499
|
page?: InputMaybe<Scalars['Float']>;
|
|
339
500
|
search: Scalars['String'];
|
|
@@ -372,6 +533,7 @@ export type SnackVideoCreatedWithCursor = {
|
|
|
372
533
|
__typename?: 'SnackVideoCreatedWithCursor';
|
|
373
534
|
cursor?: Maybe<Scalars['JSON']>;
|
|
374
535
|
snackVideos?: Maybe<Array<SnackVideosCreated>>;
|
|
536
|
+
totalItems?: Maybe<Scalars['Float']>;
|
|
375
537
|
};
|
|
376
538
|
export type SnackVideoGetAll = ErrorGeneral | SnackVideoCreatedArray;
|
|
377
539
|
export type SnackVideoRelationshipInput = {
|
|
@@ -480,6 +642,78 @@ export type UpdateCustomizationMutation = {
|
|
|
480
642
|
timestamp: string;
|
|
481
643
|
};
|
|
482
644
|
};
|
|
645
|
+
export type DeleteChatMessageMutationVariables = Exact<{
|
|
646
|
+
data: DeleteChatInput;
|
|
647
|
+
}>;
|
|
648
|
+
export type DeleteChatMessageMutation = {
|
|
649
|
+
__typename?: 'Mutation';
|
|
650
|
+
deleteChatMessage: {
|
|
651
|
+
__typename: 'DeleteChatMessageSuccess';
|
|
652
|
+
message: string;
|
|
653
|
+
} | {
|
|
654
|
+
__typename: 'ErrorGeneral';
|
|
655
|
+
message: string;
|
|
656
|
+
};
|
|
657
|
+
};
|
|
658
|
+
export type GetAllChatMessageQueryVariables = Exact<{
|
|
659
|
+
data: GetAllChatMessageInput;
|
|
660
|
+
}>;
|
|
661
|
+
export type GetAllChatMessageQuery = {
|
|
662
|
+
__typename?: 'Query';
|
|
663
|
+
getAllChatMessage: {
|
|
664
|
+
__typename: 'ChatMessageArray';
|
|
665
|
+
data?: Array<{
|
|
666
|
+
__typename?: 'ChatMessage';
|
|
667
|
+
account: string;
|
|
668
|
+
connectionId?: string | null;
|
|
669
|
+
data: string;
|
|
670
|
+
email?: string | null;
|
|
671
|
+
id: string;
|
|
672
|
+
idEvent: string;
|
|
673
|
+
sendDate?: string | null;
|
|
674
|
+
sessionId?: string | null;
|
|
675
|
+
type?: string | null;
|
|
676
|
+
username?: string | null;
|
|
677
|
+
isAdmin?: boolean | null;
|
|
678
|
+
}> | null;
|
|
679
|
+
} | {
|
|
680
|
+
__typename: 'ErrorGeneral';
|
|
681
|
+
message: string;
|
|
682
|
+
statusCode: string;
|
|
683
|
+
timestamp: string;
|
|
684
|
+
};
|
|
685
|
+
};
|
|
686
|
+
export type GetChatRoomTokenQueryVariables = Exact<{
|
|
687
|
+
data: GetChatRoomInput;
|
|
688
|
+
}>;
|
|
689
|
+
export type GetChatRoomTokenQuery = {
|
|
690
|
+
__typename?: 'Query';
|
|
691
|
+
getChatRoomToken: {
|
|
692
|
+
__typename: 'ChatRoomTokenData';
|
|
693
|
+
data?: {
|
|
694
|
+
__typename?: 'ChatRoomToken';
|
|
695
|
+
token: string;
|
|
696
|
+
} | null;
|
|
697
|
+
} | {
|
|
698
|
+
__typename: 'ErrorGeneral';
|
|
699
|
+
message: string;
|
|
700
|
+
statusCode: string;
|
|
701
|
+
timestamp: string;
|
|
702
|
+
};
|
|
703
|
+
};
|
|
704
|
+
export type PinChatMessageMutationVariables = Exact<{
|
|
705
|
+
data: PinChatInput;
|
|
706
|
+
}>;
|
|
707
|
+
export type PinChatMessageMutation = {
|
|
708
|
+
__typename?: 'Mutation';
|
|
709
|
+
pinChatMessage: {
|
|
710
|
+
__typename: 'ErrorGeneral';
|
|
711
|
+
message: string;
|
|
712
|
+
} | {
|
|
713
|
+
__typename: 'PinChatMessageSuccess';
|
|
714
|
+
message: string;
|
|
715
|
+
};
|
|
716
|
+
};
|
|
483
717
|
export type AddCollectionMutationVariables = Exact<{
|
|
484
718
|
data: CreateCollectionInput;
|
|
485
719
|
}>;
|
|
@@ -666,6 +900,7 @@ export type FindMinimalEventQuery = {
|
|
|
666
900
|
recordVideoPath?: string | null;
|
|
667
901
|
createdAt: string;
|
|
668
902
|
status: EventStatus;
|
|
903
|
+
thumbnails?: Array<string> | null;
|
|
669
904
|
} | null;
|
|
670
905
|
};
|
|
671
906
|
};
|
|
@@ -740,6 +975,19 @@ export type DeleteRelationshipWithSnackVideoMutation = {
|
|
|
740
975
|
statusCode: string;
|
|
741
976
|
};
|
|
742
977
|
};
|
|
978
|
+
export type DeleteSnackVideoMutationVariables = Exact<{
|
|
979
|
+
data: DeleteSnackVideoInput;
|
|
980
|
+
}>;
|
|
981
|
+
export type DeleteSnackVideoMutation = {
|
|
982
|
+
__typename?: 'Mutation';
|
|
983
|
+
deleteSnackVideo: {
|
|
984
|
+
__typename: 'ActionSnackVideoSuccess';
|
|
985
|
+
message: string;
|
|
986
|
+
} | {
|
|
987
|
+
__typename: 'ErrorGeneral';
|
|
988
|
+
message: string;
|
|
989
|
+
};
|
|
990
|
+
};
|
|
743
991
|
export type FindManySnackVideosQueryVariables = Exact<{
|
|
744
992
|
data: FindManySnackVideoInput;
|
|
745
993
|
}>;
|
|
@@ -781,6 +1029,7 @@ export type GetAllSnackVideosQuery = {
|
|
|
781
1029
|
data?: {
|
|
782
1030
|
__typename?: 'SnackVideoCreatedWithCursor';
|
|
783
1031
|
cursor?: any | null;
|
|
1032
|
+
totalItems?: number | null;
|
|
784
1033
|
snackVideos?: Array<{
|
|
785
1034
|
__typename?: 'SnackVideosCreated';
|
|
786
1035
|
id: string;
|
|
@@ -828,6 +1077,7 @@ export type SearchSnackVideosQuery = {
|
|
|
828
1077
|
data?: {
|
|
829
1078
|
__typename?: 'SnackVideoCreatedWithCursor';
|
|
830
1079
|
cursor?: any | null;
|
|
1080
|
+
totalItems?: number | null;
|
|
831
1081
|
snackVideos?: Array<{
|
|
832
1082
|
__typename?: 'SnackVideosCreated';
|
|
833
1083
|
id: string;
|
|
@@ -875,6 +1125,18 @@ export declare const GetAllCustomizationDocument: DocumentNode<GetAllCustomizati
|
|
|
875
1125
|
export declare const UpdateCustomizationDocument: DocumentNode<UpdateCustomizationMutation, Exact<{
|
|
876
1126
|
data: CustomPlayerInput;
|
|
877
1127
|
}>>;
|
|
1128
|
+
export declare const DeleteChatMessageDocument: DocumentNode<DeleteChatMessageMutation, Exact<{
|
|
1129
|
+
data: DeleteChatInput;
|
|
1130
|
+
}>>;
|
|
1131
|
+
export declare const GetAllChatMessageDocument: DocumentNode<GetAllChatMessageQuery, Exact<{
|
|
1132
|
+
data: GetAllChatMessageInput;
|
|
1133
|
+
}>>;
|
|
1134
|
+
export declare const GetChatRoomTokenDocument: DocumentNode<GetChatRoomTokenQuery, Exact<{
|
|
1135
|
+
data: GetChatRoomInput;
|
|
1136
|
+
}>>;
|
|
1137
|
+
export declare const PinChatMessageDocument: DocumentNode<PinChatMessageMutation, Exact<{
|
|
1138
|
+
data: PinChatInput;
|
|
1139
|
+
}>>;
|
|
878
1140
|
export declare const AddCollectionDocument: DocumentNode<AddCollectionMutation, Exact<{
|
|
879
1141
|
data: CreateCollectionInput;
|
|
880
1142
|
}>>;
|
|
@@ -911,6 +1173,9 @@ export declare const CreateSnackVideoBatchDocument: DocumentNode<CreateSnackVide
|
|
|
911
1173
|
export declare const DeleteRelationshipWithSnackVideoDocument: DocumentNode<DeleteRelationshipWithSnackVideoMutation, Exact<{
|
|
912
1174
|
data: SnackVideoRelationshipKeys;
|
|
913
1175
|
}>>;
|
|
1176
|
+
export declare const DeleteSnackVideoDocument: DocumentNode<DeleteSnackVideoMutation, Exact<{
|
|
1177
|
+
data: DeleteSnackVideoInput;
|
|
1178
|
+
}>>;
|
|
914
1179
|
export declare const FindManySnackVideosDocument: DocumentNode<FindManySnackVideosQuery, Exact<{
|
|
915
1180
|
data: FindManySnackVideoInput;
|
|
916
1181
|
}>>;
|
package/dist/lib/types/api.d.ts
CHANGED
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
export interface ChatMessageBase {
|
|
2
|
+
id: string;
|
|
3
|
+
account: string;
|
|
4
|
+
idEvent: string;
|
|
5
|
+
sessionId?: string;
|
|
6
|
+
username: string;
|
|
7
|
+
fingerprint: string;
|
|
8
|
+
type?: string;
|
|
9
|
+
color?: string;
|
|
10
|
+
second?: number;
|
|
11
|
+
email?: string;
|
|
12
|
+
all?: boolean;
|
|
13
|
+
}
|
|
14
|
+
export interface ChatQuestion {
|
|
15
|
+
data: string;
|
|
16
|
+
username: string;
|
|
17
|
+
type?: string;
|
|
18
|
+
}
|
|
19
|
+
export interface ChatMessage extends ChatMessageBase {
|
|
20
|
+
id: string;
|
|
21
|
+
sendDate: string;
|
|
22
|
+
data: string;
|
|
23
|
+
action: string;
|
|
24
|
+
isAdmin?: boolean;
|
|
25
|
+
isResponse?: boolean;
|
|
26
|
+
responseData?: string;
|
|
27
|
+
question?: ChatQuestion;
|
|
28
|
+
}
|
|
@@ -12,11 +12,11 @@ export interface ApiV2Response<T = any> {
|
|
|
12
12
|
duration: string;
|
|
13
13
|
method: 'GET' | 'POST' | 'PUT' | 'DELETE';
|
|
14
14
|
}
|
|
15
|
-
export type Primitive = string | boolean | number;
|
|
16
15
|
export interface CustomFetchConfig extends RequestInit {
|
|
17
16
|
url: RequestInfo;
|
|
18
17
|
raw?: boolean;
|
|
19
18
|
contentTypeJson?: boolean;
|
|
19
|
+
timeout?: number;
|
|
20
20
|
}
|
|
21
21
|
export type Environment<T> = typeof environment & T;
|
|
22
22
|
export type RequiredKeys<T> = {
|
|
@@ -1,5 +1,10 @@
|
|
|
1
1
|
import { CustomFetchConfig } from '../types';
|
|
2
|
-
export declare function customFetch<T = any>(config: CustomFetchConfig
|
|
2
|
+
export declare function customFetch<T = any>(config: CustomFetchConfig & {
|
|
3
|
+
raw?: false;
|
|
4
|
+
}): Promise<T>;
|
|
5
|
+
export declare function customFetch(config: CustomFetchConfig & {
|
|
6
|
+
raw: true;
|
|
7
|
+
}): Promise<Response>;
|
|
3
8
|
declare interface ApiCall {
|
|
4
9
|
url: string;
|
|
5
10
|
method?: string;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/// <reference types="node" />
|
|
2
|
+
/// <reference types="node" />
|
|
3
|
+
/// <reference types="node" />
|
|
4
|
+
/// <reference types="node" />
|
|
5
|
+
export declare function downloadFile(filename: string, url: string, ext: string): void;
|
|
6
|
+
export declare const jsDownload: (data: Blob, filename: string, mime?: string) => boolean | NodeJS.Timeout;
|
|
@@ -1,3 +1,20 @@
|
|
|
1
|
-
import { Primitive } from '../types';
|
|
2
1
|
export declare const shortId: (length?: number) => string;
|
|
3
|
-
|
|
2
|
+
/**
|
|
3
|
+
* Constructs a search parameter string from a given object of key-value pairs.
|
|
4
|
+
*
|
|
5
|
+
* @param {Record<string, any>} params - The object containing key-value pairs.
|
|
6
|
+
* @returns {string} The search parameter string formatted as '?key1=value1&key2=value2&key3=value3', or an empty string if no valid parameters are provided.
|
|
7
|
+
*
|
|
8
|
+
* @example
|
|
9
|
+
* const params = {
|
|
10
|
+
* key1: 'value1',
|
|
11
|
+
* key2: 'value2',
|
|
12
|
+
* key3: undefined,
|
|
13
|
+
* key4: 'value4'
|
|
14
|
+
* };
|
|
15
|
+
*
|
|
16
|
+
* const searchParamString = searchParams(params);
|
|
17
|
+
* console.log(searchParamString); // Output: "?key1=value1&key2=value2&key4=value4"
|
|
18
|
+
*/
|
|
19
|
+
export declare const searchParams: (params: Record<string, any>) => string;
|
|
20
|
+
export declare function fileOrigin(): string;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import log from 'loglevel';
|
|
2
|
+
type Logger = log.Logger;
|
|
3
|
+
export declare const logger: log.Logger;
|
|
4
|
+
/**
|
|
5
|
+
* Create a LogLevel instance for given context
|
|
6
|
+
* @param {string} context - The context to create logger for
|
|
7
|
+
* @returns {Logger} LogLevel logger instance
|
|
8
|
+
*/
|
|
9
|
+
export declare function createLogger(context: string): Logger;
|
|
10
|
+
/**
|
|
11
|
+
* Register a logger instance in registry
|
|
12
|
+
* @param {string} context - The context of the logger to register
|
|
13
|
+
* @param {Logger} logger - The logger instance
|
|
14
|
+
*/
|
|
15
|
+
export declare function registerLogger(context: string, logger: Logger): void;
|
|
16
|
+
/**
|
|
17
|
+
* Get a logger instance from registry by context
|
|
18
|
+
* @param {string} context - The context to get the logger for
|
|
19
|
+
* @returns {Logger} The registered LogLevel logger
|
|
20
|
+
*/
|
|
21
|
+
export declare function getLogger(context: string): Logger;
|
|
22
|
+
/**
|
|
23
|
+
* Initialize a logger - create, register and return instance
|
|
24
|
+
* @param {string} context - The context to initialize logger for
|
|
25
|
+
* @returns {Logger} The initialized LogLevel logger instance
|
|
26
|
+
*/
|
|
27
|
+
export declare function initializeLogger(context: string): Logger;
|
|
28
|
+
export {};
|
package/dist/package.json
CHANGED