@paydock/client-sdk 1.119.2 → 1.120.1-beta

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.
@@ -1,3 +1,4 @@
1
1
  import { ApplePayButtonType } from "../types/apple-pay-button-type.type";
2
2
  export declare const generateApplePayButtonStyles: (buttonType?: ApplePayButtonType) => string;
3
+ export declare const generateApplePaySpanStyles: () => string;
3
4
  //# sourceMappingURL=apple-pay-button-style.constant.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"apple-pay-button-style.constant.d.ts","sourceRoot":"","sources":["../../../../../src/wallet-buttons-express/services/apple-pay/constants/apple-pay-button-style.constant.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,qCAAqC,CAAC;AAEzE,eAAO,MAAM,4BAA4B,gBAAgB,kBAAkB,KAAa,MAqDvF,CAAA"}
1
+ {"version":3,"file":"apple-pay-button-style.constant.d.ts","sourceRoot":"","sources":["../../../../../src/wallet-buttons-express/services/apple-pay/constants/apple-pay-button-style.constant.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,qCAAqC,CAAC;AAEzE,eAAO,MAAM,4BAA4B,gBAAgB,kBAAkB,KAAa,MAsDvF,CAAA;AAGD,eAAO,MAAM,0BAA0B,cAiBtC,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"multi-widget.d.ts","sourceRoot":"","sources":["../../src/widget/multi-widget.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,IAAI,EAAe,MAAM,oBAAoB,CAAC;AACvD,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,EACL,OAAO,EACP,MAAM,EAMN,WAAW,EAEX,MAAM,EACN,iBAAiB,EAAE,WAAW,EAAE,iBAAiB,EAAE,YAAY,EAChE,MAAM,qBAAqB,CAAC;AAE7B,OAAO,EACH,kBAAkB,EAClB,kBAAkB,EAClB,yBAAyB,EACzB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E,MAAM;IASlC,MAAM;IAIb;;;;;;;;;OASG;IACI,aAAa,CAChB,EAAE,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,EACzB,OAAO,GAAE,CAAC,KAAK,KAAA,KAAK,IAAqB,GAC1C,IAAI;IAgBP;;;;;;OAMG;IACI,WAAW,CAAC,IAAI,KAAA;IAIhB,OAAO;IAId,SAAS,CAAC,gBAAgB,CAAC,GAAG,EAAE,WAAW;CAa9C;AAED,OAAO,EAAE,WAAW,EAAE,CAAC"}
@@ -929,7 +929,7 @@
929
929
  version: 'x-sdk-version',
930
930
  type: 'x-sdk-type'
931
931
  });
932
- SDK._version = 'v1.119.2';
932
+ SDK._version = 'v1.120.1-beta';
933
933
 
