gxd-uni-library-editx 1.0.138 → 1.0.140

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gxd-uni-library-editx",
3
- "version": "1.0.138",
3
+ "version": "1.0.140",
4
4
  "private": false,
5
5
  "description": "聚福宝基础插件专用库",
6
6
  "main": "index.js",
@@ -437,8 +437,8 @@
437
437
  let windowTop = uni.getSystemInfoSync().windowTop || 0;
438
438
  let temp = 'center top'; //默认值
439
439
  let top = this.navBarHeight + this.statusBarHeight;
440
- //自定义 + 显示顶部导航
441
- if (this.navigationStyle && (this.showBar || this.isPreviewShowBar)) {
440
+ //自定义 + 显示顶部导航 (微信模式不显示bar自定强制开启自定义头)
441
+ if (this.navigationStyle && (this.showBar || this.isPreviewShowBar || this.isCustomNavigation) ) {
442
442
  temp = `center -${top + this.getRpx(windowTop)}rpx`;
443
443
  }
444
444
  return temp;
@@ -959,6 +959,21 @@ class Helpers {
959
959
  */
960
960
  handleTo(obj = {}, redirect, type = true, notHistory = false) {
961
961
 
962
+ //直接跳转到第三方
963
+ if(obj.cusType === 'thirdH5') {
964
+ let regMp = /^(https:\/\/).+$/;
965
+ let regH5 = /^(https:\/\/|\/\/|http:\/\/).+$/;
966
+ //#ifdef H5
967
+ if(regH5.test(obj.url)) window.location.href = obj.url;
968
+ // #endif
969
+ //#ifdef MP-WEIXIN
970
+ if(regMp.test(obj.url)){
971
+ uni.navigateTo({
972
+ url: `/pages/thirdview/thirdview?seatUrl=${Base64.encodeURI(obj['url'])}`
973
+ });
974
+ }
975
+ // #endif
976
+ }
962
977
 
963
978
  //#ifdef H5
964
979
  if (window['$configProject'] && window['$configProject'].isPreview) {
@@ -1264,6 +1279,7 @@ class Helpers {
1264
1279
  //链接地址
1265
1280
  if(res.type === 'url' && res.value){
1266
1281
  obj.url = res.value;
1282
+ obj.cusType = 'thirdH5';
1267
1283
  cb(obj)
1268
1284
  }
1269
1285
  })