@wscsports/blaze-web-sdk 0.0.113 → 0.0.116
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/package.json +1 -3
- package/publish/index.d.ts +20 -86
- package/publish/index.js +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wscsports/blaze-web-sdk",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.116",
|
|
4
4
|
"main": "publish/index",
|
|
5
5
|
"types": "publish/index",
|
|
6
6
|
"files": [
|
|
@@ -17,10 +17,8 @@
|
|
|
17
17
|
"@types/hammerjs": "^2.0.41",
|
|
18
18
|
"@types/lodash": "^4.14.195",
|
|
19
19
|
"@types/ua-parser-js": "^0.7.36",
|
|
20
|
-
"css-loader": "^6.8.1",
|
|
21
20
|
"html-webpack-plugin": "^5.5.3",
|
|
22
21
|
"javascript-obfuscator": "^4.0.2",
|
|
23
|
-
"style-loader": "^3.3.3",
|
|
24
22
|
"ts-loader": "^9.4.4",
|
|
25
23
|
"typescript": "^5.1.6",
|
|
26
24
|
"typescript-declaration-webpack-plugin": "^0.3.0",
|
package/publish/index.d.ts
CHANGED
|
@@ -449,7 +449,7 @@ export declare class API {
|
|
|
449
449
|
|
|
450
450
|
export * from './api';
|
|
451
451
|
|
|
452
|
-
export declare
|
|
452
|
+
export declare class BaseHTMLElement extends HTMLElement {
|
|
453
453
|
protected _animationDuration: number;
|
|
454
454
|
constructor();
|
|
455
455
|
getAttribute<T = any>(qualifiedName: string): T;
|
|
@@ -504,18 +504,7 @@ export interface ResizeEvent extends Event {
|
|
|
504
504
|
}
|
|
505
505
|
export declare function throttle<T extends Event>(func: EventHandler<T>, delay: number): (event: T) => void;
|
|
506
506
|
|
|
507
|
-
export declare class
|
|
508
|
-
titleContainer: HTMLDivElement;
|
|
509
|
-
textContainer: HTMLDivElement;
|
|
510
|
-
constructor();
|
|
511
|
-
static get observedAttributes(): string[];
|
|
512
|
-
connectedCallback(): void;
|
|
513
|
-
disconnectedCallback(): void;
|
|
514
|
-
attributeChangedCallback(name: string, oldValue: string, newValue: string): void;
|
|
515
|
-
setAttribute(qualifiedName: 'alert-title' | 'alert-text', value: string): void;
|
|
516
|
-
}
|
|
517
|
-
|
|
518
|
-
export declare class BlazeChip extends BaseHTMLElement {
|
|
507
|
+
export declare class BlazeChip extends HTMLElement {
|
|
519
508
|
constructor();
|
|
520
509
|
}
|
|
521
510
|
|
|
@@ -523,28 +512,12 @@ export interface BlazeImageOptions {
|
|
|
523
512
|
fetchPriority: FetchPriorityType;
|
|
524
513
|
src: string;
|
|
525
514
|
}
|
|
526
|
-
export declare class BlazeImage extends
|
|
527
|
-
constructor();
|
|
515
|
+
export declare class BlazeImage extends HTMLElement {
|
|
516
|
+
constructor(options: BlazeImageOptions);
|
|
528
517
|
}
|
|
529
518
|
|
|
530
|
-
export * from './alert';
|
|
531
519
|
export * from './chip';
|
|
532
520
|
export * from './image';
|
|
533
|
-
export * from './toast';
|
|
534
|
-
|
|
535
|
-
export declare class BlazeToast extends BaseHTMLElement {
|
|
536
|
-
constructor();
|
|
537
|
-
static get observedAttributes(): string[];
|
|
538
|
-
connectedCallback(): void;
|
|
539
|
-
disconnectedCallback(): void;
|
|
540
|
-
attributeChangedCallback(name: string, oldValue: string, newValue: string): void;
|
|
541
|
-
show(options: {
|
|
542
|
-
show: boolean;
|
|
543
|
-
sevrity: SeverityType;
|
|
544
|
-
title?: string;
|
|
545
|
-
text: string;
|
|
546
|
-
}): void;
|
|
547
|
-
}
|
|
548
521
|
|
|
549
522
|
export declare enum StoryAction {
|
|
550
523
|
Start = "story_start",
|
|
@@ -671,12 +644,6 @@ export declare enum Delegation {
|
|
|
671
644
|
|
|
672
645
|
export * from './event';
|
|
673
646
|
|
|
674
|
-
export declare abstract class ElementsFactory {
|
|
675
|
-
static create<T extends BaseHTMLElement>(e: ElementType): T;
|
|
676
|
-
}
|
|
677
|
-
|
|
678
|
-
export * from './elements.factory';
|
|
679
|
-
|
|
680
647
|
export type EnvironmentType = 'prod' | 'uat';
|
|
681
648
|
export interface IBlazeSDKOptions {
|
|
682
649
|
apiKey: string;
|
|
@@ -738,17 +705,6 @@ export interface IWidgetView {
|
|
|
738
705
|
reload: (labels?: string[]) => void;
|
|
739
706
|
}
|
|
740
707
|
|
|
741
|
-
declare const AlertServiceClass_base: {
|
|
742
|
-
new (): {};
|
|
743
|
-
_instance: AlertServiceClass;
|
|
744
|
-
getInstance(): AlertServiceClass;
|
|
745
|
-
};
|
|
746
|
-
declare abstract class AlertServiceClass extends AlertServiceClass_base implements IService {
|
|
747
|
-
init(): Promise<void>;
|
|
748
|
-
alert(): void;
|
|
749
|
-
}
|
|
750
|
-
export declare const AlertService: AlertServiceClass;
|
|
751
|
-
|
|
752
708
|
export declare enum AdAction {
|
|
753
709
|
Request = "ad_request",
|
|
754
710
|
Load = "ad_load",
|
|
@@ -1047,7 +1003,6 @@ declare abstract class EventServiceClass extends EventServiceClass_base implemen
|
|
|
1047
1003
|
}
|
|
1048
1004
|
export declare const EventService: EventServiceClass;
|
|
1049
1005
|
|
|
1050
|
-
export * from './alert.ervice';
|
|
1051
1006
|
export * from './analytics.service';
|
|
1052
1007
|
export * from './blaze-api.service';
|
|
1053
1008
|
export * from './blaze-database.service';
|
|
@@ -1197,27 +1152,18 @@ export declare function getLabelStyle(el: IAttributeParser): Partial<LabelStyle>
|
|
|
1197
1152
|
export declare function setupLayoutStyle(layoutStyle: LayoutStyle): void;
|
|
1198
1153
|
export declare function getLayoutStyle(el: IAttributeParser): DeepPartial<LayoutStyle>;
|
|
1199
1154
|
|
|
1200
|
-
|
|
1201
1155
|
export type ClientPlatform = 'Web';
|
|
1202
1156
|
|
|
1203
|
-
export type ComponentsElementType = 'blaze-alert' | 'blaze-toast' | 'blaze-chip' | 'blaze-image';
|
|
1204
|
-
export type WidgetElementType = 'blaze-sdk';
|
|
1205
|
-
export type ElementType = WidgetElementType | ComponentsElementType;
|
|
1206
|
-
|
|
1207
1157
|
export type FetchPriorityType = 'low' | 'high' | 'auto';
|
|
1208
1158
|
|
|
1209
1159
|
export * from './client-platform.type';
|
|
1210
|
-
export * from './element.type';
|
|
1211
1160
|
export * from './fetch-priority.type';
|
|
1212
1161
|
export * from './order.type';
|
|
1213
|
-
export * from './severity.type';
|
|
1214
1162
|
export * from './shape.type';
|
|
1215
1163
|
export * from './thumbnail.type';
|
|
1216
1164
|
|
|
1217
1165
|
export type OrderType = 'Manual' | 'RecentlyUpdatedFirst' | 'AtoZ' | 'RecentlyUpdatedLast' | 'ZtoA';
|
|
1218
1166
|
|
|
1219
|
-
export type SeverityType = 'error' | 'warning' | 'info' | 'success';
|
|
1220
|
-
|
|
1221
1167
|
export type ShapeType = 'rectangle' | 'custom' | 'circle';
|
|
1222
1168
|
|
|
1223
1169
|
export type ThumbnailType = 'SquareIcon' | 'VerticalTwoByThree';
|
|
@@ -1230,12 +1176,9 @@ interface ChipSizeOptions {
|
|
|
1230
1176
|
}
|
|
1231
1177
|
export declare function getChipSize(options: ChipSizeOptions): DOMRect;
|
|
1232
1178
|
|
|
1233
|
-
export declare function delay(ms: number): Promise<void>;
|
|
1234
|
-
|
|
1235
1179
|
export declare function GuardNullOrEmpty(name: string, value: any): void;
|
|
1236
1180
|
|
|
1237
1181
|
export * from './chip.utils';
|
|
1238
|
-
export * from './common.utils';
|
|
1239
1182
|
export * from './guard.utils';
|
|
1240
1183
|
|
|
1241
1184
|
export { BlazeWidgetItem } from './widget-item';
|
|
@@ -1252,7 +1195,6 @@ export { BlazeWidgetStoryModal } from './widget-story-modal';
|
|
|
1252
1195
|
export { BlazeWidgetStoryPlayer } from './widget-story-player';
|
|
1253
1196
|
export { BlazeWidgetStoryPreview } from './widget-story-preview';
|
|
1254
1197
|
export { BlazeWidgetStoryVideo } from './widget-story-video';
|
|
1255
|
-
export { BlazeWidgetScrollable } from './wigdet-scrollable';
|
|
1256
1198
|
|
|
1257
1199
|
export interface BlazeWidgetItemOptions {
|
|
1258
1200
|
theme: IWidgetTheme;
|
|
@@ -1308,18 +1250,25 @@ export declare class BlazeWidgetLayout extends BaseHTMLElement implements Observ
|
|
|
1308
1250
|
reloadTimeout: NodeJS.Timeout | undefined;
|
|
1309
1251
|
analyticsStack: Record<WidgetAction, boolean>;
|
|
1310
1252
|
intersectionObserver: IntersectionObserver;
|
|
1253
|
+
totalMouseMovement: number;
|
|
1311
1254
|
onResizeEvent: () => () => void;
|
|
1312
|
-
|
|
1255
|
+
clickEvent: ((event: MouseEvent) => void | undefined) | undefined;
|
|
1256
|
+
mouseMoveEvent: ((event: MouseEvent) => void | undefined) | undefined;
|
|
1257
|
+
touchMoveEvent: ((event: TouchEvent) => void | undefined) | undefined;
|
|
1258
|
+
constructor(options?: IWidgetViewOptions);
|
|
1313
1259
|
setLabels(labels: string[]): void;
|
|
1314
1260
|
getTheme(): IWidgetTheme;
|
|
1315
1261
|
setTheme(theme: IWidgetTheme): void;
|
|
1316
1262
|
reload(labels?: string[]): void;
|
|
1317
1263
|
connectedCallback(): void;
|
|
1318
1264
|
disconnectedCallback(): void;
|
|
1265
|
+
onClick(event: MouseEvent): void;
|
|
1266
|
+
onMouseMove(event: MouseEvent): void;
|
|
1267
|
+
onTouchMove(event: TouchEvent): void;
|
|
1319
1268
|
attributeChangedCallback(name: string, oldValue?: string, newValue?: string): void;
|
|
1320
1269
|
setLabel(label: string | BlazeWidgetLabel): void;
|
|
1321
|
-
setMaxSize
|
|
1322
|
-
setMaxItemsSize
|
|
1270
|
+
private setMaxSize;
|
|
1271
|
+
private setMaxItemsSize;
|
|
1323
1272
|
handleIntersection(entries: IntersectionObserverEntry[]): void;
|
|
1324
1273
|
createModal(): void;
|
|
1325
1274
|
createMomentsModal(): void;
|
|
@@ -1347,7 +1296,6 @@ export declare class BlazeWidgetModal extends HTMLElement {
|
|
|
1347
1296
|
open(): void;
|
|
1348
1297
|
close(): void;
|
|
1349
1298
|
disconnectedCallback(): void;
|
|
1350
|
-
setTheme(theme: IWidgetTheme): void;
|
|
1351
1299
|
}
|
|
1352
1300
|
|
|
1353
1301
|
export declare class BlazeWidgetMomentModal extends BlazeWidgetModal {
|
|
@@ -1475,10 +1423,11 @@ export declare class BlazeWidgetMoment extends HTMLElement {
|
|
|
1475
1423
|
}
|
|
1476
1424
|
|
|
1477
1425
|
export declare class BlazeWidgetSdk extends BaseHTMLElement {
|
|
1426
|
+
protected readonly apiKey: string;
|
|
1478
1427
|
static isMuted: boolean;
|
|
1479
1428
|
static isPlaying: boolean;
|
|
1480
1429
|
static get observedAttributes(): string[];
|
|
1481
|
-
constructor();
|
|
1430
|
+
constructor(apiKey: string, options?: IBlazeSDKOptions);
|
|
1482
1431
|
connectedCallback(): Promise<void>;
|
|
1483
1432
|
attributeChangedCallback(name: string, oldValue: string, newValue: string): Promise<void>;
|
|
1484
1433
|
private getConfigAttributes;
|
|
@@ -1543,10 +1492,10 @@ export declare class BlazeWidgetStoryModal extends BlazeWidgetModal {
|
|
|
1543
1492
|
exitPopup: HTMLElement;
|
|
1544
1493
|
exitButton: HTMLElement;
|
|
1545
1494
|
onClose: (() => void) | undefined;
|
|
1495
|
+
onResize: (this: Window, ev: UIEvent) => any | undefined;
|
|
1546
1496
|
hammer: HammerManager | null;
|
|
1547
1497
|
isMultiTouch: boolean;
|
|
1548
1498
|
constructor(parentWidget: HTMLElement);
|
|
1549
|
-
setTheme(theme: IWidgetTheme): void;
|
|
1550
1499
|
setStories(stories: IStory[]): void;
|
|
1551
1500
|
seek(id: string): void;
|
|
1552
1501
|
onKeyDown(ev: KeyboardEvent): void;
|
|
@@ -1578,6 +1527,7 @@ export declare class BlazeWidgetStoryPlayer extends BaseHTMLElement {
|
|
|
1578
1527
|
background: HTMLCanvasElement;
|
|
1579
1528
|
tmpBackground: HTMLCanvasElement;
|
|
1580
1529
|
onClose: (() => void) | undefined;
|
|
1530
|
+
onResize: (this: Window, ev: UIEvent) => any | undefined;
|
|
1581
1531
|
listeners: EventsListener;
|
|
1582
1532
|
backgroundAnimation?: Animation;
|
|
1583
1533
|
firstTime: boolean;
|
|
@@ -1682,7 +1632,6 @@ export declare class BlazeWidgetStoryVideo extends BlazeWidgetStoryBase {
|
|
|
1682
1632
|
loader: HTMLElement | undefined;
|
|
1683
1633
|
source: HTMLElement | undefined;
|
|
1684
1634
|
loaderTimeoutRefAppending: NodeJS.Timeout | undefined;
|
|
1685
|
-
loaderTimeoutRefCheckingForIssues: NodeJS.Timeout | undefined;
|
|
1686
1635
|
isPlaying: boolean;
|
|
1687
1636
|
isError: boolean;
|
|
1688
1637
|
retryTimes: number;
|
|
@@ -1697,8 +1646,8 @@ export declare class BlazeWidgetStoryVideo extends BlazeWidgetStoryBase {
|
|
|
1697
1646
|
unload(): Promise<void>;
|
|
1698
1647
|
removeLoader(): void;
|
|
1699
1648
|
startPlayVideo(video: HTMLVideoElement, retryTimes: number): Promise<void>;
|
|
1700
|
-
reloadVideo(retry: number):
|
|
1701
|
-
play():
|
|
1649
|
+
reloadVideo(retry: number): void;
|
|
1650
|
+
play(): void;
|
|
1702
1651
|
pause(): void;
|
|
1703
1652
|
set currentTime(value: number);
|
|
1704
1653
|
get currentTime(): number;
|
|
@@ -1788,18 +1737,3 @@ export declare class BlazeWidgetStory extends HTMLElement {
|
|
|
1788
1737
|
render(): void;
|
|
1789
1738
|
}
|
|
1790
1739
|
|
|
1791
|
-
export declare class BlazeWidgetScrollable extends BaseHTMLElement {
|
|
1792
|
-
buttonsState: never[];
|
|
1793
|
-
mouseMoveEvent: ((e: MouseEvent) => void | undefined) | undefined;
|
|
1794
|
-
touchMoveEvent: ((e: TouchEvent) => boolean | undefined) | undefined;
|
|
1795
|
-
clickEvent: ((e: MouseEvent) => void | undefined) | undefined;
|
|
1796
|
-
totalMovement: number;
|
|
1797
|
-
constructor();
|
|
1798
|
-
connectedCallback(): void;
|
|
1799
|
-
onClick(event: MouseEvent): void;
|
|
1800
|
-
onMouseMove(event: MouseEvent): void;
|
|
1801
|
-
onMouseWheel(event: WheelEvent): void;
|
|
1802
|
-
onTouchMove(event: TouchEvent): boolean;
|
|
1803
|
-
disconnectedCallback(): void;
|
|
1804
|
-
}
|
|
1805
|
-
|