fs-alipay-ad-component 0.0.7 → 0.0.8
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/CHANGELOG.md +4 -0
- package/es/config/index.js +1 -1
- package/es/index/index.js +10 -3
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
package/es/config/index.js
CHANGED
|
@@ -5,7 +5,7 @@ export var MOCK_URL = 'http://127.0.0.1:4523/mock/1080865/'; // mock地址
|
|
|
5
5
|
export default function getEnv() {
|
|
6
6
|
// 环境变量类型,值为:test、beta、prod
|
|
7
7
|
var ENVIRONMENT_TYPE = 'prod';
|
|
8
|
-
var XCXVERSION = '0.0.
|
|
8
|
+
var XCXVERSION = '0.0.8'; // 组件版本号
|
|
9
9
|
var APP_ID = "fs-alipay-ad-component-" + ENVIRONMENT_TYPE;
|
|
10
10
|
var environmentObj = {
|
|
11
11
|
test: {
|
package/es/index/index.js
CHANGED
|
@@ -36,6 +36,8 @@ Component({
|
|
|
36
36
|
// 付呗自用
|
|
37
37
|
minaVersion: '',
|
|
38
38
|
// 宿主小程序版本号
|
|
39
|
+
showConfirm: false,
|
|
40
|
+
// 是否展示确认弹窗
|
|
39
41
|
onAdInfoReady: function onAdInfoReady() {}
|
|
40
42
|
},
|
|
41
43
|
didMount: function didMount() {
|
|
@@ -134,7 +136,7 @@ Component({
|
|
|
134
136
|
if (res) {
|
|
135
137
|
_this3.setData({
|
|
136
138
|
adInfo: res,
|
|
137
|
-
showPayed:
|
|
139
|
+
showPayed: _this3.props.showConfirm
|
|
138
140
|
});
|
|
139
141
|
_this3.props.onAdInfoReady();
|
|
140
142
|
}
|
|
@@ -147,8 +149,11 @@ Component({
|
|
|
147
149
|
showAd: function showAd() {
|
|
148
150
|
this.setData({
|
|
149
151
|
showAdDom: true,
|
|
150
|
-
showPayed:
|
|
152
|
+
showPayed: this.props.showConfirm
|
|
151
153
|
});
|
|
154
|
+
if (!this.props.showConfirm) {
|
|
155
|
+
this.handleShowAd();
|
|
156
|
+
}
|
|
152
157
|
this.handleExposureDataReport();
|
|
153
158
|
},
|
|
154
159
|
/**
|
|
@@ -172,7 +177,9 @@ Component({
|
|
|
172
177
|
if (typeId === AD_TYPE_ID.H5Link) {
|
|
173
178
|
this.navigateToH5();
|
|
174
179
|
}
|
|
175
|
-
this.
|
|
180
|
+
if (this.props.showConfirm) {
|
|
181
|
+
this.handleExposureDataReport(ACTION_TYPE.click);
|
|
182
|
+
}
|
|
176
183
|
},
|
|
177
184
|
/**
|
|
178
185
|
* @function 跳转H5页面
|