934
934
  /******************************************************************************
935
935
  Copyright (c) Microsoft Corporation.
@@ -1774,6 +1774,20 @@
1774
1774
  return null;
1775
1775
  }
1776
1776
  }
1777
+ }, {
1778
+ key: "validateJWTWhitelistedDomains",
1779
+ value: function validateJWTWhitelistedDomains(body) {
1780
+ var _a;
1781
+ try {
1782
+ if (!body.meta) return true;
1783
+ var meta = this.extractData(body);
1784
+ if (!meta) return true;
1785
+ if (!((_a = meta.whitelist_domains) === null || _a === void 0 ? void 0 : _a.length)) return true;
1786
+ return meta.whitelist_domains.includes(window.location.hostname);
1787
+ } catch (err) {
1788
+ return true;
1789
+ }
1790
+ }
1777
1791
  }, {
1778
1792
  key: "getAccessHeaderNameByToken",
1779
1793
  value: function getAccessHeaderNameByToken(token) {
@@ -4191,8 +4205,8 @@
4191
4205
  var params = {
4192
4206
  enabled: 'true',
4193
4207
  accountId: '974691',
4194
- agentId: '1386157152',
4195
- applicationId: '1386157152',
4208
+ agentId: '1386157150',
4209
+ applicationId: '1386157150',
4196
4210
  licenseKey: '4848a32285',
4197
4211
  trustKey: '974691'
4198
4212
  };
@@ -5803,7 +5817,9 @@
5803
5817
  MASTERCARD: 'mastercard',
5804
5818
  SOLO: 'solo',
5805
5819
  VISA: 'visa',
5806
- VISA_WHITE: 'visa_white'
5820
+ VISA_WHITE: 'visa_white',
5821
+ EFTPOS: 'eftpos',
5822
+ EFTPOS_WHITE: 'eftpos_white'
5807
5823
  };
5808
5824
  var SUPPORTED_CHECKOUT_META_COLLECTION = [].concat(['brand_name', 'cart_border_color', 'reference', 'email', 'hdr_img', 'logo_img', 'pay_flow_color', 'first_name', 'last_name', 'address_line', 'address_line2', 'address_city', 'address_state', 'address_postcode', 'address_country', 'phone', 'hide_shipping_address'], ['first_name', 'last_name', 'phone', 'tokenize', 'email', 'gender', 'date_of_birth', 'charge', 'statistics', 'hide_shipping_address'], ['amount', 'currency', 'email', 'first_name', 'last_name', 'address_line', 'address_line2', 'address_city', 'address_state', 'address_postcode', 'address_country', 'phone'], ['customer_storage_number', 'tokenise_algorithm']);
5809
5825
  var WALLET_GATEWAY;
@@ -10825,6 +10841,26 @@
10825
10841
  }]);
10826
10842
  }(WalletService);
10827
10843
 
10844
+ var APPLE_PAY_BUTTON_TYPES_ARIA_LABEL_MAPPING = {
10845
+ 'add-money': 'Add money with Apple Pay',
10846
+ "book": 'Book with Apple Pay',
10847
+ "buy": 'Buy with Apple Pay',
10848
+ 'check-out': 'Check out with Apple Pay',
10849
+ "continue": 'Continue with Apple Pay',
10850
+ "contribute": 'Contribute with Apple Pay',
10851
+ "donate": 'Donate with Apple Pay',
10852
+ "order": 'Order with Apple Pay',
10853
+ "pay": 'Pay with Apple Pay',
10854
+ "plain": 'Apple Pay',
10855
+ "reload": 'Reload with Apple Pay',
10856
+ "rent": 'Rent with Apple Pay',
10857
+ 'set-up': 'Set up with Apple Pay',
10858
+ "subscribe": 'Subscribe with Apple Pay',
10859
+ "support": 'Support with Apple Pay',
10860
+ "tip": 'Tip with Apple Pay',
10861
+ 'top-up': 'Top up with Apple Pay'
10862
+ };
10863
+
10828
10864
  var AppleWalletService = /*#__PURE__*/function (_WalletService) {
10829
10865
  function AppleWalletService(publicKey, meta, gatewayName, eventEmitter) {
10830
10866
  var _this;
@@ -10977,11 +11013,13 @@
10977
11013
  var _a, _b, _c;
10978
11014
  if (((_a = this.meta) === null || _a === void 0 ? void 0 : _a.style) && _typeof$1((_b = this.meta) === null || _b === void 0 ? void 0 : _b.style) === 'object') {
10979
11015
  var metaStyles = JSON.parse(JSON.stringify((_c = this.meta) === null || _c === void 0 ? void 0 : _c.style));
10980
- if ('google' in metaStyles) metaStyles === null || metaStyles === void 0 ? true : delete metaStyles.google; // to offer backward compatibility
10981
- if ('apple' in metaStyles) return metaStyles === null || metaStyles === void 0 ? void 0 : metaStyles.apple;else return metaStyles; // to offer backward compatibility
10982
- } else {
10983
- return null;
11016
+ if ('google' in metaStyles)
11017
+ // biome-ignore lint/performance/noDelete: <explanation>
11018
+ metaStyles === null || metaStyles === void 0 ? true : delete metaStyles.google; // to offer backward compatibility
11019
+ if ('apple' in metaStyles) return metaStyles === null || metaStyles === void 0 ? void 0 : metaStyles.apple;
11020
+ return metaStyles; // to offer backward compatibility
10984
11021
  }
11022
+ return null;
10985
11023
  }
10986
11024
  }, {
10987
11025
  key: "getMetaRawDataInitialization",
@@ -10989,11 +11027,13 @@
10989
11027
  var _a, _b, _c, _d;
10990
11028
  if (((_a = this.meta) === null || _a === void 0 ? void 0 : _a.raw_data_initialization) && ((_b = this.meta) === null || _b === void 0 ? void 0 : _b.raw_data_initialization) && _typeof$1((_c = this.meta) === null || _c === void 0 ? void 0 : _c.raw_data_initialization) === 'object') {
10991
11029
  var metaRawDataInit = JSON.parse(JSON.stringify((_d = this.meta) === null || _d === void 0 ? void 0 : _d.raw_data_initialization));
10992
- if ('google' in metaRawDataInit) metaRawDataInit === null || metaRawDataInit === void 0 ? true : delete metaRawDataInit.google; // to offer backward compatibility
10993
- if ('apple' in metaRawDataInit) return metaRawDataInit === null || metaRawDataInit === void 0 ? void 0 : metaRawDataInit.apple;else return metaRawDataInit; // to offer backward compatibility
10994
- } else {
10995
- return null;
11030
+ if ('google' in metaRawDataInit)
11031
+ // biome-ignore lint/performance/noDelete: <explanation>
11032
+ metaRawDataInit === null || metaRawDataInit === void 0 ? true : delete metaRawDataInit.google; // to offer backward compatibility
11033
+ if ('apple' in metaRawDataInit) return metaRawDataInit === null || metaRawDataInit === void 0 ? void 0 : metaRawDataInit.apple;
11034
+ return metaRawDataInit; // to offer backward compatibility
10996
11035
  }
11036
+ return null;
10997
11037
  }
