@wscsports/blaze-web-sdk 0.1.64 → 0.1.67
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 -1
- package/publish/index.d.ts +62 -44
- package/publish/index.js +1 -1
package/package.json
CHANGED
package/publish/index.d.ts
CHANGED
|
@@ -160,13 +160,12 @@ export declare class BlazeDrawer extends BaseWidget {
|
|
|
160
160
|
private animateDrawer;
|
|
161
161
|
}
|
|
162
162
|
|
|
163
|
-
export interface BlazeImageOptions {
|
|
164
|
-
fetchPriority: FetchPriorityType;
|
|
165
|
-
src: string;
|
|
166
|
-
}
|
|
167
163
|
export declare class BlazeImage extends BaseWidget {
|
|
164
|
+
thumbnailElement: HTMLImageElement;
|
|
168
165
|
constructor();
|
|
169
|
-
|
|
166
|
+
load(src: string): void;
|
|
167
|
+
setRatio(ratio: string): void;
|
|
168
|
+
setBorderRadius(radius: string): void;
|
|
170
169
|
}
|
|
171
170
|
|
|
172
171
|
export * from './alert';
|
|
@@ -356,6 +355,7 @@ export interface IThumbnail {
|
|
|
356
355
|
|
|
357
356
|
export declare enum ErrorCode {
|
|
358
357
|
FailedToFindContainerId = 1,
|
|
358
|
+
FailedContainerIdHasWidgetAlready = 2,
|
|
359
359
|
FailedLoadingStories = 100,
|
|
360
360
|
FailedEnrichStories = 101,
|
|
361
361
|
FailedToHaveLabels = 103,
|
|
@@ -535,7 +535,7 @@ export interface IWidgetLabelBuilder {
|
|
|
535
535
|
|
|
536
536
|
export type ContentType = 'story';
|
|
537
537
|
export interface IWidgetViewOptionsBase {
|
|
538
|
-
orderType
|
|
538
|
+
orderType?: OrderType;
|
|
539
539
|
maxItemsCount?: number;
|
|
540
540
|
maxDisplayItemsCount?: number;
|
|
541
541
|
contentType?: ContentType;
|
|
@@ -689,7 +689,7 @@ export declare class AnalyticsEvent {
|
|
|
689
689
|
export declare class StoryEvent {
|
|
690
690
|
'story_start_id': string;
|
|
691
691
|
'story_id': string;
|
|
692
|
-
'
|
|
692
|
+
'story_title': string;
|
|
693
693
|
'story_page_id': string;
|
|
694
694
|
'story_page_count': number;
|
|
695
695
|
'story_page_type': string;
|
|
@@ -1035,6 +1035,7 @@ export interface LabelStyle {
|
|
|
1035
1035
|
padding: string;
|
|
1036
1036
|
font: string;
|
|
1037
1037
|
fontSize: string;
|
|
1038
|
+
textAlign?: string;
|
|
1038
1039
|
position: PositionType;
|
|
1039
1040
|
}
|
|
1040
1041
|
export interface StoryPlayerStyle {
|
|
@@ -1439,7 +1440,12 @@ export type OrderType = 'Manual' | 'AtoZ' | 'ZtoA' | 'RecentlyUpdatedFirst' | 'R
|
|
|
1439
1440
|
export declare const PlayTypeArray: readonly ["Widget", "Share", "SingleStory"];
|
|
1440
1441
|
export type PlayType = typeof PlayTypeArray[number];
|
|
1441
1442
|
|
|
1442
|
-
export type
|
|
1443
|
+
export type PositionInsideType = 'insideTopLeft' | 'insideTopRight' | 'insideMiddle' | 'insideBottomRight' | 'insideBottomLeft' | 'insideBottomMiddle' | 'insideMiddleLeft' | 'insideMiddleRight';
|
|
1444
|
+
export type PositionOutsideType = 'outsideUnder' | 'outsideBelow' | 'outsideAbove' | 'outsideTop' | 'outsideTopLeft' | 'outsideTopRight' | 'outsideBottomLeft' | 'outsideBottomRight' | 'outsideBottom' | 'outsideRight' | 'outsideLeft';
|
|
1445
|
+
export type PositionType = PositionInsideType | PositionOutsideType;
|
|
1446
|
+
export type PositionCircleRowLabelType = 'outsideBelow' | 'outsideAbove';
|
|
1447
|
+
export type PositionRectangleRowLabelType = PositionCircleRowLabelType | PositionInsideType;
|
|
1448
|
+
export type PositionRectangleRowHorizontalLabelType = PositionInsideType;
|
|
1443
1449
|
|
|
1444
1450
|
export type SeverityType = 'error' | 'warning' | 'info' | 'success';
|
|
1445
1451
|
|
|
@@ -1473,7 +1479,6 @@ export declare function mergeStyles(element: HTMLElement, styles: Partial<CSSSty
|
|
|
1473
1479
|
export declare function formatDate(date: Date): string;
|
|
1474
1480
|
export declare function formatUTCDate(date: Date): string;
|
|
1475
1481
|
export declare function getRandomId(): string;
|
|
1476
|
-
export declare function loadImage(src: string): Promise<any>;
|
|
1477
1482
|
export declare function setId(element: HTMLElement, prefix?: string, suffix?: string): void;
|
|
1478
1483
|
declare let isMobile: boolean;
|
|
1479
1484
|
declare const isIOS: boolean;
|
|
@@ -1526,50 +1531,56 @@ export * from './widget-story-video';
|
|
|
1526
1531
|
|
|
1527
1532
|
export interface BlazeWidgetItemOptions {
|
|
1528
1533
|
theme: IWidgetTheme;
|
|
1529
|
-
|
|
1534
|
+
content: IStory;
|
|
1530
1535
|
}
|
|
1531
|
-
export type itemStateType = 'loading' | 'done' | 'failed';
|
|
1532
1536
|
export declare class BlazeWidgetItem extends BaseWidget {
|
|
1533
1537
|
protected options: BlazeWidgetItemOptions;
|
|
1534
|
-
wrapper
|
|
1535
|
-
container
|
|
1536
|
-
|
|
1537
|
-
|
|
1538
|
-
|
|
1539
|
-
|
|
1540
|
-
|
|
1541
|
-
|
|
1542
|
-
theme
|
|
1543
|
-
|
|
1538
|
+
private wrapper;
|
|
1539
|
+
private container;
|
|
1540
|
+
private thumbnail;
|
|
1541
|
+
private thumbnailString;
|
|
1542
|
+
private thumbnailType;
|
|
1543
|
+
private label;
|
|
1544
|
+
private labelContainer;
|
|
1545
|
+
private labelBackground;
|
|
1546
|
+
private theme;
|
|
1547
|
+
private chip;
|
|
1548
|
+
private isLive;
|
|
1549
|
+
private isDisplaySkeleton;
|
|
1550
|
+
private blazeSkeletonThumbnail;
|
|
1551
|
+
private blazeSkeletonLabel;
|
|
1552
|
+
private analyticsCalls;
|
|
1553
|
+
private statusIndicatorSettings;
|
|
1554
|
+
content: IStory;
|
|
1544
1555
|
onClick: (() => void) | undefined;
|
|
1545
|
-
chip: HTMLElement;
|
|
1546
|
-
newChip: HTMLElement | undefined;
|
|
1547
|
-
state: itemStateType;
|
|
1548
|
-
isLive: boolean | undefined;
|
|
1549
|
-
isDisplaySkeleton: boolean;
|
|
1550
|
-
blazeSkeletonThumbnail: BlazeSkeleton | undefined;
|
|
1551
|
-
blazeSkeletonLabel: BlazeSkeleton | undefined;
|
|
1552
|
-
thumbnail: string;
|
|
1553
|
-
analyticsCalls: any;
|
|
1554
|
-
statusIndicatorSettings: IndicatorStyle;
|
|
1555
1556
|
constructor(options: BlazeWidgetItemOptions);
|
|
1556
|
-
|
|
1557
|
-
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
|
|
1561
|
-
|
|
1562
|
-
|
|
1563
|
-
|
|
1557
|
+
private initializeWidget;
|
|
1558
|
+
connectedCallback(): void;
|
|
1559
|
+
disconnectedCallback(): void;
|
|
1560
|
+
updateWidget(): void;
|
|
1561
|
+
private setupDOMElements;
|
|
1562
|
+
private setupEventListeners;
|
|
1563
|
+
private handleWidgetClick;
|
|
1564
|
+
private setData;
|
|
1565
|
+
getThumbnailUrl(): string;
|
|
1566
|
+
private removeSkeleton;
|
|
1567
|
+
private updateWidgetLayout;
|
|
1568
|
+
private updateLabel;
|
|
1569
|
+
private updateThumbnail;
|
|
1570
|
+
private updateContainerStyles;
|
|
1571
|
+
private updateLabelStyles;
|
|
1572
|
+
private updateInsideLabelStyles;
|
|
1573
|
+
private updateOutsideLabelStyles;
|
|
1574
|
+
private updateThumbnailStyles;
|
|
1575
|
+
getMaxChipSize(): DOMRect;
|
|
1564
1576
|
get chipDimenssions(): {
|
|
1565
1577
|
chipWidth: number;
|
|
1566
1578
|
chipHeight: number;
|
|
1567
1579
|
};
|
|
1568
|
-
|
|
1569
|
-
|
|
1570
|
-
|
|
1571
|
-
|
|
1572
|
-
thumbnailUrl(): string;
|
|
1580
|
+
private updateChipStyles;
|
|
1581
|
+
setTheme(theme: IWidgetTheme): void;
|
|
1582
|
+
setLive(): void;
|
|
1583
|
+
event(action: WidgetAction, data: Partial<WidgetEvent>, label?: string | undefined): void;
|
|
1573
1584
|
render(): void;
|
|
1574
1585
|
}
|
|
1575
1586
|
|
|
@@ -1582,6 +1593,10 @@ export declare class BlazeWidgetLabel {
|
|
|
1582
1593
|
mustInclude(...labels: Array<string | BlazeWidgetLabel>): BlazeWidgetLabel;
|
|
1583
1594
|
atLeastOneOf(...labels: Array<string | BlazeWidgetLabel>): BlazeWidgetLabel;
|
|
1584
1595
|
toString(): string;
|
|
1596
|
+
private static createLabel;
|
|
1597
|
+
private static validateAndProceed;
|
|
1598
|
+
private static validateNoCommas;
|
|
1599
|
+
private static isValidLabelFormat;
|
|
1585
1600
|
}
|
|
1586
1601
|
|
|
1587
1602
|
/// <reference types="node" />
|
|
@@ -1598,6 +1613,7 @@ export declare class BlazeWidgetLayout extends BlazeWidgetScrollable implements
|
|
|
1598
1613
|
analyticsStack: Record<WidgetAction, boolean>;
|
|
1599
1614
|
intersectionObserver: IntersectionObserver;
|
|
1600
1615
|
onResizeEvent: (this: Window, ev: UIEvent) => void;
|
|
1616
|
+
isWidgetReload: boolean | undefined;
|
|
1601
1617
|
constructor();
|
|
1602
1618
|
connectedCallback(): void;
|
|
1603
1619
|
disconnectedCallback(): void;
|
|
@@ -2058,6 +2074,7 @@ export declare class BlazeWidgetStory extends HTMLElement {
|
|
|
2058
2074
|
isStoryLoadCompletedTriggered: boolean;
|
|
2059
2075
|
isStoryActive: boolean;
|
|
2060
2076
|
isResumeOnFocusExecuted: boolean;
|
|
2077
|
+
refWidget: BlazeWidgetStory[] | undefined;
|
|
2061
2078
|
pageIndex: number;
|
|
2062
2079
|
container: HTMLElement;
|
|
2063
2080
|
progress: HTMLElement;
|
|
@@ -2140,5 +2157,6 @@ export declare class BlazeWidgetStory extends HTMLElement {
|
|
|
2140
2157
|
disconnectedCallback(): void;
|
|
2141
2158
|
renderCtaButton(pageIndex: number): void;
|
|
2142
2159
|
render(): void;
|
|
2160
|
+
shouldDisplayButton(navType: string): string;
|
|
2143
2161
|
}
|
|
2144
2162
|
|