@tivio/sdk-react 3.6.1 → 3.6.2
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/README.md +3 -0
- package/README.md.bak +3 -0
- package/dist/index.d.ts +309 -92
- package/dist/index.js +2 -1
- package/dist/index.js.LICENSE.txt +347 -0
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
@@ -6,6 +6,38 @@ import { OrderByDirection } from '@firebase/firestore-types';
|
|
6
6
|
import { default as React_2 } from 'react';
|
7
7
|
import { WhereFilterOp } from '@firebase/firestore-types';
|
8
8
|
|
9
|
+
export declare interface AdExternal {
|
10
|
+
/**
|
11
|
+
* Can user seek out of it?
|
12
|
+
*/
|
13
|
+
canSeek: boolean;
|
14
|
+
/**
|
15
|
+
* Can it be skipped right now?
|
16
|
+
*/
|
17
|
+
canSkip: boolean;
|
18
|
+
durationMs: number;
|
19
|
+
/**
|
20
|
+
* Is it skippable in general?
|
21
|
+
*/
|
22
|
+
isSkippable: boolean;
|
23
|
+
order: number | null;
|
24
|
+
secondsToSkippable: number | null;
|
25
|
+
/**
|
26
|
+
* Countdown for un-skippable ads
|
27
|
+
*/
|
28
|
+
secondsToEnd: number;
|
29
|
+
skipDelayMs: number | null;
|
30
|
+
/**
|
31
|
+
* How many ads are there in total
|
32
|
+
*/
|
33
|
+
totalCount: number | null;
|
34
|
+
click: () => void;
|
35
|
+
/**
|
36
|
+
* @private
|
37
|
+
*/
|
38
|
+
skip: () => void;
|
39
|
+
}
|
40
|
+
|
9
41
|
declare type AdSegment = {
|
10
42
|
id: string;
|
11
43
|
/**
|
@@ -74,15 +106,15 @@ export declare enum ALGOLIA_INDEX_NAME {
|
|
74
106
|
USERS = "users"
|
75
107
|
}
|
76
108
|
|
77
|
-
declare interface Asset {
|
109
|
+
export declare interface Asset {
|
78
110
|
background: string;
|
79
111
|
}
|
80
112
|
|
81
|
-
declare type Assets = {
|
113
|
+
export declare type Assets = {
|
82
114
|
[assetName: string]: ScalableAsset;
|
83
115
|
};
|
84
116
|
|
85
|
-
declare type AuthOverlayPayload = {
|
117
|
+
export declare type AuthOverlayPayload = {
|
86
118
|
prefilledData?: {
|
87
119
|
email: string;
|
88
120
|
};
|
@@ -93,25 +125,52 @@ declare type AuthOverlayPayload = {
|
|
93
125
|
redirectAfterSubmit?: ((...args: any[]) => void) | null;
|
94
126
|
};
|
95
127
|
|
96
|
-
declare type AuthOverlayState = {
|
128
|
+
export declare type AuthOverlayState = {
|
97
129
|
type: AuthOverlayType;
|
98
130
|
closeAuthOverlay: () => void;
|
99
131
|
openAuthOverlay: (type: AuthOverlayType, payload?: AuthOverlayPayload) => void;
|
100
132
|
payload?: AuthOverlayPayload | null;
|
101
133
|
};
|
102
134
|
|
103
|
-
declare type AuthOverlayType = 'login' | 'registration' | 'closed' | 'reset-password';
|
135
|
+
export declare type AuthOverlayType = 'login' | 'registration' | 'closed' | 'reset-password';
|
104
136
|
|
105
|
-
declare interface AvailableSeason {
|
137
|
+
export declare interface AvailableSeason {
|
106
138
|
seasonNumber: number;
|
107
139
|
}
|
108
140
|
|
141
|
+
export declare type AvatarProps = {
|
142
|
+
cover?: string;
|
143
|
+
isLoading?: boolean;
|
144
|
+
size?: number;
|
145
|
+
};
|
146
|
+
|
109
147
|
export declare type BadRequestError = Error & {
|
110
148
|
details?: {
|
111
149
|
reason?: 'DOES_NOT_EXIST' | 'EXPIRED' | 'ALREADY_USED';
|
112
150
|
};
|
113
151
|
};
|
114
152
|
|
153
|
+
export declare type BannerProps = {
|
154
|
+
isLoading: boolean;
|
155
|
+
text: string;
|
156
|
+
focused: boolean;
|
157
|
+
onClick?: () => void;
|
158
|
+
hoverable: boolean;
|
159
|
+
broadcastInfo: string;
|
160
|
+
coverPadding: CoverPadding;
|
161
|
+
cover: string;
|
162
|
+
fullWidth: boolean;
|
163
|
+
height: number;
|
164
|
+
width: number;
|
165
|
+
overlay: boolean;
|
166
|
+
price: string;
|
167
|
+
hasRoundCorners: boolean;
|
168
|
+
buttonText?: string;
|
169
|
+
onButtonClick?: () => void;
|
170
|
+
};
|
171
|
+
|
172
|
+
export declare type BannerPropsPartial = Partial<BannerProps>;
|
173
|
+
|
115
174
|
export declare type BetOffer = {
|
116
175
|
betService: string;
|
117
176
|
league: string;
|
@@ -130,18 +189,15 @@ export declare type BetOffer = {
|
|
130
189
|
*/
|
131
190
|
export declare const bundlePromise: Promise<RemoteBundleState>;
|
132
191
|
|
133
|
-
export declare
|
192
|
+
export declare interface Channel {
|
134
193
|
id: string;
|
135
194
|
name: string;
|
136
195
|
header: string;
|
137
196
|
headerLogo: string;
|
138
197
|
recentVideos: Video[];
|
139
|
-
};
|
140
|
-
|
141
|
-
declare interface Channel_2 {
|
142
198
|
}
|
143
199
|
|
144
|
-
export declare const ChannelsContext: React_2.Context<DataState<
|
200
|
+
export declare const ChannelsContext: React_2.Context<DataState<Channel>>;
|
145
201
|
|
146
202
|
export declare type ChannelSource = {
|
147
203
|
new (uri: string, originalOptions: Record<string, any>, channelName: string, programName: string, programDescription: string, from: Date, to: Date): ChannelSource;
|
@@ -157,18 +213,6 @@ export declare type ChannelSource = {
|
|
157
213
|
} | null;
|
158
214
|
};
|
159
215
|
|
160
|
-
declare interface ChannelSource_2 {
|
161
|
-
type: 'ChannelSource';
|
162
|
-
uri: string;
|
163
|
-
originalOptions: any;
|
164
|
-
channelName: string;
|
165
|
-
programName: string;
|
166
|
-
programDescription: string;
|
167
|
-
from: Date;
|
168
|
-
to: Date;
|
169
|
-
poster?: string;
|
170
|
-
}
|
171
|
-
|
172
216
|
export declare interface ChannelSourcePojo {
|
173
217
|
type: 'ChannelSource';
|
174
218
|
uri: string;
|
@@ -192,7 +236,7 @@ export declare type Config = Pick<InternalConfig, 'bundleUrlOverride' | 'currenc
|
|
192
236
|
runFeatureSupportCheck?: boolean;
|
193
237
|
};
|
194
238
|
|
195
|
-
declare type CoverPadding = {
|
239
|
+
export declare type CoverPadding = {
|
196
240
|
top?: number;
|
197
241
|
bottom?: number;
|
198
242
|
left?: number;
|
@@ -208,7 +252,9 @@ export declare const createRemotePackageLoader: () => (secret: string, conf: Int
|
|
208
252
|
|
209
253
|
export declare const createUseRemoteBundle: () => (conf: InternalConfig) => RemoteBundleState;
|
210
254
|
|
211
|
-
declare type CreateUserWithEmailAndPassword = (email: string, password: string, username?: string, referralToken?: string) => Promise<string | null>;
|
255
|
+
export declare type CreateUserWithEmailAndPassword = (email: string, password: string, username?: string, referralToken?: string) => Promise<string | null>;
|
256
|
+
|
257
|
+
export declare const CURRENCIES: string[];
|
212
258
|
|
213
259
|
export declare type Currency = 'CZK' | 'EUR' | 'USD';
|
214
260
|
|
@@ -228,9 +274,14 @@ declare interface DataState<T> {
|
|
228
274
|
setData: (key: string, data: HookData<T>) => void;
|
229
275
|
}
|
230
276
|
|
231
|
-
declare
|
277
|
+
export declare const DEFAULT_ORDER_BY: {
|
278
|
+
field: DefaultOrderByField;
|
279
|
+
directionStr: OrderByDirection;
|
280
|
+
}[];
|
281
|
+
|
282
|
+
export declare type DefaultOrderByField = 'created';
|
232
283
|
|
233
|
-
declare type DetailedPrice = {
|
284
|
+
export declare type DetailedPrice = {
|
234
285
|
amount: number;
|
235
286
|
currency: Currency;
|
236
287
|
frequency?: MONETIZATION_FREQUENCY;
|
@@ -240,7 +291,12 @@ export declare type Disposer = () => void;
|
|
240
291
|
|
241
292
|
declare type Disposer_2 = () => void;
|
242
293
|
|
243
|
-
declare type
|
294
|
+
export declare type DividerProps = {
|
295
|
+
verticalSpacing?: number;
|
296
|
+
horizontalSpacing?: number;
|
297
|
+
};
|
298
|
+
|
299
|
+
export declare type DocumentOptions = Partial<{
|
244
300
|
lazyLoading: boolean;
|
245
301
|
subscribeOnChanges: boolean;
|
246
302
|
}>;
|
@@ -284,6 +340,50 @@ declare interface HookData<T> {
|
|
284
340
|
isLoading: boolean;
|
285
341
|
}
|
286
342
|
|
343
|
+
export declare interface IndexedObject {
|
344
|
+
objectID: string;
|
345
|
+
path: string;
|
346
|
+
}
|
347
|
+
|
348
|
+
export declare interface IndexedTag extends IndexedObject {
|
349
|
+
tagId: string;
|
350
|
+
tagTypePath?: string;
|
351
|
+
organizationPath: string;
|
352
|
+
created: Date;
|
353
|
+
name: Translation;
|
354
|
+
description?: string;
|
355
|
+
}
|
356
|
+
|
357
|
+
export declare interface IndexedTvChannel extends IndexedObject {
|
358
|
+
channelKey: string;
|
359
|
+
created: Date;
|
360
|
+
filters: string[];
|
361
|
+
name: string;
|
362
|
+
organizationPath: string;
|
363
|
+
}
|
364
|
+
|
365
|
+
export declare interface IndexedUser extends IndexedObject {
|
366
|
+
authUserId: string;
|
367
|
+
type: string;
|
368
|
+
externalUserId?: string;
|
369
|
+
email?: string;
|
370
|
+
organizationPath?: string;
|
371
|
+
}
|
372
|
+
|
373
|
+
export declare interface IndexedVideo extends IndexedObject {
|
374
|
+
organizationPath?: string;
|
375
|
+
tagPaths?: string[];
|
376
|
+
created: Date;
|
377
|
+
isDraft: boolean;
|
378
|
+
type: VideoType;
|
379
|
+
contentType?: VideoContentType;
|
380
|
+
name: string;
|
381
|
+
description: string;
|
382
|
+
hide: boolean;
|
383
|
+
isDuplicate: boolean;
|
384
|
+
externals?: VideoExternals;
|
385
|
+
}
|
386
|
+
|
287
387
|
export declare type InputSource = AdSource | ChannelSource | VodTivioSource | VodExternalSource;
|
288
388
|
|
289
389
|
export declare type InternalConfig = {
|
@@ -332,12 +432,17 @@ export declare type InternalConfig = {
|
|
332
432
|
forceCloudFnResolver?: boolean;
|
333
433
|
};
|
334
434
|
|
435
|
+
export declare type InternalTvConfig = {
|
436
|
+
logo: string;
|
437
|
+
screens: ScreenConfig[];
|
438
|
+
};
|
439
|
+
|
335
440
|
declare interface IntroMarker {
|
336
441
|
marker: Marker;
|
337
442
|
skip: () => void;
|
338
443
|
}
|
339
444
|
|
340
|
-
declare type ItemsInRow = Tag | Video | TvChannel;
|
445
|
+
export declare type ItemsInRow = Tag | Video | TvChannel;
|
341
446
|
|
342
447
|
/**
|
343
448
|
* Enum of all supported languages codes as in ISO 639-1
|
@@ -352,7 +457,17 @@ export declare enum LangCode {
|
|
352
457
|
SP = "sp"
|
353
458
|
}
|
354
459
|
|
355
|
-
|
460
|
+
/**
|
461
|
+
* All supported languages codes as in ISO 639-1
|
462
|
+
*/
|
463
|
+
export declare const languages: LangCode[];
|
464
|
+
|
465
|
+
/**
|
466
|
+
* Possible language key of all supported language mutations.
|
467
|
+
*/
|
468
|
+
export declare type LanguageType = `${LangCode}`;
|
469
|
+
|
470
|
+
export declare type LinkedVideo = {
|
356
471
|
video: Video;
|
357
472
|
type: 'CUT' | 'TRAILER' | 'BONUS' | 'CHILD';
|
358
473
|
};
|
@@ -397,7 +512,7 @@ export declare interface Monetization {
|
|
397
512
|
localizedBenefits?: string[];
|
398
513
|
}
|
399
514
|
|
400
|
-
declare enum MONETIZATION_FREQUENCY {
|
515
|
+
export declare enum MONETIZATION_FREQUENCY {
|
401
516
|
ONE_TIME_PAYMENT = "ONE_TIME_PAYMENT",
|
402
517
|
DAILY = "DAILY",
|
403
518
|
WEEKLY = "WEEKLY",
|
@@ -405,7 +520,7 @@ declare enum MONETIZATION_FREQUENCY {
|
|
405
520
|
ANNUALLY = "ANNUALLY"
|
406
521
|
}
|
407
522
|
|
408
|
-
declare type MonetizationType = 'advertisement' | 'transaction' | 'subscription';
|
523
|
+
export declare type MonetizationType = 'advertisement' | 'transaction' | 'subscription';
|
409
524
|
|
410
525
|
/**
|
411
526
|
* TODO: Duplicate, because we can't import types from core-js.
|
@@ -418,25 +533,30 @@ export declare type Nullable<T> = {
|
|
418
533
|
[P in keyof T]: T[P] | null;
|
419
534
|
};
|
420
535
|
|
421
|
-
declare
|
536
|
+
export declare type ObjectType = Record<string, any>;
|
537
|
+
|
538
|
+
export declare interface OrderBy {
|
422
539
|
field: string;
|
423
540
|
directionStr?: OrderByDirection;
|
424
541
|
}
|
425
542
|
|
543
|
+
export declare interface Organization {
|
544
|
+
}
|
545
|
+
|
426
546
|
declare type PaginationData<T> = {
|
427
547
|
items: T[];
|
428
548
|
hasNextPage: boolean;
|
429
549
|
fetchMore: Function;
|
430
550
|
};
|
431
551
|
|
432
|
-
declare type PaginationInterface<Entity> = {
|
552
|
+
export declare type PaginationInterface<Entity> = {
|
433
553
|
items: Entity[];
|
434
554
|
fetchMore: () => void;
|
435
555
|
hasNextPage?: boolean;
|
436
556
|
loading?: boolean;
|
437
557
|
};
|
438
558
|
|
439
|
-
declare type PaginationOptions = Partial<{
|
559
|
+
export declare type PaginationOptions = Partial<{
|
440
560
|
limit: number;
|
441
561
|
noLimit: boolean;
|
442
562
|
}>;
|
@@ -575,14 +695,6 @@ export declare interface PubSub {
|
|
575
695
|
}
|
576
696
|
|
577
697
|
export declare type Purchase = {
|
578
|
-
isPurchased: boolean;
|
579
|
-
monetizationId: string;
|
580
|
-
videoId: string;
|
581
|
-
status: string;
|
582
|
-
video: Video | null;
|
583
|
-
};
|
584
|
-
|
585
|
-
declare type Purchase_2 = {
|
586
698
|
id: string;
|
587
699
|
isPurchased: boolean;
|
588
700
|
monetizationRef: firebase_3.firestore.DocumentReference | null;
|
@@ -598,7 +710,7 @@ declare type Purchase_2 = {
|
|
598
710
|
voucherId?: string;
|
599
711
|
};
|
600
712
|
|
601
|
-
declare type PurchaseMonetization = {
|
713
|
+
export declare type PurchaseMonetization = {
|
602
714
|
currency: Currency;
|
603
715
|
period: number;
|
604
716
|
price: number;
|
@@ -612,7 +724,7 @@ declare type PurchaseMonetization = {
|
|
612
724
|
voucherPurchaseDuration?: number;
|
613
725
|
};
|
614
726
|
|
615
|
-
declare enum PurchaseStatus {
|
727
|
+
export declare enum PurchaseStatus {
|
616
728
|
NEW = "NEW",
|
617
729
|
PAID = "PAID",
|
618
730
|
CANCELLED = "CANCELLED",
|
@@ -649,7 +761,17 @@ export declare interface QerkoPaymentInfo {
|
|
649
761
|
monetizationFrequency: MONETIZATION_FREQUENCY;
|
650
762
|
}
|
651
763
|
|
652
|
-
declare interface
|
764
|
+
export declare interface QerkoPaymentProps {
|
765
|
+
transaction: QerkoTransaction;
|
766
|
+
qrCodeCaption?: string;
|
767
|
+
renderErrorComponent: () => any;
|
768
|
+
enablePayByCard?: boolean;
|
769
|
+
payByCardCaption?: string;
|
770
|
+
visaLogoUrl?: string;
|
771
|
+
masterCardLogoUrl?: string;
|
772
|
+
}
|
773
|
+
|
774
|
+
export declare interface QerkoTransaction {
|
653
775
|
paymentInfo: QerkoPaymentInfo | null;
|
654
776
|
paymentError: string | null;
|
655
777
|
paymentStatus: string | null;
|
@@ -683,7 +805,7 @@ export declare interface RouterOverridesContextState {
|
|
683
805
|
routerOverrides: RouterOverrides;
|
684
806
|
}
|
685
807
|
|
686
|
-
declare interface Row {
|
808
|
+
export declare interface Row {
|
687
809
|
id: string;
|
688
810
|
rowId: string;
|
689
811
|
name: string;
|
@@ -700,37 +822,52 @@ export declare enum ROW_ITEM_TYPES {
|
|
700
822
|
TV_CHANNEL = "TV_CHANNEL"
|
701
823
|
}
|
702
824
|
|
703
|
-
declare enum RowComponent {
|
825
|
+
export declare enum RowComponent {
|
704
826
|
ROW = "ROW",
|
705
827
|
BANNER = "BANNER"
|
706
828
|
}
|
707
829
|
|
708
|
-
declare interface RowItem extends RowItemAssets {
|
830
|
+
export declare interface RowItem extends RowItemAssets {
|
709
831
|
itemType: ROW_ITEM_TYPES;
|
710
832
|
name?: string;
|
711
833
|
description?: string;
|
712
834
|
assets: Assets | null;
|
713
835
|
}
|
714
836
|
|
715
|
-
declare interface RowItemAssets {
|
837
|
+
export declare interface RowItemAssets {
|
716
838
|
landscape?: string | null;
|
717
839
|
portrait?: string | null;
|
718
840
|
circled?: string | null;
|
719
841
|
banner?: string | null;
|
720
842
|
}
|
721
843
|
|
722
|
-
declare enum RowItemComponent {
|
844
|
+
export declare enum RowItemComponent {
|
723
845
|
ROW_ITEM_PORTRAIT = "ROW_ITEM_PORTRAIT",
|
724
846
|
ROW_ITEM_LANDSCAPE = "ROW_ITEM_LANDSCAPE",
|
725
847
|
ROW_ITEM_CIRCLED = "ROW_ITEM_CIRCLED"
|
726
848
|
}
|
727
849
|
|
728
|
-
|
850
|
+
/**
|
851
|
+
* Listen to items in row of a screen
|
852
|
+
* @param rowId - row ID (user defined ID via studio.tiv.io)
|
853
|
+
* @param cb - callback on items changes or error, with information
|
854
|
+
* whether data is loading and a fetchMore function
|
855
|
+
* @param limit - max item count (default 10)
|
856
|
+
* @returns Disposer
|
857
|
+
*/
|
858
|
+
export declare type RowItemsSubscription = (rowId: string, cb: (error: Error | null, data: {
|
859
|
+
items: Video[];
|
860
|
+
hasNextPage: boolean;
|
861
|
+
} | null, fetchMore: null | ((count?: number) => void), isLoading: boolean) => void, limit?: number) => Disposer_2;
|
862
|
+
|
863
|
+
export declare type ScalableAsset = {
|
729
864
|
'@1': Asset;
|
730
865
|
'@2'?: Asset;
|
731
866
|
'@3'?: Asset;
|
732
867
|
};
|
733
868
|
|
869
|
+
export declare type Scale = '@1' | '@2' | '@3';
|
870
|
+
|
734
871
|
declare interface Screen_2 {
|
735
872
|
id: string;
|
736
873
|
name: string;
|
@@ -738,25 +875,36 @@ declare interface Screen_2 {
|
|
738
875
|
assets: Assets;
|
739
876
|
rows: Row[];
|
740
877
|
}
|
878
|
+
export { Screen_2 as Screen }
|
741
879
|
|
742
|
-
declare type
|
880
|
+
export declare type ScreenConfig = {
|
881
|
+
id: string;
|
882
|
+
name: string;
|
883
|
+
};
|
884
|
+
|
885
|
+
export declare type ScreenOptions = Partial<{
|
743
886
|
language: LangCode;
|
744
887
|
initRows: boolean;
|
745
888
|
}> & DocumentOptions;
|
746
889
|
|
747
|
-
declare type ScreenRowType = 'filter' | 'custom' | 'continueToWatch' | 'favourites';
|
890
|
+
export declare type ScreenRowType = 'filter' | 'custom' | 'continueToWatch' | 'favourites';
|
891
|
+
|
892
|
+
/**
|
893
|
+
* Listen to screen data
|
894
|
+
* @param screenId - screen ID (user defined ID via studio.tiv.io)
|
895
|
+
* @param cb - callback on screen data change or error
|
896
|
+
* @returns Disposer
|
897
|
+
*/
|
898
|
+
export declare type ScreenSubscription = (screenId: string, cb: (error: Error | null, data: Screen_2 | null) => void) => Disposer_2;
|
748
899
|
|
749
|
-
export declare
|
900
|
+
export declare interface Section {
|
750
901
|
id: string;
|
751
902
|
name: string;
|
752
903
|
channel: Channel;
|
753
904
|
videos: Video[];
|
754
|
-
};
|
755
|
-
|
756
|
-
declare interface Section_2 {
|
757
905
|
}
|
758
906
|
|
759
|
-
export declare const SectionsContext: React_2.Context<DataState<
|
907
|
+
export declare const SectionsContext: React_2.Context<DataState<Section>>;
|
760
908
|
|
761
909
|
export declare type Settings = {
|
762
910
|
/**
|
@@ -765,6 +913,16 @@ export declare type Settings = {
|
|
765
913
|
setUser: (userId: string, userPayload: unknown) => Promise<void>;
|
766
914
|
};
|
767
915
|
|
916
|
+
/**
|
917
|
+
* Used for entities, that can be global (e.g. asset presets, tag types).
|
918
|
+
* Non-global is stored under organizations (in sub-collection), and shown for organization's users and super-admin.
|
919
|
+
* Global is stored in separate collection and shown only for super-admin.
|
920
|
+
*/
|
921
|
+
export declare interface SettingsItem {
|
922
|
+
name: string;
|
923
|
+
isGlobal?: boolean;
|
924
|
+
}
|
925
|
+
|
768
926
|
/**
|
769
927
|
* Set user to sign in/out.
|
770
928
|
*
|
@@ -775,25 +933,33 @@ export declare const setUser: (userId: string | null, payload?: UserPayload | un
|
|
775
933
|
|
776
934
|
export declare const showGdprConsentPreferences: () => Promise<void>;
|
777
935
|
|
778
|
-
declare type SubscribeToItemsInRow = (rowId: string, cb: (error: Error | null, data: PaginationInterface<ItemsInRow> | null) => void, options?: SubscribeToItemsInRowOptions) => Disposer_2;
|
936
|
+
export declare type SubscribeToItemsInRow = (rowId: string, cb: (error: Error | null, data: PaginationInterface<ItemsInRow> | null) => void, options?: SubscribeToItemsInRowOptions) => Disposer_2;
|
779
937
|
|
780
|
-
declare type SubscribeToItemsInRowOptions = Partial<{
|
938
|
+
export declare type SubscribeToItemsInRowOptions = Partial<{
|
781
939
|
fetchTags: boolean;
|
782
940
|
}> & PaginationOptions;
|
783
941
|
|
784
|
-
declare type SubscribeToRowsInScreen = (screenId: string, cb: (error: Error | null, data: PaginationInterface<Row> | null) => void, options?: PaginationOptions) => Disposer_2;
|
942
|
+
export declare type SubscribeToRowsInScreen = (screenId: string, cb: (error: Error | null, data: PaginationInterface<Row> | null) => void, options?: PaginationOptions) => Disposer_2;
|
785
943
|
|
786
|
-
declare type SubscribeToScreen = (screenId: string, cb: (error: Error | null, data: Screen_2 | null) => void, options?: ScreenOptions) => Disposer_2;
|
944
|
+
export declare type SubscribeToScreen = (screenId: string, cb: (error: Error | null, data: Screen_2 | null) => void, options?: ScreenOptions) => Disposer_2;
|
787
945
|
|
788
|
-
declare type SubscribeToTaggedVideos = (tagIds: string[], cb: (error: Error | null, data: PaginationInterface<Video> | null) => void, options?: SubscribeToTaggedVideosOptions) => Disposer_2;
|
946
|
+
export declare type SubscribeToTaggedVideos = (tagIds: string[], cb: (error: Error | null, data: PaginationInterface<Video> | null) => void, options?: SubscribeToTaggedVideosOptions) => Disposer_2;
|
789
947
|
|
790
|
-
declare type SubscribeToTaggedVideosOptions = SubscribeToItemsInRowOptions & {
|
948
|
+
export declare type SubscribeToTaggedVideosOptions = SubscribeToItemsInRowOptions & {
|
791
949
|
orderBy?: (Omit<OrderBy, 'field'> & {
|
792
950
|
field: TaggedVideosOrderByField;
|
793
951
|
})[];
|
794
952
|
where?: WhereFilter[];
|
795
953
|
};
|
796
954
|
|
955
|
+
export declare interface SubscriptionCardProps {
|
956
|
+
subscription: Monetization;
|
957
|
+
onClick: (subscription: Monetization) => void;
|
958
|
+
buttonLabel: string;
|
959
|
+
purchased: boolean;
|
960
|
+
focused?: boolean;
|
961
|
+
}
|
962
|
+
|
797
963
|
declare type SubscriptionInfo = {
|
798
964
|
type: 'subscription';
|
799
965
|
name: string;
|
@@ -813,7 +979,7 @@ export declare type SubscriptionOverlayState = {
|
|
813
979
|
openSubscriptionOverlay: (data: SubscriptionOverlayData) => void;
|
814
980
|
};
|
815
981
|
|
816
|
-
declare interface Tag extends RowItem {
|
982
|
+
export declare interface Tag extends RowItem {
|
817
983
|
id: string;
|
818
984
|
tagId: string;
|
819
985
|
type?: string | null;
|
@@ -826,9 +992,9 @@ declare interface Tag extends RowItem {
|
|
826
992
|
removeFromFavorites: () => void;
|
827
993
|
}
|
828
994
|
|
829
|
-
declare type TaggedVideosOrderByField = 'seasonNumber' | 'episodeNumber' | 'contentType' | DefaultOrderByField;
|
995
|
+
export declare type TaggedVideosOrderByField = 'seasonNumber' | 'episodeNumber' | 'contentType' | DefaultOrderByField;
|
830
996
|
|
831
|
-
declare type TileProps = {
|
997
|
+
export declare type TileProps = {
|
832
998
|
cover: string;
|
833
999
|
isLoading: boolean;
|
834
1000
|
bottomLabel: string;
|
@@ -854,13 +1020,13 @@ declare type TileProps = {
|
|
854
1020
|
containerMargin?: number | string;
|
855
1021
|
};
|
856
1022
|
|
857
|
-
declare type TilePropsPartial = Partial<TileProps>;
|
1023
|
+
export declare type TilePropsPartial = Partial<TileProps>;
|
858
1024
|
|
859
1025
|
export declare interface TivioAuth {
|
860
1026
|
changePassword: (newPassword: string) => Promise<void>;
|
861
1027
|
changeUserPhoto(file: File): Promise<void>;
|
862
1028
|
removeUserPhoto(): Promise<void>;
|
863
|
-
getPurchasedVodsWithInitializedVideos: () => Promise<
|
1029
|
+
getPurchasedVodsWithInitializedVideos: () => Promise<Purchase[]>;
|
864
1030
|
/**
|
865
1031
|
* @param email
|
866
1032
|
* @param password
|
@@ -1059,7 +1225,7 @@ export declare type TivioInternalHooks = {
|
|
1059
1225
|
useSubscriptionsOverlay: () => SubscriptionOverlayState;
|
1060
1226
|
useQerkoOverlay: () => QerkoOverlayState;
|
1061
1227
|
usePurchasesWithVideos: () => {
|
1062
|
-
purchases:
|
1228
|
+
purchases: Purchase[];
|
1063
1229
|
};
|
1064
1230
|
useOrganizationSubscriptions: () => {
|
1065
1231
|
subscriptions: Monetization[];
|
@@ -1226,11 +1392,11 @@ export declare type Translation = {
|
|
1226
1392
|
[key in LangCode]: string;
|
1227
1393
|
};
|
1228
1394
|
|
1229
|
-
declare type TvAppProps = {
|
1395
|
+
export declare type TvAppProps = {
|
1230
1396
|
customer: CUSTOMER_BUILD;
|
1231
1397
|
};
|
1232
1398
|
|
1233
|
-
declare interface TvChannel extends RowItem {
|
1399
|
+
export declare interface TvChannel extends RowItem {
|
1234
1400
|
name: string;
|
1235
1401
|
id: string;
|
1236
1402
|
path: string;
|
@@ -1279,7 +1445,7 @@ export declare function useApplyInviteCode(): {
|
|
1279
1445
|
|
1280
1446
|
export declare const useBetOffer: () => BetOffer | null;
|
1281
1447
|
|
1282
|
-
declare type UseCancelSubscription = (subscriptionId: string) => {
|
1448
|
+
export declare type UseCancelSubscription = (subscriptionId: string) => {
|
1283
1449
|
cancelSubscription: () => Promise<void>;
|
1284
1450
|
cancellationInfo: QerkoCancellationInfo | null;
|
1285
1451
|
error?: string | null;
|
@@ -1303,12 +1469,12 @@ export declare const useChannel: (channelId: string) => {
|
|
1303
1469
|
*/
|
1304
1470
|
export declare const useChannelsInWidget: (widgetId: string, limit?: number) => {
|
1305
1471
|
error: Error | null;
|
1306
|
-
data: PaginationData<
|
1472
|
+
data: PaginationData<Channel> | null;
|
1307
1473
|
isLoading: boolean;
|
1308
1474
|
};
|
1309
1475
|
|
1310
|
-
declare type UseChannelSource = (tvChannelId: string) => {
|
1311
|
-
source:
|
1476
|
+
export declare type UseChannelSource = (tvChannelId: string) => {
|
1477
|
+
source: ChannelSourcePojo | null;
|
1312
1478
|
error: Error | null;
|
1313
1479
|
};
|
1314
1480
|
|
@@ -1374,14 +1540,14 @@ export declare const usePurchaseSubscription: (monetizationId: string, voucher?:
|
|
1374
1540
|
* Return purchases with initialized video (purchases[i].video not null)
|
1375
1541
|
*/
|
1376
1542
|
export declare const usePurchasesWithVideos: () => {
|
1377
|
-
purchases:
|
1543
|
+
purchases: Purchase[];
|
1378
1544
|
};
|
1379
1545
|
|
1380
1546
|
export declare type User = {
|
1381
|
-
purchases:
|
1382
|
-
allPurchases:
|
1383
|
-
purchasedVods:
|
1384
|
-
purchasedSubscriptions:
|
1547
|
+
purchases: Purchase[];
|
1548
|
+
allPurchases: Purchase[];
|
1549
|
+
purchasedVods: Purchase[];
|
1550
|
+
purchasedSubscriptions: Purchase[];
|
1385
1551
|
isPurchasesInitialized: boolean;
|
1386
1552
|
isSignedIn: boolean;
|
1387
1553
|
email?: string;
|
@@ -1400,7 +1566,7 @@ export declare const useRowsInScreen: (screenId: string, options?: PaginationOpt
|
|
1400
1566
|
|
1401
1567
|
export declare type UserPayload = Record<string, any>;
|
1402
1568
|
|
1403
|
-
declare enum UserType {
|
1569
|
+
export declare enum UserType {
|
1404
1570
|
ORGANIZATION_USER = "ORGANIZATION_USER",
|
1405
1571
|
TIVIO_USER = "TIVIO_USER"
|
1406
1572
|
}
|
@@ -1418,7 +1584,7 @@ export declare const useScreens: () => {
|
|
1418
1584
|
screens: Screen_2[];
|
1419
1585
|
};
|
1420
1586
|
|
1421
|
-
declare type UseSearch = <T extends ALGOLIA_INDEX_NAME>(indexName: T, options?: UseSearchOptions) => {
|
1587
|
+
export declare type UseSearch = <T extends ALGOLIA_INDEX_NAME>(indexName: T, options?: UseSearchOptions) => {
|
1422
1588
|
search: (query: string) => void;
|
1423
1589
|
pagination: PaginationInterface<UseSearchResult<T>> | null;
|
1424
1590
|
error: Error | null;
|
@@ -1433,11 +1599,11 @@ declare type UseSearch = <T extends ALGOLIA_INDEX_NAME>(indexName: T, options?:
|
|
1433
1599
|
*/
|
1434
1600
|
export declare const useSearch: UseSearch;
|
1435
1601
|
|
1436
|
-
declare type UseSearchOptions = PaginationOptions & Partial<{
|
1602
|
+
export declare type UseSearchOptions = PaginationOptions & Partial<{
|
1437
1603
|
minQueryLength: number;
|
1438
1604
|
}>;
|
1439
1605
|
|
1440
|
-
declare type UseSearchResult<T extends ALGOLIA_INDEX_NAME> = T extends ALGOLIA_INDEX_NAME.VIDEOS ? Video : T extends ALGOLIA_INDEX_NAME.TAGS ? Tag : T extends ALGOLIA_INDEX_NAME.TV_CHANNELS ? TvChannel : unknown;
|
1606
|
+
export declare type UseSearchResult<T extends ALGOLIA_INDEX_NAME> = T extends ALGOLIA_INDEX_NAME.VIDEOS ? Video : T extends ALGOLIA_INDEX_NAME.TAGS ? Tag : T extends ALGOLIA_INDEX_NAME.TV_CHANNELS ? TvChannel : unknown;
|
1441
1607
|
|
1442
1608
|
/**
|
1443
1609
|
* Use section
|
@@ -1455,7 +1621,7 @@ export declare const useSection: (sectionId: string) => {
|
|
1455
1621
|
*/
|
1456
1622
|
export declare const useSectionsInChannel: (channelId: string, limit?: number) => {
|
1457
1623
|
error: Error | null;
|
1458
|
-
data: PaginationData<
|
1624
|
+
data: PaginationData<Section> | null;
|
1459
1625
|
isLoading: boolean;
|
1460
1626
|
};
|
1461
1627
|
|
@@ -1477,7 +1643,7 @@ export declare const useTivioReadyData: () => RemoteBundleState | null;
|
|
1477
1643
|
|
1478
1644
|
export declare const useTransactionPayment: (videoId: string, monetizationId: string, voucher?: NewVoucher | undefined) => QerkoTransaction;
|
1479
1645
|
|
1480
|
-
declare type UseTvChannel = (tvChannelId: string) => {
|
1646
|
+
export declare type UseTvChannel = (tvChannelId: string) => {
|
1481
1647
|
tvChannel: TvChannel | null;
|
1482
1648
|
error: Error | null;
|
1483
1649
|
loading: boolean;
|
@@ -1537,6 +1703,29 @@ export declare const useWidget: (widgetId: string) => {
|
|
1537
1703
|
widget: Widget | null;
|
1538
1704
|
};
|
1539
1705
|
|
1706
|
+
export declare const VAST_PROVIDERS: ({
|
1707
|
+
id: VastProvider;
|
1708
|
+
name: string;
|
1709
|
+
development?: undefined;
|
1710
|
+
} | {
|
1711
|
+
id: VastProvider;
|
1712
|
+
name: string;
|
1713
|
+
development: boolean;
|
1714
|
+
})[];
|
1715
|
+
|
1716
|
+
export declare enum VastProvider {
|
1717
|
+
ETARGET_PREBID = "etarget-prebid",
|
1718
|
+
MALL_TV_PREBID = "malltv-prebid",
|
1719
|
+
IMPRESSION_MEDIA_PREBID = "impressionMedia-prebid",
|
1720
|
+
MALL_TV = "malltv",
|
1721
|
+
FALLBACK_MP4 = "fallback",
|
1722
|
+
FALLBACK_HLS = "fallback-hls",
|
1723
|
+
JOJ = "joj",
|
1724
|
+
PRIMA = "prima",
|
1725
|
+
GARAZ_TV = "garaz.tv",
|
1726
|
+
GARAZ_TV_DEV = "garaz.tv.dev"
|
1727
|
+
}
|
1728
|
+
|
1540
1729
|
export declare interface Video extends RowItem {
|
1541
1730
|
id: string;
|
1542
1731
|
/**
|
@@ -1595,7 +1784,7 @@ declare type VideoAvailabilityField = {
|
|
1595
1784
|
manual: boolean;
|
1596
1785
|
};
|
1597
1786
|
|
1598
|
-
declare enum VideoContentType {
|
1787
|
+
export declare enum VideoContentType {
|
1599
1788
|
/**
|
1600
1789
|
* Default video content type
|
1601
1790
|
*/
|
@@ -1604,10 +1793,38 @@ declare enum VideoContentType {
|
|
1604
1793
|
SERIES = "SERIES"
|
1605
1794
|
}
|
1606
1795
|
|
1796
|
+
export declare interface VideoExternals {
|
1797
|
+
tvProfiProgramId?: string;
|
1798
|
+
tvProfiContentId?: string;
|
1799
|
+
tvProfiSerialId?: string;
|
1800
|
+
contentId?: string;
|
1801
|
+
provysId?: string;
|
1802
|
+
mallTvEntityId?: string;
|
1803
|
+
/**
|
1804
|
+
* DRM content Key ID - should't be more connected with buyDRM or streamOnline? It is not general thing
|
1805
|
+
*/
|
1806
|
+
keyId?: string;
|
1807
|
+
}
|
1808
|
+
|
1607
1809
|
declare type VideoPath = string;
|
1608
1810
|
|
1609
1811
|
export declare const VideosContext: React_2.Context<DataState<Video>>;
|
1610
1812
|
|
1813
|
+
/**
|
1814
|
+
* Video type.
|
1815
|
+
*/
|
1816
|
+
export declare enum VideoType {
|
1817
|
+
/**
|
1818
|
+
* Video is composed of several other videos.
|
1819
|
+
*/
|
1820
|
+
PLAYLIST = "PLAYLIST",
|
1821
|
+
/**
|
1822
|
+
* Video is a standard single video.
|
1823
|
+
*/
|
1824
|
+
VIDEO = "VIDEO",
|
1825
|
+
TV_PROGRAM = "TV_PROGRAM"
|
1826
|
+
}
|
1827
|
+
|
1611
1828
|
export declare type VodExternalSource = {
|
1612
1829
|
new (uri: string, monetizationId: string, name: string, description: string, originalOptions: Record<string, any>): VodTivioSource;
|
1613
1830
|
type: 'vod_external';
|
@@ -1696,7 +1913,7 @@ export declare interface WebPlayerProps {
|
|
1696
1913
|
onPlayerControllerCreated?: (playerController: any) => void;
|
1697
1914
|
}
|
1698
1915
|
|
1699
|
-
declare type WebRowProps = {
|
1916
|
+
export declare type WebRowProps = {
|
1700
1917
|
items?: ItemsInRow[];
|
1701
1918
|
variant?: RowItemComponent;
|
1702
1919
|
rowName?: string;
|
@@ -1704,11 +1921,11 @@ declare type WebRowProps = {
|
|
1704
1921
|
onTileClick?: (item: ItemsInRow) => void;
|
1705
1922
|
};
|
1706
1923
|
|
1707
|
-
declare type WebSeriesDetailScreenProps = {
|
1924
|
+
export declare type WebSeriesDetailScreenProps = {
|
1708
1925
|
tagId: string;
|
1709
1926
|
};
|
1710
1927
|
|
1711
|
-
declare interface WhereFilter {
|
1928
|
+
export declare interface WhereFilter {
|
1712
1929
|
field: string;
|
1713
1930
|
operator: WhereFilterOp;
|
1714
1931
|
value: any;
|