10998
11038
  }, {
10999
11039
  key: "isShippingRequired",
@@ -11080,16 +11120,25 @@
11080
11120
  key: "mount",
11081
11121
  value: function mount(container) {
11082
11122
  var _this4 = this;
11083
- var style = document.createElement('style');
11084
- style.innerHTML = this.createButtonStyle();
11085
- document.head.appendChild(style);
11086
- var button = document.createElement('div');
11123
+ var _a;
11124
+ var styleButton = document.createElement('style');
11125
+ styleButton.innerHTML = this.createButtonStyle();
11126
+ document.head.appendChild(styleButton);
11127
+ var styleSpan = document.createElement('style');
11128
+ styleSpan.innerHTML = this.createSpanStyle();
11129
+ document.head.appendChild(styleSpan);
11130
+ var button = document.createElement('button');
11087
11131
  button.onclick = function () {
11088
11132
  return _this4.onApplePayButtonClicked();
11089
11133
  };
11134
+ var span = document.createElement('span');
11135
+ var text = APPLE_PAY_BUTTON_TYPES_ARIA_LABEL_MAPPING[((_a = this.getMetaStyles()) === null || _a === void 0 ? void 0 : _a.button_type) || 'plain'];
11136
+ span.innerText = text;
11090
11137
  button.classList.add('paydock-apple-container', 'apple-pay-button', 'apple-pay-button-black');
11091
11138
  button.setAttribute('tabindex', '0');
11092
11139
  button.setAttribute('role', 'button');
11140
+ button.appendChild(span);
11141
+ button.setAttribute('aria-label', text);
11093
11142
  container.getElement().appendChild(button);
11094
11143
  }
11095
11144
  }, {
@@ -11184,7 +11233,12 @@
11184
11233
  key: "createButtonStyle",
11185
11234
  value: function createButtonStyle() {
11186
11235
  var _a, _b;
11187
- return "\n .paydock-apple-container {\n width: 100%;\n height: 40px;\n }\n\n @supports (-webkit-appearance: -apple-pay-button) {\n .apple-pay-button {\n display: inline-block;\n -webkit-appearance: -apple-pay-button;\n -apple-pay-button-type: ".concat(((_a = this.getMetaStyles()) === null || _a === void 0 ? void 0 : _a.button_type) || 'plain', "\n }\n .apple-pay-button-black {\n -apple-pay-button-style: black;\n }\n .apple-pay-button-white {\n -apple-pay-button-style: white;\n }\n .apple-pay-button-white-with-line {\n -apple-pay-button-style: white-outline;\n }\n }\n\n @supports not (-webkit-appearance: -apple-pay-button) {\n .apple-pay-button {\n display: inline-block;\n background-size: 100% 60%;\n background-repeat: no-repeat;\n background-position: 50% 50%;\n border-radius: 5px;\n padding: 0px;\n box-sizing: border-box;\n min-width: 200px;\n min-height: 32px;\n max-height: 64px;\n -apple-pay-button-type: ").concat(((_b = this.getMetaStyles()) === null || _b === void 0 ? void 0 : _b.button_type) || 'plain', "\n }\n .apple-pay-button-black {\n background-image: -webkit-named-image(apple-pay-logo-white);\n background-color: black;\n }\n .apple-pay-button-white {\n background-image: -webkit-named-image(apple-pay-logo-black);\n background-color: white;\n }\n .apple-pay-button-white-with-line {\n background-image: -webkit-named-image(apple-pay-logo-black);\n background-color: white;\n border: .5px solid black;\n }\n }\n ");
11236
+ return "\n .paydock-apple-container {\n width: 100%;\n height: 40px;\n position: relative;\n }\n\n @supports (-webkit-appearance: -apple-pay-button) {\n .apple-pay-button {\n display: inline-block;\n -webkit-appearance: -apple-pay-button;\n -apple-pay-button-type: ".concat(((_a = this.getMetaStyles()) === null || _a === void 0 ? void 0 : _a.button_type) || 'plain', "\n }\n .apple-pay-button-black {\n -apple-pay-button-style: black;\n }\n .apple-pay-button-white {\n -apple-pay-button-style: white;\n }\n .apple-pay-button-white-with-line {\n -apple-pay-button-style: white-outline;\n }\n }\n\n @supports not (-webkit-appearance: -apple-pay-button) {\n .apple-pay-button {\n display: inline-block;\n background-size: 100% 60%;\n background-repeat: no-repeat;\n background-position: 50% 50%;\n border-radius: 5px;\n padding: 0px;\n box-sizing: border-box;\n min-width: 200px;\n min-height: 32px;\n max-height: 64px;\n -apple-pay-button-type: ").concat(((_b = this.getMetaStyles()) === null || _b === void 0 ? void 0 : _b.button_type) || 'plain', "\n }\n .apple-pay-button-black {\n background-image: -webkit-named-image(apple-pay-logo-white);\n background-color: black;\n }\n .apple-pay-button-white {\n background-image: -webkit-named-image(apple-pay-logo-black);\n background-color: white;\n }\n .apple-pay-button-white-with-line {\n background-image: -webkit-named-image(apple-pay-logo-black);\n background-color: white;\n border: .5px solid black;\n }\n }\n ");
11237
+ }
11238
+ }, {
11239
+ key: "createSpanStyle",
11240
+ value: function createSpanStyle() {
11241
+ return "\n .apple-pay-button span {\n color: transparent;\n position: absolute;\n top: -2px;\n left: -2px;\n right: -2px;\n bottom: -2px;\n border-radius: 5px;\n transition: all 0.3s ease;\n }\n\n .apple-pay-button:focus span {\n box-shadow: -2px 2px 2px 2px rgba(0,0,0,0.3);\n }\n ";
11188
11242
  }
11189
11243
  }]);
