zmp-sdk 2.15.0-rc.1 → 2.15.0-rc.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/dist/browser.min.js +28 -16
- package/dist/index.es.js +28 -16
- package/dist/index.js +3 -3
- package/dist/index.umd.js +3 -3
- package/package.json +1 -1
package/dist/browser.min.js
CHANGED
|
@@ -36793,7 +36793,7 @@
|
|
|
36793
36793
|
}
|
|
36794
36794
|
};
|
|
36795
36795
|
|
|
36796
|
-
var version = "2.15.0-rc.
|
|
36796
|
+
var version = "2.15.0-rc.2";
|
|
36797
36797
|
|
|
36798
36798
|
class Basics {
|
|
36799
36799
|
/**
|
|
@@ -38693,21 +38693,33 @@
|
|
|
38693
38693
|
if (!resData || resData.err !== 0) {
|
|
38694
38694
|
throw apiResponse.error.cannotGetShareInfo();
|
|
38695
38695
|
}
|
|
38696
|
-
|
|
38697
|
-
|
|
38698
|
-
|
|
38699
|
-
|
|
38700
|
-
|
|
38701
|
-
}
|
|
38702
|
-
|
|
38703
|
-
|
|
38704
|
-
|
|
38705
|
-
|
|
38706
|
-
|
|
38707
|
-
|
|
38708
|
-
|
|
38709
|
-
|
|
38710
|
-
|
|
38696
|
+
const zaloVersion = getZaloVersion();
|
|
38697
|
+
const platform = checkPlatform();
|
|
38698
|
+
if ((platform.isAndroid && zaloVersion % 100000 <= 593) ||
|
|
38699
|
+
(platform.isIOS && zaloVersion <= 424)) {
|
|
38700
|
+
reqData = {
|
|
38701
|
+
link: `${resData.data.shareUrl}`,
|
|
38702
|
+
chatOnly: object.data.chatOnly ? 1 : 0
|
|
38703
|
+
};
|
|
38704
|
+
object.type = 'link';
|
|
38705
|
+
}
|
|
38706
|
+
else {
|
|
38707
|
+
reqData = {
|
|
38708
|
+
data: {
|
|
38709
|
+
ZInstantAPIInfo: {
|
|
38710
|
+
url: `${resData.data.zinstantApi}`,
|
|
38711
|
+
zinstantdata_id: `templateId=11412&appId=${this.getAppId()}&shareId=${resData.data.shareId}`
|
|
38712
|
+
},
|
|
38713
|
+
previewMsgText: {
|
|
38714
|
+
msg: {
|
|
38715
|
+
en: description.en,
|
|
38716
|
+
vi: description.vi
|
|
38717
|
+
}
|
|
38718
|
+
},
|
|
38719
|
+
enableReactions: 1
|
|
38720
|
+
}
|
|
38721
|
+
};
|
|
38722
|
+
}
|
|
38711
38723
|
}
|
|
38712
38724
|
return yield this.callNative(ACTION.OPEN_SHARESHEET.name, Object.assign(Object.assign({ type: ShareSheetType[object.type] }, reqData), { zapp: this.getZAppId() }), {
|
|
38713
38725
|
haveTimeout: false
|
package/dist/index.es.js
CHANGED
|
@@ -36790,7 +36790,7 @@ const apiResponse = {
|
|
|
36790
36790
|
}
|
|
36791
36791
|
};
|
|
36792
36792
|
|
|
36793
|
-
var version = "2.15.0-rc.
|
|
36793
|
+
var version = "2.15.0-rc.2";
|
|
36794
36794
|
|
|
36795
36795
|
class Basics {
|
|
36796
36796
|
/**
|
|
@@ -38690,21 +38690,33 @@ class Zalo {
|
|
|
38690
38690
|
if (!resData || resData.err !== 0) {
|
|
38691
38691
|
throw apiResponse.error.cannotGetShareInfo();
|
|
38692
38692
|
}
|
|
38693
|
-
|
|
38694
|
-
|
|
38695
|
-
|
|
38696
|
-
|
|
38697
|
-
|
|
38698
|
-
}
|
|
38699
|
-
|
|
38700
|
-
|
|
38701
|
-
|
|
38702
|
-
|
|
38703
|
-
|
|
38704
|
-
|
|
38705
|
-
|
|
38706
|
-
|
|
38707
|
-
|
|
38693
|
+
const zaloVersion = getZaloVersion();
|
|
38694
|
+
const platform = checkPlatform();
|
|
38695
|
+
if ((platform.isAndroid && zaloVersion % 100000 <= 593) ||
|
|
38696
|
+
(platform.isIOS && zaloVersion <= 424)) {
|
|
38697
|
+
reqData = {
|
|
38698
|
+
link: `${resData.data.shareUrl}`,
|
|
38699
|
+
chatOnly: object.data.chatOnly ? 1 : 0
|
|
38700
|
+
};
|
|
38701
|
+
object.type = 'link';
|
|
38702
|
+
}
|
|
38703
|
+
else {
|
|
38704
|
+
reqData = {
|
|
38705
|
+
data: {
|
|
38706
|
+
ZInstantAPIInfo: {
|
|
38707
|
+
url: `${resData.data.zinstantApi}`,
|
|
38708
|
+
zinstantdata_id: `templateId=11412&appId=${this.getAppId()}&shareId=${resData.data.shareId}`
|
|
38709
|
+
},
|
|
38710
|
+
previewMsgText: {
|
|
38711
|
+
msg: {
|
|
38712
|
+
en: description.en,
|
|
38713
|
+
vi: description.vi
|
|
38714
|
+
}
|
|
38715
|
+
},
|
|
38716
|
+
enableReactions: 1
|
|
38717
|
+
}
|
|
38718
|
+
};
|
|
38719
|
+
}
|
|
38708
38720
|
}
|
|
38709
38721
|
return yield this.callNative(ACTION.OPEN_SHARESHEET.name, Object.assign(Object.assign({ type: ShareSheetType[object.type] }, reqData), { zapp: this.getZAppId() }), {
|
|
38710
38722
|
haveTimeout: false
|