@paystack/inline-js 2.11.0-dev.12 → 2.11.0-dev.13

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.
Files changed (2) hide show
  1. package/dist/inline.js +11 -8
  2. package/package.json +1 -1
package/dist/inline.js CHANGED
@@ -18,7 +18,8 @@ var devConfig = _extends({}, baseConfig, {
18
18
  paystackApiUrl: 'https://studio-api.paystack.co/',
19
19
  siteUrl: 'https://paystack.com',
20
20
  pusherKey: '1c7b262ee18455815893',
21
- pusherUrl: 'http://localhost:8081/static/vendor/pusher.min.js'
21
+ pusherUrl: 'http://localhost:8081/static/vendor/pusher.min.js',
22
+ amplitudeApiKey: '665517b6c99a9ac8f24924f0871f5750'
22
23
  });
23
24
 
24
25
  var stagingConfig = _extends({}, baseConfig, {
@@ -27,7 +28,8 @@ var stagingConfig = _extends({}, baseConfig, {
27
28
  paystackApiUrl: 'https://studio-api.paystack.co/',
28
29
  siteUrl: 'https://beta.paystack.com',
29
30
  pusherKey: '1c7b262ee18455815893',
30
- pusherUrl: 'https://checkout-studio.paystack.com/static/vendor/pusher.min.js'
31
+ pusherUrl: 'https://checkout-studio.paystack.com/static/vendor/pusher.min.js',
32
+ amplitudeApiKey: '6f20866a07122ac9d35f97111561fb8d'
31
33
  });
32
34
 
33
35
  var productionConfig = _extends({}, baseConfig, {
@@ -36,7 +38,8 @@ var productionConfig = _extends({}, baseConfig, {
36
38
  paystackApiUrl: 'https://api.paystack.co/',
37
39
  siteUrl: 'https://paystack.com',
38
40
  pusherKey: '8e4b9b7ca3418bd5cdc8',
39
- pusherUrl: 'https://checkout.paystack.com/static/vendor/pusher.min.js'
41
+ pusherUrl: 'https://checkout.paystack.com/static/vendor/pusher.min.js',
42
+ amplitudeApiKey: 'e2bee428e183863bc7699daded4d1f7d'
40
43
  });
41
44
 
42
45
  var configurations = {
@@ -914,7 +917,7 @@ var isAppleOS = function isAppleOS() {
914
917
  return isIOS() || isMAC && isSafari;
915
918
  };
916
919
 
917
- var AnalyticsAPI = {
920
+ var TransactionLoggingAPI = {
918
921
  saveLog: function saveLog(transactionId, merchantPublicKey, log) {
919
922
  var url = config.paystackApiUrl + "transaction/update_log/" + transactionId;
920
923
  var headers = {
@@ -935,7 +938,7 @@ var AnalyticsAPI = {
935
938
  }
936
939
  };
937
940
 
938
- var AnalyticsFunctions = {
941
+ var TransactionLoggingFunctions = {
939
942
  initializeLog: function initializeLog(log) {
940
943
  var _ref = log || {},
941
944
  attempts = _ref.attempts,
@@ -1014,7 +1017,7 @@ var AnalyticsFunctions = {
1014
1017
  saveLog: function saveLog() {
1015
1018
  try {
1016
1019
  if (this.response) {
1017
- return AnalyticsAPI.saveLog(this.id, this.response.merchant_key, this.log);
1020
+ return TransactionLoggingAPI.saveLog(this.id, this.response.merchant_key, this.log);
1018
1021
  }
1019
1022
  } catch (error) {
1020
1023
  // we don't need to do anything since this should not affect the transaction
@@ -1023,7 +1026,7 @@ var AnalyticsFunctions = {
1023
1026
  saveIpAddress: function saveIpAddress() {
1024
1027
  try {
1025
1028
  if (this.response) {
1026
- return AnalyticsAPI.saveIp(this.id, this.response.merchant_key);
1029
+ return TransactionLoggingAPI.saveIp(this.id, this.response.merchant_key);
1027
1030
  }
1028
1031
  } catch (error) {
1029
1032
  // we don't need to do anything since this should not affect the transaction
@@ -1056,7 +1059,7 @@ var TransactionApi = {
1056
1059
 
1057
1060
  // Analytics
1058
1061
  inlineTransactionInstance.log = null;
1059
- Object.assign(inlineTransactionInstance, AnalyticsFunctions);
1062
+ Object.assign(inlineTransactionInstance, TransactionLoggingFunctions);
1060
1063
  inlineTransactionInstance.initializeLog(res.data.log);
1061
1064
  inlineTransactionInstance.saveIpAddress();
1062
1065
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@paystack/inline-js",
3
- "version": "2.11.0-dev.12",
3
+ "version": "2.11.0-dev.13",
4
4
  "description": "Client-side library to load the Paystack checkout form",
5
5
  "main": "lib/inline.js",
6
6
  "module": "es/inline.js",