11190
11244
  }(WalletService);
@@ -13604,7 +13658,9 @@
13604
13658
  sdk_type: SDK.type
13605
13659
  });
13606
13660
  }
13607
- if (!!AccessToken.validateJWT(accessToken)) {
13661
+ var jwt = AccessToken.validateJWT(accessToken);
13662
+ if (!!jwt) {
13663
+ if (!AccessToken.validateJWTWhitelistedDomains(jwt.body)) throw Error('access Token is not valid for current domain');
13608
13664
  this.link.setParams({
13609
13665
  token: accessToken
13610
13666
  });
@@ -16504,7 +16560,10 @@
16504
16560
 
16505
16561
  var generateApplePayButtonStyles = function generateApplePayButtonStyles() {
16506
16562
  var buttonType = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'plain';
16507
- return "\n .paydock-apple-container {\n display: inline-block;\n width: 100%;\n height: 44px;\n cursor: pointer;\n }\n\n @supports (-webkit-appearance: -apple-pay-button) {\n .apple-pay-button {\n -webkit-appearance: -apple-pay-button;\n -apple-pay-button-type: ".concat(buttonType, ";\n }\n .apple-pay-button-black {\n -apple-pay-button-style: black;\n }\n .apple-pay-button-white {\n -apple-pay-button-style: white;\n }\n .apple-pay-button-white-outline {\n -apple-pay-button-style: white-outline;\n }\n }\n\n @supports not (-webkit-appearance: -apple-pay-button) {\n .apple-pay-button {\n background-size: 100% 60%;\n background-repeat: no-repeat;\n background-position: 50% 50%;\n border-radius: 5px;\n padding: 0px;\n box-sizing: border-box;\n min-width: 200px;\n min-height: 32px;\n max-height: 64px;\n -apple-pay-button-type: ").concat(buttonType, ";\n }\n .apple-pay-button-black {\n background-image: -webkit-named-image(apple-pay-logo-white);\n background-color: black;\n }\n .apple-pay-button-white {\n background-image: -webkit-named-image(apple-pay-logo-black);\n background-color: white;\n }\n .apple-pay-button-white-outline {\n background-image: -webkit-named-image(apple-pay-logo-black);\n background-color: white;\n border: .5px solid black;\n }\n }\n ");
16563
+ return "\n .paydock-apple-container {\n display: inline-block;\n width: 100%;\n height: 44px;\n cursor: pointer;\n position: relative;\n }\n\n @supports (-webkit-appearance: -apple-pay-button) {\n .apple-pay-button {\n -webkit-appearance: -apple-pay-button;\n -apple-pay-button-type: ".concat(buttonType, ";\n }\n .apple-pay-button-black {\n -apple-pay-button-style: black;\n }\n .apple-pay-button-white {\n -apple-pay-button-style: white;\n }\n .apple-pay-button-white-outline {\n -apple-pay-button-style: white-outline;\n }\n }\n\n @supports not (-webkit-appearance: -apple-pay-button) {\n .apple-pay-button {\n background-size: 100% 60%;\n background-repeat: no-repeat;\n background-position: 50% 50%;\n border-radius: 5px;\n padding: 0px;\n box-sizing: border-box;\n min-width: 200px;\n min-height: 32px;\n max-height: 64px;\n -apple-pay-button-type: ").concat(buttonType, ";\n }\n .apple-pay-button-black {\n background-image: -webkit-named-image(apple-pay-logo-white);\n background-color: black;\n }\n .apple-pay-button-white {\n background-image: -webkit-named-image(apple-pay-logo-black);\n background-color: white;\n }\n .apple-pay-button-white-outline {\n background-image: -webkit-named-image(apple-pay-logo-black);\n background-color: white;\n border: .5px solid black;\n }\n }\n ");
16564
+ };
16565
+ var generateApplePaySpanStyles = function generateApplePaySpanStyles() {
16566
+ return "\n .apple-pay-button span {\n color: transparent;\n position: absolute;\n top: -2px;\n left: -2px;\n right: -2px;\n bottom: -2px;\n border-radius: 5px;\n transition: all 0.3s ease;\n }\n\n .apple-pay-button:focus span {\n box-shadow: -2px 2px 2px 2px rgba(0,0,0,0.3);\n }\n ";
16508
16567
  };
16509
16568
 
16510
16569
  /**
@@ -16633,16 +16692,24 @@
16633
16692
  value: function mount() {
16634
16693
  var _this3 = this;
16635
16694
  var _a, _b;
16636
- var style = document.createElement('style');
16637
- style.innerHTML = generateApplePayButtonStyles((_a = this.meta.style) === null || _a === void 0 ? void 0 : _a.button_type);
16638
- document.head.appendChild(style);
16639
- var button = document.createElement('div');
16695
+ var styleButton = document.createElement('style');
16696
+ styleButton.innerHTML = generateApplePayButtonStyles((_a = this.meta.style) === null || _a === void 0 ? void 0 : _a.button_type);
16697
+ document.head.appendChild(styleButton);
16698
+ var styleSpan = document.createElement('style');
16699
+ styleSpan.innerHTML = generateApplePaySpanStyles();
16700
+ document.head.appendChild(styleSpan);
16701
+ var button = document.createElement('button');
16640
16702
  button.onclick = function () {
16641
16703
  return _this3.onApplePayButtonClicked();
16642
16704
  };
16705
+ var text = APPLE_PAY_BUTTON_TYPES_ARIA_LABEL_MAPPING['buy'];
16706
+ var span = document.createElement('span');
16707
+ span.innerText = text;
16643
16708
  button.classList.add('paydock-apple-container', 'apple-pay-button', "apple-pay-button-".concat(((_b = this.meta.style) === null || _b === void 0 ? void 0 : _b.button_style) || 'black'));
16644
16709
  button.setAttribute('tabindex', '0');
16645
16710
  button.setAttribute('role', 'button');
16711
+ button.appendChild(span);
16712
+ button.setAttribute('aria-label', text);
16646
16713
  this.container.getElement().appendChild(button);
16647
16714
  }
16648
16715
  }, {
@@ -329,6 +329,8 @@ declare const SUPPORTED_CARD_TYPES: {
329
329
  SOLO: string;
330
330
  VISA: string;
331
331
  VISA_WHITE: string;
332
+ EFTPOS: string;
333
+ EFTPOS_WHITE: string;
332
334
  };
333
335
  interface IIcons {
334
336
  paypal_checkout_button?: string;
@@ -588,7 +590,7 @@ declare enum WALLET_TYPE {
588
590
  AFTERPAY = "afterpay"
589
591
  }
590
592
  interface ApplePayStyles {
591
- button_type?: string;
593
+ button_type?: 'add-money' | 'book' | 'buy' | 'check-out' | 'continue' | 'contribute' | 'donate' | 'order' | 'pay' | 'plain' | 'reload' | 'rent' | 'set-up' | 'subscribe' | 'support' | 'tip' | 'top-up';
592
594
  }
593
595
  interface GooglePayStyles {
594
596
  button_type?: 'book' | 'buy' | 'checkout' | 'donate' | 'order' | 'pay' | 'plain' | 'subscribe';
@@ -329,6 +329,8 @@ declare const SUPPORTED_CARD_TYPES: {
329
329
  SOLO: string;
330
330
  VISA: string;
331
331
  VISA_WHITE: string;
332
+ EFTPOS: string;
333
+ EFTPOS_WHITE: string;
332
334
  };
333
335
  interface IIcons {
334
336
  paypal_checkout_button?: string;
@@ -588,7 +590,7 @@ declare enum WALLET_TYPE {
588
590
  AFTERPAY = "afterpay"
589
591
  }
590
592
  interface ApplePayStyles {
591
- button_type?: string;
593
+ button_type?: 'add-money' | 'book' | 'buy' | 'check-out' | 'continue' | 'contribute' | 'donate' | 'order' | 'pay' | 'plain' | 'reload' | 'rent' | 'set-up' | 'subscribe' | 'support' | 'tip' | 'top-up';
592
594
  }
593
595
  interface GooglePayStyles {
594
596
  button_type?: 'book' | 'buy' | 'checkout' | 'donate' | 'order' | 'pay' | 'plain' | 'subscribe';