@inappstory/slide-api 0.0.9 → 0.0.11
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/index.cjs +9 -6
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +4 -4
- package/dist/index.d.ts +4 -4
- package/dist/index.js +9 -6
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -616,7 +616,7 @@ interface SDKApi {
|
|
|
616
616
|
type: string;
|
|
617
617
|
}> | null;
|
|
618
618
|
}): void;
|
|
619
|
-
shareSlideScreenshot(shareId: string, hideElementsSelector?: string): void;
|
|
619
|
+
shareSlideScreenshot(shareId: string, hideElementsSelector?: string, shareText?: string): void;
|
|
620
620
|
isExistsShowStorySlide: boolean;
|
|
621
621
|
showStorySlide(index: number): void;
|
|
622
622
|
isExistsShowNextStory: boolean;
|
|
@@ -789,7 +789,7 @@ interface SDKInterface {
|
|
|
789
789
|
*
|
|
790
790
|
* window.share_slide_screenshot(shareId, hideElementsSelector);
|
|
791
791
|
*/
|
|
792
|
-
shareSlideScreenshot(shareId: string, hideElementsSelector?: string): void;
|
|
792
|
+
shareSlideScreenshot(shareId: string, hideElementsSelector?: string, shareText?: string): void;
|
|
793
793
|
/**
|
|
794
794
|
* Possible implementation
|
|
795
795
|
*
|
|
@@ -807,7 +807,7 @@ interface SDKInterface {
|
|
|
807
807
|
*/
|
|
808
808
|
setStorySessionValue(key: string, value: string): void;
|
|
809
809
|
getStorySessionValue(key: string): string | undefined;
|
|
810
|
-
updateTimeline(slideIndex: number, action: TIMELINE_ACTION, currentTime: number, duration: number, showLoader: boolean, showError: boolean): void;
|
|
810
|
+
updateTimeline?(slideIndex: number, action: TIMELINE_ACTION, currentTime: number, duration: number, showLoader: boolean, showError: boolean): void;
|
|
811
811
|
/**
|
|
812
812
|
* Get fonts from session.cache
|
|
813
813
|
*/
|
|
@@ -846,4 +846,4 @@ type SlideApi = {
|
|
|
846
846
|
};
|
|
847
847
|
declare const getSlideApi: (_sdkInterface: SDKInterface) => SlideApi;
|
|
848
848
|
export { getSlideApi, Widgets };
|
|
849
|
-
export type { SDKInterface, SlideApi, WidgetCopyApi, WidgetDataInputApi, WidgetDateCountdownApi, WidgetMultiSlideApi, WidgetPollApi, WidgetPollLayersApi, WidgetQuestApi, WidgetQuizApi, WidgetQuizGroupedApi, WidgetRangeSliderApi, WidgetRateApi, WidgetShareApi, WidgetTestApi, WidgetVoteApi, IAnimation, WidgetsSharedDataMap, WidgetRangeSliderSharedData, WidgetPollSharedData, WidgetVoteSharedData };
|
|
849
|
+
export type { SDKInterface, SlideApi, WidgetCopyApi, WidgetDataInputApi, WidgetDateCountdownApi, WidgetMultiSlideApi, WidgetPollApi, WidgetPollLayersApi, WidgetQuestApi, WidgetQuizApi, WidgetQuizGroupedApi, WidgetRangeSliderApi, WidgetRateApi, WidgetShareApi, WidgetTestApi, WidgetVoteApi, IAnimation, WidgetsSharedDataMap, WidgetRangeSliderSharedData, WidgetPollSharedData, WidgetVoteSharedData, FontDTO };
|
package/dist/index.d.ts
CHANGED
|
@@ -616,7 +616,7 @@ interface SDKApi {
|
|
|
616
616
|
type: string;
|
|
617
617
|
}> | null;
|
|
618
618
|
}): void;
|
|
619
|
-
shareSlideScreenshot(shareId: string, hideElementsSelector?: string): void;
|
|
619
|
+
shareSlideScreenshot(shareId: string, hideElementsSelector?: string, shareText?: string): void;
|
|
620
620
|
isExistsShowStorySlide: boolean;
|
|
621
621
|
showStorySlide(index: number): void;
|
|
622
622
|
isExistsShowNextStory: boolean;
|
|
@@ -789,7 +789,7 @@ interface SDKInterface {
|
|
|
789
789
|
*
|
|
790
790
|
* window.share_slide_screenshot(shareId, hideElementsSelector);
|
|
791
791
|
*/
|
|
792
|
-
shareSlideScreenshot(shareId: string, hideElementsSelector?: string): void;
|
|
792
|
+
shareSlideScreenshot(shareId: string, hideElementsSelector?: string, shareText?: string): void;
|
|
793
793
|
/**
|
|
794
794
|
* Possible implementation
|
|
795
795
|
*
|
|
@@ -807,7 +807,7 @@ interface SDKInterface {
|
|
|
807
807
|
*/
|
|
808
808
|
setStorySessionValue(key: string, value: string): void;
|
|
809
809
|
getStorySessionValue(key: string): string | undefined;
|
|
810
|
-
updateTimeline(slideIndex: number, action: TIMELINE_ACTION, currentTime: number, duration: number, showLoader: boolean, showError: boolean): void;
|
|
810
|
+
updateTimeline?(slideIndex: number, action: TIMELINE_ACTION, currentTime: number, duration: number, showLoader: boolean, showError: boolean): void;
|
|
811
811
|
/**
|
|
812
812
|
* Get fonts from session.cache
|
|
813
813
|
*/
|
|
@@ -846,4 +846,4 @@ type SlideApi = {
|
|
|
846
846
|
};
|
|
847
847
|
declare const getSlideApi: (_sdkInterface: SDKInterface) => SlideApi;
|
|
848
848
|
export { getSlideApi, Widgets };
|
|
849
|
-
export type { SDKInterface, SlideApi, WidgetCopyApi, WidgetDataInputApi, WidgetDateCountdownApi, WidgetMultiSlideApi, WidgetPollApi, WidgetPollLayersApi, WidgetQuestApi, WidgetQuizApi, WidgetQuizGroupedApi, WidgetRangeSliderApi, WidgetRateApi, WidgetShareApi, WidgetTestApi, WidgetVoteApi, IAnimation, WidgetsSharedDataMap, WidgetRangeSliderSharedData, WidgetPollSharedData, WidgetVoteSharedData };
|
|
849
|
+
export type { SDKInterface, SlideApi, WidgetCopyApi, WidgetDataInputApi, WidgetDateCountdownApi, WidgetMultiSlideApi, WidgetPollApi, WidgetPollLayersApi, WidgetQuestApi, WidgetQuizApi, WidgetQuizGroupedApi, WidgetRangeSliderApi, WidgetRateApi, WidgetShareApi, WidgetTestApi, WidgetVoteApi, IAnimation, WidgetsSharedDataMap, WidgetRangeSliderSharedData, WidgetPollSharedData, WidgetVoteSharedData, FontDTO };
|
package/dist/index.js
CHANGED
|
@@ -1131,8 +1131,8 @@ class EsModuleSdkApi {
|
|
|
1131
1131
|
share(id, config) {
|
|
1132
1132
|
this.sdkBinding().share(id, config);
|
|
1133
1133
|
}
|
|
1134
|
-
shareSlideScreenshot(shareId, hideElementsSelector) {
|
|
1135
|
-
this.sdkBinding().shareSlideScreenshot(shareId, hideElementsSelector);
|
|
1134
|
+
shareSlideScreenshot(shareId, hideElementsSelector, shareText) {
|
|
1135
|
+
this.sdkBinding().shareSlideScreenshot(shareId, hideElementsSelector, shareText);
|
|
1136
1136
|
}
|
|
1137
1137
|
get isExistsShowStorySlide() {
|
|
1138
1138
|
return true;
|
|
@@ -1153,7 +1153,10 @@ class EsModuleSdkApi {
|
|
|
1153
1153
|
return this.sdkBinding().getStorySessionValue(key);
|
|
1154
1154
|
}
|
|
1155
1155
|
updateTimeline(slideIndex, action, currentTime, duration, showLoader, showError) {
|
|
1156
|
-
this.sdkBinding().updateTimeline
|
|
1156
|
+
const updateTimeline = this.sdkBinding().updateTimeline;
|
|
1157
|
+
if (updateTimeline != null) {
|
|
1158
|
+
updateTimeline(slideIndex, action, currentTime, duration, showLoader, showError);
|
|
1159
|
+
}
|
|
1157
1160
|
}
|
|
1158
1161
|
storyPausedCallback(currentTime) { }
|
|
1159
1162
|
storyResumedCallback(currentTime) { }
|
|
@@ -1558,7 +1561,7 @@ class WidgetCopy extends WidgetBase {
|
|
|
1558
1561
|
si: this.slideIndex,
|
|
1559
1562
|
wi: this.elementId,
|
|
1560
1563
|
wl: buttonText,
|
|
1561
|
-
|
|
1564
|
+
wv: clipboardTarget,
|
|
1562
1565
|
}, {
|
|
1563
1566
|
story_id: this.storyId,
|
|
1564
1567
|
slide_index: this.slideIndex,
|
|
@@ -4406,7 +4409,7 @@ class WidgetShare extends WidgetBase {
|
|
|
4406
4409
|
si: this.slideIndex,
|
|
4407
4410
|
wi: this.elementId,
|
|
4408
4411
|
wl: buttonText,
|
|
4409
|
-
|
|
4412
|
+
wv: this.shareTarget ?? "",
|
|
4410
4413
|
wa: result ? 1 : 0,
|
|
4411
4414
|
wal: via ?? "",
|
|
4412
4415
|
}, {
|
|
@@ -4438,7 +4441,7 @@ class WidgetShare extends WidgetBase {
|
|
|
4438
4441
|
});
|
|
4439
4442
|
}
|
|
4440
4443
|
else if (this.shareType === "slide") {
|
|
4441
|
-
this.sdkApi.shareSlideScreenshot(this.id, "[data-element-id='" + this.elementId + "']");
|
|
4444
|
+
this.sdkApi.shareSlideScreenshot(this.id, "[data-element-id='" + this.elementId + "']", this.shareTarget ? this.shareTarget : undefined);
|
|
4442
4445
|
}
|
|
4443
4446
|
}
|
|
4444
4447
|
}
|